Media playback is unsupported on your device Media caption There were cheers as Maryland State Attorney Marilyn Mosby said there was "probable cause to bring criminal charges" against Freddie Gray officers

Baltimore's top prosecutor has announced criminal charges against six officers in the case of Freddie Gray who died in police custody.

State prosecutor Marilyn Mosby said the death of the 25-year-old black man was a homicide, and his arrest was illegal.

The charges range from second-degree murder to assault. But a lawyer for the officers says they "did nothing wrong".

All six officers have been suspended and are now under arrest. Gray's death sparked protests that turned violent.

Ms Mosby told reporters that the findings of an independent investigation, coupled with the medical examiner's view that the death was a homicide, had "led us to believe that we have probable cause to file criminal charges".

Celebrations broke out across Baltimore after the announcement. Drivers honked their car horns as people took to the streets with fists raised in triumph.

Media playback is unsupported on your device Media caption Freddie Gray's stepfather Richard Shipley: "Without justice there is no peace, but let us have peace in the pursuit of justice"

However, a lawyer for some of the officers accused Ms Mosby of an "egregious rush to judgement".

"The officers did nothing wrong," Michael Davey said. He said the officers "at all times acted reasonably and in accordance with their training", and none of them had injured or caused harm to Gray.

At the scene: The BBC's Tara McKelvey in Baltimore

It feels like a party, and it's all happening at West North Avenue and Pennsylvania Avenue - in front of a CVS store that was torched. People have ducked out of work to come here, and they're waving scarves and blaring car stereos and celebrating after hearing the news about charges that will be against six Baltimore police officers.

A woman in tight jeans and black trainers skips across the street, and a moment later schoolchildren walk down the sidewalk and chant: "Freddie! Freddie! Freddie!" Traffic is snarled up, and the air here smells of car exhaust and cigars.

The late afternoon sun feels warm on your skin. Gospel music is playing. "I give myself away," sings someone, "my God is awesome". A truck driver lays on the horn as he barrels through the intersection, pumping his fist up and down.

How did Freddie Gray die?

Who is prosecutor Marilyn Mosby?

Ms Mosby said Gray died as a result of injuries suffered while he was shackled inside a Baltimore police van, but not restrained by a seat belt - as he was legally required to be.

Ms Mosby said the officers failed to provide medical aid to Gray after he repeatedly pleaded for help.

Mayor Stephanie Rawlings Blake said that five of the officers were in custody. The sixth later turned himself in. The officers were suspended after Gray's death.

"No one in our city is above the law," Ms Blake said. "Justice must apply to all of us equally."

Image copyright Getty Images Image caption Baltimore has seen nightly protests since the death of Freddie Gray

Image copyright BBC News

The driver of the van, Caesar Goodson, 45, faces the most serious charge, second-degree murder. Mr Goodson faces more than 30 years in prison if convicted.

The other officers face charges including involuntary manslaughter, assault and misconduct.

"To the people of Baltimore and the demonstrators across America, I heard your call for 'no justice, no peace'. Your peace is sincerely needed, as I work to deliver justice on behalf of this young man," Ms Mosby said.

Ms Mosby said that Gray was not carrying an illegal switchblade as reported earlier by police, but a legal pocketknife.

The police union has defended the officers and said they acted "diligently". The union has called for an independent prosecutor, something Ms Mosby said was not needed.

Image copyright AP Image caption Freddie Gray

After Gray's funeral on Monday, riots broke out in sections of West Baltimore. About 200 people were arrested as more than 100 cars were set alight and 15 buildings destroyed.

Since then, the city and state officials deployed thousands of extra law enforcement officers and National Guard troops to keep the peace and enacted a citywide curfew.

Those measures have brought relative calm to Baltimore as thousands have taken part in nightly protests.

Media playback is unsupported on your device Media caption US President Barack Obama: "What the people of Baltimore want more than anything else is the truth"

President Barack Obama responded to questions about the charges in Washington, saying the legal process should run its course.

"What I think the people of Baltimore want more than anything else is the truth," Mr Obama said.

Ciara Ford of Baltimore expressed surprise at the decision to prosecute.

"I hope this can restore some peace," she told the Associated Press. "If we had kept quiet, I don't think they would have prosecuted."

Gray's death is the latest in a string of high-profile cases where black men have died after contact with the police.

The charges