## ## #### ## #### ## ##
___ | _`\ | (_) ) | , / | |\ \ (_) (_)
###### ## ## ## ## ####
#### ## ## ###### ## ####
### ## ## ## ## ## ####
IMPORTANT: enter the case-INsensitive alphabetic (no numbers) code AND WRITE SOME SHORT summary of changes (below) if you are saving changes. (not required for previewing changes). Wiki-spamming is not tolerated, will be removed, so it does NOT even show up in history. Spammers go away now. Visit Preferences to set your user name Summary of change: This shows an example config.txt with comments that are mostly useful Begin Config.txt ---------------- <code> ################################################ # Last Updated 23 Mar 2005 # GRM car: NA car # 4 window hall sensor # target board v3.2 # Most copied from Marcell's v3.1 config and tables # Im not sure which injectors I have # going with lebaron 2.2 turbo injectors # Injectors Populated: INJA, INJB, INJD, INJG # Wideband Heater: WB1 # IGNition Drivers: DR_00, DR_01, DR_02, DR_03, # ################################################### # STARTUP # Pump Priming primep=0D # 1.3ms # # --- Hot start Priming pulse scaling at 170F (80= half FF = same as cold) primep_temp_scaling=A0 # ======== Cranking Pulse # typically cwh =~ 0.2 * cwl cwl=46 # Cranking pulsewidth [100 usec] at -40 F (7ms) cwh=14 # Cranking pulsewidth [100 usec] at 170 F (2ms) cranking_thres=03 # Cranking threshold [100 rpm] ################################################### # # Initial Start and Warmup # # ======== Afterstart # TODO: try avew=28 and awec=A0 initially awev=44 # Afterstart warmup enrichment (percent, added value) awev_temp_scaling=98 # Afterstart warmup scaling at 170F (80=half, ff=same as cold) awec=41 # Afterstart number of engine cycles # ======== Warmup Coolant # warmup_clt_range defines the temperature bins used for interpolation # the values in warmup_clt_range is degrees Fahrenheit + 40 # C = 5/9 * F - 40 # F = 9/5 * C + 72 warmup_clt_range[0]=00 # -40.0 C warmup_clt_range[1]=14 # -28.8 C warmup_clt_range[2]=28 # -17.7 C warmup_clt_range[3]=3C # -6.6 C warmup_clt_range[4]=50 # 4.4 C warmup_clt_range[5]=64 # 15.5 C warmup_clt_range[6]=78 # 26.6 C warmup_clt_range[7]=8C # 37.7 C warmup_clt_range[8]=AA # 54.4 C warmup_clt_range[9]=C8 # 71.1 C # warmup_clt is the value of each bin defined in warmup_clt_range # this is the actual warmup enrichment. Values biased at 100 warmup_clt[0]=9B warmup_clt[1]=9B warmup_clt[2]=99 warmup_clt[3]=93 warmup_clt[4]=8A warmup_clt[5]=7d warmup_clt[6]=78 warmup_clt[7]=6e warmup_clt[8]=6a warmup_clt[9]=64 # warmup enrichment can be decreased as a function of rpm. # set all to 0x64 to disable warmup_rpm[0]=64 # 100% warmup_rpm[1]=64 warmup_rpm[2]=64 warmup_rpm[3]=64 warmup_rpm[4]=64 warmup_rpm[5]=64 warmup_rpm[6]=64 warmup_rpm[7]=64 ############################################################## # # Injector settings # # Fueling Parameters (Last years settings bad! Need NON-PWM settings) req_fuel = 48 # Fuel constant (req_fuel) (72 Decimal) # for a 4 cyl you normally want # divider * (alternate+1) = 4 # That is divider=02 and alternate=01 for 2 banks # or divider=01 and alternate=03 for 4 injector banks divider = 02 # IRQ divide factor for pulse # this is alternate=01, but bit4=1 enables squirting both banks at cranking alternate= 11 # Alternate injector drivers Works with h[0] # alternate = 00 means use only first (batch fire or TBI) # alternate = 01 means alternate between first and second # alternate = 03 to use indexes 3,2,1,0 # alternate = 07 to use indexes 7,6,5,4,3,2,1,0 injopen=22 # [16usec] based, (mutiply MS standard value by 6.25 to get [16usec]) battfac=24 # [16usec] based, (mutiply MS standard value by 6.25 to get [16usec]) # TODO: 104 kPa (GM) MAP sensor. Do you have this? kpafac=34 kpaofs=00 # TODO: check injocful from Marcell's config injocfuel=00 #PW-correlated amount of fuel injected during injector open[4usec] injrampup_battfac=FF injpwm=FF # Injector PWM duty cycle (when current limiting is active) (set to ~100% no PWM - JJR 03/31 15:15) injpwmt=FF # Injector PWM time at which to activate pwm [100 usec] FF=disabled (set to 1 mS per MegaManual for starting point) injpwm6=00 # added Injector PWM duty cycle during low battery voltage (6V) # rpmk[0]=0B #12000 rpm/4clyn rpmk[1]=B8 #################################################################### # # TPS related information # tpsdot_kpadot_conf=00 # TPS dot bins tpsdotrate[0]=05 tpsdotrate[1]=0E tpsdotrate[2]=20 tpsdotrate[3]=40 # TPS accelerator enrichement: set to 00 for inital VE tuning tpsaq[0]=00 tpsaq[1]=00 tpsaq[2]=00 tpsaq[3]=00 # not sure about these tps_thresh=05 tpsasync=02 acmult=64 tpsacold=05 tpsdq=64 decel_fuelcut_thres=FF overrun_fuelcut=10 # 1600 RPM overrun_fuelresume=0F # 1500 RPM ######################################################### # # Rev limiter # # Rev limit (hard) [x100 rpm] eg. 0x4B * 100rpm = 7500rpm rev_limit=4B ######################################################### # # No idea # airden_ignore=62 ########################################################### # # these are important # These useful descriptions are left over from Megasquirt # config11=30 # old config 31 config12=30 # 4 cylinders config13=02 # old config 00 ############################################################ # # battery calibration for starting and dwell I believe # batt_cal=BC ########################################################### # # Fast Idle # fastidle=C6 #RPM?? ########################################################### # # Barometer settings # # ==== Mean Barometric Pressure -- TODO explain better baro=64 # ========= max allowed difference in barometric pressure # else use baro=0x64 (100 kPa) # dbaro=10 # Marcells setting dbaro=0C ########################################################### # # TPS calibration # read TPS from LCD (or serial connection Manmll) # in both endstates of throttle and configure these # Important for triggering idle mode and acceleration enrichment # --- TPS calibration means that the Analog(voltage) to Digital (count) is set # at zero throttle and Wide Open Throttle (WOT) # The standard: lowest voltage for closed throttle # highest voltage for open throttle # --- See Manual or wiki page for how to hook up. # --- Most Tuning software has this function in them # Megatune, Megatunix, etc. # tps_low=00 tps_high=FF ########################################################### # # Coolant Fan output # This ouput is generally used to trigger a relay to turn on # the electric radiator fan, or engage the electric clutch for # engine cooling fan # NOTE: the GRM cars use the stock VW low temp fan switch in the radiator # And as such this ouput is not needed # --- Temperature when fan will turn on degC eg. 0x55 = 85degC fan_temp=EA # --- Decrease in temperature required to turn fan off. # --- fun_temp-fan_hyst=temp when fun will turn off 0x55 - 0x09 = 0x4C (76degC) fan_hyst=05 # coolant fan, output selection (digitalout) fan_channel=FF ########################################################### # # Idle air controller -- I dont have one. # # This is where the idle is setup lots of stuff here to screw up. # iac_step_seq=C9 # stepper is enabled with 7E, you probably want iac_conf=18 or whatever ..check it iac_conf=7E ??? iac_max_steps=F0 iac_tps_thres=05 iac_cold_idle_temp=A0 iac_warm_idle_temp=D0 iac_cold_rpm=74 iac_warm_rpm=67 iac_cold_start_pos=E2 iac_warm_start_pos=B0 iac_afterstart_rpm=1F iac_afterstart_duration=20 iac_afterstart_steps=04 iac_kp=25 iac_ki=10 iac_kd=30 iac_integral_speed=C0 iac_integral_limit_dec=05 iac_integral_limit_inc=E0 iac_integral_deadband=0A iac_deadband=05 iac_pid_conf=01 iac_overclose_interval=B8 iac_ref_pos[0]=35 iac_ref_pos[1]=34 iac_ref_pos[2]=33 iac_ref_pos[3]=32 iac_ref_pos[4]=31 iac_ref_pos[5]=30 iac_ref_pos[6]=2F iac_ref_pos[7]=2E iac_ref_pos[8]=2D iac_ref_pos[9]=2C iac_sol_channel=FF iac_ign_advance_change=28 iac_ign_retard_change=20 iac_ign_advance_limit=10 iac_ign_retard_limit=1A iac_ign_threshold=08 ########################################################### # # EGO Exhaust Gas Oxygen -- very important. # EGO configuration ########################################################### # Dave Brul's EGO setup ### --- 07 Variable Air Fuel Ratio ego_conf=07 # 07 variable afr # --- Step size (percent) [0.4%] eg. 0x02 * 0.4% = 0.8% ego_delta=02 ### --- Time constant (engine cycles) for changing correction factor # This will help smooth out the learning process ego_lag=15 ### --- Min coolant temperature for ego enabling[F] eg. 0xC2 = 194degF (108degC) # C = 5/9 * F - 40 # 60 degrees celcius # Setting this requires you to know if F or Cel is your chosen measurement ego_coolant=94 #C2 ### --- Max TPS position for ego correction, This setting allows for learning at WOT ego_maxtps=FF ### --- Max MAP for O2 correction[kPa] ego_maxmap=FF ### --- Min RPM for ego enabling [100rpm] eg. 0x0C * 100rpm = 1200rpm # Ignore all information below this RPM ego_minrpm=0C ### --- Max rpm for O2 correction [100rpm] 0x32 * 100rpm = 7500rpm ego_maxrpm=FF ### --- Warmup time [sec] eg. 0x3C (60 sec) [IS THIS FOR THE O2 sensor?] ego_warmup=3C ### --- Max percent to lean afr[0.4%] eg. 0x30 * 0.4% = 19.2% ego_lean_limit=30 ### --- Max percent to rich afr[0.4%] eg. 0x80 * 0.4% = 51.2% ego_rich_limit=30 ### --- THIS NEEDS DEFINED ego_pid_kp=40 # --- ego_target = 51 * O2_sensor_voltage ego_target=19 # --- not used for the wbo2 incredible ego, only for NBO2_PID_EGO_EXPERIMENT # Does this need to be commented for WBO2 setup? ego_pid_window=FF # MCELL vs DaveB (X = same; - = diff) # X ego_conf=07 DB:07 # - ego_lag=04 DB:15 # - ego_coolant=00 DB:94 # X ego_maxtps=FF DB:FF # X ego_maxmap=FF DB:FF # - ego_minrpm=04 DB:0C # X ego_maxrpm=FF DB:FF # X ego_warmup=3C DB:3c # - ego_lean_limit=1D DB:30 # - ego_rich_limit=28 DB:30 # X ego_pid_kp=40 DB:40 # NA mt_unused=00 DB: NOT DEFINED # NA ego_delta=01 DB: NOT DEFINED # X ego_target=19 DB:19 # X ego_pid_window=FF DB:FF ########################################################### # # Copy WBO2 section from somewhere, # Marcell's setup is special and MUST NOT BE USED # TODO: Rip MCELLs WBO2 from the Reference firmware # TODO: setup standard LSU4 setup and other std WBO2 used # # Dave Brul's WBO2 setup # wbo2 config with softpwm_act; softpmw_act_var is broken!! # You must still calibrate your WBO2 see Manual or # wiki page: # # --- Semi useful varable names wbo2_warmup_ramp=A0 wbo2_warmup_target=FF wbo2_abs_limit=E4 wbo2_limit_maxt=A0 wbo2_fallback=60 wbo2_retry_t=06 wbo2_edgetime_corr=BA wbo2_edgetime_min=50 # Dave I see your calculations here. Are they for the Calibration? # How about putting a worksheet here? # (2.55mA * 61.9 / 106.2 ) + 2.55 = 4.036299 mA # 4.036299 * 510 Ohm = 2.058512712 V # i measured +/- 2.06V -> Good! # 1% is eaten by the 10k pump+ to pump- resistor # but does the AE calibration value also match my Rcal of 106.2 ? # --- O2 percentage of 'normal' air: 20.947%, calibrated to 20.95 wbo2_calibration=AE # A1 for the ETAS3 sensor with Rcal = 75.3 ohm # --- I NEED A DESCRIPTION wbo2_pump_pw_zero=64 # wbo2, target Ri (pulse amplitude) [5V/8192] wbo2_ri_target=96 # OPA amplification, g = 270/75 + 1 = 4.6 # Vadc = g * (5 - Vnernst) # # Vnernst DC at sensor wire = 4.45V # Vnernst DC at adc = 4.6 * (5 - 4.45) = 2.53 # # nernstdc_target = Vadc / g * 256 = 141 = 0x8D # --- wbo2, target nernstDC [5V/256] wbo2_nernstdc_target=8D # --- I NEED A DESCRIPTION wbo2_heater_pid_kp=46 wbo2_heater_pid_ki=10 wbo2_heater_pid_kd=1A wbo2_heater_pid_ilimit=80 # --- I NEED A DESCRIPTION wbo2_pump_pid_kp=40 # 2E wbo2_pump_pid_ki=2E # 1D wbo2_pump_pid_kd=08 # 08 wbo2_pump_pid_ilimit=84 # 84 # --- I NEED A DESCRIPTION wbo2_ri_confidence_scale=80 ########################################################### # # Knock Detection and correction 2-channel Knock sensor control # # NOTE: GRM car NOT using Knock being used this go round # --- Dave Brul's notes PROBLEM his has more settings. # engine with bore 83mm and stroke 86mm # f_knock = 900 / (pi*r) = 900 / (pi * 0.5 * 0.083) = 6.903 kHz # from datasheet tpic801.pdf page 10 table#1 # bandpass frequency selection 6.94 kHz is closest to 6.903 kHz # filter setting = 29 hex (41 dec) # -- Overall System SettingsKnock selection knock_conf=00 knock_sampling_window=FF # --- RPM range valid for FF, FF means no knock knock_minrpm=FF knock_maxrpm=FF # --- Channel #1 setup knock1_frequency=29 knock1_gain=FF knock1_integrator=FF # --- Channel #2 setup knock2_frequency=29 knock2_gain=FF knock2_integrator=FF # --- Trigger level knock_threshold=FF knock_noise_scale=FF # --- Ignition effects # ----- Knock getting louder knock_max_retard=FF knock_default_retard=00 knock_retard_step=FF knock_retard_delay=FF # ----- Knock getting softer knock_advance_step=FF knock_advance_delay=FF ########################################################### # # VE learning VERY important # # ok how does this work ve_learn_coolant=D8 ve_learn_max_power=FF ve_learn_rpm_scale=1E ve_learn_kpa_scale=1E ve_learn_ego_scale=43 ve_learn_min_weight=4D ve_learn_speed=FF ve_learn_limit=FF ve_learn_conf=00 ########################################################### # # LCD layout # # A better description would definately be helpful lcd_c0=FE lcd_delay=FF lcd_backlight=FF lcd_offs[0]=FF lcd_offs[1]=FF lcd_offs[2]=FF lcd_offs[3]=FF lcd_default_view=00 ########################################################### # # Triggers, HW determines VR or Hall # software defines how it reacts # # The ITB GRM car uses a 4 window hall sensor for a trigger # # ========== 4 WINDOW HALL SENSOR ==================== # # ======Primary_Trigger ==================== # FE: Rising Edge trigger # FF: Falling Edge trigger # 01: Multi-tooth configuration primary_trigger=FE # Rising edge Hall sensor # --- tooth_wheel: Used for multi-tooth wheels (total # of teeth) tooth_wheel = 00 # not used in a basic coil type trigger aka DummyIgnition # --- NEED A LITTLE HELP HERE tooth_wheel_twidth1=06 # --- trigger_tooth:Used for multi-tooth wheels (Tooth that triggers event) trigger_tooth = 00 # not used in basic coil type trigger aka DummyIgnition # NOTE: ALL TRIGGERS below here not used in coil type trigger # ========== NOT USED [Example 60-2 wheel & cam sync config?] ==================== # ======Secondary_Trigger ==================== # FE: Rising Edge trigger # FF: Falling Edge trigger # 01: Multi-tooth configuration # ??: Cam Sync setup? secondary_trigger=FE # Rising edge Hall sensor -- NOTE: GRM car doesnt have this HW populated # --- another_trigger_tooth: NEED HELP HERE. guessing secondary better grouping would be inorder another_trigger_tooth=1E # --- NEED A LITTLE HELP HERE tooth_wheel_twidth2=12 # --- this is for folks with a cam Sync cam_sync_r_edge_phase=FF cam_sync_f_edge_phase=FF reset_engphase_after=FF ########################################################### # MCELL's Trigger setup, using a 60-1 VR wheel # Triggers, HW determines VR or Hall # software defines how it reacts # ======Primary Trigger ==================== #primary_trigger=01 #tooth_wheel=3A #trigger_tooth=10 # ======Secondary Trigger ==================== #secondary_trigger=FF #another_trigger_tooth=1E #crank_minper=50 #tooth_wheel_twidth1=06 #tooth_wheel_twidth2=12 #cam_sync_r_edge_phase=FF #cam_sync_f_edge_phase=FF #reset_engphase_after=FF ########################################################### # # Ingition stuff # ign_tdcdelay=60 # 96 degrees BTDC # GRM car uses BOSCH-008 Module so Dwell is done in that IGBT module ign_dwell14=26 ign_dwell6=32 ign_crank_advance=20 # ignition advance at cranking (8 deg) [0.25crankdeg] ign_out=71 # Dummy ignition # at least 0..ignchmax index of h[2] must be filled in ignchmax=03 engine_off_delay=08 ########################################################### # # Fuel Pump Control # # NOTE: GRM car uses stock VW fuel pump relay. # it does this function automatically # --- It primes the system at startup # --- It runs as long as the coil is firing # --- It stops if the coil signal goes away # Ahh the beauty of an A1 VW fuel pump relay pump_on_mintime=10 # do you have a free injector driver to drive the fuelpump relay? # TODO: select another channel (eg. from P259 ) if no # or set last element of h[0] # or disable with FF (but always-ON pump is dangerous, don't do that) fuelpump_channel=70 ########################################################### # # second stage of injectors # # NOTE: GRM not using, A description of use would be nice inj_stage2_rate=FF inj_stage2_start_tps=FF inj_stage2_start_map=FF ########################################################### # # Anti-lag system # # NOTE: GRM not using, A description of use would be nice als_lowrpm=FF als_maxtps=FF als_ignretard=FF als_rich=FF ########################################################### # # Misc outputs (WOT & RPM, WOT, RPM, channel definition) # # FF disables the outputs # GRM needs/wants: # WOT & RPM( 4000RPM < X <7200RPM ) switched ground for relay (nitrous activation) # RPM ( >7000 RPM) Switched ground for SuperBright LED (SHIFT LIGHT) # RPM ( >rev_limit(7500 RPM) )Switched ground for SuperBright LED (REV Limiter) # # ============== Misc 1 output ================= misc1out_minrpm=FF misc1out_maxrpm=FF misc1out_mintps=FF misc1out_maxtps=FF misc1out_minmap=FF misc1out_maxmap=FF misc1out_channel=FF # ============== Misc 2 output ================= misc2out_minrpm=FF misc2out_maxrpm=FF misc2out_mintps=FF misc2out_maxtps=FF misc2out_minmap=FF misc2out_maxmap=FF misc2out_channel=FF # ============== Channel Select ================= act_wot_rpm=FF act_wot_channel=C0 act_rpm_rpm=FF act_rpm_channel=FF ########################################################### # # Exhaust Gas Temperature # # NOTE: GRM not using, A description of use would be nice egt1_cal=40 egt1_offs=00 ########################################################### # # Boost Controller # # NOTE: GRM not using, A description of use would be nice boost_conf=00 boost_targetoffs=00 boost_minpressure=FF boost_pid_kp=20 boost_pid_ki=80 boost_pid_kd=01 boost_pid_ilimit=FF boost_channel=FF ########################################################### # # Water pump Controller # # NOTE: GRM not using, A description of use would be nice water_pump_temp=00 hybrid_rpm_a=00 hybrid_rpm_m=00 water_pump_hyst=00 water_pump_channel=FF End Config.txt -------------------------------------------------------------------------------- Tables.txt is not commented as well yet. Begin Tables.txt # Injector map j[0]=667F 667F 6736 697F 6E7F 717F 717F 737F j[1]=677F 6859 6B7F 6F7F 757F 797F 7A7F 797F j[2]=687F 6C7F 717F 787F 837F 887F 867F 827F j[3]=6F7F 717C 797F 847F 917F 987F 987F 927F j[4]=7B7F 7F7F 847F 8D7F 9B7F A47F A87F A17F j[5]=827F 837F 8C7F 937F A87F B37F B958 B37F j[6]=867F 8B7F 937F 9C7F AF7F B87F BF7D BE7F j[7]=877F 8CB0 967F A07F B07F BA7F C57F C27F # NA k[0]=14 1E 28 32 3C 4B 5A 69 r[0]=05 0A 0F 14 1E 28 32 40 # lambda correction map l[0]=45 38 38 36 34 34 34 34 l[1]=38 38 38 38 36 36 36 36 l[2]=38 38 38 38 38 38 38 38 l[3]=38 38 38 38 38 38 38 38 l[4]=38 38 41 47 4F 4F 4F 4F l[5]=45 45 4F 59 59 59 59 59 l[6]=6A 6A 6A 6A 6A 6A 6A 6A l[7]=6A 6A 6A 6A 6A 6A 6A 6A # Fero said that max l=0x5c (NA) is too rich. So he set it for 0x6A (even more rich :-) # ingition map n[0]=3C 3C 50 77 A0 B4 B4 B4 n[1]=3C 3C 50 78 A0 B1 B2 B1 n[2]=3C 3C 50 77 99 AA AB A9 n[3]=3C 3C 50 76 95 A1 A2 A1 n[4]=3C 3C 50 75 8D 99 9B 9A n[5]=3C 3C 50 6F 83 8E 8F 8F n[6]=3C 3C 50 67 7A 81 83 84 n[7]=3C 3C 50 5F 6F 78 78 78 # injector sequence # maskconfig.alternate elements are used # (going reverse order, last element is looked up first). # FETs are numbered 01,02,04,08,10,20,40,80. # # Injectors Populated: #### INJA[01, EC36p07] #### INJB[02, EC36p19] #### INJD[08, EC36p20] #### INJG[40, EC36p06] # LSB fired first # this fires them in batch mode A&B and D&G h[0]=03 48 00 00 00 00 00 <for fuelpump_channel=70 here goes injmask for fuelpump relay> # NOT used Obsolete h[1]=00 00 00 00 00 00 00 00 # Ingition Driver # Fire the one installed #IGNition Drivers Installed # DR_00[h[2] = 00, EC36p35] # DR_01[h[2] = 01, EC36p33] # DR_02[h[2] = 02, EC36p34] # DR_03[h[2] = 03, EC36p36] # using DR_03 just to show where it goes, not that it has to be this one h[2]=03 03 03 03 03 03 03 03 # wasted spark would look like #h[2]=01 02 01 02 01 02 01 02 # chris G's notes: # third line contains the ignition sequence, each element # represents the bitnumber of the p259 output going to coil # we start at the end (ignchmax) and work our way back # fire igbts 07 for all events please (single coil firing through distributor) #-----------these are for something else b[0]=28 30 38 40 48 50 58 60 t[0]=20 40 17 80 A0 C0 E0 FF -------------------------------------------------------------------------------- </code> End tables.txt Optional: Add document to category: Wiki formatting: * is Bullet list ** Bullet list subentry ... '''Bold''', ---- is horizontal ruler, <code> preformatted text... </code> See wiki editing HELP for tables and other formatting tips and tricks.