INDIANAPOLIS (AP) — A Chicago man who was pardoned after spending more than seven years in prison for an armed robbery he didn’t commit has reached a $7.5 million settlement with a northern Indiana city and former police officers, his attorney said Wednesday.

Keith Cooper’s attorney, Elliot Slosar, said it is the largest wrongful conviction settlement in Indiana history and that the lawsuit “exposed the systemic pattern of police and prosecutorial misconduct that exists in Elkhart, Indiana.”

“Mr. Cooper’s wrongful conviction did not happen by accident nor was it an aberration. Through this case, he has paved the way for other wrongfully convicted people from Elkhart to get a fair chance at justice,” Slosar said in a news release.

Lawyers for the plaintiffs and defendants filed notice of the settlement Tuesday in a South Bend federal court. They didn’t disclose the terms of the deal but said the lawsuit would be dismissed with prejudice, meaning it couldn’t be refiled, if payment is made within 45 days.

Corinne Straight, Elkhart’s director of communications, said city officials were aware that there had been a settlement involving Cooper’s lawsuit but that they wouldn’t discuss it publicly until later Wednesday.

Cooper, 54, was pardoned in February 2017 by Gov. Eric Holcomb, who said he believed Cooper had been wrongly convicted in a 1996 armed robbery in Elkhart during which a teenager was shot and wounded. Holcomb cited the state parole board’s support for the pardon, along with the backing of the prosecutor and witnesses in the case.

Cooper was sentenced to 40 years in prison for the robbery, but advances in DNA testing and a nationwide offender database excluded him as the attacker and identified another person.

The Indiana Court of Appeals overturned his co-defendant’s conviction in 2005, and Cooper was given the choice of being released with a felony record or facing a new trial before the same judge who convicted him. He elected to be released in 2006 to go home to his wife and three children, who at times were homeless during his incarceration.

Cooper’s pardon by Holcomb was followed in March 2017 by a judge’s approval of the expungement of his armed robbery conviction.

Cooper had sought a pardon since 2009 and the deputy prosecutor who handled his trial asked then-Gov. Mike Pence in 2015 to approve the pardon to remove the felony conviction.

But Pence’s general counsel notified Slosar in September 2016, two months after Pence became Donald Trump’s vice presidential running mate, that he believed Cooper needed to first exhaust all his options in court for having the conviction overturned before a pardon would be considered.

Cooper sued Elkhart, its police chief and three officers in November 2017, alleging that the officers framed him for the crime and “nearly destroyed his life.”

At the time of his arrest, Cooper had no criminal convictions, was a married father of three and was gainfully employed and providing for his family, according to his lawsuit. But after he was wrongfully incarcerated, the suit said his wife was forced to sell the family’s belongings and had “to live in shelters to survive.”

Cooper’s lawsuit accused the Elkhart Police Department of employing a “routine practice” of pursuing wrongful convictions “through reckless and profoundly flawed investigations” that included false evidence and reports and coerced evidence. It also contended that supervising officers knew of this misconduct but failed to properly supervise those officers.

Rick Callahan, The Associated Press