Start up and Idle. This note states the adjustments for the engine from stationary state until After_Start_Time and Coolant_Temperature reaches certain condition. Usually 40 seconds and 200F coolant temperature.
Like a steady state operation condition, during start-up/cranking, fuel needs to be injected and the mixture needs to be ignited. But without a good way to properly measure the engine performance/behavior. It takes some guess work to put in numbers to start the engine successfully. Fortunately, the amount of fuel and ignition timing only needs to be in a reasonable range for this.
Like a regular VE table, there is a CrankVE_Table based on engine load/MAP and engine speed. Normal cranking speed is about 200-300rpm. So my tables are filled with numbers of engine speed up to 250rpm. There is a LambdaCrankingTable just like the regular LambdaTargetTable. But this LambdaCranking table is based on coolant temperature for simplicity. There is also an IgnMap_Crank table based on engine speed and coolant temperature, due to the temperature having influence on how the flames burns and spreads. Hotter the engine is, mixture burns easier and flame spreads faster. Less timing advance is required. If timing is advanced too much, kickback will happen. You should know kickback if you ever tried to crank an engine over manually. Less timing advance is better just for avoiding the kickback. Correct amount of timing advance can result in a "strong" start. These cranking tables will be ignored, as soon as the engine speed is above 400rpm.
It is different for hot start and cold start in different perspectives. During hot start/restart, engine is usually heavily heat soaked, causing Intake Air Temp(IAT) sensor to read high. False high reading of the IAT sensor can cause problem when calculating fuel. Equation of calculating fuel is in Notes1. False high air temperature will tell the ECU to inject less fuel than actual condition, causing it to run leaner than your target lambda. During cold start, especially port injected engines, fuel gets condensed on the intake manifold and inside of the cylinder instead of being in the mixture to be ignited.
Port-injection engine has a puddle of fuel under the injectors, because not all the fuel gets into the cylinder. It is called wall-wetting, and it has significant influence on start up and transition states. Wall-wetting/the puddle of fuel are mainly affected by air speed and temperature of the engine.
So, Here is a brief recap. From cold start to idle, engine temperature is low. Friction and resistance are high. Fuel gets condensed. From hot start to idle, sensor is having a false reading. Inside of the AEM infinity, there is a FuelTrim_Coolant table. This table adjusts the amount of fuel injected after the fuel calculation. So, if your target lambda is 0.88 when you initially start up, ECU calculates the amount of fuel needed and injected. But your measured lambda is 0.92, because fuel went to the puddle instead of burning. You can add 0.04 to the cell inside the FuelTrim_Coolant table to tell ECU to add more fuel bringing it to the target. These steps occur in sequence and really quick. ECU looks at your target lambda value, and VE for an initial fuel calculation. It then looks at your FuelTrim table, adjusts the calculation of fuel. It will have a final amount and inject.
This table is 3 dimensional table, depending on After_Start_Time and ECT(coolant temperature). It adds certain extra percentage of fuel after each start-up at different coolant temperature. For tuning, I let the O2 sensor warms up first by turning the ignition on, then start the engine at different ECT temp. Log the TargetLambda and Lambda, then adjust accordingly. Under normal operating condition, engine will be running in open loop without O2 feedback. Because O2 sensor is cold.
LambdaAfterStartTrim is 3D table adding/subtracting lambda value directly from the main LambdaTargetTable. This table is beneficial for cold start by aiming a richer than normal idle mixture. Other than condensation, fuel mixture can't burn properly when cold. Aiming for a rich mixture ensures the engine to run smoothly and consistently after each start. It your engine died after it starts up, most likely, it's a cause relating to this. I adjusted this lambda trim with main lambda target table so my engine runs around 0.95 for 10 seconds at 200F ECT and decay away. 0F and 0s After_Start_Time is about 0.85. It's a value from googling. To help the engine run smoothly and consistently, engine speed can also be adjusted higher for a period of time through IdleTargetOffset table. I added 300rpm on top of normal idle target speed at 0s then decay away to 0rpm at 10s after_start_time. *LambdaAfterStartTrim helps with IAT sensor false reading when hot restart, by aiming for a rich mixture. IAT sensor false reading can cause engine speed hunting* (this is a note from my research. I can't really understand or confirm)
So far, the engine should start up successfully each time hot or cold, and it should be running at your target lambda.
Just to help it warm up faster, IdleTarget_table defines a target idle speed according to the coolant temp. It is a one axis table. When the coolant is cold, set the idle target speed higher. There are other necessary trims for the target idle speed as well due to changing load/resistance. Engine will be running more steady responding to switching on AC compressor or other things. ECU will have a final target idle speed with extra load or not. It will then set the idle valve position controlling the air flow, according to IdleBasePosition. It is a one dimension table for the ECU to know where the idle air valve should be for a certain idle speed. When the IdleBasePosition table is set correctly, engine rpm will be the same as target idle speed. This is the initial open loop control to the engine idle speed.
Close loop control can be utilized when the actual engine speed is not the same as target idle speed. Throttle position and rpm must meet certain conditions, like throttle position below 1% and engine speed below 2000rpm, close loop control will be engaged. ECU will try to adjust the idle air valve getting the RPM to the target idle speed.
IdleFB_active channel will show whether close loop control is engaged. Logging this channel can help tune the idle. IdleFB is how much ECU used to correct the idle air valve to get to the target idle rpm. S2000 is using a duty controlled solenoid to control the said stepper IAC valve. It is really confusing, it is not a 4/6 wire stepper motor. It is not a simple 2 wire solenoid. It has 3 wires, one connected to ECU, one is a relay controlled 12V. The other one is a ground. According default AEM setting, it seems that it should be treated as a stepper motor. Technically, its range and steps need to be set up correctly for the ECU to control it smoothly. But the base setting provided by AEM is usable. For the S2000, higher idle base position number means more air flow, higher idle speed. For some other cars, this may be inverted. In the Infinity Setting, there is a checkbox of idle airflow invert you can choose if that is the case.
Tuning idle of S2000.
So before tuning your idle, your idle air control valve needs to be in control. Idle on condition needs to be changed to TPS below 3% or any reasonable value. RPM below setting needs be higher than the highest idle speed, like 3000. Also, make the Idle FB deadband to +-3000. Ignition adjustment to 0 throughout the range. So you will have a full open loop control from idle air valve to the engine without feedback. (?????? Needs editing) Then make sure, you have a gradual change in ignition throughout the idle range. Otherwise, your engine won’t be smooth.
1, make sure your engine is in normal operating temperature (ECT and IAT).
2, Change the whole IdleTarget_table to 2200rpm.
3, adjust IdleBasePosition cell for 2200rpm so that idleFB shows -3% to -8%( it encourages high idle before any closeloop control engages.)
4, change the whole IdleTarget_table to 2000rpm, adjust IdleBasePosition for this cell.
5, repeat step 4 for every idle target cell you have until the lowest.
6, fill in the IdleTarget_table with normal values. For S2000, really cold, target at 2100. Warm idle at 850/1000
7, Set the idle on below TPS is above at rest throttle position. Idle on below rpm at 1650, so it’s out of normal operating rpm range. Also, set the idle feedback min to about -15% or -10%. So it can’t accumulate. #when the car is happening to decelerate at 1700 with above setting. Close loop control is engaged. ECU will try to shut the idle air valve, trying to get the idle in control. But it can’t. It will close the idle air valve further, and accumulates a high negative idle FB value. A high negative idle FB min would cause the rpm to drop too low/ even stall when the clutch is suddenly disengaged. So Idle FB min should be set at -15% or -10%. Idle feedback max is set to 5%.
8, Advanced idle tuning. when the idle on below TPS and idle on below rpm condition is met. Closeloop control is engaged. ECU will try to adjust the idle. How the ECU/computer reacts and controls can be adjusted through Idle PID feedback gain(proportional gain, integral gain and derivative gain) In other words, these settings adjusts the speed, accuracy and stability of this control loop. See page161 of infinity instruction on how to adjust these. Normally, it is not needed.
9, simple explanations. Proportional gain is good for controlling large error. The bigger the error is, the bigger this gain will be. But, it can result in hunting because it likes big errors and often overshoots. Integral gain takes a step every 400ms to adjust and control the target error. High integral gain means bigger step. And excessively big step can result in overshoot/instability. Derivative gain is used to control the overshoot due to above two gains. It responds to the rate of changes of target error by reducing magnitude. Idle FB deadband+/- defines target error range/what is close enough. Within this rang above/below target rpm. ECU will not try to adjust it, especially for engines with natural instability due to large cam, light flywheel or injectors that doesn’t flow well at low flow.
10, on my S2000. I set proportional gain to 0 unless it responds too slow to big errors. Integral gain is set to 0.005 compared AEM default 0.010. to make it stable and smoothly running at idle target. If engine fluctuates a bit at idle target. This can be adjusted. But take the engine’s natural instability into consideration. From infinity instruction, derivative gain should be left at 0. Even in conditions that seems to be caused by Derivative Gain, don’t adjust DG. Adjust Idle_Decel table. It’s recommended. Idle FB deadband is set to -50 and +75.
When the ECU/idle feedback close loop control gets engaged, Idle offset RPM adds additional rpm to the target table, and fades/decay away to the original number. It functions like a cushion when the rpm drops. In addition to this cushion, Idle_Decel table adds extra idle air valve base position % before it reaches the target rpm, then back to target number as it dropping down to target rpm. (infinity instruction: this is especially helpful for engines with lightweight flywheel. Like me, ap1 flywheel on F22. Values 300-800rpm above target speed are the most important to adjust.) When both of them is set correctly, step on the throttle in neutral, engine should fall back to your target idle speed smoothly and consistently.
IgnTrimIdle adjust the ignition timing to help control the idle. It retards the timing from the main timing table when the rpm is higher than target, advances the timing when rpm is lower than target. It responds and adjusts faster than the IAC valve. Many factory ECU utilizes this method to achieve a super smooth idling engine.
11, since I don’t have AC on the car. Idle AC offset adds additional valve opening to the idle base position. It’s set to 0. Idle AC target offset is set to 0 as well. Idle coolant fan offset opens up extra idle air valve position. It’s set to 0.8. If these are not set correctly, idle FB value will fluctuate significantly when these things turning on and off. Engine speed will fluctuate as well.
Aside from above target idle and close loop control. IdleTargetOffset and IdleTPSOffset control the target idle speed as well. IdleTargetOffset is additional idle speed to fight lean mixture due to excessive wall wetting/poor atomization when cold starting. It can also help CAT to light up faster. IdleTPSOffset is for drivability. When you lightly press on the throttle, while still in the close loop control range, ECU tells the engine to rev higher/target at a higher idle speed. It helps taking off in a stop and go traffic.
Experiment with above steps, P168 of infinity instruction has detailed steps about adjusting idleFB oscillating and responses. And it explained some of the relationship of above settings.
It has been over 6 months since I initially had the idea of tuning my own car. There are way more things and knowledge involved to properly tune a car than I anticipated.
A brief history of my car. It is a 2000 Honda S2000 with mileage around 100K. Its original engine F20 became seized after a trip to the track Road America. Detailed disassembly of the engine is here. A F22 from a 2004 AP2 S2000 was swapped into the car to be used with the original AP1 ECU. According to the internet, it should work just fine : ) Compression test and leak down test on the F22 all showed great results after the install. But the engine was not running right. At a typical 20-min track session, the oil temperature would go over 265F even with upgraded radiator and oil cooler. It will misfire from time to time. During a WOT dyno-pull, AFR is around 14:1. Other parts on the car tend to fall apart whenever I am pushing it on the track. The car spent more time sitting on the jack stands than running. Thus, I decided to learn on this car. The worst it can do is not running, which is what this car is good at.
I am using a AEM Infinity standalone ECU. The install is easy with plug and play adaptor harness. The most difficult part was to put everything in the tiny space behind driver side kicker panel. A fuel pressure sensor tapped on the fuel rail, oil pressure sensor and oil temperature sensor mounted on an oil filter sandwich plate are wired into the AEM, which give me more data about the engine. These data can also be used for failsafe protection thanks to the features of AEM. I also replaced all my old and tired ignition coils as they are suspected to be causing the misfire. They were the cause as confirmed later.
I tuned the engine based on VE mode, which is the most popular and the default mode on AEM Infinity. VE based tuning means airflow/air mass based tuning. The ECU calculates the fuel using this mode by looking at 3 main inputs from the engine. MAP (manifold absolute pressure), IAT(intake air temperature) and engine speed from either CKP(crankshaft position sensor) or CMP(camshaft position sensor).
I have notes on Fundamentals of Engine Tuning here. Following is a brief review of how ECU works. In order to have the engine running at a fuel-air mixture you want. You want to tell the engine what your target AFR is at different engine load and engine speed. ECU will use your target AFR and air mass it measured from the engine to calculate the fuel. According to the ideal gas law, PV=nRT=NKT(R,K are ideal gas law constant). Air mass “N”=PV/KT. In plain words, The air mass in the cylinder = pressure(MAP)*Volume of the Cylinders/temperature of the air* a constant. Thus, fuel needed to reach the target AFR = air/target AFR = PV/KT*target AFR. (V=volume of air=engine displacement*RPM/2) But, due to restrictions of the air intake path, NA engine usually cannot fill its cylinder completely with air particles. The actual air mass divided by its ideal amount is called Volumetric efficiency/ VE. Put both volume and VE into the calculation. Following equation is the core of VE mode.
Fuel=P*RPM /T*K*engine displacement/2 *VE* target AFR
Due to the dynamic nature of an engine, many compensations are used for calculating the actual amount of fuel to inject. Gasoline needs to burn to produce work, and it burns at a certain rate of speed. If you tell the ECU to ignition the mixture when the piston just went past the top dead center. The flame and in cylinder pressure will be chasing the piston as the piston going downwards. To have a higher in cylinder pressure, air-fuel mixture needs to be ignited before piston reaches the top of the cylinder. The goal is to have the highest in cylinder pressure when the piston has the most mechanical leverage. And you will have the most torque.
Following Tuning Notes will be broke up into different stages of tuning, because a really long essay can be really boring. Basic theories will be given and available adjustments in the AEM infinity. My setting and reasoning will be given after the basic theory.