After lot of test with cars with very light flywheel i found out it is better to set iac integral to 0 always when car is moving(regardless on map).
So:
+ if (iac_integral_moving() && wheel_speed1.wspeed ) {
+ iac.integral = 0;}
+ if (engine_kpa8() < config.iac_integral_lowmap && !iac_integral_frozen() ){/// TODO: needs to check result
+ iac.integral = 0;
+ return;
+ }
Test with 1.1.87 and all is good. Idle is again perfect :).
Log
http://www.vems.hu/files/DamirMuha/1.1.87/v3.3_n001057-2010.12.19-16.55.48.vemslog
How to set perfect idle. First you need perfect VE table:).
Than set your ref iac position to +200-300rpm above target rpms.
Set PID, P=35 I=10 D=50 (or similar), iac limit -60 and +50.
My proposal for universal solution(all are happy :)
Add two bits:
first bit= iac integral frozen bit, so if bit is set and engine is in idle and engine_kpa8() < config.iac_integral_lowmap then iac.integral is frozen (doesn't change)
But when isn't set, and ngine is in idle and ngine_kpa8() < config.iac_integral_lowmap then iac.integral is set to 0
second bit= iac integral moving bit, when is set and cars is moving (car speed from speed sensor>0) and car is in idle then iac.integral is set to 0
if isn't set, then nothing
+ if (engine_kpa8() < config.iac_integral_lowmap ){/// TODO: needs to check result
+ if (!iac_integral_frozen() || (iac_integral_moving() && wheel_speed1.wspeed ))
+ iac.integral = 0;
+ return;
+ }
- define iac_integral_frozen() (config.config12 & _BV(iac_integral_frozen_bit))
- define iac_integral_moving() (config.config12 & _BV(iac_integral_moving_bit))
I new version of firmware (1.1.80, 1.1.84) iac.integral is frozen if map is higher than in config. But when you shift gears, always you have small decrease in iac.integral as you can see in log:
http://www.vems.hu/files/DamirMuha/1.1.84/v3.3_n001057-2010.11.15-21.00.02.vemslog
At idle i have iac.integral -32(1s). When i start driving iac.integral is -34, but when i change gear from first to second (5s in log), iac.integral is decreased to -44. After 4 gear changes iac.integral is -70 and i have problem with car stalling.
IMHO better solution is like older firmware has(less than 1.1.74). If map is higher than in config iac.intergral is 0.
- At this moment I dont have the possibility to open your log, what do you have the iac_close delay set to? This affects the integral-reset so when set too high it doesn't reset the integral controller fast enough. /Larsa
- set is to 255s. With that value and 1.1.74 firmware i had perfect idle at 800rpm. Now i have problems with 950rpm.
- Tried to set 3,5,10s, nothing is good. IMHO one bit should be add. If engine.speed>0 than iac.integral=0. That feature use most cars ecu. So if you are driving or driving slow idle is little higher(ref position table) and with that you don't have problems when you are driving few km/h at parking lot with small amount of throttle(no changing of IAC values).
- Didn't the integral reset after this time? or did you still get a negative windup resulting in engine stall? Try to set correct overrun_fuelcut settings(1500rpm or so), I saw your was set to 25 000. These settings affects Integral reset aswell.. (when tps=0 and rpm > overrun_fuelresume then integral=0) /Larsa
- that helping when i hit clutch after 1500rpm. But when i drive slow, 1200rpm and hit clutch engine dies.
-- but if you put when car is moving iac.integral=0 and integral min map=0 you don't have problem with stuck at high rpms(only when driving(speed!=0)). Only problems are if ref position is set to low(imho good setting is 200-250 above idle).