RepairPal is your advocate for car care advice and guidance

Q: P0170 Fault Code on 2004 Mercedes-Benz C230

I keep getting the P0170 fault code for fuel trim malfunction. The first time this fault appeared it also gave a fault code for the oxygen sensor downstream of the catalytic converter. After replacing the oxygen sensor the check engine light (CEL) remained off for several months. Now only the P0170 fault comes on. I read about the cam actuators leaking oil into the wire harness, so I've changed those as well as putting in the isolation wires. I keep cleaning the connectors to the oxygen sensors, cam adjusters and the engine control and there doesn't seem to be any evidence of oil anymore. Not sure what to do next without any fault code pointing to replacing a part. I've also cleaned the air flow sensor with air flow sensor spray, but it looked good, quite a job to get to that. I can only think of changing the up stream oxygen sensor or change out the engine wire harness, I really don't want to change the harness. Any suggestions would be greatly appreciated.
Get a Repair Estimate
Guaranteed by certified locations nationwide. Learn more
RepairPal estimates are guaranteed at over 1,700 quality certified locations nationwide. Learn more
The code P0170 refers to a problem with the computer control of the air fuel mixture. This is called Fuel Trim. Code P0170 means that the Fuel Trim has reached its limit for compensating for a RICH Fuel Mixture. There are several reasons for a rich fuel mixture problem.
I think that the best way to determine the cause of a rich fuel trim is to use a data streaming scan tool. Ihe first thing I look at is the grams/per second that the Mass Air Flow Sensor is reporting. I also look at the barometric pressure and compare it to the altitude of the location of where I currently am. If the pressure is off ( the baro pressure sensor is part of the Mass Air Flow Sensor ) then the whole fuel fuel reference map is way off either too rich or too lean depending on the error. Fuel pressure should also be checked to make sure that it is not too high or that the vacuum line to the fuel pressure regulator has not fallen off or become split. The Oxygen Sensors should set codes if they are defective and usually do on a ' Benz in my experience. Typically when I have harness problems with a Mercedes, I find that the car misfires, idles funny or has non-functioning injectors. there are usually several codes as well ( like 5-10 codes ). If this kind of information is a bit over your head, then I would take your car to a good German Shop who has a good Diagnostic Tech. I used to work for Bosch and now I do Emissions Diagnosis for a living in N Calif. and I find that the work at many dealerships is not very consistent. I recently had to explain to a very, very large Mercedes Dealer how the Diagnostic Module worked on an E-Class. I was shocked that the service department and parts department did not really understand an important aspect of their own product . Good Luck!

A good tool for this is about 10K and up. The factory scanner is 150k The most common problem is the Mass Air Flow Sensor for this code on your model Benz. if you replace this, be sure to absolutely MATCH the part number and only use a Bosch part. NO AFTER MARKET PARTS for this job. Then you need to do a fuel system adaption re-set or the light will come on again. it will take a couple of days of driving for the fuel system to re-learn with no adaption re-set. so the light may come on/stay on with out it for a 2-3 days Best of Luck!
Thank You Dandd for your great answer. Can you recommend a streaming scan tool, model, p/n that isn't too expensive. Also where would I find the correct values for the different parameters that you mentioned. I have the official Mercedes Maintenance Manual CD but have not come across any values for mass airflow or fuel pressure etc, where would I find this information? Or where to find the fuel reference map?

I found that my air filters were really dirty. would changing the filters make the problem go away?
Since your Mercedes has an OBD-II system ( 1996 and later ) you can get a small OBD-II scanner that has a data stream for about $200. We have 1 at the RepairPal office and use it to help employees with their cars, such as the soft ware developers etc. I believe it is sold by MAC Tools. Ask a Mac Tool truck, they would know for sure.
As for the correct values, they are not going to be in a manual. This what I study and take classes for, however, you want to see the LTFT or Long Term Fuel Trim to be as close to 1% positive as possible. As for the Mass Air Flow Sensor, you want to see about 2.5-3.1 grams at idle with a fully warmed up engine under no load, not even in gear. You also want to see that the Air Cleaner element is spotless and has no evidence of any oil. If it does, then most likely the Mass Air Flow Sensor element has been contaminated by oil and though some Techs will try to clean it, I find that the most reliable way to repair this situation is to replace the Mass Air Flow Sensor with, and this is very important, with a part number matched factory Mass Air Flow Sensor. Also replace the Air Filter element and clean the housing. If there is an oil 'blow by' problem, this also has to be resolved, usually a dirty or plugged PCV system, or the new parts will be ruined in short order by the oil.
Thanks for your advice. How do I makes sure I'm replacing the MAS with a matched factory part? I also have a the codes P0335,and P1073 what does this mean? Is this a costly repair for 2001 C320 with 112,000 miles?
Hello. Do you know where to find the w168 MAFS sensor alone? It's a TEMIC 311.874 and as you probably know it's soldered to the ECU. Thanks.
Didn't find what you were looking for?