Dr Stella Nyanzi collapsed at the International War Crimes Division of the High Court in Kampala on Thursday minutes after the judge order for her release from Luzira Prison where she has been for months.
Dr Nyanzi was last year convicted and sentenced to 18 months for harassing President Museveni.
However, she appealed against the conviction and sentence citing unfairness and that the trial court erred in law.
On Thursday, Justice Henry Peter Adonyo who heard her appeal ordered for her “immediate release” from prison.
The judge noted that Buganda Road trial magistrate, Gladys Kamasanyu had no jurisdiction to convict Dr Nyanzi of cyber harassment.
In addition, Justice Adonyo said no evidence was adduced by prosecution showing the location- of the device- where the offence was committed; either Uganda or out of the country.
“Prosecution did not as well ascertain the kind of device which was used to send as the digital prints were not presented before Buganda road,” the judge observed.
Court also observed that Dr Nyanzi and her lawyers were not allowed enough time to prepare their defence thus amounting to unfairness.
The first prosecution witness did not provide a forensic report on his findings indicating which mobile data was used after he asserted that Dr Nyanzi might have used a phone.
The judge also said that in criminal offences, it is the duty of court to ensure that defense witnesses appear by providing the defendant the favorable avenues like issuing arrest warrants for defence witnesses who are not compliant which the magistrate never did.