BIRMINGHAM, Ala. -- A man who spent nearly 30 years on Alabama's death row was freed Friday after a decades-long fight to prove his innocence.

Ray Hinton, 58, was released in the morning from the Jefferson County Jail in Birmingham. He hugged family members as he walked out, saying, "Thank you Jesus."

Hinton was convicted of the 1985 murders of two Birmingham fast-food restaurant managers. Crime scene bullets were the only evidence that linked Hinton to the crime. However, prosecutors said this week that modern forensic methods did not show the fatal bullets came from a revolver in Hinton's home, or even from the same gun.

"Every day, every month, every year that the state took from him, they took something that they don't have the power to give back. While this moment is quite joyous and is quite wonderful, this case is quite tragic," Bryan Stevenson, Hinton's attorney and director of the Alabama-based Equal Justice Initiative, said Thursday.

The U.S. Supreme Court ruled last year that Hinton had inadequate counsel and sent the case back for a second trial. Prosecutors had been preparing for a retrial but moved to dismiss the case following the testing on the bullets.

The Supreme Court ruled last year that Hinton had "constitutionally deficient" representation at his initial trial. Hinton's defence lawyer wrongly thought he had only $1,000 to hire a ballistics expert to try to rebut the prosecution testimony about the bullets. The lawyer hired the only person willing to take the job at that price, even though he had concerns about the expert's credentials. At the time, jurors chuckled as the defence expert struggled to answer questions on cross-examination.

Stevenson said he became convinced of Hinton's innocence when he took on the case 16 years ago.

"He was a poor person who was convicted because he didn't have the money to prove his innocence at trial. He was unable to get the legal help he needed for years. He was convicted based on bad science," Stevenson said.