DETROIT — A federal court judge in Detroit sentenced a former Volkswagen manager Wednesday to seven years in prison and ordered him to pay $400,000 in the company's massive diesel emissions cheating scandal, but Judge Sean Cox made clear that justice has not yet been served.

This photo provided by the Broward County Sheriff's Office shows Oliver Schmidt under arrest on Jan. 7, 2017. Schmidt, the former general manager of the engineering and environmental office for Volkswagen America, was arrested in connection with the company's emissions-cheating scandal. He was scheduled to plead guilty in Detroit Friday, Aug. 4.

Broward County Sheriff, AP

Cox described the ex-manager, Oliver Schmidt, as an opportunist and a significant player in Volkswagen's attempted coverup. But he also noted that "senior management has not been held accountable" in a case that has hurt both consumers who thought they were getting a good product and blue-collar and middle-management workers at VW. He said the VW case "attacks and destroys" the foundation of the country's economic system — the trust between buyers and sellers.

Cox had harsh words for Schmidt, seeing no excuses for the highly educated mechanical engineer. He doesn't suffer from the substance abuse common among criminals, comes from a good family and was well-off financially, with a $130,000 base salary, $40,000 annual bonuses and a net worth of $1 million.

"You saw this attempted coverup of this massive fraud in the United States as an opportunity to impress senior management at VW and therefore advance your career at VW," Cox told Schmidt.

Cox sided with the U.S. Attorney's Office in its sentencing recommendation. The defense, led by attorney David DuMouchel of Detroit, had requested 40 months and a $100,000 fine.

Prosecutors portrayed Schmidt, a German national who will be deported after serving his sentence, as uncooperative. They said he destroyed documents pertinent to the investigation and encouraged subordinates to do the same, lied about his involvement and was a key player in the conspiracy, which cost VW about $17 billion in civil settlements and an extra $4.3 billion to settle criminal charges.

According to court officials, numerous other VW and Audi employees have been charged but remain at large in the case.

The company installed so-called defeat devices, a type of software, on its diesel vehicles that were designed to make the vehicles perform differently in road and test conditions, which led to significantly higher levels of pollution in actual use than permitted. Authorities said VW installed the software on about 500,000 2.0-liter diesel vehicles sold in the United States between 2009 and 2015.

Ben Singer, deputy chief of the local U.S. Attorney's Office criminal division, said Schmidt was the "conduit between the senior people in Germany and the regulators."

He noted that Schmidt briefed former VW CEO Martin Winterkorn directly in July 2015. Singer said Schmidt is not the most culpable person in the case, although he did not disclose who he believes is.

Schmidt's lawyers said he was a 48-year-old engineer with no criminal history who was "less culpable" than others, including co-defendant and engineer James Liang who was sentenced in August to 40 months in prison. They submitted numerous letters from family and friends attesting to Schmidt's character in an effort to convince the judge to consider a lesser sentence.

DuMouchel noted that Schmidt was not the mastermind of the scheme and became involved later than others. He disputed the contention that Schmidt was a decision-maker, portraying him instead as someone who in effect did what he was told. He also disagreed that Schmidt had intentionally deleted documents to keep them secret.

Schmidt pleaded guilty in August to conspiracy and violation of the clean air act, both felonies. A more serious charge of wire fraud was dismissed as part of his plea.

Schmidt worked at Volkswagen's research and development center in Auburn Hills, Mich.,where he was general manager of the company's Engineering and Environmental Office. He was also the automaker's liaison with the U.S. EPA and the California Air Resources Board, and his interaction with regulators and decision not to disclose the existence of the defeat devices were key parts of the case.

In a letter to the judge last month, Schmidt described the humiliation of the ordeal, including having his mugshot become the international face of the scandal, and claims to have been "misused by my own company" and misled by his superiors.

"After reading the government’s discovery during my many sleepless nights in my prison cell, I’ve learned that my superiors that claimed to me to have not been involved earlier than me at VW knew about this for many, many years. In fact, somewhat to my detriment, much of what I now know about what transpired here I learned from reading the discovery," Schmidt wrote.

Schmidt, dressed in a red jail jumpsuit and shackled at the wrists and ankles, also addressed the court Wednesday, noting the hardship of being separated from his family for so many years, including his wife, whom he married in 2010.

But Schmidt, at times breaking down in tears, said he is to blame for the disruption of his life.

"I accept the responsibility for the wrong that I committed," Schmidt said.