BALTIMORE (Reuters) - A mistrial was declared on Wednesday in the case of a Baltimore police officer charged in the death of Freddie Gray, a black man whose killing while in custody sparked riots in April, and the city’s mayor urged calm.

Moments before his arrest, activist Darius Rosebrough leads a protest in front of the courthouse in Baltimore, December 16, 2015. REUTERS/Bryan Woolston -

The judge dismissed the jury in the involuntary manslaughter trial of Officer William Porter - the first of six officers to be tried in Gray’s death - after 16 hours of deliberations during which the jurors were unable to reach a verdict on any of the charges against the policeman.

Baltimore City Circuit Court Judge Barry Williams said an administrative judge would schedule a new trial, but said there would be no court proceedings in the case on Thursday.

Gray’s death triggered rioting in the majority-black city of 620,000 people, and intensified a U.S. debate on police treatment of minorities.

On Wednesday, scores of protesters marched through downtown Baltimore following the ruling, chanting “we have nothing to lose but our chains” and “the whole damn system is guilty as Hell.” Uniformed police officers took up positions throughout the city, including by the courthouse and police headquarters, and at least two demonstrators were arrested.

Gray’s family and officials, including Baltimore Mayor Stephanie Rawlings-Blake, called for calm, eager to avoid a replay of the unrest that followed Gray’s death.

“We ask the public to remain calm and patient,” said Gray’s stepfather, Richard Shipley. “We are confident there will be another trial with a different jury. We are calm; you should be calm too.”

Rawlings-Blake, who is black, said, “Our reaction needs to be one of respect for our neighborhoods. In the case of any disturbance in the city we are prepared to respond.”

Porter, 26, was charged in Gray’s death from a broken neck suffered while the 25-year-old man was transported in the back of a police van.

The jury of five men and seven women had said on Tuesday that it was deadlocked, but Williams had told them to keep trying to reach a verdict.

Porter, who like Gray is black, was charged for having put Gray in the back of the van without seat-belting him and with being too slow to pass on his request for medical assistance.

The officer’s attorneys had argued that Porter may have been unaware of department policy mandating that detainees be seat-belted, which was put into place shortly before Gray’s arrest.

Baltimore officials had come under heavy criticism for a restrained initial response to the rioting, which some observers contended allowed arson and looting to spiral out of control.

The death and its aftermath followed the police killings of black men in cities including Ferguson, Missouri, and New York, which also sparked protests, helping to spark the growth of the Black Lives Matter movement.

LEGAL EXPERTS WEIGH IN

In addition to involuntary manslaughter, Porter had been charged with second-degree assault, reckless endangerment and misconduct in office. The charges against the other officers range from second-degree murder for the van’s driver, to misconduct.

Gray was arrested after fleeing from police. He was put in a transport van, shackled and handcuffed, but was not secured by a seat belt, in violation of department policy. He died a week later.

Slideshow ( 23 images )

Porter testified Gray told him he needed medical aid. Porter told the van’s driver and a supervisor that Gray had asked for aid but none was summoned, according to testimony.

The defense argued that Porter did not believe Gray was seriously injured until the van’s final stop. His lawyers have said that Porter acted as any reasonable officer would have.

Warren Brown, a Baltimore defense lawyer who was in the courtroom, said he was not surprised by Wednesday’s decision.

“I think you will have the same scenario with the other trials,” Brown said.

Seven jurors were black and five were white.

Another legal expert said he was surprised to see a mistrial declared on just the third day of deliberations.

“I thought the judge would never declare a mistrial absent a fistfight until the jury had been deliberating for six or seven days,” said Jim Cohen, a professor at Fordham Law School in New York. “They chose the wrong defendant to try first.”

Odessa Rose, a 49-year-old Maryland state employee, also said she was not surprised by the outcome. “I knew it was going to be hard on both sides. It was a difficult case; it was hard. I feel for the state and I feel for the family of Freddie Gray,” Rose, who is black, said outside the courthouse.

Asked if she thought there would be violence, she said, “I hope not; I don’t think so. I think people learned from last time.”