Following on from Closed Loop Tuning, here's a bit of a spill about fuel trims! Modern factory computers are pretty clever and can automatically adjust the motor's tune in response to an array of environmental variables. There are a number of articles out on the interwebs about fuel trims but I'll have a whack at explaining it!
Let's have a closer look at fuel trims, what affects it and what can you do to help smooth it out on your tune!
Fuel Trims are adjustments that a Engine Control Unit (ECU) applies to compensate in changes in environmental variables to ensure the motor remains on its factory base map (usually stoich) in the 'Closed Loop' mode.
Closed loop is when the ECU is using an O2 sensor to get an air/fuel ratio reading from the exhaust to determine whether the motor is running in accordance with the base map. 'Open Loop' is when the ECU is relying solely on the base map for fueling and fuel trims are not applied. The ECU is in closed loop when the O2 sensor is sufficiently warmed up (needs to be at a working temperature to work) and utilised throughout the entire RPM range under partial throttle including idle and cruising. During start-up, when the O2 sensor is still 'cold', the ECU cannot trust the O2 sensor signals yet so it relies on the base map for fueling levels; hence the ECU would be in Open-Loop. The ECU also goes into open-loop in Wide Open Throttle (WOT) as the changes in O2 readings are too rapid to use as a suitable data source as well as in 'off-throttle' deceleration (in many cars).
Factory and standalone computers have fuel trim capabilities but piggy backs usually don't as it requires other inputs and more sophisticated mappings which defeat the purpose of having a simple (and cheap) piggy back computer.
What affects Fuel Trims?
The environmental variables that affect fuel trims include intake air-temperature, water temperature, oxygen (O2) readings, air flow readings and Manifold Absolute Pressure (MAP). Different computers may also use other environmental variables (e.g. Exhaust Gas Temps (EGT), ignition, cam/crank sensors), but to get a general feel for fuel trims, we'll look at these guys:
Intake air-temperature: as temperatures rise, the ECU can compensate by adding more fuel to cool the intake charge to keep the motor at stoich or the factory map.
Water temperature: if temperatures are too low (cold), the ECU can actually cause the motor to run slightly lean to increase cylinder temperatures and hence increase water (coolant) temperatures. If temperatures are 'normal' or 'hot', the ECU usually shouldn't need to adjust fueling (please correct me if I'm wrong!).
O2 sensor readings: This is the primary mechanism for fuel trims. As explained earlier, deviations in O2 readings from the base map gets trimmed. If exhaust gases are detected as being too fuel rich, the ECU can adjust fueling to bring it back to the factory map value (usually stoich); likewise if the exhaust is too lean.
Air flow (MAF) / MAP: these guys are the primary loads (reference points) of ECUs. Technically, fuel doesn't get trimmed because of these, rather, the changes in these affect fuel delivery, which in turn affects the O2 sensor readings and deviations from the base map gets trimmed accordingly. So if you increase MAF / MAP, you move the break point in the computer's map, and then from the increase in fuel detected by the O2 sensor, the computer trims that fuel back to base map value.
The cool thing with fuel trims is that as the environment changes, the ECU automatically compensates and always has your motor running as close as possible to its base map. If it gets too cold, the ECU adjusts, if it gets too hot, the ECU adjusts.. Clever!
The problem surfaces when you want to adjust the ECU's base map for turbo applications. It's not a problem for a standalone computer as you have direct access to the map. It's the primary problem of piggy backs as you are trying to adjust the map indirectly by feeding different signals to the factory ECU. Its the number one cause of having your tune 'disappear' on you!
Short-Term and Long-Term Fuel Trims
Before we get into fuel trim management, let's have a look at the two types of fuel trims; short-term and long-term. If you hook up your factory computer to a scan tool you should be able to find these trim values.
Short-Term Fuel Trims (STFT) are immediately applied compensation values that the ECU actions in response to changes in environmental variables. These adjustments are applied quickly in real-time and done many times per second. If the ECU has to continuously apply compensation values to the same breakpoint, it eventually 'learns' that there is a lean/rich spot and semi-permanently records that trim as Long-Term Fuel Trims (LTFT). So long-term fuel trims are semi-permanent adjustment to the base map, while short-term fuel trims are adhoc adjustments to the base map. It's semi-permanent as you can reset these trims by resetting the factory ECU (full power-down).
It is common to see the ECU trim out fuel in response to environmental variables, here is an example:
No change.
STFT: 0
LTFT: 0
Increase in fuel detected by O2 sensor, mixture too rich.
STFT: -6
LTFT: 0
Mixture normal again.
STFT: 0
LTFT: 0
Increase in fuel detected again by O2 sensor, mixture too rich.
STFT: -6
LTFT: 0
Increase in fuel detected again by O2 sensor, mixture too rich.
STFT: -6
LTFT: 0
Due to constant trimming down of fuel, ECU adds long term adjustment.
STFT: -3
LTFT: -3
Mixture normal again.
STFT: 0
LTFT: -3
Increase in fuel detected again by O2 sensor, mixture too rich.
STFT: -3
LTFT: -3
Increase in fuel detected again by O2 sensor, mixture too rich.
STFT: -3
LTFT: -3
Due to constant trimming down of fuel, ECU adds long term adjustment:
STFT: 0
LTFT: -6
Mixture normal again.
STFT: 0
LTFT: -6
Mixture normal again.
STFT: 0
LTFT: -6
From the example above, you can see that the STFTs gets applied immediately and can fluctuate quite rapidly. LTFTs however don't change as rapidly and the increments are usually quite subtle.
Tuning Fuel Trims
So how can we 'manage' fuel trims in your piggy back tune?
Fuel trims usually become a problem in boost situations when you want to have a richer air fuel ratio than the factory base map. Open-Loop isn't a problem as the ECU is ignoring the O2 sensor and is running purely on the base map. The output of that map is usually consistent and doesn't fluctuate as there are no fuel trims applied. Closed-loop, is where the action is!
Once you've sorted out your Open-Loop tune (usually WOT) you can start venturing through the wondrous world of closed-loop tuning. The requirement for close-loop tuning is usually during partial throttle where boost is already building.
The primary way of compensating for the increase in fuel delivered by the piggy back fuel map is to adjust the O2 sensor reading that gets sent to the factory ECU. For the AEM FIC, the AEM team have already compiled instructional videos for both narrow band and wide band O2 sensors (note that the 1NZFE uses narrow band).
I used their guide to construct a basic O2 map but from then on, it was a long and iterative process in order to get a stable tune. Tuning the O2 map to stabilise fuel trims will take a nice chunk of your time as the factory ECU can behave very... Naughtily. But persevere!
Here are some tips for O2 tuning:
- Make sure you motor is warm/hot and that fuel trims have settled (i.e. not too much fluctuations in STFT). If you don't, you'll be trying to tune out trim that the ECU is compensating for start-up temps.
- Adjust the O2 map in small increments. The voltage range of some O2 sensors are quite narrow and a little adjustment could create large changes.
- An external wideband Air/Fuel Ratio (AFR) meter is KING. Make sure you reach your target AFRs! No point in stabilising trims if you are running too lean/rich. Stabilise the trims to HOLD your AFR!
- Tune to stabilise LTFT! Don't worry so much about STFTs as the factory ECU will always be compensating for something. If you can stabilise the LTFTs to +/- 5 or so, then you've pretty much stabilised STFT (remember how they are related?).
- Positive fuel trim means the ECU thinks the motor is running lean and is adding fuel.
- Negative fuel trim means the ECU thinks the motor is running rich and is removing fuel.
- STFTs are considered 'additive' as it adds a factor to the base map.
- LTFTs are considered 'multiplicative' as it multiplies a factor the the base map.
- Make your cell transitions as smooth as you can, large jumps between cells has the potential to confuse the factory ECU.
- Tune as much as you can for one day, then leave it for a couple of days. LTFTs can take several drives before it becomes locked in. Once it gets locked in, then you'll have an indication on where you need to go with STFTs.
- If you get absolutely stuck and cannot adjust the trims any further, you can try to amend the MAF map, but make absolutely sure that your fuel map is in order by checking your wide band air/fuel ratio.
When I was tuning the O2 map, I would warm the motor, make the adjustments to the point that trims were stable or when I got sick and tired of it. I then stopped tuning and just monitored trims for the next day or so. With the 'updated' LTFTs I could see where in the RPM and MAP range I needed to tune, I would then make the adjustments and just monitor trims again for another day.
The more you tune O2, the more you get to know the behaviour of the factory ECU. Eventually, you'll be able to predict what state it is in and what it could do next. By this time, your trims should be stable 'enough' and that the trim behaviour is predictable. At this point, you can call it a day.
Remember, piggy back tuning is unfortunately not an accurate art. If you can tune it to almost +/- 5, 6, 7 or even 10 LTFT, then that's good enough! When the weather changes, all those trims will get mucked up anyway!
And just to reiterate... Your wideband AFR is KING!! Stabilise your LTFTs to HOLD your target AFR! Don't just tune to stabilise your trims!
O2 tuning requires a crap loads of patience, numerous days of tuning runs and the aim for stability rather than outright performance.
Good luck!
I have a question on this.. What do you do if you cannot read the STFT and LTFT's Like on an older Toyota where the diagnostic equipment is not available apart from Toyota garages themselves. Are there any ways to interpret the trims or is it a case of you cant so guess?
ReplyDeleteThanks!
That's a good question! Unfortunately you'll have to fall back to the "truth" which is the actual readings on an external air/fuel ratio gauge. You'll have to base your tune around that but the annoyance is that you don’t know when and where on the RPM scale the factory computer adjust fuelling. You could be perfect one run, but on second run it could run too rich or lean because the factory computer may have already applied a short term trim level on the first run, but didn’t get saved to long term fuel trim. It’s difficult to guess what the factory computer does because it takes a heap of engine parameter inputs (e.g. RPM, TPS, temps, CAM angles etc) then computes a fuelling strategy but the changes in each input may not correspond to a linear fuelling output from the computer, if that make sense. So some tips to tune without trim information, but just would like to reiterate how difficult it is:
Delete1. Allow the motor to warm up. Keeping with your base tune, do a number of runs then shutoff the engine. This allows the computer to possibly save a “baseline” of trims.
2. Then adjust your tune, warm the engine again and do a few runs. Take note of AFRs. Shutdown the engine once more to allow the computer to “learn” (i.e. save the adjusted trims).
3. Keeping with that tune, warm up the motor and do a run. Check your AFRs (or other data) against the run immediately after adjusting your tune. Was it rich? Was it lean? That at least gives you an indicator of whether the computer is adding/trimming fuel. Then you can adjust your O2 map to try to compensate.
Try your best anyway, but after trial and error you should be able to get a stable enough tune. Try to work with the factory computer and allow it to adjust fuel in response to changes in environmental variables, but remember, this is just for closed loop which means partial throttle, medium RPM; only a concern during initial acceleration. Full pedal to the metal, wide open throttle should have the computer in open loop and the piggyback in full control of fuelling. Good luck and all the best!
Thanks for that! Ill give it a go anyway :)
ReplyDeleteI was thinking about avoiding having to map closed loop altogether by using the FIC's vtec switch to activate a relay to disconnect the lambda forcing it into open loop, or fool the ecu into thinking im at WOT by using one of the analog outputs to show a set voltage when it reads boost.
Its a bit crude but if i cannot get the tune right without knowing the fuel trims i will have to to give one of those ideas a go!
Also i saw your internal map sensor failed. One check i found was to blow through the vacuum pipe into the fic.. obviously you shouldnt be able to blow through it. If you can the connection comes loos just inside as its held on with a cable tie and an plastic nut (which comes loose and alloys the pipe to disconnect itself inside the unit.
Thanks again!
Yup! Although crude, if you can get those methods to work, then it's all good! It may throw a Check Engine Light (CEL) if the factory computer gets confused, but at least it's doing what you need it to do!
DeleteThanks heaps for the tip regarding the FIC internal map sensor! I actually disassembled the FIC to check just that and found everything honky dory.. Tried giving it a clean with some IPA but to no avail.....
Sorry for bringing up old post. I too am thinking of going through the relay route. I've tested my stock vehicle with the narrowband o2 disconnected and everything works fine with no CEL. WOT and everything works fine except part throttle mileage will be terrible as the ECU was unable to maintain stoich since O2 disconnected hence keeping it in open loop. Granted it may not be the case for other cars.
DeleteI just installed a supercharger on my daily, so it's not a track truck and I won't be racing it down the road, so I'd like to keep my AFRs at stock 14.7 and trims close to 0 to keep the ECU happy; I don't want to work against it obviously. My question is, since me and the ECU share the same goal, can I adjust trim solely using the fuel map and not even touch the MAF and O2 maps? The ECU will be adding fuel anyway since the the supercharger is adding more air, so if the ECU adds X% of fuel at a given load, can I just add that same amount of fuel at the same load to zero out the trim without touching the other maps? Am I correct in my logic? Thanks!
ReplyDeleteI just installed a supercharger on my daily, so it's not a track truck and I won't be racing it down the road, so I'd like to keep my AFRs at stock 14.7 and trims close to 0 to keep the ECU happy; I don't want to work against it obviously. My question is, since me and the ECU share the same goal, can I adjust trim solely using the fuel map and not even touch the MAF and O2 maps? The ECU will be adding fuel anyway since the the supercharger is adding more air, so if the ECU adds X% of fuel at a given load, can I just add that same amount of fuel at the same load to zero out the trim without touching the other maps? Am I correct in my logic? Thanks!
ReplyDeleteHey SC, great question!
DeleteAlthough most ECUs will try to keep AFRs at 14.7 during idle, depending on the car and tune, at certain loads, the ECU may be pre-programmed to run a different AFR (e.g. more rich/lean during load).
The main issue is really the MAF sensor. When running boost, it's not accurate enough to see the extra air in the motor when compared with a Manifold Absolute Pressure (MAP) sensor. So with a MAF sensor the ECU may not see the extra air and won't add any more fuel. If you add more fuel, the ECU would see this (via the O2 sensor) but the MAF reading says there's no extra air so it will trim that extra fuel out.
It's really tricky behaviour.
I understand your logic; if you add more fuel, it should get burnt up with the extra air and the O2 sensor should read "normal"; but this isn't always the case. For safety, I usually like to run it a bit rich in boost which means the O2 sensor will definitely sense rich fuel from the exhaust. So you'll definitely need to adjust the O2 map to compensate.
But hey, why not give it a go anyway? Make sure you have a Wideband AFR gauge (which you can link to your AEM FIC software) and see what happens to your trims. Once you understand your particular ECU's behaviour you can then adjust as you go.
Do let us know if you were able to tune just with fuel! That would be interesting indeed!!
Good luck!
I gave it a go and it actually worked extremely well in vacuum to tune just with fuel (AFR is at 14.7 and ltft are staying at .8 at idle and cruise which surprised me haha) but in boost it is exactly as you described in your answer. It doesn't realize that there's a lot more air coming in than it thinks, so it is compensating. I will be trying a fix in the morning!
DeleteThank you so much for all these articles! I've learned so much after studying them all for hours and hours haha they've been a huge help and I'm sure all of us, not just me, appreciate them!
Aww thanks so much SC! I'm so glad that these ideas help others as much as it did with me! And now with your contribution, it'll expand our understanding even more! Thank you again and good luck with it!!
DeleteHi,
ReplyDeleteIam running emanage ultimate which has autotune function and also has wideband sensor integrated to the emanage ultimate. Just wondering if i would like to be in close loop while crusing, i just could use the autotune feature to make the AFR at 14.7. Would it affect my LTFT or STFT with my narrowband o2 sensor unplugged.
Hi Aliff! So closed loop means that the factory ECU is using the factory narrowband determine fuel and timing. If you autotune to 14.7 AFR on the piggyback eManage, it should make your motor run 14.7. However, it's hard to tell what the factory ECU will be doing. On the narrowband it should show 14.7 as well, but because it is not as accurate as a wideband, there will be fluctuations. These fluctuations will cause changes ins STFTs. If the fluctuations are constant and persistent, the ECU will lock this into the LTFTs. You know what? Give it a go! See whether you do get lots of changes in your trims. Just make sure you monitor your real AFRs through the wideband. Check your trims every four or so drives to allow the LTFTs to accumulate. Who knows, you might be fine! Good luck and let us know how you go!
DeleteSo ive manage to replace my NB with WB with afr target map. It sorta works, the key of having 14.7 afr while crusing is to play with the feedback cycle. Currently the afr fluctuates between 14.5-15.2 which is close to NB o2 sensor (14.6-15.1). My current feedback setup is 175ms. The only issue with the setup is when the pedal suddenly depressed, the afr goes lean for a sec. Still doing some trial and error to sort this out.
ReplyDeleteWith the NB o2 sensor removed, iam wondering whether the stock ecu retards its timing. I couldnt do some dataloging due to crappy laptop battery.
Another thing is the idle, at first i set the afr target includes the idle map, but after reading around, emanage will alter the map (rich/lean) during cranking thus making startup PITA. So ive just use manual idle map.
Setup
Start afr target: 1.5krpm
Feedback cycle: 175ms
Feedback amount:1%
Delay start 20sec
If i could share my afr target map, maybe you could provide some input
Hey Aliff! Well done! Indeed, when you are cruising in closed loop, the factory ECU should be in control, the trick is to get it to respond immediately when the pedal is depressed and you begin to go into boost. When you cruise, the turbo is already spooling and it is easier to build up boost, so be careful if your wideband reads stoich or lean.
DeleteMy mentality with regards to piggyback tuning is to let the factory ECU control "everything", BUT when we approach boost and during boost, let the piggyback computer do the work. The tricky thing with replacing your narrowband is that the factory computer no longer has that input. It's like it's lost its arms. So the piggyback needs to do more work and provide it with the right inputs for certain conditions. It can work though, as you have proven! Just as long as you give it the correct limbs (inputs). Do you data logging and see how you go, it takes a few drives before you get any meaningful data.
Idle is probably the more easier thing to tune as you can just sit there and check that you hit stoich. But yes, you are right, that map and those breakpoints are only useful in idle. You need to also look at the breakpoints where the motor starts and determine whether you need to richen or lean up those values. Those breakpoints are in the vacuum vs. 0 rpm (low rpm) values.
Ha! I can't comment on your AFR target map..! I think it will be a great learning experience for you to understand it and see how your motor responds. I believe each car is an individual.
Do your changes incrementally and monitor all the way. Back off if the numbers don't meet your intentions!
Let us know how you go! You've taken lots of great steps in setting up your tune the way you want.
Good luck!
Thank you for tips, I didn't take consideration of when pedal is depressed suddenly when in boost. Current ideal setup is using TPS vs AFR target as it is much more stable rather than Pressure vs AFR target. As i wont use AFR target during boost, it wouldnt be a problem to use TPS vs AFR target(its to reduce risk if the WB went kaput during WOT).
ReplyDeleteOwh yesterday i went a drive hour an hour just to get all the data based on the AFR gauge. Datalog is not an option, laptop just wont stay up more than 10 minutes. With my latest setup, it much more precise and the highest afr is at 16. And after a while, it got me thinking, maybe emanage could'nt see afr input as 14.7 from the wideband, thats why i couldnt tune the idle at 14.7, maybe need to re-apply the idle at lower afr target.
Well the reason iam going to this path is due to my NB was faulty and its hard to get a new titania type o2 sensor and why not just use the WB for close loop function during cruising only. This also could provide solution for LTFT issues for piggyback system. The current setup is as per below list:
Setup
Start afr target: 1.5krpm
Feedback cycle: 200ms
Feedback amount:1%
Delay start: 20sec
MAP: TPS vs AFR Target
AFR target RPM: from 1.5kprm to 4krpm
TPS: 3 to 35%
The setup may change for close loop idle operation.
So here's my current conclusion for this setup as i may revert back to NB input for close loop operation:
Pros:
1. No more LTFT interfere with WOT tuning MAP.
2. Reduce OEM sensor to ECU for standalone like operation.
3. Able to run leaner/richer while cruising as per AFR target MAP.
Cons:
1. slower close loop feedback due to piggyback need to calculate the appropriate fuel trim to achieve desired target.
2. Trial and error method to gain the best output.
3.Need to closely monitor afr.
Current Map use below as reference.
http://www.vvwc.ca/albums/album23/TargetAFR_2_001.jpg
Hi Aliff! Ah that's challenging as your narrowband sensor is not operational.
DeleteYes, throttle position tuning is an option but only on a portion of your tuning map as it is not very accurate in determining whether you are tuning in boost or vacuum. I think you are limiting your TPS tuning so that's good!
Because you are tuning with lots of variables, indeed you will need to trial and error as it is difficult to predict what the factory ECU is doing and responding to the eManage tune.
You'll have to be patient as it is difficult to see the change in response. Do your change, then leave it for a few drives. Sometimes the immediate response from the motor may not the it's true response.
It'll be a long journey ahead, but hang in there!
Good luck!!