Jens Meyer / AP

Martin Winterkorn, the chief executive of Volkswagen, has resigned amid a scandal involving software that allowed 11 million of the automaker’s diesel vehicles worldwide to cheat emissions tests.

In a statement, Winterkorn said he was “not aware of any wrong doing” on his part, but was resigning in the company’s best interests.

“I am shocked by the events of the past few days,” he said. “Above all, I am stunned that misconduct on such a scale was possible in the Volkswagen Group.”

Winterkorn’s resignation was widely expected, though as recently as Tuesday the CEO said he would stay on. The move came after a crisis meeting held by the executive committee of Volkswagen’s supervisory board.

That panel, in a statement after Winterkorn’s resignation said it expected “further personnel consequences in the next days.” It added a criminal investigation into the scandal may be necessary, and that it was submitting a complaint to the state prosecutors’ office in Brunswick, Germany.

About Winterkorn, the panel said:

The Executive Committee has great respect for Chairman Professor Dr. Winterkorn’s offer to resign his position and to ask that his employment agreement be terminated. The Executive Committee notes that Professor Dr. Winterkorn had no knowledge of the manipulation of emissions data. The Executive Committee has tremendous respect for his willingness to nevertheless assume responsibility and, in so doing, to send a strong signal both internally and externally. Dr. Winterkorn has made invaluable contributions to Volkswagen. The company’s rise to global company is inextricably linked to his name. The Executive Committee thanks Dr. Winterkorn for towering contributions in the past decades and for his willingness to take responsibility in this criticall phase for the company. This attitude is illustrious.

The scandal came to light last Friday when the Environmental Protection Agency ordered Volkswagen to recall about 500,000 cars that were installed with “defeat devices” to cheat emission tests.

My colleague Robinson Meyer explained how those devices worked:

These devices, essentially, let the cars pretend to not break the law. The software could sense when the car was undergoing emissions testing and activate its pollution-control systems accordingly. When the car was being driven during normal use, these systems largely did not activate—making the car a much heavier polluter in real-life than it looked on paper.

With those systems deactivated, the car’s emissions violated the Clean Air Act and California’s state pollution-control regulation.

Then on Tuesday, the automaker said it had installed the “defeat devices” in 11 million cars worldwide—and it would cost about $7.25 billion to fix the deception. Regulators were not amused, and several countries recalled the cars and ordered inquiries. The automaker faces fines of up to $18 billion in the U.S., as well as class-action lawsuits worldwide.

The company’s stock price—as well as its reputation—has taken a beating. But in many ways, it was a scandal of Volkswagen’s own creation. As my colleague Bourree Lam reported, the automaker denied the allegations for years. The only reason it came to light, Reuters reports, was because the EPA and California’s Air Resources Board threatened to withhold certification for Volkswagen’s 2016 diesel model.

We want to hear what you think about this article. Submit a letter to the editor or write to letters@theatlantic.com.