Weapons charges against pop star-turned-politician Bobi Wine dropped by military court but he’s now accused of treason.

Robert Kyagulanyi, a musician-turned-MP whose arrest prompted protests in Uganda, has been charged with treason.

The indictment at a civilian court on Thursday came shortly after military prosecutors dropped weapons possession charges against Kyagulanyi, who is better known by his stage name, Bobi Wine.

There were scenes of celebration as the court dropped the weapons charges, and supporters were seen hugging the pop star. But he was rearrested moments later.

A civilian magistrate ordered Kyagulanyi remanded in custody until August 30 and granted him access to private doctors citing the “health of the accused”, according to footage broadcast on state channel UBC.

Kyagulanyi has been under military custody since August 14 for allegedly leading a group of people to pelt Ugandan President Yoweri Museveni‘s convoy with stones ahead of a by-election in a northern town.

Kyagulanyi was beaten while in detention, family members said. The Ugandan government called assault accusations “rubbish”.

The court ordered he be held in the northern city of Gulu, about 330km north of the capital, Kampala.

{articleGUID}

It was the first time the legislator had been seen in public since his detention. Walking with a limp, he clenched his fists and greeted supporters.

“The bogus charges have been dropped,” lawyer Medard Sseggona told local broadcaster NBS. “They claim they prefer charging him with the more serious offence of treason.”

The popular musician has emerged as an influential critic of Museveni after winning a seat in parliament last year.

‘A lot of pain’

Kyagulanyi had been arrested with four other opposition MPs, three of whom also face treason charges. A fifth legislator was hospitalised with injuries allegedly sustained during detention.

Al Jazeera’s Catherine Soi in Kampala reported Kyagulanyi looked physically unwell.

“He appears to be very weak and in a lot of pain. He has been having difficulties getting up from his chair,” she said.

Dozens of other Ugandans have been charged with treason and illegal possession of firearms over their alleged role in the stoning of the president’s convoy after a local election rally.

In recent days, Uganda’s government has faced pressure to free Kyagulanyi, with dozens of musicians around the world speaking out against his alleged beating in detention.

“This has backfired [against the government], many are demonstrating against Museveni,” Joseph Ochieno, an African affairs commentator, told Al Jazeera.

“Lawyers, organisations, actors and actresses, are beginning to take interest in Uganda, perhaps rather too late but we are here,” he added.

Security forces in recent days have violently put down street protests by Ugandans demanding his release. Scores were arrested in riots in Kampala on Monday, and video by local broadcasters showed men in military uniforms beating people, including at least two journalists.

Ugandan police also arrested two opposition politicians on Thursday for defying police orders not to leave their homes.

Kizza Besigye, who contested and lost four elections against Museveni, and Kato Lubwama were taken to police detention facilities, police spokesman Emilian Kayima said.

Earlier, police surrounded the homes of several opposition politicians, saying they had been placed under “preventive arrest” to try to stop unrest.

“These guys are rattled, because they know they are losing the support of the people, and anything could happen, ordinary Ugandans will simply say enough is enough,” Ochieno said.

{articleGUID}

#FreeBobiWine

In a statement made on Wednesday evening, Museveni accused “unprincipled politicians” of luring youth into rioting.

Responding to calls on social media to #FreeBobiWine, the president said he had no power to do so. “Let us therefore wait for the courts and see what they decide,” Museveni said.

Museveni took power by force in 1986 and has since been elected five times. Although he has campaigned on his record of establishing peace and stability, some worry those gains are being eroded the longer he stays in power.

The 74-year-old is now able to seek re-election in 2021 because parliament passed legislation last year removing a clause in the constitution that had prevented anyone over 75 from holding the presidency.