FILE PHOTO - A U.S. flag flutters in the wind above a Volkswagen dealership in Carlsbad, California, U.S. May 2, 2016. REUTERS/Mike Blake/File Photo

WASHINGTON (Reuters) - Volkswagen AG VOWG_p.DE is set to plead guilty on Feb. 24 in Detroit to three felony counts as part of a plea agreement with the U.S. Justice Department to resolve an excess diesel emissions investigation, a court filing shows.

As part of a $4.3 billion settlement with U.S. regulators, the German automaker has agreed to sweeping reforms, new audits and oversight by an independent monitor for three years to resolve diesel emissions cheating investigations.

Under the settlement of charges it installed secret software in U.S. vehicles to allow them to emit up to 40 times the amount of legally permitted pollution, Volkswagen agreed to change the way it operates in the United States and other countries.

The Justice Department charged VW with conspiring for nearly 10 years to cheat on diesel emissions tests. The German automaker agreed to pay $4.3 billion in U.S. civil and criminal fines.

In total, VW has now agreed to spend up to $22 billion in the United States to address claims from owners, environmental regulators, U.S. states and dealers, and offered to buy back about 500,000 polluting vehicles.