A hung jury has been declared in the trial of William Porter, the first of six Baltimore police officers to go on trial in the death of 25-year-old Freddie Gray, who was fatally injured in a police van in April.

The jury told Judge Barry Williams on Wednesday that it couldn't reach a unanimous decision on any of the four charges against Porter, a day after they said they were deadlocked and urged to continue deliberations.

Williams thanked jurors for their service and dismissed them, saying, "The court finds you are a hung jury."

Legal analyst Warren Brown said he was not surprised the jury was hung.

"When you look at the law, which calls for a callous mindset, a callous disregard for human life ... they said that it's just not there," he said.

Some protesters gathered outside the courthouse after the announcement, chanting “What do we want? Justice! When do we want it? Now!” and “if we don’t get it, shut it down!” Protests immediately after the verdict centered around TV cameras near the courthouse. The rest of the downtown area seemed calm, video taken from Chopper4 showed.

The Gray family will speak at the courthouse at 5 p.m., family attorney Billy Murphy said.

Porter May Be Tried Again by a New Jury

Porter may be retried by a new jury. Attorneys will appear in front of an administrative judge Thursday to possibly pick a date for a retrial.

Porter was charged with manslaughter, second-degree assault, reckless endangerment and misconduct in office in the April 19 death of Gray, who died a week after his neck was broken during a ride in the back of a police van.

Five other officers are also facing various charges, the most serious of which is second-degree "depraved heart" murder in the case of Officer Caesar R. Goodson Jr., who was driving the van. His trial, the next on the calendar, is scheduled for January.

During Porter's trial, prosecutors claimed Porter was criminally negligent for ignoring a policy requiring officers to strap prisoners in with a seat belt and for not calling an ambulance immediately after Gray indicated he needed medical aid.

The wagon "became his casket on wheels," prosecutor Janice Bledsoe said during her closing argument. Porter "just didn't care enough," she said.

But Porter and other witnesses testified that it was Goodson's responsibility to buckle Gray into the seat belt, and the defense said the prosecution's case was based on speculation and called Gray's death a "horrific tragedy."

"There is literally no evidence" that Porter's actions in any way caused it, the defense argued.

The mistrial was declared a day after jurors first informed Williams that they were deadlocked. On Tuesday afternoon, the judge told the jury it was their responsibility to reach a verdict, and asked them to continue deliberating. The jury resumed work and left for the day without a verdict Tuesday.

The 12-member jury was comprised of four black women, three white women, three black men and two white men.

Calling for Order in Baltimore

Moments after a mistrial was declared, Baltimore Mayor Stephanie Rawlings-Blake called for peace.

"Twelve Baltimore residents listened to the evidence presented and were unable to render a unanimous decision. As a unified city, we must respect the outcome of the judicial process," she said in a statement posted on Twitter.

"In the coming days, if some choose to demonstrate peacefully to express their opinion, that is their constitutional right," Rawlings-Blake continued. " I urge everyone to remember that collectively, our reaction needs to be one of respect for our neighborhoods, and for the residents and businesses of our city. In the case of any disturbance in the city, we are prepared to respond. We will protect our neighborhoods, our businesses and the people of our city."

Maryland Gov. Larry Hogan said via a representative, "the administration respects the legal progress that is currently underway and will continue to monitor activity in the city," the governor's office told WTOP.

In the days leading to the end of the trial, the city began preparing for the possibility of unrest similar to the riots that left parts of West Baltimore in chaos in April. A number of groups took to the streets of Baltimore following Gray's death, including members of the ever-growing Black Lives Matter movement.

The demonstrations were peaceful for several days, but on the day Gray was buried, looting began. Some businesses were burned down. At one point, Maryland Gov. Larry Hogan declared a state of emergency and deployed the National Guard. The city also was placed on a 10 p.m. curfew, which was lifted May 3.

The troubles forced Rawlings-Blake to end her re-election campaign, toppled the career of Baltimore police commissioner Anthony Batts and increased scrutiny nationwide of how minorities are treated by police.

Earlier this week, Rawlings-Blake called for people to respect the jury's decision. She also announced the opening of an emergency operations center as a precaution so that authorities can coordinate any necessary response.

The calls for peace ahead of Porter's verdict have also reached the White House.

A reporter asked spokesman Josh Earnest at a Monday briefing whether there was a message from the White House to people in Baltimore. Earnest said President Barack Obama's comments after Chicago police recently released video of the fatal shooting of 17-year-old Laquan McDonald were relevant. Earnest says the president was proud of how the community responded with a "forceful but peaceful display of concern."

Earnest says the administration is "hopeful that as activists and individuals in other communities have similar concerns to express, that they do so peacefully."

Preparing for the Outcome

Baltimore's mayor said in a letter to community leaders that she has "no doubt" city officials are prepared for anything, and that the city is also communicating with outside law enforcement agency partners.

Baltimore Police Commissioner Kevin Davis, who replaced Batts, also called for the city's officers to continue their commitment to protect and serve.

"Regardless of the outcome of this trial or any future trial, we refuse to surrender to the low expectation of those who wish to see us fail," Davis said in a letter to the police department.

Davis also canceled leave for all officers through Friday, saying "the community has an expectation for us to be prepared for a variety of scenarios."

Armored vehicles and police were stationed around the city ahead of the verdict.

Maryland State Police had troopers and large vehicles, including a Humvee, in a park Tuesday afternoon near The Maryland Zoo. There were also reports of officers with helmets and shields.

Officers from other jurisdictions have also offered their help. Lori Boone, a spokeswoman with the Howard County Police Department, says the county has officers prepared to assist. The Carroll County Sheriff's Office also is prepared to help.

Baltimore Police spokesman T.J. Smith said officers from out of town and tactical equipment will be used only "if absolutely necessary."

Students in the city's public schools have also been warned to avoid participation in any response that leads to destruction.

Baltimore City Public Schools Schools CEO Gregory Thornton said Monday that schools will facilitate student expression but warned of consequences for "walkouts, vandalism, civil disorder and any form of violence."

Some school systems in the surrounding area have canceled field trips to Baltimore.

Baltimore County Public School spokesman Mychael Dickerson said Tuesday that the school system is postponing, and in some cases canceling, field trips and events in Baltimore city through Friday.

Schools in Harford and Howard counties have also canceled field trips, The Baltimore Sun reports.

Stay with NBCWashington.com for more details on this developing story.