;-------------------------------------------------------------------------------
; $Id: ms3.ini,v 1.281.2.4 2012/06/11 16:26:30 jsmcortina Exp $
;
; This ini file is Copyright 2007,2008,2009,2010 James Murray and Kenneth Culver.
; It is only to be used with a genuine B&G MS3.
;
; Original author(s) uncertain. Contains work of Eric Fahlgren
; Re-written to support MS3
;
;
; configuration defines, either #set or #unset

;This enables the "full" CAN/serial commands so this INI can be used anywhere on the CAN network.
#unset CAN_COMMANDS

#unset EXPANDED_CLT_TEMP   ; change this line to SET if you want to use the extended range
#unset INI_VERSION_2 ; this is set by TunerStudio, but needs to be unset for Megatune to work

#set MPH       ; unset for kph
#set METRES    ;unset for inches in wheel size
#unset INTERNAL_LOG_FIELDS
#unset PW_4X
#unset CYL_12_16_SUPPORT

[MegaTune]
   MTversion      = 2.25 ; MegaTune itself; needs to match exec version.

#if CAN_COMMANDS
   versionInfo    = "r\x00\x0e\x00\x00\x00\x3c"  ; Title bar
   queryCommand   = "r\x00\x0f\x00\x00\x00\x14"  ; Verify against signature.
#else
   versionInfo    = "S"  ; Put this in the title bar.
   queryCommand   = "Q"  ; Verify against signature.
#endif
   signature      = "MS3 Format 0238.002" ; MS-II sends a null at 20th byte.
                   ; 123456789.123456789.

;----------------------------------------------------------------------------
#if INI_VERSION_2
; ok
#else
 #error Megatune cannot be used with MS3 - please upgrade to TunerStudio
#endif
;----------------------------------------------------------------------------
; Temperature Limits and Settings Reference
; contributed by Mike Soultanian
;----------------------------------------------------------------------------
;
; Below is a listing of all of the temperature ranges used throughout the INI
; for the MegaSquirt.
;
; CELSIUS (Expanded/Normal):
;     Low limit: -40C/-40C
;     High limit: 230C/150C
;     Low danger: 65C/10C
;     Low warning: 93C/65C
;     High warning: 162C/93C
;     High danger: 176C/104C
;
; FAHRENHEIT (Expanded/Normal):
;     Low Limit: -40F/-40F
;     High limit: 450F/300F
;     Low danger: 150F/50F
;     Low warning: 200F/150F
;     High warning: 325F/200F
;     High danger: 350F/220F (also used for curve editor limits)
;----------------------------------------------------------------------------

[ReferenceTables]

    tableWriteCommand 	= "t" ; 
    
    referenceTable = mafTableBurner, "Calibrate MAF Table..."
        tableIdentifier = 003, "MAF Table"
        adcCount 	= 1024 	; length of the table
        bytesPerAdc 	= 2 	; using words
        scale		= 1 ; scale before sending to controller
        tableGenerator  = fileBrowseGenerator, "Browse for Inc File"
    	solutionsLabel	= "MAF Sensor"
    	solution	= "Default", 	{ table(adcValue, "maffactor.inc") }
    	solution	= "Ford V8", 	{ table(adcValue, "maffactor.inc") }
    	solution	= "Ford Lightning MAF", 	{ table(adcValue, "maffactor_1L3F_Lightning.inc") }
		solution	= "Infiniti Q45 MAF", 		{ table(adcValue, "maffactor_Q45.inc") }
		solution	= "GM LT1/LS1/LS2 MAF", 	{ table(adcValue, "maffactor_lsx.inc") }
        solution    = "Custom inc File",    fileBrowseGenerator

[SettingGroups]
   ; the referenceName will over-ride previous, so if you are creating a 
   ; settingGroup with a reference name of lambdaSensor, it will replace the 
   ; setting group defined in the settingGroups.xml of the TunerStudio config
   ; folder. If is is an undefined referenceName, it will be added.
   ; keyword    =  referenceName,  DisplayName

    settingGroup = lambdaSensor, "Oxygen Sensor / Display" 
    settingOption = NARROW_BAND_EGO, "Narrowband Sensor - Volts"
    settingOption = LAMBDA, "Wideband - Lambda"
    settingOption = DEFAULT, "WideBand - AFR" ; DEFAULT will be over looked and this will fall into the #else block of the statement.

    settingGroup = lambdaDisplay, "" ; Hide this settingGroup option
    settingOption = DEFAULT, "" ;

[PcVariables]
   ; valid types: boolean, double, int, list
   ;  
   ; no offset as they are local variables. 
   ; entry format the same as Constants, except there is no offset.
   ; arrays are not yet supported. 
   ; name = class,  type,    shape,  units,       scale, translate,    lo,      hi, digits
   ; name = type, min, max;
   ;
   ; type List: value will be index.
   
   ;tsCanId      = bits,   U08,   [0:3] ; The short one, just numbers
    tsCanId       = bits,   U08,   [0:3], "CAN ID 0", "CAN ID 1", "CAN ID 2", "CAN ID 3", "CAN ID 4", "CAN ID 5", "CAN ID 6", "CAN ID 7", "CAN ID 8", "CAN ID 9", "CAN ID 10","CAN ID 11","CAN ID 12","INVALID","CAN ID 14","INVALID"
;    testScale     = scalar, U16,    "%",   0.001,   0,    0,    600,   4
;    testTransform = scalar, U08,    "#",     0.1,   0,    0,   25.5,   1
    rpmhigh = scalar, U16, "rpm", 1, 0, 0, 30000, 0
    rpmwarn = scalar, U16, "rpm", 1, 0, 0, 30000, 0
    rpmdang = scalar, U16, "rpm", 1, 0, 0, 30000, 0
    loadhigh = scalar, U16, "", 1, 0, 100, 1000, 0
;    clt_exp = bits, U08, [0:0], "Normal", "Expanded"

[LoggerDefinition]
    ; valid logger types: composite, tooth, trigger, csv
    
    ;loggerDef = uniqueName, Display Name, type
    loggerDef = mapLogger, "MAP Logger", csv
       dataReadCommand = "r\\x00\\xf4\\x00\\x00\\x04\\x00" ; standard TS command format
       dataReadTimeout = 10000 ; time in ms
       dataReadyCondition = { ( status3 & 0x02 ) == 0x02 }
       ;dataLength = 1024 ; in bytes, including headers, footers and data //not used..
       
       ;recordDef = headerLen. footerLen, recordLen
       recordDef =   0,   0,   2; in bytes, the recordLen is for each record, currently limited to 4 bytes
       
       ;recordField = Name,          HeaderName, startBit, bitCount, scale, units, updateCondition
       recordField = nonMap,           "Not MAP",       15, 1, 1.0, "Flag"
       recordField = mapWindow,        "Where",         14, 1, 1.0, "Flag", { !nonMap } 
       recordField = rpmPrint,         "isRPM",         14, 1, 1.0, "Flag", { nonMap } 
       recordField = mapSensor,        "Sensor",        10, 3, 1.0, "#",    { !nonMap }    
       recordField = mapAdc,           "MAP ADC",       0, 10, 1.0, "ADC",  { !nonMap }    
       recordField = sampleRpm,        "RPM",           0, 14, 1.0, "rpm",  { nonMap && rpmPrint }    
       recordField = crankAngle,       "CrankAngle",    0, 13, 0.1, "deg",  { nonMap && !rpmPrint } 
       
       ;calcField  = name,        HeaderName,    units, expression
       calcField   = mapValue,         "MAP",   "kPa",  { map0 + (mapmax - map0) * mapAdc/1023 }

[Constants]

   ;----------------------------------------------------------------------------
   ; Constants Definition
   ; --------------------
   ;
   ; Scalar Values
   ; -------------
   ; The scaling and translation values are used as follows:
   ;    msValue   = userValue / scale - translate
   ;    userValue = (msValue + translate) * scale
   ;
   ; Array Values
   ; ------------
   ; Arrays are specified just like scalars, except that they have a "shape"
   ; entry in the fourth parameter.  The shape allows you to define lists or
   ; tables, for example [8] defines a list with eight values and [2x4] defines
   ; a table with eight values (two rows and four columns).  Tables may be
   ; stored in either "X-" or "Y-order."  X-order means that memory is layed
   ; out like.
   ;
   ;     [x1,y1] [x2,y1]...[xn,y1] [x1,y2]...
   ;
   ; Y-order would be
   ;
   ;     [x1,y1] [x1,y2]...[x1,yn] [x2,y1]...
   ;
   ; To use the TableEditor, you must define two lists and a table, and
   ; the lengths of the lists must correspond to the shape of the table.
   ;
   ; Bit Fields
   ; ----------
   ; Bits are numbered 0-7, the rightmost being bit zero.  The basic
   ; data word that stores bit fields must be unsigned.
   ;
   ; You need NOT supply the correct number of labels matching the
   ; number of bits you've specified (one bit requires 2 values, two
   ; bits requires 4 values and so on).  If you neglect to supply enough
   ; labels, they will be synthesized using the sequence "1", "2" and so
   ; on based upon their position in the sequence (the cltType and matType
   ; will end up with identical lists).
   ;
   ;----------------------------------------------------------------------------

; updated settings from "new" serial
   pageActivationDelay = 1
   blockReadTimeout = 300
; next two from TS 1.18.1 testing
   writeBlocks = on
   interWriteDelay = 0

;Relationship between TS pages and MS3 pages
;MT  MS3 internal
;MS3 internal pages 0-3 are sensor lookup tables
;1     4
;2     5
;MS3 internal pages 6,7 are outpc,txbuf
;3     8
;4     9
;5     10
;6     11
;7     12
;8     13
;9     18
;10    19
;11    21
;12    22
;13    23
;14    24

   endianness          = big
   nPages              = 14
   pageSize            = 1024,                1024,                1024,                1024,	     1024,	       1024,	        1024,	          1024,              1024,              1024,              1024,               1024,             1024,              1024
   pageIdentifier      = "\$tsCanId\x04",   "\$tsCanId\x05",  "\$tsCanId\x08",   "\$tsCanId\x09",   "\$tsCanId\x0a",  "\$tsCanId\x0b",  "\$tsCanId\x0c",  "\$tsCanId\x0d",   "\$tsCanId\x12",  "\$tsCanId\x13",   "\$tsCanId\x15",   "\$tsCanId\x16",   "\$tsCanId\x17",   "\$tsCanId\x18"
   burnCommand         = "b%2i",            "b%2i",           "b%2i",            "b%2i",            "b%2i",           "b%2i",           "b%2i",           "b%2i",            "b%2i",           "b%2i",            "b%2i",            "b%2i",            "b%2i",            "b%2i"
   pageReadCommand     = "r%2i%2o%2c",      "r%2i%2o%2c",     "r%2i%2o%2c",      "r%2i%2o%2c",      "r%2i%2o%2c",     "r%2i%2o%2c",     "r%2i%2o%2c",     "r%2i%2o%2c",      "r%2i%2o%2c",     "r%2i%2o%2c",      "r%2i%2o%2c",      "r%2i%2o%2c",      "r%2i%2o%2c",      "r%2i%2o%2c"
   pageValueWrite      = "w%2i%2o%2c%v",    "w%2i%2o%2c%v",   "w%2i%2o%2c%v",    "w%2i%2o%2c%v",    "w%2i%2o%2c%v",   "w%2i%2o%2c%v",   "w%2i%2o%2c%v",   "w%2i%2o%2c%v",    "w%2i%2o%2c%v",   "w%2i%2o%2c%v",    "w%2i%2o%2c%v",    "w%2i%2o%2c%v",    "w%2i%2o%2c%v",    "w%2i%2o%2c%v"
   pageChunkWrite      = "w%2i%2o%2c%v",    "w%2i%2o%2c%v",   "w%2i%2o%2c%v",    "w%2i%2o%2c%v",    "w%2i%2o%2c%v",   "w%2i%2o%2c%v",   "w%2i%2o%2c%v" ,  "w%2i%2o%2c%v",    "w%2i%2o%2c%v",   "w%2i%2o%2c%v",    "w%2i%2o%2c%v",    "w%2i%2o%2c%v",    "w%2i%2o%2c%v",    "w%2i%2o%2c%v"
   crc32CheckCommand   = "k%2i\x00\x00\x00\x04",   "k%2i\x00\x00\x00\x04",   "k%2i\x00\x00\x00\x04",   "k%2i\x00\x00\x00\x04",   "k%2i\x00\x00\x00\x04", "k%2i\x00\x00\x00\x04", "k%2i\x00\x00\x00\x04", "k%2i\x00\x00\x00\x04", "k%2i\x00\x00\x00\x04", "k%2i\x00\x00\x00\x04", "k%2i\x00\x00\x00\x04", "k%2i\x00\x00\x00\x04", "k%2i\x00\x00\x00\x04", "k%2i\x00\x00\x00\x04"

; new serial
   messageEnvelopeFormat = msEnvelope_1.0 

   page = 1
   ;  name            = class,  type, offset,      shape,  units,       scale, translate,    lo,      hi, digits
      nCylinders      = bits,    U08,      0,      [0:4], "INVALID","1","2","3","4","5","6","7","8","9","10","11","12","13","14","15","16","INVALID","INVALID","INVALID","INVALID","INVALID","INVALID","INVALID","INVALID","INVALID","INVALID","INVALID","INVALID","INVALID","INVALID","INVALID"
      no_skip_pulses  = scalar,  U08,      1,             "",         1.00000,   0.00000,  1.00,  10.00,      0 ; * (  1 byte)
      ICIgnCapture    = bits,    U08,      2,      [0:0], "Falling Edge", "Rising Edge"                          ; ICIgnOption
      engineType      = bits,    U08,      2,      [3:3], "Even fire", "Odd fire"
      spkout_hi_lo    = bits,    U08,      2,      [4:4], "Going Low (Normal)", "Going High (Inverted)"          ; *
      max_coil_dur    = scalar,  U08,      3,             "ms",       0.1000,   0.00000,  1.00,    8.00,      1 ; * (  1 byte)
      max_spk_dur     = scalar,  U08,      4,             "ms",       0.1000,   0.00000,  0.00,   25.50,      1 ; * (  1 byte)

      dwellAcc        = scalar,  U08,      5,             "ms",       0.1000,   0.00000,  0.00,   25.50,      0 ; * (  1 byte)
      crankingRPM     = scalar,  S16,     6,             "RPM",      1.00000,   0.00000,  0.00,  3000.0,      0 ; * (  2 bytes)
      triggerOffset   = scalar,  S16,     8,             "deg",      0.10000,   0.00000, -90.0,  180.00,      1 ; * (  2 bytes)
      TpsBypassCLTRevlim = scalar, S16,   10,             "TPS %",    0.10000,   0.00000, 0,      100,         1 ; * (  2 bytes)
      RevLimRpm2      = scalar,  S16,     12,             "RPM",      1.00000,   0.00000,  0.00,{rpmhigh},      0 ; * (  2 bytes)
      map0            = scalar,  S16,    14,             "%",      0.10000,   0.00000, -100.0, 3276.7,      1 ; * (  2 bytes)
      mapmax          = scalar,  S16,    16,             "%",      0.10000,   0.00000, -100.0, 3276.7,      1 ; * (  2 bytes)
#if CELSIUS
      clt0            = scalar,  S16,    18,             "°C",       0.05555,  -320.000, -100.0,  500.0,      1 ; * (  2 bytes)
      cltmult         = scalar,  S16,    20,             "%",        1.00000,   0.00000, -200.0,  200.0,      0 ; * (  2 bytes)
      mat0            = scalar,  S16,    22,             "°C",       0.05555,  -320.000, -100.0,  500.0,      1 ; * (  2 bytes)
#else
      clt0            = scalar,  S16,    18,             "°F",       0.10000,   0.00000, -100.0,  500.0,      1
      cltmult         = scalar,  S16,    20,             "%",        1.00000,   0.00000, -200.0,  200.0,      0
      mat0            = scalar,  S16,    22,             "°F",       0.10000,   0.00000, -100.0,  500.0,      1
#endif
      matmult         = scalar,  S16,    24,             "%",        1.00000,   0.00000, -200.0,  200.0,      0 ; * (  2 bytes)

      tpsMin          = scalar,  S16,    26,             "ADC",      1.00000,   0.00000,    0.0, 1023.0,      0 ; * (  2 bytes)
      tpsMax          = scalar,  S16,    28,             "ADC",      1.00000,   0.00000,    0.0, 1023.0,      0 ; * (  2 bytes)
      batt0           = scalar,  S16,    30,             "V",        0.10000,   0.00000,    0.0, 3276.7,      1 ;   (  2 bytes)
      battmax         = scalar,  S16,    32,             "V",        0.10000,   0.00000,-3276.8, 3276.7,      1 ;   (  2 bytes)
      ego0            = scalar,  S16,    34,             "afr",      0.10000,   0.00000,-3276.8, 3276.7,      1 ;   (  2 bytes)
      egomult         = scalar,  S16,    36,             "%",        1.00000,   0.00000, -200.0,  200.0,      0 ;   (  2 bytes)

      baro0           = scalar,  S16,    38,             "kPa",      0.10000,   0.00000,-3276.8, 3276.7,      1 ; * (  2 bytes)
      baromax         = scalar,  S16,    40,             "kPa",      0.10000,   0.00000,-3276.8, 3276.7,      1 ; * (  2 bytes)
      bcor0           = scalar,  S16,    42,             "%",        1.00000,   0.00000,-3276.8, 3276.7,      1 ; * (  2 bytes)
      bcormult        = scalar,  S16,    44,             "%",        1.00000,   0.00000, -200.0,  200.0,      0 ; * (  2 bytes)
      Xknock0          = scalar,  S16,    46,             "V",        0.01000,   0.00000,    0.0,    5.0,      1 ; * (  2 bytes)
      Xknockmax        = scalar,  S16,    48,             "V",        0.01000,   0.00000,    0.0,    5.0,      1 ; * (  2 bytes)
      crankTolerance  = scalar,  U08,    50,             "%",        1.00000,   0.00000,  0.00,  255.00,      0 ; * (  1 byte)
      asTolerance     = scalar,  U08,    51,             "%",        1.00000,   0.00000,  0.00,  255.00,      0 ; * (  1 byte)
      pulseTolerance  = scalar,  U08,    52,             "%",        1.00000,   0.00000,  0.00,  255.00,      0 ; * (  1 byte)
      IdleCtl         = bits  ,  U08,    53,      [0:3], "None", "On/Off valve", "IAC Stepper Moving Only", "IAC Stepper Always On", "PWM Warmup", "15-Minute IAC", "PWM Closed-loop", "IAC Closed-loop moving only", "IAC Closed-loop always-on", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID" ; *
      IdleCtl_vss     = bits  ,  U08,    53,      [4:4], "Standard", "Use VSS"
      IACtstep        = scalar,  U08,    54,             "ms",       0.128,   0.00000,  0.00,   25.50,      1 ; * (  1 byte) changed to be 0.128 ticks
      IAC_tinitial_step=scalar,  U08,    55,             "ms",  0.128,   0.00000,  0.00,   25.50,      1 ; * (  1 byte)
      IACminstep      = scalar,  U08,    56,             "steps",         1.00000,   0.00000,  0.00,  255.00,      0 ; * (  1 byte)
      dwellduty       = scalar,  U08,    57,             "%",        0.39,      0.0,      0,     100,0
      IACStart        = scalar,  S16,    58,             "",         1.00000,   0.00000,  0.00, 4000.00,      0 ; * (  1 byte)
#if CELSIUS
	#if EXPANDED_CLT_TEMP
      IdleHyst        = scalar,  S16,    60,             "°C",       0.05555,   0.00000, -40.0,  230.0,       1 ; * (  2 bytes)
      IACcoldtmp      = scalar,  S16,    66,             "°C",       0.05555,  -320.000, -40.0,  230.0,       1 ; * (  2 bytes)
	#else
      IdleHyst        = scalar,  S16,    60,             "°C",       0.05555,   0.00000, -40.0,  150.0,       1 ; * (  2 bytes)
      IACcoldtmp      = scalar,  S16,    66,             "°C",       0.05555,  -320.000, -40.0,  150.0,       1 ; * (  2 bytes)
	#endif
#else
	#if EXPANDED_CLT_TEMP
      IdleHyst        = scalar,  S16,    60,             "°F",       0.10000,   0.00000, -40.0,  450.0,       1
      IACcoldtmp      = scalar,  S16,    66,             "°F",       0.10000,   0.00000,-40.00,  450.00,      1
	#else
      IdleHyst        = scalar,  S16,    60,             "°F",       0.10000,   0.00000, -40.0,  300.0,       1
      IACcoldtmp      = scalar,  S16,    66,             "°F",       0.10000,   0.00000,-40.00,  300.00,      1
	#endif
#endif
      IACcrankpos     = scalar,  S16,    62,             "steps",    1.00000,   0.00000,  0.00, 4000.00,      0 ; * (  2 bytes)
      IACcrankxt      = scalar,  S16,    64,             "sec",      1.00000,   0.00000,  0.00,32767.00,      0 ; * (  2 bytes)
;coldtemp above to save IF clauses
      IACcoldpos      = scalar,  S16,    68,             "steps",    1.00000,   0.00000,  0.00, 4000.00,      0 ; * (  2 bytes)
      IACcoldxt       = scalar,  S16,    70,             "sec",      1.00000,   0.00000,  0.00,32767.00,      0 ; * (  2 bytes)
      OverBoostKpa2   = scalar,  S16,    72,             "kPa",      0.10000,   0.00000,  0.00,  {loadhigh},        1
      fc_rpm_lower    = scalar,  U16,    74,             "rpm",      1.00000,       0.0,   0.0,     {rpmhigh},    0 ; * (  1 byte)
      OverBoostOption = bits,    U08,    76,     [0:1],  "None",    "Fuel Cut", "Spark Cut", "Both"
      hardware_spk    = bits,    U08,    77,     [0:2],   "JS10 spark", "LEDs spark", "MS3X spark", "INVALID", "Tacho", "INVALID", "INVALID", "INVALID"
      hardware_cam    = bits,    U08,    77,     [3:3],   "JS10", "MS3X Cam in"
      hardware_fuel   = bits,    U08,    77,     [4:4],   "Std fuel", "MS3X fuel"
      hardware_injij  = bits,    U08,    77,     [5:5],   "Mainboard", "H3+H4"
      OverBoostKpa    = scalar,  S16,    78,             "kPa",      0.10000,   0.00000,  0.00,  {loadhigh},        1
      OverBoostHyst   = scalar,  S16,    80,             "kPa",      0.10000,   0.00000,  0.00,  100,         1
      overboostcutx   = scalar,  U08,    82,             "",         1, 0, 0, 255, 0
      overboostcuty   = scalar,  U08,    83,             "",         1, 0, 0, 255, 0 
      tpsThresh       = scalar,  S16,    84,             "%/s",      0.10000,   0.00000,  0.00,  1000.0,      1 ; * (  2 byte)
      mapThresh       = scalar,  S16,    86,             "kPa/s",    1.00000,   0.00000,  0.00,  1000.0,      0 ; * (  2 byte) threshold for MAE
      taeColdA        = scalar,  U08,    88,             "%ReqFuel",       1,   0.00000,  0.00,  255,      0 ; * (  1 byte) ; Tpsacold
      taeColdM        = scalar,  U08,    89,             "%",        1.00000,   0.00000,  0.00,  255.00,      0 ; * (  1 byte) ; AccMult
      taeTime         = scalar,  U08,    90,             "s",        0.10000,   0.00000,  0.00,   25.50,      1 ; * (  1 byte) ; TpsAsync
      tdePct          = scalar,  U08,    91,             "",         1.00000,   0.00000,  0.00,  255.00,      0 ; * (  1 byte) ; TPSDQ
      floodClear      = scalar,  S16,    92,             "%",        0.10000,   0.00000,  0.00,  100.00,      1 ; * (  2 bytes) ; TPSWOT
      TPSOXLimit      = scalar,  S16,    94,             "%",        0.10000,   0.00000,  0.00,  300.00,      1 ; * (  2 bytes) ; TPSOXLimit
      tpsProportion   = scalar,  U08,    96,             "%",        1.00000,   0.00000,  0.00,  100.00,      0 ; * (  1 byte) ; Tps_acc_wght
      baroCorr        = bits  ,  U08,    97,      [0:1], "None", "Initial MAP Reading", "Two Independent Sensors", "INVALID"; BaroOption
      egoType         = bits  ,  U08,    98,      [0:1], "Disabled", "Narrow Band", "Wide Band", "INVALID"                  ; egoOption
      egoCount        = scalar,  U08,    99,             "",         1.00000,   0.00000,  0.00,  255.00,      0 ; * (  1 byte)
      egoDelta        = scalar,  U08,    100,             "%",        1.00000,   0.00000,  0.00,  255.00,      0 ; * (  1 byte)
      oldegoLimit     = scalar,  U08,    101,             "%",        1.00000,   0.00000,  0.00,  255.00,      0 ; * (  1 byte)
      EGOVtarget       = scalar,  U08,    102,             "Volts",     0.00489,   0.00000,  0.00,   1,     3 
      tempUnits       = bits  ,  U08,    103,      [0:0], "Coolant/MAT Tables in °F", "Coolant/MAT Tables in °C" ; * (  1 byte)
      egonum          = scalar,  U08,    104,               "",         1, 0, 0, 16, 0
;pad
#if CELSIUS
	#if EXPANDED_CLT_TEMP
      fastIdleT       = scalar,  S16,    106,             "°C",       0.05555,  -320.000,-40.00,  230.00,      1 ; * (  2 bytes)
      egoTemp         = scalar,  S16,    108,             "°C",       0.05555,  -320.000,-40.00,  230.00,      1 ; * (  2 bytes)
	#else
      fastIdleT       = scalar,  S16,    106,             "°C",       0.05555,  -320.000,-40.00,  150.00,      1 ; * (  2 bytes)
      egoTemp         = scalar,  S16,    108,             "°C",       0.05555,  -320.000,-40.00,  150.00,      1 ; * (  2 bytes)
	#endif	  
#else
	#if EXPANDED_CLT_TEMP
      fastIdleT       = scalar,  S16,    106,             "°F",       0.10000,   0.00000,-40.00,  450.00,      1
      egoTemp         = scalar,  S16,    108,             "°F",       0.10000,   0.00000,-40.00,  450.00,      1
	#else
      fastIdleT       = scalar,  S16,    106,             "°F",       0.10000,   0.00000,-40.00,  300.00,      1
      egoTemp         = scalar,  S16,    108,             "°F",       0.10000,   0.00000,-40.00,  300.00,      1
	#endif
#endif
      egoRPM          = scalar,  S16,    110,             "RPM",      1.00000,   0.00000,  0.00, {rpmhigh},      0 ; * (  2 bytes)
#if PW_4X
      reqFuel         = scalar,  U16,    112,             "ms",       0.004,   0.00000,  0.00,  262.143,      2 ; * (  2 bytes)
#else
      reqFuel         = scalar,  U16,    112,             "ms",       0.001,   0.00000,  0.00,  65.535,      2 ; * (  2 bytes)
#endif
      divider         = scalar,  U08,    114,             "",         1.00000,   0.00000,  0.00,     255,      0 ; * (  1 byte)
      alternate       = bits,    U08,    115,      [0:0], "Simultaneous", "Alternating"                          ; * (  1 byte)
      altcrank        = bits,    U08,    115,      [1:1], "Every event", "Alternate events"
      injPwmT         = scalar,  U08,    116,             "ms",       0.12800,   0.128,  0.00,   32.64,      1 ; * (  1 byte)
      injPwmPd        = scalar,  U08,    117,             "us",       1.00000,   0.00000, 40.00,  100.00,      0 ; * (  1 byte)
      injPwmP         = scalar,  U08,    118,             "%",        1.00000,   0.00000,  0.00,  100.00,      0 ; * (  1 byte)
      twoStroke       = bits,    U08,    119,      [0:1], "Four-stroke",    "Two-stroke", "INVALID", "Rotary"    ; *
      injType         = bits,    U08,    120,      [0:0], "Port Injection", "Throttle Body"                      ; *
      nInjectors      = bits,    U08,    121,      [0:4], "INVALID", "1", "2", "3", "4", "5", "6", "7", "8", "9", "10", "11", "12", "13", "14", "15", "16", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID"
      OddFireang      = scalar,  U16,    122,             "",         0.10000,   0.00000,  0.00,  720.00,      0 ; * (  2 byte)
      rpmLF           = scalar,  U08,    124,             "",         1.00000,   0.00000,  10.00,  100.00,      0 ; * (  1 byte)
      mapLF           = scalar,  U08,    125,             "",         1.00000,   0.00000,  10.00,  100.00,      0 ; * (  1 byte)
      tpsLF           = scalar,  U08,    126,             "",         1.00000,   0.00000,  10.00,  100.00,      0 ; * (  1 byte)
      egoLF           = scalar,  U08,    127,             "",         1.00000,   0.00000,  10.00,  100.00,      0 ; * (  1 byte)
      adcLF           = scalar,  U08,    128,             "",         1.00000,   0.00000,  10.00,  100.00,      0 ; * (  1 byte)
      knk_pin_out     = bits, U08,      129, [0:4], "Off", "IAC1", "IAC2", "FIDLE", "D15", "Nitrous 1", "Nitrous 2", "Tacho", "Idle", "Boost", "VVT", "Inj Bank 1", "Inj Bank 2", "D14", "D16", "JS11", "Inj A", "Inj B", "Inj C", "Inj D", "Inj E", "Inj F", "Inj G", "Inj H", "PT4", "IGN (JS10)", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID"
      AMCOption       = bits,    U08,    130,      [0:1], "Disabled", "RAM Update", "FLASH Update", "INVALID"    ; * (  1 byte)
    UNUSED_1_131      = bits,    U08,    131,      [0:0], "Single Table", "Dual Table"                           ; *
      algorithm       = bits,    U08,    132,      [0:3], "INVALID", "Speed Density", "Percent Baro", "Alpha-N", "INVALID", "MAF", "ITB", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID" ; *
      algorithm2      = bits,    U08,    132,      [4:7], "Disabled", "Speed Density", "Percent Baro", "Alpha-N", "MAFMAP", "INVALID", "ITB", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID"
      IgnAlgorithm    = bits,    U08,    133,      [0:3], "INVALID", "Speed Density", "Percent Baro", "Alpha-N", "MAFMAP", "INVALID", "ITB", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID"
      IgnAlgorithm2   = bits,    U08,    133,      [4:7], "Disabled", "Speed Density", "Percent Baro", "Alpha-N", "MAFMAP", "INVALID", "ITB", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID"
      AfrAlgorithm    = scalar,  U08,    134,             "",         1.00000,   0.00000,  0.00,  255.00,      0 ; U (  1 byte) UNUSED
      dwelltime       = scalar,  U08,    135,             "ms",       0.10000,       0,        0.1,     25.5, 1
      trigret_ang     = scalar,  U16,    136,    "deg", 0.1, 0, 5, 180,1
      RevLimOption_retard = bits,U08,    138,      [0:1], "Off", "Progressive retard", "Fixed angle", "INVALID"
      RevLimOption_spkcut = bits,U08,    138,      [2:2], "Off", "On"
      RevLimCLTbased  = bits,    U08,    138,      [3:3], "Normal", "CLT based"
      RevLimMaxRtd    = scalar,  U08,    139,             "deg",      0.10000,   0.00000,0,   25.5,      0 ; * (  1 byte)
      ego_startdelay  = scalar,  U08,    140,             "sec",      1, 0, 0, 120, 0
      can_poll2_ego   = bits,    U08,    141, [0:0], "Disable", "Enable"
      opt142_rtc      = bits,    U08,    142, [0:1], "Off", "On-board", "CAN", "INVALID"
      opt142_gs_share = bits,    U08,    142, [2:2], "Off", "On"
      injPwmT2        = scalar,  U08,    143,             "ms",       0.12800,   0.12800,  0.00,   32.64,      1 ; * (  1 byte)
      injPwmPd2       = scalar,  U08,    144,             "us",       1.00000,   0.00000, 40.00,  100.00,      0 ; * (  1 byte)
      injPwmP2        = scalar,  U08,    145,             "%",        1.00000,   0.00000,  0.00,  100.00,      0 ; * (  1 byte)
      can_ego_id      = scalar,  U08,    146,            "",        1.00000,   0.00000,  0.00,  14,      0 ;
	  can_ego_table   = scalar,  U08,    147,             "",         1.00000,   0.00000,     0,     15,       0 ; * (  1 byte)
	  can_ego_offset  = scalar,  U16,    148,             "bytes",    1.00000,   0.00000,     0,   4095,       0
      baro_upper      = scalar,  S16,    150,             "kPa",      0.10000,   0.00000,  0.00,  {loadhigh},      1 ;
      baro_lower      = scalar,  S16,    152,             "kPa",      0.10000,   0.00000,  0.00,  {loadhigh},      1 ;
      baro_default    = scalar,  S16,    154,             "kPa",      0.10000,   0.00000,  0.00,  {loadhigh},      1 ;
      RevLimTPSbypassRPM = scalar, S16,  156,             "RPM",      1.00000,   0.00000,  0.00,  {rpmhigh},       0 ;
      RevLimNormal1 =   scalar,  S16,    158,             "RPM",      1.00000,   0.00000,  0.00,  {rpmhigh},       0 ;
      RevLimNormal2 =   scalar,  S16,    160,             "RPM",      1.00000,   0.00000,  0.00,  {rpmhigh},       0 ;
      hw_latency      = scalar,  U08,    162,      "usec", 1.0, 0.00000, 0.00, 255.00, 0
;next three are loadopts in the firmware
      loadCombine     = bits,    U08,    163,      [0:0], "additive", "multiplicitive"
      loadMult	      = bits,    U08,    163,      [2:2], "don't multiply", "multiply"
      loadStoich      = bits,    U08,    163,      [3:3], "don't include AFRtarget", "include AFRtarget"
      baud            = scalar,  U32,    164,             "",         1.00000,   0.00000,9600.0,115200.0,      0 ; x (  4 bytes)
      MAPOXLimit      = scalar,  S16,    168,             "%",      0.10000,   0.00000,  0.00,  300.00,      2 ; * (  2 bytes)

      can_poll_id_rtc = scalar,  U08,    170,            "",        1.00000,   0.00000,  0.00,  14,      0 ;
      mycan_id        = scalar,  U08,    171,            "",        1.00000,   0.00000,  0.00,  14,      0 ;

      mapsample_percent = scalar, U08,   172,            "%",       1.00000,   0.00000,  0.00,  50,       0
      can_poll_id_ports = scalar,  U08,    173,            "",        1.00000,   0.00000,  0.00,  14,      0 ;
      can_poll_id     = scalar,  U08,    174,            "",        1.00000,   0.00000,  0.00,  14,      0 ;
      aeTaperTime     = scalar,  U08,    175,             "s",        0.10000,   0.00000,  0.00,   25.50,      1 ; * (  1 byte) ; TpsAsync2
      aeEndPW         = scalar,  S16,    176,             "%ReqFuel",       1,   0.00000,  0.00, 100,      0 ; * tpsaccel2 ; TpsAccel2

      egoAlgorithm    = bits  ,  U08,    178,      [0:1], "Simple", "INVALID", "PID", "No correction" ; * (  1 byte)
      egoKP           = scalar,  U08,    179,             "%",        1.00000,   0.00000,  0.00,  200.00,      0 ; * (  1 byte)
      egoKI           = scalar,  U08,    180,             "%",        1.00000,   0.00000,  0.00,  200.00,      0 ; * (  1 byte)
      egoKD           = scalar,  U08,    181,             "%",        1.00000,   0.00000,  0.00,  200.00,      0 ; * (  1 byte)

#if MPH
      ac_idleup_vss_offpoint = scalar,  U16,    182,      "MPH",      0.22369,   0.00000,  0.00,   200,      0 ; * (  2 bytes)
      ac_idleup_vss_hyst     = scalar,  U16,    184,      "MPH",      0.22369,   0.00000,  0.00,   200,      0 ; * (  2 bytes)
#else
      ac_idleup_vss_offpoint = scalar,  U16,    182,      "KPH",      0.3600,    0.00000,  0.00,   300,      0  
      ac_idleup_vss_hyst =     scalar,  U16,    184,      "KPH",      0.3600,    0.00000,  0.00,   300,      0
#endif

      flexFuel        = bits  ,  U08,    186,      [0:0], "Disabled", "Enabled"                                  ; * (  1 byte)
      flexport        = bits,    U08,    186,      [1:2], "PE0/JS7", "JS11", "Flex input", "INVALID";  (1 byte )
      fuelFreq        = array ,  U08,    187,    [    2], "Hz",       1.00000,   0.00000,  0.00,     255,      0 ; * (  2 bytes)
         fuelFreq0    = scalar,  U08,    187,             "Hz",       1.00000,   0.00000,  0.00,     255,      0
         fuelFreq1    = scalar,  U08,    188,             "Hz",       1.00000,   0.00000,  0.00,     255,      0
      fuelCorr        = array ,  U08,    189,    [    2], "%",        1.00000,   0.00000,  0.00,     255,      0 ; * (  2 bytes)
         fuelCorr0    = scalar,  U08,    189,             "%",        1.00000,   0.00000,  0.00,     255,      0
         fuelCorr1    = scalar,  U08,    190,             "%",        1.00000,   0.00000,  0.00,     255,      0

      dwellmode       = bits  ,  U08,    191,  [0:1], "Standard Dwell", "Fixed Duty", "Time after Spark", "Charge at Trigger"
      pwmidle_shift_lower_rpm = scalar, U16, 192,        "rpm",       1.00000,   0.00000,  0.00,      {rpmhigh},    0
      ac_idleup_tps_offpoint = scalar,  S16, 194,        "%",         0.10000,   0.00000,  0.00,      100.00,   1 
      ac_idleup_tps_hyst = scalar,      S16, 196,        "%",         0.10000,   0.00000,  0.00,      100.00,   1
      fan_idleup_tps_offpoint = scalar, S16, 198,        "%",         0.10000,   0.00000,  0.00,      150.00,   1
      fan_idleup_tps_hyst = scalar,     S16, 200,        "%",         0.10000,   0.00000,  0.00,      100.00,   1
#if MPH
      fan_idleup_vss_offpoint = scalar, U16, 202,        "MPH",       0.22369,   0.00000,  0.00,      200.00,   0
#else
      fan_idleup_vss_offpoint = scalar, U16, 202,        "KPH",       0.3600,    0.00000,  0.00,      300.00,   0
#endif

      knk_option       = bits ,  U08,    204,      [0:1], "Disabled", "Safe Mode", "Aggressive Mode", "INVALID"  ; * (  1 byte )
      knk_option_an    = bits ,  U08,    204,      [2:3], "On/Off", "Analogue", "INVALID", "Internal"

      knkDirection    = bits  ,  U08,    204,      [4:4], "Low Input", "High Input"                   ; *
      knkpull         = bits  ,  U08,    204,      [5:6], "INVALID", "None", "Pull up", "INVALID"                   ; *
      knk_option_wind  = bits ,  U08,    204,      [7:7], "At end", "Peak"

      knk_maxrtd      = scalar,  U08,    205,             "deg",      0.1,       0.0,      0.0,    25.5,       1 ; * (  1 byte )
      knk_step1       = scalar,  U08,    206,             "deg",      0.1,       0.0,      1.0,    25.5,       1 ; * (  1 byte )
      knk_step2       = scalar,  U08,    207,             "deg",      0.1,       0.0,      0.5,    10.0,       1 ; * (  1 byte )
      knk_trtd        = scalar,  U08,    208,             "sec",      0.1,       0.0,      0.0,    25.5,       1 ; * (  1 byte )
      knk_tadv        = scalar,  U08,    209,             "sec",      0.1,       0.0,      0.0,    25.5,       1 ; * (  1 byte )
      knk_dtble_adv   = scalar,  U08,    210,             "deg",      0.1,       0.0,      0.0,    25.5,       1 ; * (  1 byte )
      knk_ndet        = scalar,  U08,    211,             "knocks",   1.0,       0.0,      0.0,     255,       0 ; * (  1 byte )
      EAEOption       = bits  ,  U08,    212,      [0:2], "Off", "EAE", "INVALID", "X-tau", "X-tau with CLT correction", "INVALID", "INVALID", "INVALID"      ; * (  1 byte )
      knkport         = bits,    U08,    213, [0:3], "INVALID", "Tableswitch", "PE0/JS7", "PE1", "JS10", "JS11", "JS5 (ADC6)", "JS4 (ADC7)", "Nitrous In", "Launch in", "Datalog In", "EXT_MAP (ADC11)", "EGO2 (ADC12)", "Spare ADC (ADC13)","INVALID","INVALID" 
      knk_maxmap      = scalar,  U16,    214,             "kPa",      0.1,       0.0,      0.0,   {loadhigh},       1 ; * (  2 bytes)
      knk_lorpm       = scalar,  U16,    216,             "rpm",      1.0,       0.0,      0.0,   {rpmhigh},       0 ; * (  2 bytes)
      knk_hirpm       = scalar,  U16,    218,             "rpm",      1.0,       0.0,      0.0,   {rpmhigh},       0 ; * (  2 bytes)


      triggerTeeth    = scalar,  U16,    220,             "teeth",    1.0,       0.0,      0.0,     512,       0 ; * (  2 bytes)
      No_Miss_Teeth   = scalar,  U08,    222,             "teeth",    1.0,       0.0,      0.0,     255,       0 ; * (  1 byte )
      pwmidle_shift_open_time = scalar, U08, 223,         "sec",      1.0,       0.0,      0.0,     20,        0 ; * (  1 byte )
      Miss_ang        = scalar,  U16,    224,             "deg BTDC",    0.1,       0.0,      0.0,     720,       1 ; * (  2 bytes )
      ICISR_tmask     = scalar,  U08,    226,             "ms",       0.1,       0.0,      0.0,    25.5,       1 ; * (  1 byte )
      ICISR_pmask     = scalar,  U08,    227,             "%",        1.0,       0.0,      0.0,     90,       0 ; * (  1 byte )

      ae_lorpm        = scalar,  U16,    228,             "rpm",      1.0,       0.0,      0.0,   {rpmhigh},       0 ; * (  2 bytes)
      ae_hirpm        = scalar,  U16,    230,             "rpm",      1.0,       0.0,      0.0,   {rpmhigh},       0 ; * (  2 bytes)

      fuelSpkDel      = array ,  S16,    232,    [    2], "deg",      0.10000,   0.00000,-45.00,   45.00,      1 ; * (  4 bytes)
         fuelSpkDel0  = scalar,  S16,    232,             "deg",      0.10000,   0.00000,-45.00,   45.00,      1
         fuelSpkDel1  = scalar,  S16,    234,             "deg",      0.10000,   0.00000,-45.00,   45.00,      1

      spk_conf2_gm    = bits  ,  U08,    236,      [0:0], "Off", "GM Bypass on SpkB"
      spk_conf2_tfi   = bits  ,  U08,    236,      [1:2], "Off", "TFI Non-signature", "INVALID", "TFI Signature PIP"
;      spk_conf2_cam   = bits  ,  U08,    236,      [3:3], "Off", "On"
      spk_conf2_oddodd= bits  ,  U08,    236,      [4:4], "Alternate", "Paired"
      spk_conf2_dwell = bits  ,  U08,    236,      [5:5], "Off", "On"
      spk_conf2_ngc   = bits  ,  U08,    236,      [6:6], "Off", "Alternate"
      spk_conf2_dli   = bits  ,  U08,    236,      [7:7], "Off", "Toyota DLI"
;spk_config
      spk_config_campol   =bits, U08,    237,      [0:0], "Low", "High"
      spk_config_camcrank = bits, U08,   237,      [1:1], "Crank wheel", "Cam wheel"
      spk_config_trig2 =bits,    U08,    237,      [2:3], "INVALID", "Single wheel with missing tooth", "Dual wheel", "Dual wheel with missing tooth"
      spk_config_trig2l =bits,   U08,    237,      [4:5], "INVALID", "Rising edge", "Falling edge", "Poll level"
      spk_config_resetcam =bits, U08,    237,      [6:7], "Cam", "Crank", "Every cylinder", "INVALID"

 ; invalids in next line are spare and should be used
      spk_mode0       = bits  ,  U08,    238,      [0:5], "EDIS", "EDIS Multispk", "Basic trigger", "Trigger return",  "Toothed wheel", "420A/Neon", "36-2+2", "36-2-2-2", "Subaru 6/7", "Miata 99-04", "6g72", "IAW Weber", "CAS 4/1", "4G63", "Twin trigger", "Chrysler 2.2/2.5", "Renix 44-2-2", "Suzuki Swift", "Suzuki Vitara 2.0", "Daihatsu 3cyl", "Daihatsu 4cyl", "VTR1000", "Rover#1", "Rover#2", "Rover#3", "GM 7X", "Log crank", "Log crank&cam", "QR25DE", "Honda RC51", "Fiat 1.8 16V", "Fuel Only", "Optispark", "Nissan SR20", "Nissan RB25", "CAS360-3","CAS360-4", "CAS360-5", "CAS360-6", "CAS360-7","LS1", "YZF1000", "Honda Acura", "VQ35DE","Jeep 2000", "Jeep 2002", "Zetec VCT", "Flywheel tri-tach", "2JZ VVTi", "Honda TSX/D17", "Mazda6 2.3 VVT", "Viper V10","INVALID", "INVALID", "INVALID", "INVALID","INVALID", "INVALID", "INVALID", "INVALID","INVALID", "INVALID", "INVALID", "INVALID"
      spk_mode3_trim  = bits,    U08,    239,      [0:0], "Off", "On"
      spk_mode3_tach3 = bits,    U08,    239,      [1:1], "MS3X Cam", "JS10"
      spk_mode3_hirespol= bits,  U08,    239,      [2:2], "Normal", "Inverted"

      spk_mode3       = bits,    U08,    239,      [5:7], "Single coil", "INVALID", "Wasted spark", "Wasted COP", "Coil on plug", "INVALID", "Dual dizzy", "INVALID" ;  (1 byte )
      rtbaroport      = bits,   U08,  240, [0:4], "Mainboard", "JS5 (ADC6)", "JS4 (ADC7)", "EXT_MAP (ADC11)", "EGO2 (ADC12)", "Spare ADC (ADC13)", "INVALID", "INVALID", "CAN ADC01", "CAN ADC02", "CAN ADC03", "CAN ADC04", "CAN ADC05", "CAN ADC06", "CAN ADC07", "CAN ADC08", "CAN ADC09", "CAN ADC10", "CAN ADC11", "CAN ADC12", "CAN ADC13", "CAN ADC14", "CAN ADC15", "CAN ADC16", "CAN ADC17", "CAN ADC18", "CAN ADC19", "CAN ADC20", "CAN ADC21", "CAN ADC22", "CAN ADC23", "CAN ADC24"
      ego2port        = bits,   U08,  241, [0:4], "Off", "JS5 (ADC6)", "JS4 (ADC7)", "EXT_MAP (ADC11)", "EGO2 (ADC12)", "Spare ADC (ADC13)", "INVALID", "INVALID", "CAN ADC01", "CAN ADC02", "CAN ADC03", "CAN ADC04", "CAN ADC05", "CAN ADC06", "CAN ADC07", "CAN ADC08", "CAN ADC09", "CAN ADC10", "CAN ADC11", "CAN ADC12", "CAN ADC13", "CAN ADC14", "CAN ADC15", "CAN ADC16", "CAN ADC17", "CAN ADC18", "CAN ADC19", "CAN ADC20", "CAN ADC21", "CAN ADC22", "CAN ADC23", "CAN ADC24"
      mapport      = bits,   U08,  242, [0:4], "Mainboard", "JS5 (ADC6)", "JS4 (ADC7)", "EXT_MAP (ADC11)", "EGO2 (ADC12)", "Spare ADC (ADC13)", "INVALID", "INVALID", "CAN ADC01", "CAN ADC02", "CAN ADC03", "CAN ADC04", "CAN ADC05", "CAN ADC06", "CAN ADC07", "CAN ADC08", "CAN ADC09", "CAN ADC10", "CAN ADC11", "CAN ADC12", "CAN ADC13", "CAN ADC14", "CAN ADC15", "CAN ADC16", "CAN ADC17", "CAN ADC18", "CAN ADC19", "CAN ADC20", "CAN ADC21", "CAN ADC22", "CAN ADC23", "CAN ADC24"
      mapport_t    =   bits,   U08,  242, [5:5], "Voltage", "Frequency"
      mapport_f    =   bits,   U08,  242, [6:7], "PT4", "MS3X cam PT2", "JS10 PT5", "Datalog PT6"
      knkport_an        = bits,   U08,  243, [0:2], "INVALID", "JS5 (ADC6)", "JS4 (ADC7)", "EXT_MAP (ADC11)", "EGO2 (ADC12)", "Spare ADC (ADC13)", "INVALID", "INVALID",
      RevLimcutx      = scalar,  U08,    244,  "",     1, 0, 0, 255, 0
      RevLimcuty      = scalar,  U08,    245,  "",     1, 0, 0, 255, 0
;      feature4_0ftrig  = bits,   U08,    246,      [0:0], "Simple", "Advanced"
      feature4_0igntrig= bits,   U08,    246,      [1:1], "Off", "Ignition trigger indicator"
      feature4_0VEtblsize=bits,  U08,    246,      [2:2], "16x16","12x12" // not used
      feature4_0maxdwl = bits,   U08,    246,      [3:3], "Off", "On"
      feature4_0ftrig = bits,    U08,    246,      [4:5], "Off", "INVALID", "Simple", "Advanced"
      feature4_0mindwl = bits,   U08,    246,      [6:6], "Off", "On"
      timing_flags    = bits,    U08,    247,	 [0:0], "Use Table", "Fixed timing";
      use_prediction  = bits,    U08,    247,    [1:1], "No Prediction", "1st Deriv Prediction";
      crank_dwell     = scalar,  U08,    248,     "ms", 0.1000,0.00000,1.00,8.00,1
      tsw_pin_f       = bits,    U08,    249,      [0:4], "INVALID", "Tableswitch", "PE0/JS7", "PE1", "JS10", "JS11", "JS5 (ADC6)", "JS4 (ADC7)", "Nitrous In", "Launch in", "Datalog In", "PT4 Spare in", "PT2 Cam in", "PE2 Flex", "INVALID", "INVALID", "CANIN1", "CANIN2", "CANIN3", "CANIN4", "CANIN5", "CANIN6", "CANIN7", "CANIN8", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID"
      crank_timing    = scalar,  S16,    250,     "degrees", 0.10000,0.00000,-10.00,90.00,1;
      fixed_timing    = scalar,  S16,    252,	  "degrees", 0.10000,0.00000,-90.00,90.00,1;
      tsf_rpm         = scalar,  U16,    254, "rpm", 1, 0, 0, {rpmhigh}, 0
      tsf_kpa         = scalar,  S16,    256, "kPa", 0.1, 0, 0, {loadhigh}, 1
      tsf_tps         = scalar,  S16,    258, "%", 0.10000,   0.00000,  0.00,  100.00,      1;
      tss_rpm         = scalar,  U16,    260, "rpm", 1, 0, 0, {rpmhigh}, 0
      tss_kpa         = scalar,  S16,    262, "kPa", 0.1, 0, 0, {loadhigh}, 1
      tss_tps         = scalar,  S16,    264, "%", 0.10000,   0.00000,  0.00,  100.00,      1;

;      feature5_0                        266
      OvrRunC        = bits  ,   U08,    266,      [0:0], "Off", "On"          ; * (  1 byte)
      f5_0_tsf       = bits  ,   U08,    266,      [1:1], "Off", "On"
      f5_0_tsf_opt   = bits  ,   U08,    266,      [2:3], "Hardware", "rpm", "kPa", "TPS"
      f5_0_tss       = bits  ,   U08,    266,      [4:4], "Off", "On"
      f5_0_tss_opt   = bits  ,   U08,    266,      [5:6], "Hardware", "rpm", "kPa", "TPS"

      tsw_pin_s       = bits,    U08,    267,      [0:4], "INVALID", "Tableswitch", "PE0/JS7", "PE1", "JS10", "JS11", "JS5 (ADC6)", "JS4 (ADC7)", "Nitrous In", "Launch in", "Datalog In", "PT4 Spare in", "PT2 Cam in", "PE2 Flex", "INVALID", "INVALID", "CANIN1", "CANIN2", "CANIN3", "CANIN4", "CANIN5", "CANIN6", "CANIN7", "CANIN8", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID"
      pwmidlecranktaper= scalar, U08,    268,     "s",        1.00000,   0.00000,  0.00,  100.00,      0
      knk_step_adv    = scalar,  U08,    269,             "deg",      0.1,       0.0,      0.5,    10.0,       1 ; * (  1 byte )
      fc_rpm          = scalar,  U16,    270, "rpm", 1, 0, 0, {rpmhigh}, 0
      fc_kpa          = scalar,  S16,    272, "kPa", 0.1, 0, 0, {loadhigh}, 1
      fc_tps          = scalar,  S16,    274, "%", 0.10000,   0.00000,  0.00,  10.00,      1;
#if CELSIUS
	#if EXPANDED_CLT_TEMP
      fc_clt          = scalar,   S16,    276,  "°C",       0.05555,  -320.000, -40.0,  230.0,      1 ; * (  2 bytes)
	#else
      fc_clt          = scalar,   S16,    276,  "°C",       0.05555,  -320.000, -40.0,  150.0,      1 ; * (  2 bytes)
	#endif
#else
	#if EXPANDED_CLT_TEMP
      fc_clt          = scalar,   S16,    276,  "°F",       0.10000,   0.00000, -40.0,  450.0,      1
	#else
      fc_clt          = scalar,   S16,    276,  "°F",       0.10000,   0.00000, -40.0,  300.0,      1
	#endif
#endif
      fc_delay        = scalar,  U08,    278,  "s",        0.1, 0, 0.5, 5.0, 1

      tacho_opt80     = bits,    U08,    279, [7:7], "Off", "On"
      tacho_opt40     = bits,    U08,    279, [6:6], "Normal", "Half speed"
      tacho_opt3f     = bits,    U08,    279, [0:4], "INVALID", "IAC1", "IAC2", "FIDLE", "D15", "Nitrous 1", "Nitrous 2", "Tacho", "Idle", "Boost", "VVT", "Inj Bank 1", "Inj Bank 2", "D14", "D16", "JS11", "Inj A", "Inj B", "Inj C", "Inj D", "Inj E", "Inj F", "Inj G", "Inj H", "PT4", "IGN (JS10)", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID"
      fc_ego_delay    = scalar,  U08,    280, "seconds", 1, 0, 0.00, 10, 0
      EAElagsource    = bits,    U08,    281, [0:0], "TPSdot", "MAPdot"
      EAElagthresh    = scalar,  S16,    282, "unit/sec",  1, 0, 0.00, 1000, 0
      EAElagRPMmax    = scalar,  U16,    284, "rpms", 1, 0, 0.00, {rpmhigh}, 0

      feature3_tps    = bits,    U08,    286,      [0:0], "Off", "On"
      feature3_aseunit= bits,    U08,    286,      [1:1], "Cycles", "0.1 seconds"
      feature3_maplog = bits,    U08,    286,      [2:2], "Off", "On"
      feature3_3      = bits,    U08,    286,      [3:3], "Off", "On"
      feature3_pw4x   = bits,    U08,    286,      [4:4], "Normal", "4x"
      feature3_n2oin  = bits,    U08,    286,      [5:5], "On", "Off"
      feature3_matase = bits,    U08,    286,      [6:6], "Off", "On"
      feature3_dwell  = bits,    U08,    286,      [7:7], "Off", "On"

;      XXlaunch_opt_pins = bits,    U08,    287,      [0:3], "INVALID", "Tableswitch", "PE0/JS7", "PE1", "JS10", "JS11", "JS5 (ADC6)", "JS4 (ADC7)", "Nitrous In", "Launch in", "Datalog In","INVALID","INVALID","INVALID","INVALID","INVALID"
      launch_opt_retard = bits,  U08,    287,      [3:3], "Off", "On" 
      launch_opt_bank = bits,    U08,    287,      [4:5], "Off","Bank1", "Bank2", "Both"
      launch_opt_on   = bits,    U08,    287,      [6:7], "Off", "Launch","INVALID","Launch/Flatshift"
      launch_sft_lim  = scalar,  S16,    288,      "RPM",      1.00000,   0.00000,  0.00,  {rpmhigh},      0 ; * (  2 bytes)
      launch_sft_deg  = scalar,  S16,    290,             "deg",      0.10000,   0.00000, -90.0,  180.00,      2 ; * (  2 bytes)
      launch_hrd_lim  = scalar,  S16,    292,             "RPM",      1.00000,   0.00000,  0.00,  {rpmhigh},      0 ; * (  2 bytes)
      launch_tps      = scalar,  S16,    294,  "%",       0.10000,   0.00000,   0.0,  100.00,      0 ;
      launchlimopt    = bits  ,  U08,    296,      [0:1], "None", "Spark Cut", "Fuel Cut", "Spark and fuel"         ; * (  1 byte)
      launchcutx      = scalar,  U08,    297,  "",     1, 0, 0, 255, 0
      launchcuty      = scalar,  U08,    298,  "",     1, 0, 0, 255, 0
      launch_opt_pins = bits,  U08,    299,  [0:4], "INVALID", "Tableswitch", "PE0/JS7", "PE1", "JS10", "JS11", "JS5 (ADC6)", "JS4 (ADC7)", "Nitrous In", "Launch in", "Datalog In", "PT4 Spare in", "PT2 Cam in", "PE2 Flex", "INVALID", "INVALID", "CANIN1", "CANIN2", "CANIN3", "CANIN4", "CANIN5", "CANIN6", "CANIN7", "CANIN8", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID"
      flats_arm       = scalar,  S16,    300,      "RPM",      1.00000,   0.00000,  0.00,  {rpmhigh},      0
      flats_sft       = scalar,  S16,    302,      "RPM",      1.00000,   0.00000,  0.00,  {rpmhigh},      0 ; * (  2 bytes)
      flats_deg       = scalar,  S16,    304,      "deg",      0.10000,   0.00000, -90.0,  180.00,      2 ; * (  2 bytes)
      flats_hrd       = scalar,  S16,    306,      "RPM",      1.00000,   0.00000,  0.00,  {rpmhigh},      0 ; * (  2 bytes)
      staged_pri_size = scalar,  U16,    308,      "cc",       1.00000, 0.00000, 0.0000, 15000.0,      0 ; * ( 2 bytes)
      staged_sec_size = scalar,  U16,    310,      "cc",       1.00000, 0.00000, 0.0000, 15000.0,      0 ; * ( 2 bytes)
      staged_first_param = bits, U08,   312,   [0:2], "Off", "RPM", "MAP", "TPS", "Duty", "Table", "INVALID", "INVALID"
      staged_second_param = bits, U08, 312,    [3:5], "Off", "RPM", "MAP", "TPS", "Duty", "INVALID", "INVALID", "INVALID"
      staged_transition_on = bits, U08, 312,   [6:6], "Off", "On"
      staged_second_logic = bits, U08, 312,   [7:7], "OR", "AND"
      staged_pw1_0 = bits, U08, 312, [7:7], "Off", "On"
      staged_transition_events = scalar, U08, 313, "ign events", 1.00000, 0.00000, 0.00, 255.0,  0
      staged_param_1 = scalar,   S16,    314, "units", 1.00000, 0.00000, 0.00, 25500.0, 0
      staged_param_2 = scalar,   S16,    316, "units", 1.00000, 0.00000, 0.00, 25500.0, 0
      staged_hyst_1 = scalar,    S16,    318, "units", 1.00000, 0.00000, 0.00, 25500.0, 0
      staged_hyst_2 = scalar,    S16,    320, "units", 1.00000, 0.00000, 0.00, 25500.0, 0

; Nitrous System
      N2Oopt_01     = bits,     U08, 322,[0:1],"INVALID","Bank1", "Bank2", "Both"
      N2Oopt_2      = bits,     U08, 322,[2:2], "Off", "On"  ; enables stage 1
      N2Oopt_3      = bits,     U08, 322,[3:3], "Off", "On"  ; enables stage 2
      N2Oopt_4      = bits,     U08, 322,[4:4], "Off", "On"  ; use AFR2
;input and output pins moved
      N2Oopt2_prog  = bits,     U08, 323,[0:0], "On/Off", "Progressive"
      N2Oopt2_prog_time= bits,  U08, 323,[1:1], "RPM-based", "Time-based"
      N2Oopt2_prog_freq= bits,  U08, 323,[2:4], "INVALID", "78Hz", "39Hz", "26Hz", "19.5Hz", "15.6Hz", "13Hz", "11.1Hz"
      N2ORpm        = scalar,   U16, 324, "RPM",   1, 0, 1000, {rpmhigh}, 0
      N2ORpmMax     = scalar,   U16, 326, "RPM",   1, 0, 1000, {rpmhigh}, 0
      N2OTps        = scalar,   S16, 328, "%", 0.10000,   0.00000,  0.00,  100.00,      1;

#if CELSIUS
	#if EXPANDED_CLT_TEMP
      N2OClt        = scalar, S16, 330,             "°C",       0.05555,  -320.000, -40.0,  230.0,      1 ; * (  2 bytes)
	#else
      N2OClt        = scalar, S16, 330,             "°C",       0.05555,  -320.000, -40.0,  150.0,      1 ; * (  2 bytes)
	#endif
#else
	#if EXPANDED_CLT_TEMP
      N2OClt        = scalar, S16, 330,             "°F",       0.10000,   0.00000, -40.0,  450.0,      1
	#else
      N2OClt        = scalar, S16, 330,             "°F",       0.10000,   0.00000, -40.0,  300.0,      1
	#endif
#endif

      N2OAngle      = scalar,    S16, 332,             "deg",      0.10000,   0.00000, 0,  50,      2 ; * (  2 bytes)
#if PW_4X
      N2OPWLo       = scalar,    S16, 334, "ms",  0.004, 0, -128, +128, 3
      N2OPWHi       = scalar,    S16, 336, "ms",  0.004, 0, -128, +128, 3
#else
      N2OPWLo       = scalar,    S16, 334, "ms",  0.001, 0, -32, +32, 3
      N2OPWHi       = scalar,    S16, 336, "ms",  0.001, 0, -32, +32, 3
#endif

;nitrous/launch
      N2Odel_launch = scalar, U08,   338,       "s",         0.01, 0, 0, 2.55, 2
      N2Odel_flat   = scalar, U08,   339,       "s",         0.01, 0, 0, 2.55, 2
      N2Oholdon     = scalar, U08,   340,       "s",         0.01, 0, 0, 2.55, 2
;nitrous stage 2
; Nitrous System
      N2O2delay     = scalar, U08, 341, "s", 0.01, 0, 0, 2.55,2
      N2O2Rpm       = scalar, U16, 342, "RPM",   1, 0, 1000, 25000, 0
      N2O2RpmMax    = scalar, U16, 344, "RPM",   1, 0, 1000, 25000, 0
      N2O2Angle     = scalar, S16, 346,             "deg",      0.10000,   0.00000, 0,  50,      2 ; * (  2 bytes)
#if PW_4X
      N2O2PWLo      = scalar, S16, 348, "ms",  0.004, 0, -128, +128, 3
      N2O2PWHi      = scalar, S16, 350, "ms",  0.004, 0, -128, +128, 3
#else
      N2O2PWLo      = scalar, S16, 348, "ms",  0.001, 0, -32, +32, 3
      N2O2PWHi      = scalar, S16, 350, "ms",  0.001, 0, -32, +32, 3
#endif
      RotarySplitModeFD = bits, U08, 352, [0:0], "FC mode", "FD mode"
      RotarySplitModeNeg = bits, U08, 352, [1:1], "Not Allowed", "Allowed"
      dlyct          = scalar, U08, 353, "", 1,0,0,255,0
      dwelltime_trl  = scalar,  U08, 354,             "ms",       0.10000,       0,        0.1,     25.5, 1
      N2Oopt_pins   = bits,     U08, 355, [0:4], "INVALID", "Tableswitch", "PE0/JS7", "PE1", "JS10", "JS11", "JS5 (ADC6)", "JS4 (ADC7)", "Nitrous In", "Launch in", "Datalog In", "PT4 Spare in", "PT2 Cam in", "PE2 Flex", "INVALID", "INVALID", "CANIN1", "CANIN2", "CANIN3", "CANIN4", "CANIN5", "CANIN6", "CANIN7", "CANIN8", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID"
      RevLimRtdAng    = scalar,  S16, 356,             "deg",      0.10000,   0.00000,-10,   25.5,      1
      RevLimNormal3   = scalar,  S16, 358,             "RPM",      1.00000,   0.00000,  0.00,  {rpmhigh},       0
      RevLimNormal2_hyst= scalar,S16, 360,             "RPM",      1.00000,   0.00000,  0.00,  {rpmhigh},       0
      pwmidleset_inv           = bits,   U08, 362, [3:3], "Normal, 0%=off", "Inverted, 100%=off"
      trig_init      = scalar, U08, 363, "", 1,0,0,255,0
;pwmidle
      pwmidle_ms               = scalar, U16, 364, "ms", 1, 0.00000, 0, 500, 0
      pwmidle_close_delay      = scalar, U08, 366, "sec", 1, 0.00000, 0, 10, 0
      pwmidle_open_duty        = scalar, U08, 367, "%", 0.39063, 0.00000, 0, 100, 1 
      pwmidle_open_steps       = scalar, U08, 367, "steps", 1.00000, 0.00000, 0, 255, 0 ; same but steps
      pwmidle_closed_duty      = scalar, U08, 368, "%", 0.39063, 0.00000, 0, 100, 1 
      pwmidle_closed_steps     = scalar, U08, 368, "steps", 1.00000, 0.00000, 0, 255, 0 ; same but steps
      pwmidle_pid_wait_timer   = scalar, U08, 369, "sec", 1, 0.00000, 0, 10, 0

      pwmidle_min_duty         = scalar, U08, 370, "%", 0.39063, 0.00000, 0, 255, 1 
      pwmidle_min_steps        = scalar, U08, 370, "steps", 1.00000, 0.00000, 0, 255, 0 ; same but steps
      pwmidle_engage_rpm_adder = scalar, U16, 371, "rpm", 1, 0.00000, 0, {rpmhigh}, 0
      pwmidle_tps_threshold    = scalar, U16, 373, "%", 0.1, 0.00000, 0, 1000, 1
      pwmidle_dp_adder         = scalar, U08, 375, "%", 0.39063, 0.00000, 0, 20, 1 
      pwmidle_dp_adder_steps   = scalar, U08, 375, "steps", 1.00000, 0.00000, 0, 20, 0 ; same but steps
      pwmidle_rpmdot_threshold = scalar, U16, 376, "rpm/sec", 10.0, 0.00000, 0, 1000, 0
      pwmidle_decelload_threshold=scalar,U16, 378, "%", 0.1, 0.00000, 0, 100, 1
      pwmidle_Kp               = scalar, U16, 380, "%", 0.1, 0.00000, 0, 200, 1 
      pwmidle_Ki               = scalar, U16, 382, "%", 0.1, 0.00000, 0, 200, 1 
      pwmidle_Kd               = scalar, U16, 384, "%", 0.1, 0.00000, 0, 200, 1 
      pwmidle_freq_scale       = bits,   U08, 386, [0:3], "1021Hz", "766Hz", "613Hz", "511Hz", "383Hz", "306Hz", "204Hz", "153Hz", "99Hz", "75Hz", "50Hz", "48Hz", "30Hz", "20Hz", "15Hz", "12Hz"
      pwmidle_freq_pin         = bits,   U08, 386, [5:5], "FIDLE", "Idle"
      pwmidle_freq_pin3        = bits,   U08, 386, [6:7], "Off", "FIDLE", "Boost", "VVT"
      boost_ctl_settings_freq  = bits,   U08, 387, [0:2], "INVALID", "78Hz", "39Hz", "26Hz", "19.5Hz", "15.6Hz", "13Hz", "11.1Hz"
      boost_ctl_settings_on    = bits,   U08, 387, [3:3], "Off","On"
      boost_ctl_settings_cl    = bits,   U08, 387, [4:4], "Open-loop", "Closed-loop"
      boost_ctl_settings_invert= bits,   U08, 387, [5:5], "Normal", "Inverted"
      boost_ctl_pins_pwm       = bits,   U08, 388, [5:7], "Boost", "Idle", "VVT", "Nitrous1", "Nitrous2", "Fidle", "Inj Bank 1", "Inj Bank 2"
      boost_ctl_pins           = bits,   U08, 388, [0:4], "INVALID", "IAC1", "IAC2", "FIDLE", "D15", "Nitrous 1", "Nitrous 2", "Tacho", "Idle", "Boost", "VVT", "Inj Bank 1", "Inj Bank 2", "D14", "D16", "JS11", "Inj A", "Inj B", "Inj C", "Inj D", "Inj E", "Inj F", "Inj G", "Inj H", "PT4", "IGN (JS10)", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID"
      boost_ctl_Kp             = scalar, U08, 389, "%", 1, 0.00000, 0, 200, 0
      boost_ctl_Ki             = scalar, U08, 390, "%", 1, 0.00000, 0, 200, 0
      boost_ctl_Kd             = scalar, U08, 391, "%", 1, 0.00000, 0, 200, 0
      boost_ctl_closeduty      = scalar, U08, 392, "%", 1, 0.00000, 0, 100, 0
      boost_ctl_openduty       = scalar, U08, 393, "%", 1, 0.00000, 0, 100, 0
      boost_ctl_ms             = scalar, U16, 394, "ms", 1, 0.00000, 10, 500, 0
      boost_ctl_pwm_scale      = bits,   U08, 396, [0:3], "1021Hz", "766Hz", "613Hz", "511Hz", "383Hz", "306Hz", "204Hz", "153Hz", "99Hz", "75Hz", "50Hz", "48Hz", "30Hz", "20Hz", "15Hz", "12Hz" 
      boost_ctl_pwm            = bits,   U08, 396, [4:5], "INVALID", "Mid","Slow", "INVALID"

      NoiseFilterOpts = bits, U08, 397, [0:0], "Off", "On"
      NoiseFilterOpts1 = bits, U08, 397, [1:1], "Off", "On"
      NoiseFilterOpts2 = bits, U08, 397, [2:2], "Off", "On"
      NoiseFilterOpts3 = bits, U08, 397, [3:3], "Off", "On"
      pwmidle_min_rpm = scalar, U16, 398, "rpm", 1, 0.00000, 0, {rpmhigh}, 0
      pwmidle_max_rpm = scalar, U16, 400, "rpm", 1, 0.00000, 0, {rpmhigh}, 0
      pwmidle_targ_ramptime = scalar, U08, 402, "sec", 1, 0.00000, 0, 10, 0
      inj_time_mask  = scalar, U08, 403, "", 1,0,0,100,0
;accel wizard mini tables moved here to keep on one page  
      taeBins         = array ,  U08,    404,    [    4], "%",       1,   0.00000,  0.00,   255,      0 ; * (  4 bytes)
      maeBins         = array ,  U08,    408,    [    4], "%",       1,   0.00000,  0.00,   255,      0 ; * (  4 bytes)
      taeRates        = array ,  S16,    412,    [    4], "%/s",      0.10000,   0.00000,  0.00, 2000.00,      1 ; * (  8 bytes) tpsDot bins used for AE: x for TAE interpolation
      maeRates        = array ,  S16,    420,    [    4], "kPa/s",    1.00000,   0.00000,  0.00, 32767.0,      0 ; * (  8 bytes) mapDot bins used for AE: x for MAE
      secondtrigopts  = bits,    U08,    428,     [0:0],  "Off", "On"
      secondtrigopts1 = bits,    U08,    428,     [1:1],  "Off", "On"
      secondtrigopts2 = bits,    U08,    428,     [2:2],  "Off", "On"
      secondtrigopts3 = bits,    U08,    428,     [3:3],  "Off", "On"

      TC5_required_width = scalar, U16,  429,             "uSec",     1.0,   0.00000,  0.00,  5000,        0 ;
      egoLimit =        scalar,  S16,    431,             "%",        0.10000,   0.00000,  0.00,  {loadhigh},         0 ;
      stoich =          scalar,  S16,    433,             "AFR",      0.10000,   0.00000,  0.00,  25.5,        1 ;
      MAPOXMin        = scalar,  S16,    435,             "%",      0.10000,   0.00000,  0.00,  {loadhigh},      2 ; * (  2 bytes)
      IC2ISR_tmask     = scalar,  U08,    437,             "ms",       0.1,       0.0,      0.0,    25.5,       1 ; * (  1 byte )
      IC2ISR_pmask     = scalar,  U08,    438,             "%",        1.0,       0.0,      0.0,     90,       0 ; * (  1 byte )
;afrload and eaeload are part of extra_load_opts in firmware
      afrload =          bits,    U08,    439, [0:3], "Use primary load (Algorithm)", "MAP", "% baro", "TPS", "MAFMAP", "INVALID", "ITB", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID"

      eaeload =          bits,    U08,    439, [4:7], "Use primary load (Algorithm)", "MAP", "% baro", "TPS", "MAFMAP", "INVALID", "ITB", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID"
      airden_scaling  = scalar, U08, 440, "%", 1,   0.00000,  50,  150.00,      0
#if MPH
      fan_idleup_vss_hyst = scalar, U16, 441, "MPH", 0.22369, 0, 0,  200,         0
#else
      fan_idleup_vss_hyst = scalar, U16, 441, "KPH", 0.3600,  0, 0,  300,         0
#endif
      log_style_led = bits, U08, 443, [0:5], "Off", "IAC1", "IAC2", "FIDLE", "D15", "Nitrous 1", "Nitrous 2", "Tacho", "Idle", "Boost", "VVT", "Inj Bank 1", "Inj Bank 2", "D14", "D16", "JS11", "Inj A", "Inj B", "Inj C", "Inj D", "Inj E", "Inj F", "Inj G", "Inj H", "PT4", "IGN (JS10)", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "CANOUT1", "CANOUT2", "CANOUT3", "CANOUT4", "CANOUT5", "CANOUT6", "CANOUT7", "CANOUT8", "CANOUT9", "CANOUT10", "CANOUT11", "CANOUT12", "CANOUT13", "CANOUT14", "CANOUT15", "CANOUT16"
    log_style_ledspd = bits, U08, 443, [6:7], "Normal", "Slower", "Faster", "INVALID"
    primedelay = scalar, U08,    444,             "s",        0.1,       0.0,      0.0,     3,       1 
    pwmidle_cl_opts_initvaluetable = bits, U08, 445, [0:0], "Use last value", "Use initial value table"
    pwmidle_cl_opts_initval_clt = bits, U08, 445, [1:1], "Use MAT", "Use CLT"
    pwmidle_dp_decay_factor = scalar, U08, 446, "", 1, 0, 0, 100, 0
    idleveadv_to_pid_idleadv = bits, U08, 447, [0:0], "Use normal activation", "Use PID idle activation"
    idleveadv_to_pid_idleve = bits, U08, 447, [1:1], "Use normal activation", "Use PID idle activation"
#if PW_4X
    staged_secondary_enrichment = scalar, U16, 455, "ms", 0.004, 0, 0, 10, 3
#else
    staged_secondary_enrichment = scalar, U16, 455, "ms", 0.001, 0, 0, 10, 3
#endif
    staged_primary_delay = scalar, U08, 457, "ign events", 1, 0, 0, 30, 0

      idleadvance_on  = bits, U08, 459, [0:0], "Off", "On" ;
      idleve_on       = bits, U08, 459, [1:1], "Off", "On"
      idleve_vsson    = bits, U08, 459, [2:3], "Off", "VSS1", "VSS2", "INVALID"
      idleadv_vsson   = bits, U08, 459, [4:5], "Off", "VSS1", "VSS2", "INVALID"
      idle_special_ops_timing_assist = bits, U08, 459, [6:6], "Off", "On"
      idleadvance_tps = scalar, S16, 460, "%", 0.1, 0, 0, 100, 1
      idleadvance_rpm = scalar, S16, 462, "rpm", 1, 0, 0, {rpmhigh}, 0
      idleadvance_load = scalar, S16, 464, "%", 0.1, 0, 0, 100, 0
#if CELSIUS
	#if EXPANDED_CLT_TEMP
      idleadvance_clt = scalar, S16, 466, "°C", 0.05555, -320, -40, 230.00, 1
	#else
      idleadvance_clt = scalar, S16, 466, "°C", 0.05555, -320, -40, 150.00, 1
	#endif
#else
	#if EXPANDED_CLT_TEMP
      idleadvance_clt = scalar, S16, 466, "°F", 0.10000, 0.00000, -40, 450, 1
	#else
      idleadvance_clt = scalar, S16, 466, "°F", 0.10000, 0.00000, -40, 300, 1
	#endif
#endif
      idleadvance_delay = scalar, U08, 468, "sec", 1, 0, 0, 5, 0
      idleadvance_curve = array, S16, 469, [ 4 ],  "deg", 0.10000, 0.00000, -10.00, 90.00, 1 
      idleadvance_loads = array, S16, 477, [ 4 ],  "%", 0.10000, 0.00000, 0, 100, 1


;SD datalogging
      log_style2_but = bits, U08, 485, [0:4], "INVALID", "Tableswitch", "PE0/JS7", "PE1", "JS10", "JS11", "JS5 (ADC6)", "JS4 (ADC7)", "Nitrous In", "Launch in", "Datalog In", "PT4 Spare in", "PT2 Cam in", "PE2 Flex", "INVALID", "INVALID", "CANIN1", "CANIN2", "CANIN3", "CANIN4", "CANIN5", "CANIN6", "CANIN7", "CANIN8", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID"

      log_style_block = bits, U08, 486, [0:1], "64 byte", "64 byte + stream", "INVALID", "INVALID"
;      log_style_led = bits, U08, 486, [2:4], "Off", "IAC1", "IAC2", "FIDLE", "D15 (Middle LED)", "Nitrous1", "Nitrous2", "Tacho"
      log_style_on = bits, U08, 486, [6:7], "Disabled", "Insertion", "Button", "INVALID" ;"Button+WTF"
;      XXlog_style2_but = bits, U08, 487, [0:2], "Log button", "TableSwitch", "PE0/JS7", "PE1", "JS10", "JS11", "JS5 (ADC6)", "JS4 (ADC7)"
      log_style2_samp = bits, U08, 487, [3:4], "Timed", "every tooth", "every cycle", "INVALID"
      log_style2_clg  = bits, U08, 487, [5:5], "Off", "On"
      log_style3_adc  = bits, U08, 488, [0:2], "INT_MAP", "JS5 (ADC6)", "JS4 (ADC7)", "EXT_MAP (ADC11)", "EGO2 (ADC12)", "Spare ADC (ADC13)", "INVALID", "INVALID"
      log_length    = scalar, U08, 489, "mins", 1, 0, 1, 255, 0
      log_int = scalar, U16, 490, "ms", 0.128,0,3,8388,0
      logFieldOffset  = array ,  U16,    492,    [   64], "",      1.0000,   0.00000,  0.00,  65535,      0 ; * ( 64 words)
      logFieldLength  = array ,  U08,    620,    [   64], "",      1.0000,   0.00000,  0.00,  255.00,      0 ; * ( 64 bytes)

      firea = scalar, U08, 684, "", 1,0,0,16,0
      fireb = scalar, U08, 685, "", 1,0,0,16,0
      firec = scalar, U08, 686, "", 1,0,0,16,0
      fired = scalar, U08, 687, "", 1,0,0,16,0
      firee = scalar, U08, 688, "", 1,0,0,16,0
      firef = scalar, U08, 689, "", 1,0,0,16,0
      fireg = scalar, U08, 690, "", 1,0,0,16,0
      fireh = scalar, U08, 691, "", 1,0,0,16,0
      firei = scalar, U08, 692, "", 1,0,0,16,0
      firej = scalar, U08, 693, "", 1,0,0,16,0
      firek = scalar, U08, 694, "", 1,0,0,16,0
      firel = scalar, U08, 695, "", 1,0,0,16,0
      firem = scalar, U08, 696, "", 1,0,0,16,0
      firen = scalar, U08, 697, "", 1,0,0,16,0
      fireo = scalar, U08, 698, "", 1,0,0,16,0
      firep = scalar, U08, 699, "", 1,0,0,16,0

      sequential = bits, U08, 700, [0:1], "Off", "Semi-sequential", "Fully Sequential", "INVALID"
      sequential_angle_spec = bits, U08, 700, [2:4], "INVALID", "End of squirt", "Middle of Squirt",  "INVALID", "Beginning of squirt", "INVALID", "INVALID", "INVALID"
      sequential_trim_on_off = bits, U08, 700, [5:5], "Off", "On"
;      sequential_bank_trim = bits, U08, 700, [6:6], "Off", "On" ; no longer used

      boost_launch_duty = scalar, U08, 701, "%", 1,0,0,100,0
      boost_launch_target = scalar, U16, 702, "kPa" 1,0,0,{loadhigh},0
      boost_feats_tsw     = bits,    U08,    704,      [0:4], "Off", "Tableswitch", "PE0/JS7", "PE1", "JS10", "JS11", "JS5 (ADC6)", "JS4 (ADC7)", "Nitrous In", "Launch in", "Datalog In", "PT4 Spare in", "PT2 Cam in", "PE2 Flex", "INVALID","Gear-based", "CANIN1", "CANIN2", "CANIN3", "CANIN4", "CANIN5", "CANIN6", "CANIN7", "CANIN8", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID"
      boost_feats_launch  = bits,    U08,    704,      [5:5], "Off", "On"
      boost_feats_timed   = bits,    U08,    704,      [6:6], "Off", "On"
;see lower for launch_var_on
      launch_3step_in      = bits,  U08,     705,      [0:4], "Off", "Tableswitch", "PE0/JS7", "PE1", "JS10", "JS11", "JS5 (ADC6)", "JS4 (ADC7)", "Nitrous In", "Launch in", "Datalog In", "PT4 Spare in", "PT2 Cam in", "PE2 Flex", "INVALID", "INVALID", "CANIN1", "CANIN2", "CANIN3", "CANIN4", "CANIN5", "CANIN6", "CANIN7", "CANIN8", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID"
      launch_var_low      = scalar, U16,     706, "rpm", 1,0,0,{rpmhigh},0
      launch_var_up       = scalar, U16,     708, "rpm", 1,0,0,{rpmhigh},0
      launch_var_sof      = scalar, U16,     710, "rpm", 1,0,0,{rpmhigh},0
      launch_sft_lim3     = scalar, S16,     712,      "RPM",      1.00000,   0.00000,  0.00,  {rpmhigh},      0 ; * (  2 bytes)
      launch_sft_deg3     = scalar, S16,     714,      "deg",      0.10000,   0.00000, -90.0,  180.00,      2 ; * (  2 bytes)
      launch_hrd_lim3     = scalar, S16,     716,      "RPM",      1.00000,   0.00000,  0.00,  {rpmhigh},      0 ; * (  2 bytes)
      map_sample_duration = scalar, S16,     718,      "deg",      0.10000,   0.00000,  0,     30,         1 ; * ( 2 bytes )
      opentime_opt1_master = bits, U08, 720, [7:7], "Same", "Individual"
      opentime_opt1    = bits, U08, 720, [0:1], "Curve 1", "Curve 2", "Curve 3", "Curve 4"
      opentime_opt2    = bits, U08, 721, [0:1], "Curve 1", "Curve 2", "Curve 3", "Curve 4"
      opentime_opt3    = bits, U08, 722, [0:1], "Curve 1", "Curve 2", "Curve 3", "Curve 4"
      opentime_opt4    = bits, U08, 723, [0:1], "Curve 1", "Curve 2", "Curve 3", "Curve 4"
      opentime_opt5    = bits, U08, 724, [0:1], "Curve 1", "Curve 2", "Curve 3", "Curve 4"
      opentime_opt6    = bits, U08, 725, [0:1], "Curve 1", "Curve 2", "Curve 3", "Curve 4"
      opentime_opt7    = bits, U08, 726, [0:1], "Curve 1", "Curve 2", "Curve 3", "Curve 4"
      opentime_opt8    = bits, U08, 727, [0:1], "Curve 1", "Curve 2", "Curve 3", "Curve 4"
      opentime_opta    = bits, U08, 728, [0:1], "Curve 1", "Curve 2", "Curve 3", "Curve 4"
      opentime_opta_pwm= bits, U08, 728, [4:4], "Off", "On"
      opentime_optb    = bits, U08, 729, [0:1], "Curve 1", "Curve 2", "Curve 3", "Curve 4"
      opentime_optb_pwm= bits, U08, 729, [4:4], "Off", "On"
      opentime_optb_own= bits, U08, 729, [5:5], "Off", "On"

      opentime_opt11    = bits, U08, 730, [0:1], "Curve 1", "Curve 2", "Curve 3", "Curve 4"
      opentime_opt12    = bits, U08, 731, [0:1], "Curve 1", "Curve 2", "Curve 3", "Curve 4"
      opentime_opt13    = bits, U08, 732, [0:1], "Curve 1", "Curve 2", "Curve 3", "Curve 4"
      opentime_opt14    = bits, U08, 733, [0:1], "Curve 1", "Curve 2", "Curve 3", "Curve 4"
      opentime_opt15    = bits, U08, 734, [0:1], "Curve 1", "Curve 2", "Curve 3", "Curve 4"
      opentime_opt16    = bits, U08, 735, [0:1], "Curve 1", "Curve 2", "Curve 3", "Curve 4"
;      opentime_opt17    = bits, U08, 736, [0:1], "Curve 1", "Curve 2", "Curve 3", "Curve 4"
;      opentime_opt18    = bits, U08, 737, [0:1], "Curve 1", "Curve 2", "Curve 3", "Curve 4"

      smallpw_opt1_master = bits, U08, 738, [7:7], "Off", "On"
      smallpw_opt1    = bits, U08, 738, [0:1], "Curve 1", "Curve 2", "Curve 3", "Curve 4"
      smallpw_opt2    = bits, U08, 739, [0:1], "Curve 1", "Curve 2", "Curve 3", "Curve 4"
      smallpw_opt3    = bits, U08, 740, [0:1], "Curve 1", "Curve 2", "Curve 3", "Curve 4"
      smallpw_opt4    = bits, U08, 741, [0:1], "Curve 1", "Curve 2", "Curve 3", "Curve 4"
      smallpw_opt5    = bits, U08, 742, [0:1], "Curve 1", "Curve 2", "Curve 3", "Curve 4"
      smallpw_opt6    = bits, U08, 743, [0:1], "Curve 1", "Curve 2", "Curve 3", "Curve 4"
      smallpw_opt7    = bits, U08, 744, [0:1], "Curve 1", "Curve 2", "Curve 3", "Curve 4"
      smallpw_opt8    = bits, U08, 745, [0:1], "Curve 1", "Curve 2", "Curve 3", "Curve 4"
      smallpw_opta    = bits, U08, 746, [0:1], "Curve 1", "Curve 2", "Curve 3", "Curve 4"
      smallpw_optb    = bits, U08, 747, [0:1], "Curve 1", "Curve 2", "Curve 3", "Curve 4"

      smallpw_opt11   = bits, U08, 748, [0:1], "Curve 1", "Curve 2", "Curve 3", "Curve 4"
      smallpw_opt12   = bits, U08, 749, [0:1], "Curve 1", "Curve 2", "Curve 3", "Curve 4"
      smallpw_opt13   = bits, U08, 750, [0:1], "Curve 1", "Curve 2", "Curve 3", "Curve 4"
      smallpw_opt14   = bits, U08, 751, [0:1], "Curve 1", "Curve 2", "Curve 3", "Curve 4"
      smallpw_opt15   = bits, U08, 752, [0:1], "Curve 1", "Curve 2", "Curve 3", "Curve 4"
      smallpw_opt16   = bits, U08, 753, [0:1], "Curve 1", "Curve 2", "Curve 3", "Curve 4"
;      smallpw_opt17   = bits, U08, 754, [0:1], "Curve 1", "Curve 2", "Curve 3", "Curve 4"
;      smallpw_opt18   = bits, U08, 755, [0:1], "Curve 1", "Curve 2", "Curve 3", "Curve 4"

      maxafr_opt1_on = bits, U08, 756, [0:0], "Off", "On"
      maxafr_opt1_load= bits,U08, 756, [1:2], "MAP", "TPS", "INVALID", "INVALID"
;this next line has 17 options in the space for 16 ?!
      maxafr_opt1_led = bits,U08, 757, [0:5], "Off", "IAC1", "IAC2", "FIDLE", "D15", "Nitrous 1", "Nitrous 2", "Tacho", "Idle", "Boost", "VVT", "Inj Bank 1", "Inj Bank 2", "D14", "D16", "JS11", "Inj A", "Inj B", "Inj C", "Inj D", "Inj E", "Inj F", "Inj G", "Inj H", "PT4", "IGN (JS10)", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "CANOUT1", "CANOUT2", "CANOUT3", "CANOUT4", "CANOUT5", "CANOUT6", "CANOUT7", "CANOUT8", "CANOUT9", "CANOUT10", "CANOUT11", "CANOUT12", "CANOUT13", "CANOUT14", "CANOUT15", "CANOUT16"
      maxafr_en_load   = scalar, U16,    758,    "%",    0.10000, 0,       0,      {loadhigh},   1
      maxafr_en_rpm    = scalar, U16,    760,    "rpm",  1,       0,       0,      {rpmhigh}, 0
      maxafr_en_time   = scalar, U16,    762,    "s",  0.001,     0,       0,      5.000, 1
      maxafr_spkcut_time=scalar, U16,    764,    "s",  0.001,     0,       0,      5.000, 2
      maxafr_ret_tps   = scalar, U16,    766,    "%",    0.10000, 0,       0,      110,   1
      maxafr_ret_map   = scalar, U16,    768,    "%",    0.10000, 0,       0,      {loadhigh},   1
      maxafr_ret_rpm   = scalar, U16,    770,    "rpm",  1,       0,       0,      {rpmhigh}, 1
#if PW_4X
      launch_addfuel   = scalar, S16,    772,     "ms",  0.004,   0.0000,  -128,      +128, 3
#else
      launch_addfuel   = scalar, S16,    772,     "ms",  0.001,   0.0000,  -32,      +32, 3
#endif
#if METRES
      wheeldia1        = scalar,  U16,    774,     "m",   0.001, 0, 0.3, 2, 3
      wheeldia2        = scalar,  U16,    778,     "m",   0.001, 0, 0.3, 2, 3
#else ; inches
      wheeldia1        = scalar,  U16,    774,     "in",   0.039370, 0, 12, 79, 1
      wheeldia2        = scalar,  U16,    778,     "in",   0.039370, 0, 12, 79, 1
#endif
      fdratio1         = scalar,  U16,    776,      ":1",      0.01,   0.00000,  0.40,  6.0,      2 ; * (  2 bytes)
;not a gap
      vss1_pos         = bits,    U08,    780, [0:1], "Wheel", "Driveline", "Pulses per mile", "Pulses per km"
      vss2_pos         = bits,    U08,    780, [2:3], "Wheel", "Driveline", "Pulses per mile", "Pulses per km"
      launch_var_on      = bits,   U08,  781, [0:4], "Off", "JS5 (ADC6)", "JS4 (ADC7)", "EXT_MAP (ADC11)", "EGO2 (ADC12)", "Spare ADC (ADC13)", "INVALID", "INVALID", "CAN ADC01", "CAN ADC02", "CAN ADC03", "CAN ADC04", "CAN ADC05", "CAN ADC06", "CAN ADC07", "CAN ADC08", "CAN ADC09", "CAN ADC10", "CAN ADC11", "CAN ADC12", "CAN ADC13", "CAN ADC14", "CAN ADC15", "CAN ADC16", "CAN ADC17", "CAN ADC18", "CAN ADC19", "CAN ADC20", "CAN ADC21", "CAN ADC22", "CAN ADC23", "CAN ADC24"
      reluctorteeth1   = scalar,  U08,    782,      "",        1, 0,0,255,0
      reluctorteeth2   = scalar,  U08,    783,      "",        1, 0,0,255,0
      vss_opt1         = bits,    U08,    784, [0:3], "Off", "Tableswitch", "PE0/JS7", "PE1", "JS10", "JS11", "JS5 (ADC6)", "JS4 (ADC7)", "Nitrous In", "Launch in", "Datalog In", "PT4 Spare in", "PT2 Cam in", "PE2 Flex", "CAN VSS", "Use CAN PWMin"
      vss_opt2         = bits,    U08,    784, [4:7], "Off", "Tableswitch", "PE0/JS7", "PE1", "JS10", "JS11", "JS5 (ADC6)", "JS4 (ADC7)", "Nitrous In", "Launch in", "Datalog In", "PT4 Spare in", "PT2 Cam in", "PE2 Flex", "CAN VSS", "Use CAN PWMin"
      vss1_an          = bits,    U08,   785,[0:4], "Off", "JS5 (ADC6)", "JS4 (ADC7)", "EXT_MAP (ADC11)", "EGO2 (ADC12)", "Spare ADC (ADC13)", "INVALID", "INVALID", "CAN ADC01", "CAN ADC02", "CAN ADC03", "CAN ADC04", "CAN ADC05", "CAN ADC06", "CAN ADC07", "CAN ADC08", "CAN ADC09", "CAN ADC10", "CAN ADC11", "CAN ADC12", "CAN ADC13", "CAN ADC14", "CAN ADC15", "CAN ADC16", "CAN ADC17", "CAN ADC18", "CAN ADC19", "CAN ADC20", "CAN ADC21", "CAN ADC22", "CAN ADC23", "CAN ADC24"
      vss1_can_id      = scalar, U08,    786,            "",        1.00000,   0.00000,  0.00,  255,      0 ;
      tsw_pin_ob       = bits,   U08,    787,      [0:4], "Off", "Tableswitch", "PE0/JS7", "PE1", "JS10", "JS11", "JS5 (ADC6)", "JS4 (ADC7)", "Nitrous In", "Launch in", "Datalog In", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "CANIN1", "CANIN2", "CANIN3", "CANIN4", "CANIN5", "CANIN6", "CANIN7", "CANIN8", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID"
      vss1_can_offset  = scalar, U16,    788,            "",        1.00000,   0.00000,  0.00,  65535,      0 ;
      vss2_can_offset  = scalar, U16,    790,            "",        1.00000,   0.00000,  0.00,  65535,      0 ;
      MapThreshXTD     = scalar, U08,    792,    "-kpa/sec", 1.00000,   0.00000,  0.00,  255.00,      0  ;
      MapThreshXTD2    = scalar, U08,    793,    "-kpa/sec", 1.00000,   0.00000,  0.00,  255.00,      0  ;
      reluctorteeth3   = scalar, U08,    794,      "",        1, 0,0,255,0
      reluctorteeth4   = scalar, U08,    795,      "",        1, 0,0,255,0
      ss_opt1          = bits,   U08,    796, [0:3], "Off", "Tableswitch", "PE0/JS7", "PE1", "JS10", "JS11", "JS5 (ADC6)", "JS4 (ADC7)", "Nitrous In", "Launch in", "Datalog In", "PT4 Spare in", "PT2 Cam in", "PE2 Flex", "INVALID", "Poll CAN"
      ss_opt2          = bits,   U08,    796, [4:7], "Off", "Tableswitch", "PE0/JS7", "PE1", "JS10", "JS11", "JS5 (ADC6)", "JS4 (ADC7)", "Nitrous In", "Launch in", "Datalog In", "PT4 Spare in", "PT2 Cam in", "PE2 Flex", "INVALID", "Poll CAN"
      vss2_an          = bits,    U08,   797,[0:4], "Off", "JS5 (ADC6)", "JS4 (ADC7)", "EXT_MAP (ADC11)", "EGO2 (ADC12)", "Spare ADC (ADC13)", "INVALID", "INVALID", "CAN ADC01", "CAN ADC02", "CAN ADC03", "CAN ADC04", "CAN ADC05", "CAN ADC06", "CAN ADC07", "CAN ADC08", "CAN ADC09", "CAN ADC10", "CAN ADC11", "CAN ADC12", "CAN ADC13", "CAN ADC14", "CAN ADC15", "CAN ADC16", "CAN ADC17", "CAN ADC18", "CAN ADC19", "CAN ADC20", "CAN ADC21", "CAN ADC22", "CAN ADC23", "CAN ADC24"
      ss1_pwmseq   =   scalar,  U08,    798,      "",    1.00000,   0.00000,     1,   4,       0
      ss2_pwmseq   =   scalar,  U08,    799,      "",    1.00000,   0.00000,     1,   4,       0
      gear_can_offset   = scalar, U16,    800,            "",        1.00000,   0.00000,  0.00,  65535,      0 ;
      mapsample_opt1  = bits,    U08,    802,      [0:1], "1", "2", "4", "INVALID"
      mapsample_opt2  = bits,    U08,    802,      [2:2], "Use timed min", "Use cycle average"
      map2port      = bits,   U08,  803, [0:4], "Off", "JS5 (ADC6)", "JS4 (ADC7)", "EXT_MAP (ADC11)", "EGO2 (ADC12)", "Spare ADC (ADC13)", "INVALID", "INVALID", "CAN ADC01", "CAN ADC02", "CAN ADC03", "CAN ADC04", "CAN ADC05", "CAN ADC06", "CAN ADC07", "CAN ADC08", "CAN ADC09", "CAN ADC10", "CAN ADC11", "CAN ADC12", "CAN ADC13", "CAN ADC14", "CAN ADC15", "CAN ADC16", "CAN ADC17", "CAN ADC18", "CAN ADC19", "CAN ADC20", "CAN ADC21", "CAN ADC22", "CAN ADC23", "CAN ADC24"
      n2o1n_pins       = bits,   U08, 804,[0:4], "INVALID", "IAC1", "IAC2", "FIDLE", "D15", "Nitrous 1", "Nitrous 2", "Tacho", "Idle", "Boost", "VVT", "Inj Bank 1", "Inj Bank 2", "D14", "D16", "JS11", "Inj A", "Inj B", "Inj C", "Inj D", "Inj E", "Inj F", "Inj G", "Inj H", "PT4", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID"
      n2o1f_pins       = bits,   U08, 805,[0:4], "Same", "IAC1", "IAC2", "FIDLE", "D15", "Nitrous 1", "Nitrous 2", "Tacho", "Idle", "Boost", "VVT", "Inj Bank 1", "Inj Bank 2", "D14", "D16", "JS11", "Inj A", "Inj B", "Inj C", "Inj D", "Inj E", "Inj F", "Inj G", "Inj H", "PT4", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID" 
      n2o2n_pins       = bits,   U08, 806,[0:4], "INVALID", "IAC1", "IAC2", "FIDLE", "D15", "Nitrous 1", "Nitrous 2", "Tacho", "Idle", "Boost", "VVT", "Inj Bank 1", "Inj Bank 2", "D14", "D16", "JS11", "Inj A", "Inj B", "Inj C", "Inj D", "Inj E", "Inj F", "Inj G", "Inj H", "PT4", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID" 
      n2o2f_pins       = bits,   U08, 807,[0:4], "Same", "IAC1", "IAC2", "FIDLE", "D15", "Nitrous 1", "Nitrous 2", "Tacho", "Idle", "Boost", "VVT", "Inj Bank 1", "Inj Bank 2", "D14", "D16", "JS11", "Inj A", "Inj B", "Inj C", "Inj D", "Inj E", "Inj F", "Inj G", "Inj H", "PT4", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID"
#if MPH
      vss1_an_max      = scalar, U16,   808, "MPH",        0.22369,   0.00000,  0.00,  1000,      0 
      vss2_an_max      = scalar, U16,   810, "MPH",        0.22369,   0.00000,  0.00,  1000,      0 
#else
      vss1_an_max      = scalar, U16,   808, "KPH",        0.3600,   0.00000,  0.00,  1600,      0 
      vss2_an_max      = scalar, U16,   810, "KPH",        0.3600,   0.00000,  0.00,  1600,      0 
#endif
      tsw_pin_rf       = bits,   U08,    812,      [0:4], "Off", "Tableswitch", "PE0/JS7", "PE1", "JS10", "JS11", "JS5 (ADC6)", "JS4 (ADC7)", "Nitrous In", "Launch in", "Datalog In", "PT4 Spare in", "PT2 Cam in", "PE2 Flex", "INVALID", "INVALID", "CANIN1", "CANIN2", "CANIN3", "CANIN4", "CANIN5", "CANIN6", "CANIN7", "CANIN8", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID"
      tsw_pin_afr      = bits,   U08,    813,      [0:4], "Off", "Tableswitch", "PE0/JS7", "PE1", "JS10", "JS11", "JS5 (ADC6)", "JS4 (ADC7)", "Nitrous In", "Launch in", "Datalog In", "PT4 Spare in", "PT2 Cam in", "PE2 Flex", "INVALID", "INVALID", "CANIN1", "CANIN2", "CANIN3", "CANIN4", "CANIN5", "CANIN6", "CANIN7", "CANIN8", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID"
      tsw_pin_stoich   = bits,   U08,    814,      [0:4], "Off", "Tableswitch", "PE0/JS7", "PE1", "JS10", "JS11", "JS5 (ADC6)", "JS4 (ADC7)", "Nitrous In", "Launch in", "Datalog In", "PT4 Spare in", "PT2 Cam in", "PE2 Flex", "INVALID", "INVALID", "CANIN1", "CANIN2", "CANIN3", "CANIN4", "CANIN5", "CANIN6", "CANIN7", "CANIN8", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID"
      boost_vss        = bits,   U08,    815,      [0:1], "Off", "VSS1", "VSS2", "INVALID"
#if PW_4X
      ReqFuel_alt      = scalar,  U16,    816,             "ms",       0.004,   0.00000,  0.00,  262.143,      2
#else
      ReqFuel_alt      = scalar,  U16,    816,             "ms",       0.001,   0.00000,  0.00,  65.535,      2
#endif
      stoich_alt       = scalar,  S16,    818,             "AFR",      0.10000,   0.00000,  0.00,  25.5,        1
      
      water_pins_pump  = bits,      U08, 820,[0:4], "Off", "IAC1", "IAC2", "FIDLE", "D15", "Nitrous 1", "Nitrous 2", "Tacho", "Idle", "Boost", "VVT", "Inj Bank 1", "Inj Bank 2", "D14", "D16", "JS11", "Inj A", "Inj B", "Inj C", "Inj D", "Inj E", "Inj F", "Inj G", "Inj H", "PT4", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID"
      water_pins_valve = bits,      U08, 821,[0:4], "Off", "IAC1", "IAC2", "FIDLE", "D15", "Nitrous 1", "Nitrous 2", "Tacho", "Idle", "Boost", "VVT", "Inj Bank 1", "Inj Bank 2", "D14", "D16", "JS11", "Inj A", "Inj B", "Inj C", "Inj D", "Inj E", "Inj F", "Inj G", "Inj H", "PT4", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID"
      water_pins_in_shut = bits,    U08, 822,      [0:4], "Off", "Tableswitch", "PE0/JS7", "PE1", "JS10", "JS11", "JS5 (ADC6)", "JS4 (ADC7)", "Nitrous In", "Launch in", "Datalog In", "PT4 Spare in", "PT2 Cam in", "PE2 Flex", "INVALID", "INVALID", "CANIN1", "CANIN2", "CANIN3", "CANIN4", "CANIN5", "CANIN6", "CANIN7", "CANIN8", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID"
      water_freq        = bits,     U08, 823,[0:2], "INVALID", "78Hz", "39Hz", "26Hz", "19.5Hz", "15.6Hz", "13Hz", "11.1Hz"
      water_freq_on     = bits,     U08, 823,[4:4], "Off", "On"
      water_freq_type   = bits,     U08, 823,[5:6], "Off", "Fast", "Slow", "INVALID"
      boost_vss_tps     = scalar,   U16, 824, "%", 0.1, 0, 0, 100, 0
      water_tps         = scalar,   U16, 826, "%", 0.1, 0, 0, 100, 0
      water_rpm         = scalar,   U16, 828, "RPM", 1, 0, 0, {rpmhigh}, 0
      water_map         = scalar,   U16, 830, "kPa", 0.1, 0, 0, {loadhigh}, 1
#if CELSIUS
      water_mat         = scalar,   S16, 832, "°C", 0.05555, -320, -40, 150.00, 1
#else
      water_mat         = scalar,   S16, 832, "°F", 0.10000, 0.00000, -40, 300, 1
#endif
      pwmidle_rpmdot_disablepid = scalar, S16, 834, "", 10.0000, 0.00000, 0, 1000, 0
      boost_ctl_lowerlimit =      scalar, S16, 836, "%",0.10000, 0.00000, 100, {loadhigh}, 1

	  enable_pollADC =  bits,    U08,    838,      [0:0], "Disable", "Enable"
	  enable_pollPWM =  bits,    U08,    838,      [1:2], "Disable", "16bit", "32bit", "INVALID"
	  enable_pollports_digin = bits, U08,838,      [3:3], "Disable", "Enable"
	  enable_pollports_digout = bits,U08,838,      [4:5], "Disable", "One", "Two", "INVALID"
	  enable_pwmout           = bits,U08,838,      [6:6], "Disable", "Enable"
;	  enable_poll_rtc         = bits,U08,838,      [7:7], "Disable", "Enable"

	  poll_table_rtc =   scalar,  U08,    839,             "",         1.00000,   0.00000,     0,     15,       0

	  poll_tablePWM =   scalar,  U08,    840,             "",         1.00000,   0.00000,     0,     15,       0 ; * (  1 byte)
	  poll_tableports = scalar,  U08,    841,             "",         1.00000,   0.00000,     0,     15,       0 ; * (  1 byte)
	  poll_offset_rtc =  scalar,  S16,    842,             "bytes",    1.00000,   0.00000,     0,   4095,       0
	  poll_offsetPWM =  scalar,  S16,    844,             "bytes",    1.00000,   0.00000,     0,   4095,       0 ;
	  can_poll_digin_offset = scalar, S16, 846,             "bytes",    1.00000,   0.00000,     0,   4095,       0 ;
	  can_poll_digout_offset = scalar, S16, 848,             "bytes",    1.00000,   0.00000,     0,   4095,       0 ;

      egt_num =         bits,    U08,    850,      [0:4], "Off", "1", "2", "3", "4", "5", "6", "7", "8", "9", "10", "11", "12", "13", "14", "15", "16", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID"
      accXport       =   bits,  U08,    851,    [0:4], "Off", "JS5 (ADC6)", "JS4 (ADC7)", "EXT_MAP (ADC11)", "EGO2 (ADC12)", "Spare ADC (ADC13)", "INVALID", "INVALID", "CAN ADC01", "CAN ADC02", "CAN ADC03", "CAN ADC04", "CAN ADC05", "CAN ADC06", "CAN ADC07", "CAN ADC08", "CAN ADC09", "CAN ADC10", "CAN ADC11", "CAN ADC12", "CAN ADC13", "CAN ADC14", "CAN ADC15", "CAN ADC16", "CAN ADC17", "CAN ADC18", "CAN ADC19", "CAN ADC20", "CAN ADC21", "CAN ADC22", "CAN ADC23", "CAN ADC24"
      accYport       =   bits,  U08,    852,    [0:4], "Off", "JS5 (ADC6)", "JS4 (ADC7)", "EXT_MAP (ADC11)", "EGO2 (ADC12)", "Spare ADC (ADC13)", "INVALID", "INVALID", "CAN ADC01", "CAN ADC02", "CAN ADC03", "CAN ADC04", "CAN ADC05", "CAN ADC06", "CAN ADC07", "CAN ADC08", "CAN ADC09", "CAN ADC10", "CAN ADC11", "CAN ADC12", "CAN ADC13", "CAN ADC14", "CAN ADC15", "CAN ADC16", "CAN ADC17", "CAN ADC18", "CAN ADC19", "CAN ADC20", "CAN ADC21", "CAN ADC22", "CAN ADC23", "CAN ADC24"
      accZport       =   bits,  U08,    853,    [0:4], "Off", "JS5 (ADC6)", "JS4 (ADC7)", "EXT_MAP (ADC11)", "EGO2 (ADC12)", "Spare ADC (ADC13)", "INVALID", "INVALID", "CAN ADC01", "CAN ADC02", "CAN ADC03", "CAN ADC04", "CAN ADC05", "CAN ADC06", "CAN ADC07", "CAN ADC08", "CAN ADC09", "CAN ADC10", "CAN ADC11", "CAN ADC12", "CAN ADC13", "CAN ADC14", "CAN ADC15", "CAN ADC16", "CAN ADC17", "CAN ADC18", "CAN ADC19", "CAN ADC20", "CAN ADC21", "CAN ADC22", "CAN ADC23", "CAN ADC24"
      accXcal1       = scalar,  S16,    854,    "ADC", 1, 0, 0, 4095, 0
      accXcal2       = scalar,  S16,    856,    "ADC", 1, 0, 0, 4095, 0
      accYcal1       = scalar,  S16,    858,    "ADC", 1, 0, 0, 4095, 0
      accYcal2       = scalar,  S16,    860,    "ADC", 1, 0, 0, 4095, 0
      accZcal1       = scalar,  S16,    862,    "ADC", 1, 0, 0, 4095, 0
      accZcal2       = scalar,  S16,    864,    "ADC", 1, 0, 0, 4095, 0
      accxyzLF       = scalar,  U08,    866,    "%",   1, 0, 10,  100, 0
      egt1port       =   bits,  U08,    867,    [0:4], "Off", "JS5 (ADC6)", "JS4 (ADC7)", "EXT_MAP (ADC11)", "EGO2 (ADC12)", "Spare ADC (ADC13)", "INVALID", "INVALID", "CAN ADC01", "CAN ADC02", "CAN ADC03", "CAN ADC04", "CAN ADC05", "CAN ADC06", "CAN ADC07", "CAN ADC08", "CAN ADC09", "CAN ADC10", "CAN ADC11", "CAN ADC12", "CAN ADC13", "CAN ADC14", "CAN ADC15", "CAN ADC16", "CAN ADC17", "CAN ADC18", "CAN ADC19", "CAN ADC20", "CAN ADC21", "CAN ADC22", "CAN ADC23", "CAN ADC24"
      egt2port       =   bits,  U08,    868,    [0:4], "Off", "JS5 (ADC6)", "JS4 (ADC7)", "EXT_MAP (ADC11)", "EGO2 (ADC12)", "Spare ADC (ADC13)", "INVALID", "INVALID", "CAN ADC01", "CAN ADC02", "CAN ADC03", "CAN ADC04", "CAN ADC05", "CAN ADC06", "CAN ADC07", "CAN ADC08", "CAN ADC09", "CAN ADC10", "CAN ADC11", "CAN ADC12", "CAN ADC13", "CAN ADC14", "CAN ADC15", "CAN ADC16", "CAN ADC17", "CAN ADC18", "CAN ADC19", "CAN ADC20", "CAN ADC21", "CAN ADC22", "CAN ADC23", "CAN ADC24"
      egt3port       =   bits,  U08,    869,    [0:4], "Off", "JS5 (ADC6)", "JS4 (ADC7)", "EXT_MAP (ADC11)", "EGO2 (ADC12)", "Spare ADC (ADC13)", "INVALID", "INVALID", "CAN ADC01", "CAN ADC02", "CAN ADC03", "CAN ADC04", "CAN ADC05", "CAN ADC06", "CAN ADC07", "CAN ADC08", "CAN ADC09", "CAN ADC10", "CAN ADC11", "CAN ADC12", "CAN ADC13", "CAN ADC14", "CAN ADC15", "CAN ADC16", "CAN ADC17", "CAN ADC18", "CAN ADC19", "CAN ADC20", "CAN ADC21", "CAN ADC22", "CAN ADC23", "CAN ADC24"
      egt4port       =   bits,  U08,    870,    [0:4], "Off", "JS5 (ADC6)", "JS4 (ADC7)", "EXT_MAP (ADC11)", "EGO2 (ADC12)", "Spare ADC (ADC13)", "INVALID", "INVALID", "CAN ADC01", "CAN ADC02", "CAN ADC03", "CAN ADC04", "CAN ADC05", "CAN ADC06", "CAN ADC07", "CAN ADC08", "CAN ADC09", "CAN ADC10", "CAN ADC11", "CAN ADC12", "CAN ADC13", "CAN ADC14", "CAN ADC15", "CAN ADC16", "CAN ADC17", "CAN ADC18", "CAN ADC19", "CAN ADC20", "CAN ADC21", "CAN ADC22", "CAN ADC23", "CAN ADC24"
      egt5port       =   bits,  U08,    871,    [0:4], "Off", "JS5 (ADC6)", "JS4 (ADC7)", "EXT_MAP (ADC11)", "EGO2 (ADC12)", "Spare ADC (ADC13)", "INVALID", "INVALID", "CAN ADC01", "CAN ADC02", "CAN ADC03", "CAN ADC04", "CAN ADC05", "CAN ADC06", "CAN ADC07", "CAN ADC08", "CAN ADC09", "CAN ADC10", "CAN ADC11", "CAN ADC12", "CAN ADC13", "CAN ADC14", "CAN ADC15", "CAN ADC16", "CAN ADC17", "CAN ADC18", "CAN ADC19", "CAN ADC20", "CAN ADC21", "CAN ADC22", "CAN ADC23", "CAN ADC24"
      egt6port       =   bits,  U08,    872,    [0:4], "Off", "JS5 (ADC6)", "JS4 (ADC7)", "EXT_MAP (ADC11)", "EGO2 (ADC12)", "Spare ADC (ADC13)", "INVALID", "INVALID", "CAN ADC01", "CAN ADC02", "CAN ADC03", "CAN ADC04", "CAN ADC05", "CAN ADC06", "CAN ADC07", "CAN ADC08", "CAN ADC09", "CAN ADC10", "CAN ADC11", "CAN ADC12", "CAN ADC13", "CAN ADC14", "CAN ADC15", "CAN ADC16", "CAN ADC17", "CAN ADC18", "CAN ADC19", "CAN ADC20", "CAN ADC21", "CAN ADC22", "CAN ADC23", "CAN ADC24"
      egt7port       =   bits,  U08,    873,    [0:4], "Off", "JS5 (ADC6)", "JS4 (ADC7)", "EXT_MAP (ADC11)", "EGO2 (ADC12)", "Spare ADC (ADC13)", "INVALID", "INVALID", "CAN ADC01", "CAN ADC02", "CAN ADC03", "CAN ADC04", "CAN ADC05", "CAN ADC06", "CAN ADC07", "CAN ADC08", "CAN ADC09", "CAN ADC10", "CAN ADC11", "CAN ADC12", "CAN ADC13", "CAN ADC14", "CAN ADC15", "CAN ADC16", "CAN ADC17", "CAN ADC18", "CAN ADC19", "CAN ADC20", "CAN ADC21", "CAN ADC22", "CAN ADC23", "CAN ADC24"
      egt8port       =   bits,  U08,    874,    [0:4], "Off", "JS5 (ADC6)", "JS4 (ADC7)", "EXT_MAP (ADC11)", "EGO2 (ADC12)", "Spare ADC (ADC13)", "INVALID", "INVALID", "CAN ADC01", "CAN ADC02", "CAN ADC03", "CAN ADC04", "CAN ADC05", "CAN ADC06", "CAN ADC07", "CAN ADC08", "CAN ADC09", "CAN ADC10", "CAN ADC11", "CAN ADC12", "CAN ADC13", "CAN ADC14", "CAN ADC15", "CAN ADC16", "CAN ADC17", "CAN ADC18", "CAN ADC19", "CAN ADC20", "CAN ADC21", "CAN ADC22", "CAN ADC23", "CAN ADC24"
      egt9port       =   bits,  U08,    875,    [0:4], "Off", "JS5 (ADC6)", "JS4 (ADC7)", "EXT_MAP (ADC11)", "EGO2 (ADC12)", "Spare ADC (ADC13)", "INVALID", "INVALID", "CAN ADC01", "CAN ADC02", "CAN ADC03", "CAN ADC04", "CAN ADC05", "CAN ADC06", "CAN ADC07", "CAN ADC08", "CAN ADC09", "CAN ADC10", "CAN ADC11", "CAN ADC12", "CAN ADC13", "CAN ADC14", "CAN ADC15", "CAN ADC16", "CAN ADC17", "CAN ADC18", "CAN ADC19", "CAN ADC20", "CAN ADC21", "CAN ADC22", "CAN ADC23", "CAN ADC24"
      egt10port       =   bits,  U08,    876,    [0:4], "Off", "JS5 (ADC6)", "JS4 (ADC7)", "EXT_MAP (ADC11)", "EGO2 (ADC12)", "Spare ADC (ADC13)", "INVALID", "INVALID", "CAN ADC01", "CAN ADC02", "CAN ADC03", "CAN ADC04", "CAN ADC05", "CAN ADC06", "CAN ADC07", "CAN ADC08", "CAN ADC09", "CAN ADC10", "CAN ADC11", "CAN ADC12", "CAN ADC13", "CAN ADC14", "CAN ADC15", "CAN ADC16", "CAN ADC17", "CAN ADC18", "CAN ADC19", "CAN ADC20", "CAN ADC21", "CAN ADC22", "CAN ADC23", "CAN ADC24"
      egt11port       =   bits,  U08,    877,    [0:4], "Off", "JS5 (ADC6)", "JS4 (ADC7)", "EXT_MAP (ADC11)", "EGO2 (ADC12)", "Spare ADC (ADC13)", "INVALID", "INVALID", "CAN ADC01", "CAN ADC02", "CAN ADC03", "CAN ADC04", "CAN ADC05", "CAN ADC06", "CAN ADC07", "CAN ADC08", "CAN ADC09", "CAN ADC10", "CAN ADC11", "CAN ADC12", "CAN ADC13", "CAN ADC14", "CAN ADC15", "CAN ADC16", "CAN ADC17", "CAN ADC18", "CAN ADC19", "CAN ADC20", "CAN ADC21", "CAN ADC22", "CAN ADC23", "CAN ADC24"
      egt12port       =   bits,  U08,    878,    [0:4], "Off", "JS5 (ADC6)", "JS4 (ADC7)", "EXT_MAP (ADC11)", "EGO2 (ADC12)", "Spare ADC (ADC13)", "INVALID", "INVALID", "CAN ADC01", "CAN ADC02", "CAN ADC03", "CAN ADC04", "CAN ADC05", "CAN ADC06", "CAN ADC07", "CAN ADC08", "CAN ADC09", "CAN ADC10", "CAN ADC11", "CAN ADC12", "CAN ADC13", "CAN ADC14", "CAN ADC15", "CAN ADC16", "CAN ADC17", "CAN ADC18", "CAN ADC19", "CAN ADC20", "CAN ADC21", "CAN ADC22", "CAN ADC23", "CAN ADC24"
      egt13port       =   bits,  U08,    879,    [0:4], "Off", "JS5 (ADC6)", "JS4 (ADC7)", "EXT_MAP (ADC11)", "EGO2 (ADC12)", "Spare ADC (ADC13)", "INVALID", "INVALID", "CAN ADC01", "CAN ADC02", "CAN ADC03", "CAN ADC04", "CAN ADC05", "CAN ADC06", "CAN ADC07", "CAN ADC08", "CAN ADC09", "CAN ADC10", "CAN ADC11", "CAN ADC12", "CAN ADC13", "CAN ADC14", "CAN ADC15", "CAN ADC16", "CAN ADC17", "CAN ADC18", "CAN ADC19", "CAN ADC20", "CAN ADC21", "CAN ADC22", "CAN ADC23", "CAN ADC24"
      egt14port       =   bits,  U08,    880,    [0:4], "Off", "JS5 (ADC6)", "JS4 (ADC7)", "EXT_MAP (ADC11)", "EGO2 (ADC12)", "Spare ADC (ADC13)", "INVALID", "INVALID", "CAN ADC01", "CAN ADC02", "CAN ADC03", "CAN ADC04", "CAN ADC05", "CAN ADC06", "CAN ADC07", "CAN ADC08", "CAN ADC09", "CAN ADC10", "CAN ADC11", "CAN ADC12", "CAN ADC13", "CAN ADC14", "CAN ADC15", "CAN ADC16", "CAN ADC17", "CAN ADC18", "CAN ADC19", "CAN ADC20", "CAN ADC21", "CAN ADC22", "CAN ADC23", "CAN ADC24"
      egt15port       =   bits,  U08,    881,    [0:4], "Off", "JS5 (ADC6)", "JS4 (ADC7)", "EXT_MAP (ADC11)", "EGO2 (ADC12)", "Spare ADC (ADC13)", "INVALID", "INVALID", "CAN ADC01", "CAN ADC02", "CAN ADC03", "CAN ADC04", "CAN ADC05", "CAN ADC06", "CAN ADC07", "CAN ADC08", "CAN ADC09", "CAN ADC10", "CAN ADC11", "CAN ADC12", "CAN ADC13", "CAN ADC14", "CAN ADC15", "CAN ADC16", "CAN ADC17", "CAN ADC18", "CAN ADC19", "CAN ADC20", "CAN ADC21", "CAN ADC22", "CAN ADC23", "CAN ADC24"
      egt16port       =   bits,  U08,    882,    [0:4], "Off", "JS5 (ADC6)", "JS4 (ADC7)", "EXT_MAP (ADC11)", "EGO2 (ADC12)", "Spare ADC (ADC13)", "INVALID", "INVALID", "CAN ADC01", "CAN ADC02", "CAN ADC03", "CAN ADC04", "CAN ADC05", "CAN ADC06", "CAN ADC07", "CAN ADC08", "CAN ADC09", "CAN ADC10", "CAN ADC11", "CAN ADC12", "CAN ADC13", "CAN ADC14", "CAN ADC15", "CAN ADC16", "CAN ADC17", "CAN ADC18", "CAN ADC19", "CAN ADC20", "CAN ADC21", "CAN ADC22", "CAN ADC23", "CAN ADC24"
      egt_conf_action = bits,    U08,    883,  [0:0], "Off", "On"
      egt_conf_shutdown = bits,  U08,    883,  [1:1], "Off", "On"
      egt_conf_bank     = bits,  U08,    883,  [2:3], "INVALID", "Bank 1", "Bank 2", "Both"

;EGT calibration
#if CELSIUS
      egtcal_temp0  =   scalar,  S16,    884,     "°C",  0.05555, -320, -40,  1500,      0
      egtcal_tempmax=   scalar,  S16,    886,     "°C",  0.05555, -320, -40,  1500,      0
      egt_warn      =   scalar,  S16,    888,     "°C",  0.05555, -320, -40,  1500,      0
      egt_max       =   scalar,  S16,    890,     "°C",  0.05555, -320, -40,  1500,      0
#else
      egtcal_temp0  =   scalar,  S16,    884,     "°F",  0.1,        0, -40,  2700,      0
      egtcal_tempmax=   scalar,  S16,    886,     "°F",  0.1,        0, -40,  2700,      0
      egt_warn      =   scalar,  S16,    888,     "°F",  0.1,        0, -40,  2700,      0
      egt_max       =   scalar,  S16,    890,     "°F",  0.1,        0, -40,  2700,      0
#endif
      egt_time      =   scalar,  U16,    892,     "s",   0.001,       0,   0,  10,        2
      vss1_can_scale=   scalar,  U16,    894,     "%",   0.1, 0, 0, 6553, 1
      vss2_can_scale=   scalar,  U16,    896,     "%",   0.1, 0, 0, 6553, 1
      vss1_pwmseq   =   scalar,  U08,    898,      "",    1.00000,   0.00000,     1,   4,       0
      vss2_pwmseq   =   scalar,  U08,    899,      "",    1.00000,   0.00000,     1,   4,       0
      MAFOption     =   bits,   U08,  900, [0:4], "Off", "JS5 (ADC6)", "JS4 (ADC7)", "EXT_MAP (ADC11)", "EGO2 (ADC12)", "Spare ADC (ADC13)", "MAP (ADC0)", "INVALID", "CAN ADC01", "CAN ADC02", "CAN ADC03", "CAN ADC04", "CAN ADC05", "CAN ADC06", "CAN ADC07", "CAN ADC08", "CAN ADC09", "CAN ADC10", "CAN ADC11", "CAN ADC12", "CAN ADC13", "CAN ADC14", "CAN ADC15", "CAN ADC16", "CAN ADC17", "CAN ADC18", "CAN ADC19", "CAN ADC20", "CAN ADC21", "CAN ADC22", "CAN ADC23", "CAN ADC24"
      MAFOption_t    =   bits,   U08,  900, [5:5], "Voltage", "Frequency"
      MAFOption_f    =   bits,   U08,  900, [6:7], "PT4", "MS3X cam PT2", "JS10 PT5", "Datalog PT6"
      enginesize     =   scalar,  U16,    901,    "cc",   1.00000,    0.00000,     0,   65536,    0
      vssout_opt    =   bits,    U08,    903,[0:4], "Off", "IAC1", "IAC2", "FIDLE", "D15", "Nitrous 1", "Nitrous 2", "Tacho", "Idle", "Boost", "VVT", "Inj Bank 1", "Inj Bank 2", "D14", "D16", "JS11", "Inj A", "Inj B", "Inj C", "Inj D", "Inj E", "Inj F", "Inj G", "Inj H", "PT4", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID"
      vssout_optunits=  bits,    U08,    903, [6:7], "Time", "Pulses per mile", "Pulses per km", "INVALID"
    vssout_scale  =   scalar,  U16,    904,    "", 0.1, 0, 0, 6553, 1
    vss1_can_size    =   bits,    U08,    906, [0:0], "8bit", "16bit"
    vss2_can_size    =   bits,    U08,    906, [1:1], "8bit", "16bit"
    canpwm_clk  =   scalar,  U08,    907, "MHz", 1,0,0,100,0
    canpwm_pre  =   scalar,  U08,    908, "", 1,0,0,255,0
    canpwm_div  =   scalar,  U08,    909, "", 1,0,0,255,0
    vss1_can_table = scalar, U08,  910, "", 1,0,0,255,0
    feature7_mafmat = bits,  U08,  911, [0:0], "Off", "On"
    feature7_maftrim = bits, U08,  911, [1:1], "Off", "On"
    vss1LF         = scalar, U08,  912, "", 1,0,10,100,0
    vss2LF         = scalar, U08,  913, "", 1,0,10,100,0
    ss1LF          = scalar, U08,  914, "", 1,0,10,100,0
    ss2LF          = scalar, U08,  915, "", 1,0,10,100,0
#if PW_4X
    egt_addfuel    = scalar, U16,  916,             "ms",       0.004,   0.00000,  0.00,  262.143,      2
#else
    egt_addfuel    = scalar, U16,  916,             "ms",       0.001,   0.00000,  0.00,  65.535,      2
#endif
    launch_fcut_rpm= scalar, U16,  918, "RPM", 1, 0, 1000, {rpmhigh}, 0
;gear ratios
    gear1ratio    = scalar,  U16,      920,      ":1",      0.01,   0.00000,  0.40,  5.0,      2 ; * (  2 bytes)
    gear2ratio    = scalar,  U16,      922,      ":1",      0.01,   0.00000,  0.40,  5.0,      2 ; * (  2 bytes)


    gear3ratio    = scalar,  U16,      924,      ":1",      0.01,   0.00000,  0.40,  5.0,      2 ; * (  2 bytes)
    gear4ratio    = scalar,  U16,      926,      ":1",      0.01,   0.00000,  0.40,  5.0,      2 ; * (  2 bytes)
    gear5ratio    = scalar,  U16,      928,      ":1",      0.01,   0.00000,  0.40,  5.0,      2 ; * (  2 bytes)
    gear6ratio    = scalar,  U16,      930,      ":1",      0.01,   0.00000,  0.40,  5.0,      2 ; * (  2 bytes)
    gear_method   = bits, U08, 932, [0:1], "Off", "VSS/RPM", "Analogue", "CAN Gear#"
    gear_port_an  = bits, U08, 933, [0:4], "Off", "JS5 (ADC6)", "JS4 (ADC7)", "EXT_MAP (ADC11)", "EGO2 (ADC12)", "Spare ADC (ADC13)", "INVALID", "INVALID", "CAN ADC01", "CAN ADC02", "CAN ADC03", "CAN ADC04", "CAN ADC05", "CAN ADC06", "CAN ADC07", "CAN ADC08", "CAN ADC09", "CAN ADC10", "CAN ADC11", "CAN ADC12", "CAN ADC13", "CAN ADC14", "CAN ADC15", "CAN ADC16", "CAN ADC17", "CAN ADC18", "CAN ADC19", "CAN ADC20", "CAN ADC21", "CAN ADC22", "CAN ADC23", "CAN ADC24"
    gear0v        = scalar,  U16,      934,      "V",      0.01,   0.00000,  0.00,  5.0,      2 ; * (  2 bytes)
    gear1v        = scalar,  U16,      936,      "V",      0.01,   0.00000,  0.00,  5.0,      2 ; * (  2 bytes)
    gear2v        = scalar,  U16,      938,      "V",      0.01,   0.00000,  0.00,  5.0,      2 ; * (  2 bytes)
    gear3v        = scalar,  U16,      940,      "V",      0.01,   0.00000,  0.00,  5.0,      2 ; * (  2 bytes)
    gear4v        = scalar,  U16,      942,      "V",      0.01,   0.00000,  0.00,  5.0,      2 ; * (  2 bytes)
    gear5v        = scalar,  U16,      944,      "V",      0.01,   0.00000,  0.00,  5.0,      2 ; * (  2 bytes)
    gear6v        = scalar,  U16,      946,      "V",      0.01,   0.00000,  0.00,  5.0,      2 ; * (  2 bytes)
    gear_no       = scalar,  U08,      948,      "",        1, 0, 1, 6, 0
    vssdotLF      = scalar,  U08,      949, "", 1,0,10,100,0
    vssdot_int    = scalar,  U08,      950,      "ms",     10,   0      ,  10,  2000,     0
    ac_idleup_io_in = bits, U08,       951, [0:4], "INVALID", "Tableswitch", "PE0/JS7", "PE1", "JS10", "JS11", "JS5 (ADC6)", "JS4 (ADC7)", "Nitrous In", "Launch in", "Datalog In", "PT4 Spare in", "PT2 Cam in", "PE2 Flex", "INVALID", "INVALID", "CANIN1", "CANIN2", "CANIN3", "CANIN4", "CANIN5", "CANIN6", "CANIN7", "CANIN8", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID"
    ac_idleup_settings = bits, U08,    951, [7:7], "Off", "On"
    ac_idleup_io_out = bits, U08,      952, [0:5], "Off", "IAC1", "IAC2", "FIDLE", "D15", "Nitrous 1", "Nitrous 2", "Tacho", "Idle", "Boost", "VVT", "Inj Bank 1", "Inj Bank 2", "D14", "D16", "JS11", "Inj A", "Inj B", "Inj C", "Inj D", "Inj E", "Inj F", "Inj G", "Inj H", "PT4", "IGN (JS10)", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "CANOUT1", "CANOUT2", "CANOUT3", "CANOUT4", "CANOUT5", "CANOUT6", "CANOUT7", "CANOUT8", "CANOUT9", "CANOUT10", "CANOUT11", "CANOUT12", "CANOUT13", "CANOUT14", "CANOUT15", "CANOUT16"
    ac_idleup_delay = scalar, U16,     953,      "ms",     1.0000, 0.00000, 0.00, 1000, 0
    ac_idleup_adder_duty = scalar, U08,     955,      "%",      0.39063, 0.00000, 0, 100, 1
    ac_idleup_adder_steps = scalar, U08,    955,      "steps",  1, 0, 0, 255, 0
    fanctl_settings_on = bits, U08, 956, [7:7], "Off", "On"
    fanctl_settings_idleup = bits, U08, 956, [6:6], "No", "Yes"
    fanctl_settings_pin = bits, U08, 956, [0:5], "INVALID", "IAC1", "IAC2", "FIDLE", "D15", "Nitrous 1", "Nitrous 2", "Tacho", "Idle", "Boost", "VVT", "Inj Bank 1", "Inj Bank 2", "D14", "D16", "JS11", "Inj A", "Inj B", "Inj C", "Inj D", "Inj E", "Inj F", "Inj G", "Inj H", "PT4", "IGN (JS10)", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "CANOUT1", "CANOUT2", "CANOUT3", "CANOUT4", "CANOUT5", "CANOUT6", "CANOUT7", "CANOUT8", "CANOUT9", "CANOUT10", "CANOUT11", "CANOUT12", "CANOUT13", "CANOUT14", "CANOUT15", "CANOUT16"
    fanctl_idleup_delay = scalar, U16,  957, "ms",       1.0000, 0.00000, 0.00, 1000, 0
    fanctl_idleup_adder_duty = scalar, U08,  959, "%",     0.39063, 0.00000, 0, 100, 1
    fanctl_idleup_adder_steps = scalar, U08, 959, "steps", 1.000, 0.00000, 0, 255, 0


#if CELSIUS

    fanctl_ontemp =scalar,  S16, 960,  "°C",   0.05555,  -320.000,-40.00,  150.00,      1 
    fanctl_offtemp =scalar,  S16, 962,  "°C",   0.05555,  -320.000,-40.00,  150.00,      1
#else
    fanctl_ontemp =scalar,  S16, 960,  "°F",       0.10000,   0.00000,-40.00,  300.00,      1
    fanctl_offtemp =scalar,  S16, 962,  "°F",       0.10000,   0.00000,-40.00,  300.00,      1
#endif
    canadc_opt1 = bits, U08, 964, [0:0], "Off", "On"
    canadc_opt2 = bits, U08, 964, [1:1], "Off", "On"
    canadc_opt3 = bits, U08, 964, [2:2], "Off", "On"
    canadc_opt4 = bits, U08, 964, [3:3], "Off", "On"
    canadc_opt5 = bits, U08, 964, [4:4], "Off", "On"
    canadc_opt6 = bits, U08, 964, [5:5], "Off", "On"
    fanctl_opt2_engineoff = bits, U08, 965, [0:0], "No", "Yes"
    canadc_id1  = scalar, U08,  966, "", 1, 0, 0, 14, 0, 0
    canadc_id2  = scalar, U08,  967, "", 1, 0, 0, 14, 0, 0
    canadc_id3  = scalar, U08,  968, "", 1, 0, 0, 14, 0, 0
    canadc_id4  = scalar, U08,  969, "", 1, 0, 0, 14, 0, 0
    canadc_id5  = scalar, U08,  970, "", 1, 0, 0, 14, 0, 0
    canadc_id6  = scalar, U08,  971, "", 1, 0, 0, 14, 0, 0
    canadc_tab1 = scalar, U08,  972, "", 1, 0, 0, 31, 0, 0
    canadc_tab2 = scalar, U08,  973, "", 1, 0, 0, 31, 0, 0
    canadc_tab3 = scalar, U08,  974, "", 1, 0, 0, 31, 0, 0
    canadc_tab4 = scalar, U08,  975, "", 1, 0, 0, 31, 0, 0
    canadc_tab5 = scalar, U08,  976, "", 1, 0, 0, 31, 0, 0
    canadc_tab6 = scalar, U08,  977, "", 1, 0, 0, 31, 0, 0
    canadc_off1 = scalar, U16,  978, "", 1, 0, 0, 1023, 0, 0
    canadc_off2 = scalar, U16,  980, "", 1, 0, 0, 1023, 0, 0
    canadc_off3 = scalar, U16,  982, "", 1, 0, 0, 1023, 0, 0
    canadc_off4 = scalar, U16,  984, "", 1, 0, 0, 1023, 0, 0
    canadc_off5 = scalar, U16,  986, "", 1, 0, 0, 1023, 0, 0
    canadc_off6 = scalar, U16,  988, "", 1, 0, 0, 1023, 0, 0
    ac_idleup_cl_targetadder = scalar, S16, 990, "rpm", 1, 0, 0, 700, 0
    fan_idleup_cl_targetadder = scalar, S16, 992, "rpm", 1, 0, 0, 700, 0
#if CELSIUS
	#if EXPANDED_CLT_TEMP
    boost_ctl_clt_threshold = scalar, S16, 994, "°C", 0.05555, -320, -40, 230.00, 1
	#else
    boost_ctl_clt_threshold = scalar, S16, 994, "°C", 0.05555, -320, -40, 150.00, 1
	#endif
#else
	#if EXPANDED_CLT_TEMP
    boost_ctl_clt_threshold = scalar, S16, 994, "°F", 0.10000, 0.00000, -40, 450, 1
	#else
    boost_ctl_clt_threshold = scalar, S16, 994, "°F", 0.10000, 0.00000, -40, 300, 1
	#endif
#endif
    fan_ctl_settings_acfan = bits, U08, 996, [0:0], "Leave Fan off", "Turn fan on"
#if LAMBDA
    ego_upper_bound    = scalar, U08,    997, "Lambda",  0.006803,   0.00000,  0.0476,    1.7,      3
    ego_lower_bound    = scalar, U08,    998, "Lambda",  0.006803,   0.00000,  0.0476,    1.7,      3
#else
    ego_upper_bound    = scalar, U08,    997, "AFR",  0.10000,   0.00000,  7,    25,      1 
    ego_lower_bound    = scalar, U08,    998, "AFR",  0.10000,   0.00000,  7,    25,      1 
#endif
;pad
    ac_delay_since_last_on = scalar, U08, 1003, "sec", 1.00000, 0.00000, 0, 30, 0
    boost_gear_switch = scalar, U08,  1008, "gear", 1, 0, 1, 7, 0
    staged_extended_opts_use_v3 = bits, U08, 1009, [0:0], "Use MS3x (if possible)", "Use V3"
    staged_extended_opts_simult = bits, U08, 1009, [1:1], "Alternating (2 squirts)", "Simultaneous (1 squirt)"
    staged_extended_opts_pw1off = bits, U08, 1009, [2:2], "Off", "On"

    can_pwmout_id     = scalar, U08, 1010,             "",         1.00000,   0.00000,     0,     15,       0 ; * (  1 byte)
    can_pwmout_tab    = scalar, U08, 1011,             "",         1.00000,   0.00000,     0,     15,       0 ; * (  1 byte)
    can_pwmout_offset = scalar, S16, 1012,             "bytes",    1.00000,   0.00000,     0,   4095,       0 ;
    idleve_tps =        scalar, S16, 1014,             "%",        0.10000,   0.00000,     0,   100,        1 
    idleve_rpm =        scalar, U16, 1016,             "rpm",      1.00000,   0.00000,     0,   {rpmhigh},      0
    idleve_load =       scalar, S16, 1018,             "%",        0.10000,   0.00000,     0,   {loadhigh},        1
#if CELSIUS
	#if EXPANDED_CLT_TEMP
    idleve_clt = scalar, S16, 1020, "°C", 0.05555, -320, -40, 230.00, 1
	#else
    idleve_clt = scalar, S16, 1020, "°C", 0.05555, -320, -40, 150.00, 1
	#endif
#else
	#if EXPANDED_CLT_TEMP
    idleve_clt = scalar, S16, 1020, "°F", 0.10000, 0.00000, -40, 450, 1
	#else
    idleve_clt = scalar, S16, 1020, "°F", 0.10000, 0.00000, -40, 300, 1
	#endif
#endif 
    idleve_delay = scalar, U08, 1022, "sec", 1.00000, 0.0000, 0, 10, 0
    ac_idleup_cl_lockout_mapadder = scalar, U08, 1023, "%", 0.10000, 0.00000, 0, 25.5, 0

page = 2
      testmodelock = scalar, U16, 0, "", 1,0,0,65535,0, noLocalUpdate
      testop_0    = scalar, U08, 2, "", 1,0,0,255,0, noLocalUpdate
      testop_coil = bits, U08, 2, [0:1], "Off", "One", "Sequence", "INVALID"
      testop_fp   = bits, U08, 2, [4:4], "Off", "On"
      testop_inj  = bits, U08, 2, [5:6], "Off", "One", "Sequence", "All"
      testop_pwm  = bits, U08, 2, [7:7], "Standard", "As below"

      testdwell    = scalar, U08, 3, "ms", 0.1,0,0,25.5,1
      testint      = scalar, U16, 4, "ms", 0.128,0,0,8388,1
#if PW_4X
      testpw       = scalar, U16, 6,             "ms",       0.004,   0.00000,  0,   262.143,      3, noLocalUpdate
#else
      testpw       = scalar, U16, 6,             "ms",       0.001,   0.00000,  0,   65.535,      3, noLocalUpdate
#endif
      testinjcnt   = scalar, U16, 8, "", 1,0,0,65535,0, noLocalUpdate
      testmode_0   = scalar, U08, 10, "", 1,0,0,255,0, noLocalUpdate
      testmode     = bits,   U08, 10, [0:1],  "Off", "Coils", "Injectors", "INVALID"
      testinjPwmT     = scalar,  U08,    11,             "ms",       0.12800,   0.12800,  0.00,   32.64,      1
      testinjPwmPd    = scalar,  U08,    12,             "us",       1.00000,   0.00000, 40.00,  100.00,      0
      testinjPwmP     = scalar,  U08,    13,             "%",        1.00000,   0.00000,  0.00,  100.00,      0
      testsel_inj     = bits,  U08,    14, [0:3], "InjA", "InjB", "InjC", "InjD", "InjE", "InjF", "InjG", "InjH", "Inj1/I", "Inj2/J","InjK","InjL","INVALID","INVALID","INVALID","INVALID"
      testsel_coil     = bits, U08,     14, [4:7], "CoilA", "CoilB", "CoilC", "CoilD", "CoilE", "CoilF", "CoilG", "CoilH", "CoilI", "CoilJ", "CoilK", "CoilL", "CoilM", "CoilN", "INVALID", "INVALID"

      dbgtooth    = scalar, U08, 15, "tooth", 1,0,0,255,0
      iacpostest  = scalar, U16, 16, "steps", 1,0,0,65535,0
      iachometest      = scalar, U16, 18, "steps", 1,0,0,65535,0
      iactest_0       = scalar, U08, 20, "", 1,0,0,255,0, noLocalUpdate 
      iactest         = bits, U08, 20, [0:0], "run", "home" ; // home the valve
      iactestlock     = bits, U08, 20, [1:1], "Off", "On" ; // Enable

      flashlock       = bits, U08, 21, [0:0], "Locked", "Unlocked" ; tables 0-3

;shared      boost_ctl_settings_freq2  = bits,   U08, 22, [0:2], "INVALID", "78Hz", "39Hz", "26Hz", "19.5Hz", "15.6Hz", "13Hz", "11.1Hz"
      boost_ctl_settings_on2    = bits,   U08, 22, [3:3], "Off","On"
      boost_ctl_settings_cl2    = bits,   U08, 22, [4:4], "Open-loop", "Closed-loop"
; shared      boost_ctl_settings_invert2= bits,   U08, 22, [5:5], "Normal", "Inverted"
      boost_ctl_pins_pwm2       = bits,   U08, 23, [5:7], "Boost", "Idle", "VVT", "Nitrous1", "Nitrous2", "Fidle", "Inj Bank 1", "Inj Bank 2"
      boost_ctl_pins2           = bits,   U08, 23, [0:4], "INVALID", "IAC1", "IAC2", "FIDLE", "D15", "Nitrous 1", "Nitrous 2", "Tacho", "Idle", "Boost", "VVT", "Inj Bank 1", "Inj Bank 2", "D14", "D16", "JS11", "Inj A", "Inj B", "Inj C", "Inj D", "Inj E", "Inj F", "Inj G", "Inj H", "PT4", "IGN (JS10)", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID"
      boost_ctl_Kp2             = scalar, U08, 24, "%", 1, 0.00000, 0, 200, 0
      boost_ctl_Ki2             = scalar, U08, 25, "%", 1, 0.00000, 0, 200, 0
      boost_ctl_Kd2             = scalar, U08, 26, "%", 1, 0.00000, 0, 200, 0
      boost_ctl_closeduty2      = scalar, U08, 27, "%", 1, 0.00000, 0, 100, 0
      boost_ctl_openduty2       = scalar, U08, 28, "%", 1, 0.00000, 0, 100, 0
;pad
      boost_ctl_lowerlimit2 =      scalar, S16, 30, "%",0.10000, 0.00000, 100, {loadhigh}, 1
      boost_ctl_sensor2 =  bits, U08, 32, [0:3], "Sensor 1", "Sensor 2","Sensor 3","Sensor 4","Sensor 5","Sensor 6","Sensor 7","Sensor 8","Sensor 9","Sensor 10","Sensor 11","Sensor 12","Sensor 13","Sensor 14","Sensor 15","Sensor 16"
;small gap
    egoport1    = bits,   U08,  40, [0:4], "Normal EGO", "JS5 (ADC6)", "JS4 (ADC7)", "EXT_MAP (ADC11)", "EGO2 (ADC12)", "Spare ADC (ADC13)", "INVALID", "CAN EGO", "CAN ADC01", "CAN ADC02", "CAN ADC03", "CAN ADC04", "CAN ADC05", "CAN ADC06", "CAN ADC07", "CAN ADC08", "CAN ADC09", "CAN ADC10", "CAN ADC11", "CAN ADC12", "CAN ADC13", "CAN ADC14", "CAN ADC15", "CAN ADC16", "CAN ADC17", "CAN ADC18", "CAN ADC19", "CAN ADC20", "CAN ADC21", "CAN ADC22", "CAN ADC23", "CAN ADC24"
    egoport2    = bits,   U08,  41, [0:4], "Off", "JS5 (ADC6)", "JS4 (ADC7)", "EXT_MAP (ADC11)", "EGO2 (ADC12)", "Spare ADC (ADC13)", "INVALID", "CAN EGO", "CAN ADC01", "CAN ADC02", "CAN ADC03", "CAN ADC04", "CAN ADC05", "CAN ADC06", "CAN ADC07", "CAN ADC08", "CAN ADC09", "CAN ADC10", "CAN ADC11", "CAN ADC12", "CAN ADC13", "CAN ADC14", "CAN ADC15", "CAN ADC16", "CAN ADC17", "CAN ADC18", "CAN ADC19", "CAN ADC20", "CAN ADC21", "CAN ADC22", "CAN ADC23", "CAN ADC24"
    egoport3    = bits,   U08,  42, [0:4], "Off", "JS5 (ADC6)", "JS4 (ADC7)", "EXT_MAP (ADC11)", "EGO2 (ADC12)", "Spare ADC (ADC13)", "INVALID", "CAN EGO", "CAN ADC01", "CAN ADC02", "CAN ADC03", "CAN ADC04", "CAN ADC05", "CAN ADC06", "CAN ADC07", "CAN ADC08", "CAN ADC09", "CAN ADC10", "CAN ADC11", "CAN ADC12", "CAN ADC13", "CAN ADC14", "CAN ADC15", "CAN ADC16", "CAN ADC17", "CAN ADC18", "CAN ADC19", "CAN ADC20", "CAN ADC21", "CAN ADC22", "CAN ADC23", "CAN ADC24"
    egoport4    = bits,   U08,  43, [0:4], "Off", "JS5 (ADC6)", "JS4 (ADC7)", "EXT_MAP (ADC11)", "EGO2 (ADC12)", "Spare ADC (ADC13)", "INVALID", "CAN EGO", "CAN ADC01", "CAN ADC02", "CAN ADC03", "CAN ADC04", "CAN ADC05", "CAN ADC06", "CAN ADC07", "CAN ADC08", "CAN ADC09", "CAN ADC10", "CAN ADC11", "CAN ADC12", "CAN ADC13", "CAN ADC14", "CAN ADC15", "CAN ADC16", "CAN ADC17", "CAN ADC18", "CAN ADC19", "CAN ADC20", "CAN ADC21", "CAN ADC22", "CAN ADC23", "CAN ADC24"
    egoport5    = bits,   U08,  44, [0:4], "Off", "JS5 (ADC6)", "JS4 (ADC7)", "EXT_MAP (ADC11)", "EGO2 (ADC12)", "Spare ADC (ADC13)", "INVALID", "CAN EGO", "CAN ADC01", "CAN ADC02", "CAN ADC03", "CAN ADC04", "CAN ADC05", "CAN ADC06", "CAN ADC07", "CAN ADC08", "CAN ADC09", "CAN ADC10", "CAN ADC11", "CAN ADC12", "CAN ADC13", "CAN ADC14", "CAN ADC15", "CAN ADC16", "CAN ADC17", "CAN ADC18", "CAN ADC19", "CAN ADC20", "CAN ADC21", "CAN ADC22", "CAN ADC23", "CAN ADC24"
    egoport6    = bits,   U08,  45, [0:4], "Off", "JS5 (ADC6)", "JS4 (ADC7)", "EXT_MAP (ADC11)", "EGO2 (ADC12)", "Spare ADC (ADC13)", "INVALID", "CAN EGO", "CAN ADC01", "CAN ADC02", "CAN ADC03", "CAN ADC04", "CAN ADC05", "CAN ADC06", "CAN ADC07", "CAN ADC08", "CAN ADC09", "CAN ADC10", "CAN ADC11", "CAN ADC12", "CAN ADC13", "CAN ADC14", "CAN ADC15", "CAN ADC16", "CAN ADC17", "CAN ADC18", "CAN ADC19", "CAN ADC20", "CAN ADC21", "CAN ADC22", "CAN ADC23", "CAN ADC24"
    egoport7    = bits,   U08,  46, [0:4], "Off", "JS5 (ADC6)", "JS4 (ADC7)", "EXT_MAP (ADC11)", "EGO2 (ADC12)", "Spare ADC (ADC13)", "INVALID", "CAN EGO", "CAN ADC01", "CAN ADC02", "CAN ADC03", "CAN ADC04", "CAN ADC05", "CAN ADC06", "CAN ADC07", "CAN ADC08", "CAN ADC09", "CAN ADC10", "CAN ADC11", "CAN ADC12", "CAN ADC13", "CAN ADC14", "CAN ADC15", "CAN ADC16", "CAN ADC17", "CAN ADC18", "CAN ADC19", "CAN ADC20", "CAN ADC21", "CAN ADC22", "CAN ADC23", "CAN ADC24"
    egoport8    = bits,   U08,  47, [0:4], "Off", "JS5 (ADC6)", "JS4 (ADC7)", "EXT_MAP (ADC11)", "EGO2 (ADC12)", "Spare ADC (ADC13)", "INVALID", "CAN EGO", "CAN ADC01", "CAN ADC02", "CAN ADC03", "CAN ADC04", "CAN ADC05", "CAN ADC06", "CAN ADC07", "CAN ADC08", "CAN ADC09", "CAN ADC10", "CAN ADC11", "CAN ADC12", "CAN ADC13", "CAN ADC14", "CAN ADC15", "CAN ADC16", "CAN ADC17", "CAN ADC18", "CAN ADC19", "CAN ADC20", "CAN ADC21", "CAN ADC22", "CAN ADC23", "CAN ADC24"
    egoport9    = bits,   U08,  48, [0:4], "Off", "JS5 (ADC6)", "JS4 (ADC7)", "EXT_MAP (ADC11)", "EGO2 (ADC12)", "Spare ADC (ADC13)", "INVALID", "CAN EGO", "CAN ADC01", "CAN ADC02", "CAN ADC03", "CAN ADC04", "CAN ADC05", "CAN ADC06", "CAN ADC07", "CAN ADC08", "CAN ADC09", "CAN ADC10", "CAN ADC11", "CAN ADC12", "CAN ADC13", "CAN ADC14", "CAN ADC15", "CAN ADC16", "CAN ADC17", "CAN ADC18", "CAN ADC19", "CAN ADC20", "CAN ADC21", "CAN ADC22", "CAN ADC23", "CAN ADC24"
    egoport10   = bits,   U08,  49, [0:4], "Off", "JS5 (ADC6)", "JS4 (ADC7)", "EXT_MAP (ADC11)", "EGO2 (ADC12)", "Spare ADC (ADC13)", "INVALID", "CAN EGO", "CAN ADC01", "CAN ADC02", "CAN ADC03", "CAN ADC04", "CAN ADC05", "CAN ADC06", "CAN ADC07", "CAN ADC08", "CAN ADC09", "CAN ADC10", "CAN ADC11", "CAN ADC12", "CAN ADC13", "CAN ADC14", "CAN ADC15", "CAN ADC16", "CAN ADC17", "CAN ADC18", "CAN ADC19", "CAN ADC20", "CAN ADC21", "CAN ADC22", "CAN ADC23", "CAN ADC24"
    egoport11   = bits,   U08,  50, [0:4], "Off", "JS5 (ADC6)", "JS4 (ADC7)", "EXT_MAP (ADC11)", "EGO2 (ADC12)", "Spare ADC (ADC13)", "INVALID", "CAN EGO", "CAN ADC01", "CAN ADC02", "CAN ADC03", "CAN ADC04", "CAN ADC05", "CAN ADC06", "CAN ADC07", "CAN ADC08", "CAN ADC09", "CAN ADC10", "CAN ADC11", "CAN ADC12", "CAN ADC13", "CAN ADC14", "CAN ADC15", "CAN ADC16", "CAN ADC17", "CAN ADC18", "CAN ADC19", "CAN ADC20", "CAN ADC21", "CAN ADC22", "CAN ADC23", "CAN ADC24"
    egoport12   = bits,   U08,  51, [0:4], "Off", "JS5 (ADC6)", "JS4 (ADC7)", "EXT_MAP (ADC11)", "EGO2 (ADC12)", "Spare ADC (ADC13)", "INVALID", "CAN EGO", "CAN ADC01", "CAN ADC02", "CAN ADC03", "CAN ADC04", "CAN ADC05", "CAN ADC06", "CAN ADC07", "CAN ADC08", "CAN ADC09", "CAN ADC10", "CAN ADC11", "CAN ADC12", "CAN ADC13", "CAN ADC14", "CAN ADC15", "CAN ADC16", "CAN ADC17", "CAN ADC18", "CAN ADC19", "CAN ADC20", "CAN ADC21", "CAN ADC22", "CAN ADC23", "CAN ADC24"
    egoport13   = bits,   U08,  52, [0:4], "Off", "JS5 (ADC6)", "JS4 (ADC7)", "EXT_MAP (ADC11)", "EGO2 (ADC12)", "Spare ADC (ADC13)", "INVALID", "CAN EGO", "CAN ADC01", "CAN ADC02", "CAN ADC03", "CAN ADC04", "CAN ADC05", "CAN ADC06", "CAN ADC07", "CAN ADC08", "CAN ADC09", "CAN ADC10", "CAN ADC11", "CAN ADC12", "CAN ADC13", "CAN ADC14", "CAN ADC15", "CAN ADC16", "CAN ADC17", "CAN ADC18", "CAN ADC19", "CAN ADC20", "CAN ADC21", "CAN ADC22", "CAN ADC23", "CAN ADC24"
    egoport14   = bits,   U08,  53, [0:4], "Off", "JS5 (ADC6)", "JS4 (ADC7)", "EXT_MAP (ADC11)", "EGO2 (ADC12)", "Spare ADC (ADC13)", "INVALID", "CAN EGO", "CAN ADC01", "CAN ADC02", "CAN ADC03", "CAN ADC04", "CAN ADC05", "CAN ADC06", "CAN ADC07", "CAN ADC08", "CAN ADC09", "CAN ADC10", "CAN ADC11", "CAN ADC12", "CAN ADC13", "CAN ADC14", "CAN ADC15", "CAN ADC16", "CAN ADC17", "CAN ADC18", "CAN ADC19", "CAN ADC20", "CAN ADC21", "CAN ADC22", "CAN ADC23", "CAN ADC24"
    egoport15   = bits,   U08,  54, [0:4], "Off", "JS5 (ADC6)", "JS4 (ADC7)", "EXT_MAP (ADC11)", "EGO2 (ADC12)", "Spare ADC (ADC13)", "INVALID", "CAN EGO", "CAN ADC01", "CAN ADC02", "CAN ADC03", "CAN ADC04", "CAN ADC05", "CAN ADC06", "CAN ADC07", "CAN ADC08", "CAN ADC09", "CAN ADC10", "CAN ADC11", "CAN ADC12", "CAN ADC13", "CAN ADC14", "CAN ADC15", "CAN ADC16", "CAN ADC17", "CAN ADC18", "CAN ADC19", "CAN ADC20", "CAN ADC21", "CAN ADC22", "CAN ADC23", "CAN ADC24"
    egoport16   = bits,   U08,  55, [0:4], "Off", "JS5 (ADC6)", "JS4 (ADC7)", "EXT_MAP (ADC11)", "EGO2 (ADC12)", "Spare ADC (ADC13)", "INVALID", "CAN EGO", "CAN ADC01", "CAN ADC02", "CAN ADC03", "CAN ADC04", "CAN ADC05", "CAN ADC06", "CAN ADC07", "CAN ADC08", "CAN ADC09", "CAN ADC10", "CAN ADC11", "CAN ADC12", "CAN ADC13", "CAN ADC14", "CAN ADC15", "CAN ADC16", "CAN ADC17", "CAN ADC18", "CAN ADC19", "CAN ADC20", "CAN ADC21", "CAN ADC22", "CAN ADC23", "CAN ADC24"

    egomap1     = bits,   U08,  56, [0:3], "EGO1", "EGO2", "EGO3", "EGO4", "EGO5", "EGO6", "EGO7", "EGO8", "EGO9", "EGO10", "EGO11", "EGO12", "EGO13", "EGO14", "EGO15", "EGO16"
    egomap2     = bits,   U08,  57, [0:2], "EGO1", "EGO2", "EGO3", "EGO4", "EGO5", "EGO6", "EGO7", "EGO8", "EGO9", "EGO10", "EGO11", "EGO12", "EGO13", "EGO14", "EGO15", "EGO16"
    egomap3     = bits,   U08,  58, [0:2], "EGO1", "EGO2", "EGO3", "EGO4", "EGO5", "EGO6", "EGO7", "EGO8", "EGO9", "EGO10", "EGO11", "EGO12", "EGO13", "EGO14", "EGO15", "EGO16"
    egomap4     = bits,   U08,  59, [0:2], "EGO1", "EGO2", "EGO3", "EGO4", "EGO5", "EGO6", "EGO7", "EGO8", "EGO9", "EGO10", "EGO11", "EGO12", "EGO13", "EGO14", "EGO15", "EGO16"
    egomap5     = bits,   U08,  60, [0:2], "EGO1", "EGO2", "EGO3", "EGO4", "EGO5", "EGO6", "EGO7", "EGO8", "EGO9", "EGO10", "EGO11", "EGO12", "EGO13", "EGO14", "EGO15", "EGO16"
    egomap6     = bits,   U08,  61, [0:2], "EGO1", "EGO2", "EGO3", "EGO4", "EGO5", "EGO6", "EGO7", "EGO8", "EGO9", "EGO10", "EGO11", "EGO12", "EGO13", "EGO14", "EGO15", "EGO16"
    egomap7     = bits,   U08,  62, [0:2], "EGO1", "EGO2", "EGO3", "EGO4", "EGO5", "EGO6", "EGO7", "EGO8", "EGO9", "EGO10", "EGO11", "EGO12", "EGO13", "EGO14", "EGO15", "EGO16"
    egomap8     = bits,   U08,  63, [0:2], "EGO1", "EGO2", "EGO3", "EGO4", "EGO5", "EGO6", "EGO7", "EGO8", "EGO9", "EGO10", "EGO11", "EGO12", "EGO13", "EGO14", "EGO15", "EGO16"
    egomap9     = bits,   U08,  64, [0:2], "EGO1", "EGO2", "EGO3", "EGO4", "EGO5", "EGO6", "EGO7", "EGO8", "EGO9", "EGO10", "EGO11", "EGO12", "EGO13", "EGO14", "EGO15", "EGO16"
    egomap10    = bits,   U08,  65, [0:2], "EGO1", "EGO2", "EGO3", "EGO4", "EGO5", "EGO6", "EGO7", "EGO8", "EGO9", "EGO10", "EGO11", "EGO12", "EGO13", "EGO14", "EGO15", "EGO16"
    egomap11    = bits,   U08,  66, [0:2], "EGO1", "EGO2", "EGO3", "EGO4", "EGO5", "EGO6", "EGO7", "EGO8", "EGO9", "EGO10", "EGO11", "EGO12", "EGO13", "EGO14", "EGO15", "EGO16"
    egomap12    = bits,   U08,  67, [0:2], "EGO1", "EGO2", "EGO3", "EGO4", "EGO5", "EGO6", "EGO7", "EGO8", "EGO9", "EGO10", "EGO11", "EGO12", "EGO13", "EGO14", "EGO15", "EGO16"
    egomap13    = bits,   U08,  68, [0:2], "EGO1", "EGO2", "EGO3", "EGO4", "EGO5", "EGO6", "EGO7", "EGO8", "EGO9", "EGO10", "EGO11", "EGO12", "EGO13", "EGO14", "EGO15", "EGO16"
    egomap14    = bits,   U08,  69, [0:2], "EGO1", "EGO2", "EGO3", "EGO4", "EGO5", "EGO6", "EGO7", "EGO8", "EGO9", "EGO10", "EGO11", "EGO12", "EGO13", "EGO14", "EGO15", "EGO16"
    egomap15    = bits,   U08,  70, [0:2], "EGO1", "EGO2", "EGO3", "EGO4", "EGO5", "EGO6", "EGO7", "EGO8", "EGO9", "EGO10", "EGO11", "EGO12", "EGO13", "EGO14", "EGO15", "EGO16"
    egomap16    = bits,   U08,  71, [0:2], "EGO1", "EGO2", "EGO3", "EGO4", "EGO5", "EGO6", "EGO7", "EGO8", "EGO9", "EGO10", "EGO11", "EGO12", "EGO13", "EGO14", "EGO15", "EGO16"
    egomap1t    = bits,   U08,  56, [4:4], "1", "2"
    egomap2t    = bits,   U08,  57, [4:4], "1", "2"
    egomap3t    = bits,   U08,  58, [4:4], "1", "2"
    egomap4t    = bits,   U08,  59, [4:4], "1", "2"
    egomap5t    = bits,   U08,  60, [4:4], "1", "2"
    egomap6t    = bits,   U08,  61, [4:4], "1", "2"
    egomap7t    = bits,   U08,  62, [4:4], "1", "2"
    egomap8t    = bits,   U08,  63, [4:4], "1", "2"
    egomap9t    = bits,   U08,  64, [4:4], "1", "2"
    egomap10t   = bits,   U08,  65, [4:4], "1", "2"
    egomap11t   = bits,   U08,  66, [4:4], "1", "2"
    egomap12t   = bits,   U08,  67, [4:4], "1", "2"
    egomap13t   = bits,   U08,  68, [4:4], "1", "2"
    egomap14t   = bits,   U08,  69, [4:4], "1", "2"
    egomap15t   = bits,   U08,  70, [4:4], "1", "2"
    egomap16t   = bits,   U08,  71, [4:4], "1", "2"

      tc_opt_on     = bits, U08, 72, [0:0], "Off", "On"
      tc_opt_method = bits, U08, 72, [1:2], "Perfect Run", "VSS %slip", "INVALID", "INVALID"
      tc_opt_n2o    = bits, U08, 72, [5:5], "On/Off", "INVALID"
      tc_opt_bank   = bits, U08, 72, [6:7], "INVALID", "Bank 1", "Bank 2", "Both"
      tc_slipthresh = scalar, U08, 73, "%",  1, 0.00000, 0, 100, 0
#if MPH
      tc_minvss     = scalar, U16, 74, "mph", 0.22369, 0.00000, 0, 200, 1
      tc_maxvss     = scalar, U16, 76, "mph", 0.22369, 0.00000, 0, 200, 1
#else
      tc_minvss     = scalar, U16, 74, "kph", 0.36000, 0.00000, 0, 200, 1
      tc_maxvss     = scalar, U16, 76, "kph", 0.36000, 0.00000, 0, 200, 1
#endif
      tc_mintps     = scalar, S16, 78, "%",  0.10000, 0.00000, 0, 100, 1
      tc_enin       = bits, U08, 80, [0:4], "Off", "Tableswitch", "PE0/JS7", "PE1", "JS10", "JS11", "JS5 (ADC6)", "JS4 (ADC7)", "Nitrous In", "Launch in", "Datalog In", "PT4 Spare in", "PT2 Cam in", "PE2 Flex", "INVALID", "INVALID", "CANIN1", "CANIN2", "CANIN3", "CANIN4", "CANIN5", "CANIN6", "CANIN7", "CANIN8", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID"

    knock_bpass = bits, U08, 81, [0:5], "1.22", "1.26", "1.31", "1.35", "1.40", "1.45", "1.51", "1.57", "1.63", "1.71", "1.78", "1.87", "1.96", "2.07", "2.18", "2.31", "2.46", "2.54", "2.62", "2.71", "2.81", "2.92", "3.03", "3.15", "3.28", "3.43", "3.59", "3.76", "3.95", "4.16", "4.39", "4.66", "4.95", "5.12", "5.29", "5.48", "5.68", "5.90", "6.12", "6.37", "6.64", "6.94", "7.27", "7.63", "8.02", "8.46", "8.95", "9.50", "10.12", "10.46", "10.83", "11.22", "11.65", "12.10", "12.60", "13.14", "13.72", "14.36", "15.07", "15.84", "16.71", "17.67", "18.76", "19.98"
    knock_conf_num = bits, U08, 82, [0:0], "1", "2"
    knock_conf_percyl = bits, U08, 82, [7:7], "Off", "On"
    knock_int      = bits, U08, 83, [0:4], "40", "45", "50", "55", "60", "65", "70", "75", "80", "90", "100", "110", "120", "130", "140", "150", "160", "180", "200", "220", "240", "260", "280", "300", "320", "360", "400", "440", "480", "520", "560", "600"

    ff_tpw0        = scalar, U08, 84, "ms", 0.05, 0, 0, 12.7, 2
    ff_tpw1        = scalar, U08, 85, "ms", 0.05, 0, 0, 12.7, 2
#if CELSIUS
    ff_temp0   = scalar, S16, 86, "°C", 0.05555, -320, -40, 150.00, 1
    ff_temp1   = scalar, S16, 88, "°C", 0.05555, -320, -40, 150.00, 1
#else
    ff_temp0   = scalar, S16, 86, "°F", 0.10000, 0.00000, -40, 300, 1
    ff_temp1   = scalar, S16, 88, "°F", 0.10000, 0.00000, -40, 300, 1
#endif
    fueltemp1  = bits, U08,   90, [0:4], "Off", "Flex fuel", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "Sensor 1", "Sensor 2","Sensor 3","Sensor 4","Sensor 5","Sensor 6","Sensor 7","Sensor 8","Sensor 9","Sensor 10","Sensor 11","Sensor 12","Sensor 13","Sensor 14","Sensor 15","Sensor 16"

    ;pad
    maf_freq0  = scalar, U16, 92, "Hz", 0.2, 0.00000, 0, 13107,1
    maf_freq1  = scalar, U16, 94, "Hz", 0.2, 0.00000, 0, 13107,1
    map_freq0  = scalar, U16, 96, "Hz", 0.2, 0.00000, 0, 13107,1
    map_freq1  = scalar, U16, 98, "Hz", 0.2, 0.00000, 0, 13107,1

    knock_gain01 = bits, U08, 100, [0:5], "2.000", "1.882", "1.778", "1.684", "1.600", "1.523", "1.455", "1.391", "1.333", "1.280", "1.231", "1.185", "1.143", "1.063", "1.000", "0.944", "0.895", "0.85", "0.81", "0.773", "0.739", "0.708", "0.680", "0.654", "0.630", "0.607", "0.586", "0.567", "0.548", "0.500", "0.471", "0.444", "0.421", "0.400", "0.381", "0.364", "0.348", "0.333", "0.320", "0.308", "0.296", "0.286", "0.276", "0.267", "0.258", "0.250", "0.236", "0.222", "0.211", "0.200", "0.190", "0.182", "0.174", "0.167", "0.160", "0.154", "0.148", "0.143", "0.138", "0.133", "0.129", "0.125", "0.118", "0.111"   
    knock_gain02 = bits, U08, 101, [0:5], "2.000", "1.882", "1.778", "1.684", "1.600", "1.523", "1.455", "1.391", "1.333", "1.280", "1.231", "1.185", "1.143", "1.063", "1.000", "0.944", "0.895", "0.85", "0.81", "0.773", "0.739", "0.708", "0.680", "0.654", "0.630", "0.607", "0.586", "0.567", "0.548", "0.500", "0.471", "0.444", "0.421", "0.400", "0.381", "0.364", "0.348", "0.333", "0.320", "0.308", "0.296", "0.286", "0.276", "0.267", "0.258", "0.250", "0.236", "0.222", "0.211", "0.200", "0.190", "0.182", "0.174", "0.167", "0.160", "0.154", "0.148", "0.143", "0.138", "0.133", "0.129", "0.125", "0.118", "0.111"   
    knock_gain03 = bits, U08, 102, [0:5], "2.000", "1.882", "1.778", "1.684", "1.600", "1.523", "1.455", "1.391", "1.333", "1.280", "1.231", "1.185", "1.143", "1.063", "1.000", "0.944", "0.895", "0.85", "0.81", "0.773", "0.739", "0.708", "0.680", "0.654", "0.630", "0.607", "0.586", "0.567", "0.548", "0.500", "0.471", "0.444", "0.421", "0.400", "0.381", "0.364", "0.348", "0.333", "0.320", "0.308", "0.296", "0.286", "0.276", "0.267", "0.258", "0.250", "0.236", "0.222", "0.211", "0.200", "0.190", "0.182", "0.174", "0.167", "0.160", "0.154", "0.148", "0.143", "0.138", "0.133", "0.129", "0.125", "0.118", "0.111"   
    knock_gain04 = bits, U08, 103, [0:5], "2.000", "1.882", "1.778", "1.684", "1.600", "1.523", "1.455", "1.391", "1.333", "1.280", "1.231", "1.185", "1.143", "1.063", "1.000", "0.944", "0.895", "0.85", "0.81", "0.773", "0.739", "0.708", "0.680", "0.654", "0.630", "0.607", "0.586", "0.567", "0.548", "0.500", "0.471", "0.444", "0.421", "0.400", "0.381", "0.364", "0.348", "0.333", "0.320", "0.308", "0.296", "0.286", "0.276", "0.267", "0.258", "0.250", "0.236", "0.222", "0.211", "0.200", "0.190", "0.182", "0.174", "0.167", "0.160", "0.154", "0.148", "0.143", "0.138", "0.133", "0.129", "0.125", "0.118", "0.111"   
    knock_gain05 = bits, U08, 104, [0:5], "2.000", "1.882", "1.778", "1.684", "1.600", "1.523", "1.455", "1.391", "1.333", "1.280", "1.231", "1.185", "1.143", "1.063", "1.000", "0.944", "0.895", "0.85", "0.81", "0.773", "0.739", "0.708", "0.680", "0.654", "0.630", "0.607", "0.586", "0.567", "0.548", "0.500", "0.471", "0.444", "0.421", "0.400", "0.381", "0.364", "0.348", "0.333", "0.320", "0.308", "0.296", "0.286", "0.276", "0.267", "0.258", "0.250", "0.236", "0.222", "0.211", "0.200", "0.190", "0.182", "0.174", "0.167", "0.160", "0.154", "0.148", "0.143", "0.138", "0.133", "0.129", "0.125", "0.118", "0.111"   
    knock_gain06 = bits, U08, 105, [0:5], "2.000", "1.882", "1.778", "1.684", "1.600", "1.523", "1.455", "1.391", "1.333", "1.280", "1.231", "1.185", "1.143", "1.063", "1.000", "0.944", "0.895", "0.85", "0.81", "0.773", "0.739", "0.708", "0.680", "0.654", "0.630", "0.607", "0.586", "0.567", "0.548", "0.500", "0.471", "0.444", "0.421", "0.400", "0.381", "0.364", "0.348", "0.333", "0.320", "0.308", "0.296", "0.286", "0.276", "0.267", "0.258", "0.250", "0.236", "0.222", "0.211", "0.200", "0.190", "0.182", "0.174", "0.167", "0.160", "0.154", "0.148", "0.143", "0.138", "0.133", "0.129", "0.125", "0.118", "0.111"   
    knock_gain07 = bits, U08, 106, [0:5], "2.000", "1.882", "1.778", "1.684", "1.600", "1.523", "1.455", "1.391", "1.333", "1.280", "1.231", "1.185", "1.143", "1.063", "1.000", "0.944", "0.895", "0.85", "0.81", "0.773", "0.739", "0.708", "0.680", "0.654", "0.630", "0.607", "0.586", "0.567", "0.548", "0.500", "0.471", "0.444", "0.421", "0.400", "0.381", "0.364", "0.348", "0.333", "0.320", "0.308", "0.296", "0.286", "0.276", "0.267", "0.258", "0.250", "0.236", "0.222", "0.211", "0.200", "0.190", "0.182", "0.174", "0.167", "0.160", "0.154", "0.148", "0.143", "0.138", "0.133", "0.129", "0.125", "0.118", "0.111"   
    knock_gain08 = bits, U08, 107, [0:5], "2.000", "1.882", "1.778", "1.684", "1.600", "1.523", "1.455", "1.391", "1.333", "1.280", "1.231", "1.185", "1.143", "1.063", "1.000", "0.944", "0.895", "0.85", "0.81", "0.773", "0.739", "0.708", "0.680", "0.654", "0.630", "0.607", "0.586", "0.567", "0.548", "0.500", "0.471", "0.444", "0.421", "0.400", "0.381", "0.364", "0.348", "0.333", "0.320", "0.308", "0.296", "0.286", "0.276", "0.267", "0.258", "0.250", "0.236", "0.222", "0.211", "0.200", "0.190", "0.182", "0.174", "0.167", "0.160", "0.154", "0.148", "0.143", "0.138", "0.133", "0.129", "0.125", "0.118", "0.111"   
    knock_gain09 = bits, U08, 108, [0:5], "2.000", "1.882", "1.778", "1.684", "1.600", "1.523", "1.455", "1.391", "1.333", "1.280", "1.231", "1.185", "1.143", "1.063", "1.000", "0.944", "0.895", "0.85", "0.81", "0.773", "0.739", "0.708", "0.680", "0.654", "0.630", "0.607", "0.586", "0.567", "0.548", "0.500", "0.471", "0.444", "0.421", "0.400", "0.381", "0.364", "0.348", "0.333", "0.320", "0.308", "0.296", "0.286", "0.276", "0.267", "0.258", "0.250", "0.236", "0.222", "0.211", "0.200", "0.190", "0.182", "0.174", "0.167", "0.160", "0.154", "0.148", "0.143", "0.138", "0.133", "0.129", "0.125", "0.118", "0.111"   
    knock_gain10 = bits, U08, 109, [0:5], "2.000", "1.882", "1.778", "1.684", "1.600", "1.523", "1.455", "1.391", "1.333", "1.280", "1.231", "1.185", "1.143", "1.063", "1.000", "0.944", "0.895", "0.85", "0.81", "0.773", "0.739", "0.708", "0.680", "0.654", "0.630", "0.607", "0.586", "0.567", "0.548", "0.500", "0.471", "0.444", "0.421", "0.400", "0.381", "0.364", "0.348", "0.333", "0.320", "0.308", "0.296", "0.286", "0.276", "0.267", "0.258", "0.250", "0.236", "0.222", "0.211", "0.200", "0.190", "0.182", "0.174", "0.167", "0.160", "0.154", "0.148", "0.143", "0.138", "0.133", "0.129", "0.125", "0.118", "0.111"   
    knock_gain11 = bits, U08, 110, [0:5], "2.000", "1.882", "1.778", "1.684", "1.600", "1.523", "1.455", "1.391", "1.333", "1.280", "1.231", "1.185", "1.143", "1.063", "1.000", "0.944", "0.895", "0.85", "0.81", "0.773", "0.739", "0.708", "0.680", "0.654", "0.630", "0.607", "0.586", "0.567", "0.548", "0.500", "0.471", "0.444", "0.421", "0.400", "0.381", "0.364", "0.348", "0.333", "0.320", "0.308", "0.296", "0.286", "0.276", "0.267", "0.258", "0.250", "0.236", "0.222", "0.211", "0.200", "0.190", "0.182", "0.174", "0.167", "0.160", "0.154", "0.148", "0.143", "0.138", "0.133", "0.129", "0.125", "0.118", "0.111"   
    knock_gain12 = bits, U08, 111, [0:5], "2.000", "1.882", "1.778", "1.684", "1.600", "1.523", "1.455", "1.391", "1.333", "1.280", "1.231", "1.185", "1.143", "1.063", "1.000", "0.944", "0.895", "0.85", "0.81", "0.773", "0.739", "0.708", "0.680", "0.654", "0.630", "0.607", "0.586", "0.567", "0.548", "0.500", "0.471", "0.444", "0.421", "0.400", "0.381", "0.364", "0.348", "0.333", "0.320", "0.308", "0.296", "0.286", "0.276", "0.267", "0.258", "0.250", "0.236", "0.222", "0.211", "0.200", "0.190", "0.182", "0.174", "0.167", "0.160", "0.154", "0.148", "0.143", "0.138", "0.133", "0.129", "0.125", "0.118", "0.111"   

    knock_gain13 = bits, U08, 112, [0:5], "2.000", "1.882", "1.778", "1.684", "1.600", "1.523", "1.455", "1.391", "1.333", "1.280", "1.231", "1.185", "1.143", "1.063", "1.000", "0.944", "0.895", "0.85", "0.81", "0.773", "0.739", "0.708", "0.680", "0.654", "0.630", "0.607", "0.586", "0.567", "0.548", "0.500", "0.471", "0.444", "0.421", "0.400", "0.381", "0.364", "0.348", "0.333", "0.320", "0.308", "0.296", "0.286", "0.276", "0.267", "0.258", "0.250", "0.236", "0.222", "0.211", "0.200", "0.190", "0.182", "0.174", "0.167", "0.160", "0.154", "0.148", "0.143", "0.138", "0.133", "0.129", "0.125", "0.118", "0.111"   
    knock_gain14 = bits, U08, 113, [0:5], "2.000", "1.882", "1.778", "1.684", "1.600", "1.523", "1.455", "1.391", "1.333", "1.280", "1.231", "1.185", "1.143", "1.063", "1.000", "0.944", "0.895", "0.85", "0.81", "0.773", "0.739", "0.708", "0.680", "0.654", "0.630", "0.607", "0.586", "0.567", "0.548", "0.500", "0.471", "0.444", "0.421", "0.400", "0.381", "0.364", "0.348", "0.333", "0.320", "0.308", "0.296", "0.286", "0.276", "0.267", "0.258", "0.250", "0.236", "0.222", "0.211", "0.200", "0.190", "0.182", "0.174", "0.167", "0.160", "0.154", "0.148", "0.143", "0.138", "0.133", "0.129", "0.125", "0.118", "0.111"   
    knock_gain15 = bits, U08, 114, [0:5], "2.000", "1.882", "1.778", "1.684", "1.600", "1.523", "1.455", "1.391", "1.333", "1.280", "1.231", "1.185", "1.143", "1.063", "1.000", "0.944", "0.895", "0.85", "0.81", "0.773", "0.739", "0.708", "0.680", "0.654", "0.630", "0.607", "0.586", "0.567", "0.548", "0.500", "0.471", "0.444", "0.421", "0.400", "0.381", "0.364", "0.348", "0.333", "0.320", "0.308", "0.296", "0.286", "0.276", "0.267", "0.258", "0.250", "0.236", "0.222", "0.211", "0.200", "0.190", "0.182", "0.174", "0.167", "0.160", "0.154", "0.148", "0.143", "0.138", "0.133", "0.129", "0.125", "0.118", "0.111"   
    knock_gain16 = bits, U08, 115, [0:5], "2.000", "1.882", "1.778", "1.684", "1.600", "1.523", "1.455", "1.391", "1.333", "1.280", "1.231", "1.185", "1.143", "1.063", "1.000", "0.944", "0.895", "0.85", "0.81", "0.773", "0.739", "0.708", "0.680", "0.654", "0.630", "0.607", "0.586", "0.567", "0.548", "0.500", "0.471", "0.444", "0.421", "0.400", "0.381", "0.364", "0.348", "0.333", "0.320", "0.308", "0.296", "0.286", "0.276", "0.267", "0.258", "0.250", "0.236", "0.222", "0.211", "0.200", "0.190", "0.182", "0.174", "0.167", "0.160", "0.154", "0.148", "0.143", "0.138", "0.133", "0.129", "0.125", "0.118", "0.111"   

    knock_sens01 = bits, U08, 116, [0:0], "1", "2"
    knock_sens02 = bits, U08, 117, [0:0], "1", "2"
    knock_sens03 = bits, U08, 118, [0:0], "1", "2"
    knock_sens04 = bits, U08, 119, [0:0], "1", "2"
    knock_sens05 = bits, U08, 120, [0:0], "1", "2"
    knock_sens06 = bits, U08, 121, [0:0], "1", "2"
    knock_sens07 = bits, U08, 122, [0:0], "1", "2"
    knock_sens08 = bits, U08, 123, [0:0], "1", "2"
    knock_sens09 = bits, U08, 124, [0:0], "1", "2"
    knock_sens10 = bits, U08, 125, [0:0], "1", "2"
    knock_sens11 = bits, U08, 126, [0:0], "1", "2"
    knock_sens12 = bits, U08, 127, [0:0], "1", "2"
    knock_sens13 = bits, U08, 128, [0:0], "1", "2"
    knock_sens14 = bits, U08, 129, [0:0], "1", "2"
    knock_sens15 = bits, U08, 130, [0:0], "1", "2"
    knock_sens16 = bits, U08, 131, [0:0], "1", "2"
;These are here for code dev to turn features on/off
;      feature6_0    = bits,    U08,    84,      [0:0], "Off", "On"
;      feature6_1    = bits,    U08,    84,      [1:1], "Off", "On"
;      feature6_2    = bits,    U08,    84,      [2:2], "Off", "On"
;      feature6_3    = bits,    U08,    84,      [3:3], "Off", "On"
;      feature6_4    = bits,    U08,    84,      [4:4], "Off", "On"
;      feature6_5    = bits,    U08,    84,      [5:5], "Off", "On"
;      feature6_6    = bits,    U08,    84,      [6:6], "Off", "On"
;      feature6_7    = bits,    U08,    84,      [7:7], "Off", "On"

    s16_debug = scalar, S16, 132, "", 1, 0.00000, -32768, +32767, 0
    u08_debug134 = scalar, U08, 134, "", 1, 0.00000, 0, +255, 0
    AE_options = bits, U08, 135, [0:0], "Use standard AE", "Use new accel-pump AE"
    accel_blend_percent = scalar, S16, 136, "%", 0.1, 0.0, 0, 100, 1
    accel_tpsdot_threshold = scalar, U16, 138, "%/sec", 0.1, 0, 0, 1000, 0
    accel_mapdot_threshold = scalar, U16, 140, "kpa/sec", 1, 0, 0, 5000, 0
    accel_mapdots = array, S16, 142, [8], "kpa/sec", 1, 0, -5000, 5000, 0
    accel_tpsdots = array, S16, 158, [8], "%/sec", 0.1, 0, -3000, 3000, 1
    accel_mapdot_amts = array, S16,  174, [8], "%", 0.1, 0, -500, 500, 1
    accel_tpsdot_amts = array, S16, 190, [8], "%",  0.1, 0, -500, 500, 1
    accel_CLT_multiplier = scalar, S16, 206, "%", 0.1, 0, 0, 200, 1
    cl_idle_timing_target_deltas = array, S16, 208, [8], "rpm", 1, 0, -1000, 1000, 0
    cl_idle_timing_advance_deltas = array, S16, 224, [8], "deg", 0.1, 0, -90, 90, 0

    tc_minmap     = scalar, S16, 246, "%",  0.10000, 0.00000, 0, 100, 1
      can_bcast1_on    = bits,     U08,    248,           [0:0], "Off", "On"
      can_bcast1_280x4 = bits,     U08,    248,           [1:1], "Off", "On"
      can_bcast1_280x1 = bits,     U08,    248,           [2:2], "Off", "On"
      can_bcast1_289   = bits,     U08,    248,           [3:3], "Off", "On"
;      can_bcast2 249
      can_bcast_int    = scalar, U16, 250, "ms", 0.128, 0.00000, 50, 1000,1

    timedout1_in    = bits, U08, 252, [0:4], "Off", "Tableswitch", "PE0/JS7", "PE1", "JS10", "JS11", "JS5 (ADC6)", "JS4 (ADC7)", "Nitrous In", "Launch in", "Datalog In", "PT4 Spare in", "PT2 Cam in", "PE2 Flex", "INVALID", "INVALID", "CANIN1", "CANIN2", "CANIN3", "CANIN4", "CANIN5", "CANIN6", "CANIN7", "CANIN8", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID"
    timedout1_out   = bits, U08, 253, [0:5], "Off", "IAC1", "IAC2", "FIDLE", "D15", "Nitrous 1", "Nitrous 2", "Tacho", "Idle", "Boost", "VVT", "Inj Bank 1", "Inj Bank 2", "D14", "D16", "JS11", "Inj A", "Inj B", "Inj C", "Inj D", "Inj E", "Inj F", "Inj G", "Inj H", "PT4", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "CANPWM1", "CANPWM2", "CANPWM3", "CANPWM4", "CANPWM5", "CANPWM6", "CANPWM7", "CANPWM8", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID"
    timedout1_offdelay   = array, U16,    254,    [6], "s", 0.001, 0, 0, 15, 2
    tstop_out    = bits, U08, 256, [0:5], "Off", "IAC1", "IAC2", "FIDLE", "D15", "Nitrous 1", "Nitrous 2", "Tacho", "Idle", "Boost", "VVT", "Inj Bank 1", "Inj Bank 2", "D14", "D16", "JS11", "Inj A", "Inj B", "Inj C", "Inj D", "Inj E", "Inj F", "Inj G", "Inj H", "PT4", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "CANPWM1", "CANPWM2", "CANPWM3", "CANPWM4", "CANPWM5", "CANPWM6", "CANPWM7", "CANPWM8", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID"
; pad 257
    tstop_delay  = array, U16,    258,    [6], "s", 0.001, 0, 0, 15, 2
    tstop_hold   = array, U16,    260,    [6], "s", 0.001, 0, 0, 15, 2

; really big gap here
;                       ######   ###   #####          #####      #     ######   
;                       #     #   #   #     #        #     #    # #    #     #  
;                       #     #   #   #              #         #   #   #     #  
;                       ######    #   #  ####        #  ####  #     #  ######   
;                       #     #   #   #     #        #     #  #######  #        
;                       #     #   #   #     #        #     #  #     #  #        
;                       ######   ###   #####          #####   #     #  #        
;
; big pad
;bogus - can be moved
;    bogus_x = array, U08, 667, [1x1], "", 1,0,0,0,0
;    bogus_y = array, U08, 667, [1x1], "", 1,0,0,0,0

    flex_pct0  = scalar, U16, 658, "%", 0.1, 0.00000, 0, 100,1
    flex_pct1  = scalar, U16, 660, "%", 0.1, 0.00000, 0, 100,1

;misc sensors
    sensor01_source = bits,   U08,  662, [0:4], "Off", "JS5 (ADC6)", "JS4 (ADC7)", "EXT_MAP (ADC11)", "EGO2 (ADC12)", "Spare ADC (ADC13)", "INVALID", "INVALID", "CAN ADC01", "CAN ADC02", "CAN ADC03", "CAN ADC04", "CAN ADC05", "CAN ADC06", "CAN ADC07", "CAN ADC08", "CAN ADC09", "CAN ADC10", "CAN ADC11", "CAN ADC12", "CAN ADC13", "CAN ADC14", "CAN ADC15", "CAN ADC16", "CAN ADC17", "CAN ADC18", "CAN ADC19", "CAN ADC20", "CAN ADC21", "CAN ADC22", "CAN ADC23", "CAN ADC24"
    sensor02_source = bits,   U08,  663, [0:4], "Off", "JS5 (ADC6)", "JS4 (ADC7)", "EXT_MAP (ADC11)", "EGO2 (ADC12)", "Spare ADC (ADC13)", "INVALID", "INVALID", "CAN ADC01", "CAN ADC02", "CAN ADC03", "CAN ADC04", "CAN ADC05", "CAN ADC06", "CAN ADC07", "CAN ADC08", "CAN ADC09", "CAN ADC10", "CAN ADC11", "CAN ADC12", "CAN ADC13", "CAN ADC14", "CAN ADC15", "CAN ADC16", "CAN ADC17", "CAN ADC18", "CAN ADC19", "CAN ADC20", "CAN ADC21", "CAN ADC22", "CAN ADC23", "CAN ADC24"
    sensor03_source = bits,   U08,  664, [0:4], "Off", "JS5 (ADC6)", "JS4 (ADC7)", "EXT_MAP (ADC11)", "EGO2 (ADC12)", "Spare ADC (ADC13)", "INVALID", "INVALID", "CAN ADC01", "CAN ADC02", "CAN ADC03", "CAN ADC04", "CAN ADC05", "CAN ADC06", "CAN ADC07", "CAN ADC08", "CAN ADC09", "CAN ADC10", "CAN ADC11", "CAN ADC12", "CAN ADC13", "CAN ADC14", "CAN ADC15", "CAN ADC16", "CAN ADC17", "CAN ADC18", "CAN ADC19", "CAN ADC20", "CAN ADC21", "CAN ADC22", "CAN ADC23", "CAN ADC24"
    sensor04_source = bits,   U08,  665, [0:4], "Off", "JS5 (ADC6)", "JS4 (ADC7)", "EXT_MAP (ADC11)", "EGO2 (ADC12)", "Spare ADC (ADC13)", "INVALID", "INVALID", "CAN ADC01", "CAN ADC02", "CAN ADC03", "CAN ADC04", "CAN ADC05", "CAN ADC06", "CAN ADC07", "CAN ADC08", "CAN ADC09", "CAN ADC10", "CAN ADC11", "CAN ADC12", "CAN ADC13", "CAN ADC14", "CAN ADC15", "CAN ADC16", "CAN ADC17", "CAN ADC18", "CAN ADC19", "CAN ADC20", "CAN ADC21", "CAN ADC22", "CAN ADC23", "CAN ADC24"
    sensor05_source = bits,   U08,  666, [0:4], "Off", "JS5 (ADC6)", "JS4 (ADC7)", "EXT_MAP (ADC11)", "EGO2 (ADC12)", "Spare ADC (ADC13)", "INVALID", "INVALID", "CAN ADC01", "CAN ADC02", "CAN ADC03", "CAN ADC04", "CAN ADC05", "CAN ADC06", "CAN ADC07", "CAN ADC08", "CAN ADC09", "CAN ADC10", "CAN ADC11", "CAN ADC12", "CAN ADC13", "CAN ADC14", "CAN ADC15", "CAN ADC16", "CAN ADC17", "CAN ADC18", "CAN ADC19", "CAN ADC20", "CAN ADC21", "CAN ADC22", "CAN ADC23", "CAN ADC24"
    sensor06_source = bits,   U08,  667, [0:4], "Off", "JS5 (ADC6)", "JS4 (ADC7)", "EXT_MAP (ADC11)", "EGO2 (ADC12)", "Spare ADC (ADC13)", "INVALID", "INVALID", "CAN ADC01", "CAN ADC02", "CAN ADC03", "CAN ADC04", "CAN ADC05", "CAN ADC06", "CAN ADC07", "CAN ADC08", "CAN ADC09", "CAN ADC10", "CAN ADC11", "CAN ADC12", "CAN ADC13", "CAN ADC14", "CAN ADC15", "CAN ADC16", "CAN ADC17", "CAN ADC18", "CAN ADC19", "CAN ADC20", "CAN ADC21", "CAN ADC22", "CAN ADC23", "CAN ADC24"
    sensor07_source = bits,   U08,  668, [0:4], "Off", "JS5 (ADC6)", "JS4 (ADC7)", "EXT_MAP (ADC11)", "EGO2 (ADC12)", "Spare ADC (ADC13)", "INVALID", "INVALID", "CAN ADC01", "CAN ADC02", "CAN ADC03", "CAN ADC04", "CAN ADC05", "CAN ADC06", "CAN ADC07", "CAN ADC08", "CAN ADC09", "CAN ADC10", "CAN ADC11", "CAN ADC12", "CAN ADC13", "CAN ADC14", "CAN ADC15", "CAN ADC16", "CAN ADC17", "CAN ADC18", "CAN ADC19", "CAN ADC20", "CAN ADC21", "CAN ADC22", "CAN ADC23", "CAN ADC24"
    sensor08_source = bits,   U08,  669, [0:4], "Off", "JS5 (ADC6)", "JS4 (ADC7)", "EXT_MAP (ADC11)", "EGO2 (ADC12)", "Spare ADC (ADC13)", "INVALID", "INVALID", "CAN ADC01", "CAN ADC02", "CAN ADC03", "CAN ADC04", "CAN ADC05", "CAN ADC06", "CAN ADC07", "CAN ADC08", "CAN ADC09", "CAN ADC10", "CAN ADC11", "CAN ADC12", "CAN ADC13", "CAN ADC14", "CAN ADC15", "CAN ADC16", "CAN ADC17", "CAN ADC18", "CAN ADC19", "CAN ADC20", "CAN ADC21", "CAN ADC22", "CAN ADC23", "CAN ADC24"
    sensor09_source = bits,   U08,  670, [0:4], "Off", "JS5 (ADC6)", "JS4 (ADC7)", "EXT_MAP (ADC11)", "EGO2 (ADC12)", "Spare ADC (ADC13)", "INVALID", "INVALID", "CAN ADC01", "CAN ADC02", "CAN ADC03", "CAN ADC04", "CAN ADC05", "CAN ADC06", "CAN ADC07", "CAN ADC08", "CAN ADC09", "CAN ADC10", "CAN ADC11", "CAN ADC12", "CAN ADC13", "CAN ADC14", "CAN ADC15", "CAN ADC16", "CAN ADC17", "CAN ADC18", "CAN ADC19", "CAN ADC20", "CAN ADC21", "CAN ADC22", "CAN ADC23", "CAN ADC24"
    sensor10_source = bits,   U08,  671, [0:4], "Off", "JS5 (ADC6)", "JS4 (ADC7)", "EXT_MAP (ADC11)", "EGO2 (ADC12)", "Spare ADC (ADC13)", "INVALID", "INVALID", "CAN ADC01", "CAN ADC02", "CAN ADC03", "CAN ADC04", "CAN ADC05", "CAN ADC06", "CAN ADC07", "CAN ADC08", "CAN ADC09", "CAN ADC10", "CAN ADC11", "CAN ADC12", "CAN ADC13", "CAN ADC14", "CAN ADC15", "CAN ADC16", "CAN ADC17", "CAN ADC18", "CAN ADC19", "CAN ADC20", "CAN ADC21", "CAN ADC22", "CAN ADC23", "CAN ADC24"
    sensor11_source = bits,   U08,  672, [0:4], "Off", "JS5 (ADC6)", "JS4 (ADC7)", "EXT_MAP (ADC11)", "EGO2 (ADC12)", "Spare ADC (ADC13)", "INVALID", "INVALID", "CAN ADC01", "CAN ADC02", "CAN ADC03", "CAN ADC04", "CAN ADC05", "CAN ADC06", "CAN ADC07", "CAN ADC08", "CAN ADC09", "CAN ADC10", "CAN ADC11", "CAN ADC12", "CAN ADC13", "CAN ADC14", "CAN ADC15", "CAN ADC16", "CAN ADC17", "CAN ADC18", "CAN ADC19", "CAN ADC20", "CAN ADC21", "CAN ADC22", "CAN ADC23", "CAN ADC24"
    sensor12_source = bits,   U08,  673, [0:4], "Off", "JS5 (ADC6)", "JS4 (ADC7)", "EXT_MAP (ADC11)", "EGO2 (ADC12)", "Spare ADC (ADC13)", "INVALID", "INVALID", "CAN ADC01", "CAN ADC02", "CAN ADC03", "CAN ADC04", "CAN ADC05", "CAN ADC06", "CAN ADC07", "CAN ADC08", "CAN ADC09", "CAN ADC10", "CAN ADC11", "CAN ADC12", "CAN ADC13", "CAN ADC14", "CAN ADC15", "CAN ADC16", "CAN ADC17", "CAN ADC18", "CAN ADC19", "CAN ADC20", "CAN ADC21", "CAN ADC22", "CAN ADC23", "CAN ADC24"
    sensor13_source = bits,   U08,  674, [0:4], "Off", "JS5 (ADC6)", "JS4 (ADC7)", "EXT_MAP (ADC11)", "EGO2 (ADC12)", "Spare ADC (ADC13)", "INVALID", "INVALID", "CAN ADC01", "CAN ADC02", "CAN ADC03", "CAN ADC04", "CAN ADC05", "CAN ADC06", "CAN ADC07", "CAN ADC08", "CAN ADC09", "CAN ADC10", "CAN ADC11", "CAN ADC12", "CAN ADC13", "CAN ADC14", "CAN ADC15", "CAN ADC16", "CAN ADC17", "CAN ADC18", "CAN ADC19", "CAN ADC20", "CAN ADC21", "CAN ADC22", "CAN ADC23", "CAN ADC24"
    sensor14_source = bits,   U08,  675, [0:4], "Off", "JS5 (ADC6)", "JS4 (ADC7)", "EXT_MAP (ADC11)", "EGO2 (ADC12)", "Spare ADC (ADC13)", "INVALID", "INVALID", "CAN ADC01", "CAN ADC02", "CAN ADC03", "CAN ADC04", "CAN ADC05", "CAN ADC06", "CAN ADC07", "CAN ADC08", "CAN ADC09", "CAN ADC10", "CAN ADC11", "CAN ADC12", "CAN ADC13", "CAN ADC14", "CAN ADC15", "CAN ADC16", "CAN ADC17", "CAN ADC18", "CAN ADC19", "CAN ADC20", "CAN ADC21", "CAN ADC22", "CAN ADC23", "CAN ADC24"
    sensor15_source = bits,   U08,  676, [0:4], "Off", "JS5 (ADC6)", "JS4 (ADC7)", "EXT_MAP (ADC11)", "EGO2 (ADC12)", "Spare ADC (ADC13)", "INVALID", "INVALID", "CAN ADC01", "CAN ADC02", "CAN ADC03", "CAN ADC04", "CAN ADC05", "CAN ADC06", "CAN ADC07", "CAN ADC08", "CAN ADC09", "CAN ADC10", "CAN ADC11", "CAN ADC12", "CAN ADC13", "CAN ADC14", "CAN ADC15", "CAN ADC16", "CAN ADC17", "CAN ADC18", "CAN ADC19", "CAN ADC20", "CAN ADC21", "CAN ADC22", "CAN ADC23", "CAN ADC24"
    sensor16_source = bits,   U08,  677, [0:4], "Off", "JS5 (ADC6)", "JS4 (ADC7)", "EXT_MAP (ADC11)", "EGO2 (ADC12)", "Spare ADC (ADC13)", "INVALID", "INVALID", "CAN ADC01", "CAN ADC02", "CAN ADC03", "CAN ADC04", "CAN ADC05", "CAN ADC06", "CAN ADC07", "CAN ADC08", "CAN ADC09", "CAN ADC10", "CAN ADC11", "CAN ADC12", "CAN ADC13", "CAN ADC14", "CAN ADC15", "CAN ADC16", "CAN ADC17", "CAN ADC18", "CAN ADC19", "CAN ADC20", "CAN ADC21", "CAN ADC22", "CAN ADC23", "CAN ADC24"
    sensor01_trans  = bits,   U08,  678, [0:2], "Raw", "Linear", "Same as MAP", "Same as CLT", "Same as MAT", "Same as EGO", "Same as MAF", "GM calibration"
    sensor02_trans  = bits,   U08,  679, [0:2], "Raw", "Linear", "Same as MAP", "Same as CLT", "Same as MAT", "Same as EGO", "Same as MAF", "GM calibration"
    sensor03_trans  = bits,   U08,  680, [0:2], "Raw", "Linear", "Same as MAP", "Same as CLT", "Same as MAT", "Same as EGO", "Same as MAF", "GM calibration"
    sensor04_trans  = bits,   U08,  681, [0:2], "Raw", "Linear", "Same as MAP", "Same as CLT", "Same as MAT", "Same as EGO", "Same as MAF", "GM calibration"
    sensor05_trans  = bits,   U08,  682, [0:2], "Raw", "Linear", "Same as MAP", "Same as CLT", "Same as MAT", "Same as EGO", "Same as MAF", "GM calibration"
    sensor06_trans  = bits,   U08,  683, [0:2], "Raw", "Linear", "Same as MAP", "Same as CLT", "Same as MAT", "Same as EGO", "Same as MAF", "GM calibration"
    sensor07_trans  = bits,   U08,  684, [0:2], "Raw", "Linear", "Same as MAP", "Same as CLT", "Same as MAT", "Same as EGO", "Same as MAF", "GM calibration"
    sensor08_trans  = bits,   U08,  685, [0:2], "Raw", "Linear", "Same as MAP", "Same as CLT", "Same as MAT", "Same as EGO", "Same as MAF", "GM calibration"
    sensor09_trans  = bits,   U08,  686, [0:2], "Raw", "Linear", "Same as MAP", "Same as CLT", "Same as MAT", "Same as EGO", "Same as MAF", "GM calibration"
    sensor10_trans  = bits,   U08,  687, [0:2], "Raw", "Linear", "Same as MAP", "Same as CLT", "Same as MAT", "Same as EGO", "Same as MAF", "GM calibration"
    sensor11_trans  = bits,   U08,  688, [0:2], "Raw", "Linear", "Same as MAP", "Same as CLT", "Same as MAT", "Same as EGO", "Same as MAF", "GM calibration"
    sensor12_trans  = bits,   U08,  689, [0:2], "Raw", "Linear", "Same as MAP", "Same as CLT", "Same as MAT", "Same as EGO", "Same as MAF", "GM calibration"
    sensor13_trans  = bits,   U08,  690, [0:2], "Raw", "Linear", "Same as MAP", "Same as CLT", "Same as MAT", "Same as EGO", "Same as MAF", "GM calibration"
    sensor14_trans  = bits,   U08,  691, [0:2], "Raw", "Linear", "Same as MAP", "Same as CLT", "Same as MAT", "Same as EGO", "Same as MAF", "GM calibration"
    sensor15_trans  = bits,   U08,  692, [0:2], "Raw", "Linear", "Same as MAP", "Same as CLT", "Same as MAT", "Same as EGO", "Same as MAF", "GM calibration"
    sensor16_trans  = bits,   U08,  693, [0:2], "Raw", "Linear", "Same as MAP", "Same as CLT", "Same as MAT", "Same as EGO", "Same as MAF", "GM calibration"
    sensor01_val0   = scalar, S16,  694,             "",      0.10000,   0.00000, -3276.7, 3276.7,      1 ; * (  2 bytes)
    sensor02_val0   = scalar, S16,  696,             "",      0.10000,   0.00000, -3276.7, 3276.7,      1 ; * (  2 bytes)
    sensor03_val0   = scalar, S16,  698,             "",      0.10000,   0.00000, -3276.7, 3276.7,      1 ; * (  2 bytes)
    sensor04_val0   = scalar, S16,  700,             "",      0.10000,   0.00000, -3276.7, 3276.7,      1 ; * (  2 bytes)
    sensor05_val0   = scalar, S16,  702,             "",      0.10000,   0.00000, -3276.7, 3276.7,      1 ; * (  2 bytes)
    sensor06_val0   = scalar, S16,  704,             "",      0.10000,   0.00000, -3276.7, 3276.7,      1 ; * (  2 bytes)
    sensor07_val0   = scalar, S16,  706,             "",      0.10000,   0.00000, -3276.7, 3276.7,      1 ; * (  2 bytes)
    sensor08_val0   = scalar, S16,  708,             "",      0.10000,   0.00000, -3276.7, 3276.7,      1 ; * (  2 bytes)
    sensor09_val0   = scalar, S16,  710,             "",      0.10000,   0.00000, -3276.7, 3276.7,      1 ; * (  2 bytes)
    sensor10_val0   = scalar, S16,  712,             "",      0.10000,   0.00000, -3276.7, 3276.7,      1 ; * (  2 bytes)
    sensor11_val0   = scalar, S16,  714,             "",      0.10000,   0.00000, -3276.7, 3276.7,      1 ; * (  2 bytes)

    sensor12_val0   = scalar, S16,  716,             "",      0.10000,   0.00000, -3276.7, 3276.7,      1 ; * (  2 bytes)
    sensor13_val0   = scalar, S16,  718,             "",      0.10000,   0.00000, -3276.7, 3276.7,      1 ; * (  2 bytes)
    sensor14_val0   = scalar, S16,  720,             "",      0.10000,   0.00000, -3276.7, 3276.7,      1 ; * (  2 bytes)
    sensor15_val0   = scalar, S16,  722,             "",      0.10000,   0.00000, -3276.7, 3276.7,      1 ; * (  2 bytes)
    sensor16_val0   = scalar, S16,  724,             "",      0.10000,   0.00000, -3276.7, 3276.7,      1 ; * (  2 bytes)
    sensor01_max    = scalar, S16,  726,             "",      0.10000,   0.00000, -3276.7, 3276.7,      1 ; * (  2 bytes)
    sensor02_max    = scalar, S16,  728,             "",      0.10000,   0.00000, -3276.7, 3276.7,      1 ; * (  2 bytes)
    sensor03_max    = scalar, S16,  730,             "",      0.10000,   0.00000, -3276.7, 3276.7,      1 ; * (  2 bytes)
    sensor04_max    = scalar, S16,  732,             "",      0.10000,   0.00000, -3276.7, 3276.7,      1 ; * (  2 bytes)
    sensor05_max    = scalar, S16,  734,             "",      0.10000,   0.00000, -3276.7, 3276.7,      1 ; * (  2 bytes)
    sensor06_max    = scalar, S16,  736,             "",      0.10000,   0.00000, -3276.7, 3276.7,      1 ; * (  2 bytes)
    sensor07_max    = scalar, S16,  738,             "",      0.10000,   0.00000, -3276.7, 3276.7,      1 ; * (  2 bytes)
    sensor08_max    = scalar, S16,  740,             "",      0.10000,   0.00000, -3276.7, 3276.7,      1 ; * (  2 bytes)
    sensor09_max    = scalar, S16,  742,             "",      0.10000,   0.00000, -3276.7, 3276.7,      1 ; * (  2 bytes)
    sensor10_max    = scalar, S16,  744,             "",      0.10000,   0.00000, -3276.7, 3276.7,      1 ; * (  2 bytes)
    sensor11_max    = scalar, S16,  746,             "",      0.10000,   0.00000, -3276.7, 3276.7,      1 ; * (  2 bytes)
    sensor12_max    = scalar, S16,  748,             "",      0.10000,   0.00000, -3276.7, 3276.7,      1 ; * (  2 bytes)
    sensor13_max    = scalar, S16,  750,             "",      0.10000,   0.00000, -3276.7, 3276.7,      1 ; * (  2 bytes)
    sensor14_max    = scalar, S16,  752,             "",      0.10000,   0.00000, -3276.7, 3276.7,      1 ; * (  2 bytes)
    sensor15_max    = scalar, S16,  754,             "",      0.10000,   0.00000, -3276.7, 3276.7,      1 ; * (  2 bytes)
    sensor16_max    = scalar, S16,  756,             "",      0.10000,   0.00000, -3276.7, 3276.7,      1 ; * (  2 bytes)
    sensor01LF      = scalar, U08,  758, "", 1,0,10,100,0
    sensor02LF      = scalar, U08,  759, "", 1,0,10,100,0
    sensor03LF      = scalar, U08,  760, "", 1,0,10,100,0
    sensor04LF      = scalar, U08,  761, "", 1,0,10,100,0
    sensor05LF      = scalar, U08,  762, "", 1,0,10,100,0
    sensor06LF      = scalar, U08,  763, "", 1,0,10,100,0
    sensor07LF      = scalar, U08,  764, "", 1,0,10,100,0
    sensor08LF      = scalar, U08,  765, "", 1,0,10,100,0
    sensor09LF      = scalar, U08,  766, "", 1,0,10,100,0
    sensor10LF      = scalar, U08,  767, "", 1,0,10,100,0
    sensor11LF      = scalar, U08,  768, "", 1,0,10,100,0
    sensor12LF      = scalar, U08,  769, "", 1,0,10,100,0
    sensor13LF      = scalar, U08,  770, "", 1,0,10,100,0
    sensor14LF      = scalar, U08,  771, "", 1,0,10,100,0
    sensor15LF      = scalar, U08,  772, "", 1,0,10,100,0
    sensor16LF      = scalar, U08,  773, "", 1,0,10,100,0
    sensor_temp     = bits, U08,  774, [0:0], "degF", "degC" 
;pad
#if PW_4X
    injOpen1         = scalar,  U16,    776,             "ms",       0.004,   0.00000,  0.00,   25.50,      3 ; * (  1 byte)
    injOpen2         = scalar,  U16,    778,             "ms",       0.004,   0.00000,  0.00,   25.50,      3 ; * (  1 byte)
    injOpen3         = scalar,  U16,    780,             "ms",       0.004,   0.00000,  0.00,   25.50,      3 ; * (  1 byte)
    injOpen4         = scalar,  U16,    782,             "ms",       0.004,   0.00000,  0.00,   25.50,      3 ; * (  1 byte)
    injOpen5         = scalar,  U16,    784,             "ms",       0.004,   0.00000,  0.00,   25.50,      3 ; * (  1 byte)
    injOpen6         = scalar,  U16,    786,             "ms",       0.004,   0.00000,  0.00,   25.50,      3 ; * (  1 byte)
    injOpen7         = scalar,  U16,    788,             "ms",       0.004,   0.00000,  0.00,   25.50,      3 ; * (  1 byte)

    injOpen8         = scalar,  U16,    790,             "ms",       0.004,   0.00000,  0.00,   25.50,      3 ; * (  1 byte)
    injOpena         = scalar,  U16,    792,             "ms",       0.004,   0.00000,  0.00,   25.50,      3 ; * (  1 byte)
    injOpenb         = scalar,  U16,    794,             "ms",       0.004,   0.00000,  0.00,   25.50,      3 ; * (  1 byte)
;next 8 not yet used
    injOpen11         = scalar,  U16,    796,             "ms",       0.004,   0.00000,  0.00,   25.50,      3
    injOpen12         = scalar,  U16,    798,             "ms",       0.004,   0.00000,  0.00,   25.50,      3
    injOpen13         = scalar,  U16,    800,             "ms",       0.004,   0.00000,  0.00,   25.50,      3
    injOpen14         = scalar,  U16,    802,             "ms",       0.004,   0.00000,  0.00,   25.50,      3


    injOpen15         = scalar,  U16,    804,             "ms",       0.004,   0.00000,  0.00,   25.50,      3
    injOpen16         = scalar,  U16,    806,             "ms",       0.004,   0.00000,  0.00,   25.50,      3
    injOpen17         = scalar,  U16,    808,             "ms",       0.004,   0.00000,  0.00,   25.50,      3
    injOpen18         = scalar,  U16,    810,             "ms",       0.004,   0.00000,  0.00,   25.50,      3
#else
    injOpen1         = scalar,  U16,    776,             "ms",       0.001,   0.00000,  0.00,   25.50,      3 ; * (  1 byte)
    injOpen2         = scalar,  U16,    778,             "ms",       0.001,   0.00000,  0.00,   25.50,      3 ; * (  1 byte)
    injOpen3         = scalar,  U16,    780,             "ms",       0.001,   0.00000,  0.00,   25.50,      3 ; * (  1 byte)
    injOpen4         = scalar,  U16,    782,             "ms",       0.001,   0.00000,  0.00,   25.50,      3 ; * (  1 byte)
    injOpen5         = scalar,  U16,    784,             "ms",       0.001,   0.00000,  0.00,   25.50,      3 ; * (  1 byte)
    injOpen6         = scalar,  U16,    786,             "ms",       0.001,   0.00000,  0.00,   25.50,      3 ; * (  1 byte)
    injOpen7         = scalar,  U16,    788,             "ms",       0.001,   0.00000,  0.00,   25.50,      3 ; * (  1 byte)
    injOpen8         = scalar,  U16,    790,             "ms",       0.001,   0.00000,  0.00,   25.50,      3 ; * (  1 byte)
    injOpena         = scalar,  U16,    792,             "ms",       0.001,   0.00000,  0.00,   25.50,      3 ; * (  1 byte)
    injOpenb         = scalar,  U16,    794,             "ms",       0.001,   0.00000,  0.00,   25.50,      3 ; * (  1 byte)
;next 8 not yet used
    injOpen11         = scalar,  U16,    796,             "ms",       0.001,   0.00000,  0.00,   25.50,      3
    injOpen12         = scalar,  U16,    798,             "ms",       0.001,   0.00000,  0.00,   25.50,      3
    injOpen13         = scalar,  U16,    800,             "ms",       0.001,   0.00000,  0.00,   25.50,      3
    injOpen14         = scalar,  U16,    802,             "ms",       0.001,   0.00000,  0.00,   25.50,      3
    injOpen15         = scalar,  U16,    804,             "ms",       0.001,   0.00000,  0.00,   25.50,      3
    injOpen16         = scalar,  U16,    806,             "ms",       0.001,   0.00000,  0.00,   25.50,      3
    injOpen17         = scalar,  U16,    808,             "ms",       0.001,   0.00000,  0.00,   25.50,      3
    injOpen18         = scalar,  U16,    810,             "ms",       0.001,   0.00000,  0.00,   25.50,      3
#endif

    shift_cut_on    = bits, U08, 812, [0:0], "Off", "On"
    shift_cut_auto  = bits, U08, 812, [1:1], "Button", "Auto"
    shift_cut_gear  = bits, U08, 812, [2:2], "Off", "On"
    shift_cut_in    = bits, U08, 813, [0:4], "INVALID", "Tableswitch", "PE0/JS7", "PE1", "JS10", "JS11", "JS5 (ADC6)", "JS4 (ADC7)", "Nitrous In", "Launch in", "Datalog In", "PT4 Spare in", "PT2 Cam in", "PE2 Flex", "INVALID", "INVALID", "CANIN1", "CANIN2", "CANIN3", "CANIN4", "CANIN5", "CANIN6", "CANIN7", "CANIN8", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID"
    shift_cut_out   = bits, U08, 814,[0:4], "INVALID", "IAC1", "IAC2", "FIDLE", "D15", "Nitrous 1", "Nitrous 2", "Tacho", "Idle", "Boost", "VVT", "Inj Bank 1", "Inj Bank 2", "D14", "D16", "JS11", "Inj A", "Inj B", "Inj C", "Inj D", "Inj E", "Inj F", "Inj G", "Inj H", "PT4", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID"
    shift_cut_rpm    = scalar, U16, 815, "RPM", 1, 0, 0, {rpmhigh}, 0
    shift_cut_tps    = scalar, U16, 817, "%", 0.1, 0, 0, 100, 0
    shift_cut_delay  = scalar, U08, 819, "s", 0.01, 0, 0, 2.55, 2
    shift_cut_time   = scalar, U08, 820, "s", 0.01, 0, 0, 2.55, 2
    shift_cut_add12  = scalar, U08, 821, "s", 0.01, 0, 0, 2.55, 2
    shift_cut_add23  = scalar, U08, 822, "s", 0.01, 0, 0, 2.55, 2
    shift_cut_add34  = scalar, U08, 823, "s", 0.01, 0, 0, 2.55, 2
    shift_cut_add45  = scalar, U08, 824, "s", 0.01, 0, 0, 2.55, 2
    shift_cut_add56  = scalar, U08, 825, "s", 0.01, 0, 0, 2.55, 2
    shift_cut_soldelay=scalar, U08, 826, "s", 0.01, 0, 0, 2.55, 2
    shift_cut_rpm12  = scalar, U16, 827, "RPM", 1, 0, 0, {rpmhigh}, 0
    shift_cut_rpm23  = scalar, U16, 829, "RPM", 1, 0, 0, {rpmhigh}, 0
    shift_cut_rpm34  = scalar, U16, 831, "RPM", 1, 0, 0, {rpmhigh}, 0
    shift_cut_rpm45  = scalar, U16, 833, "RPM", 1, 0, 0, {rpmhigh}, 0
    shift_cut_rpm56  = scalar, U16, 835, "RPM", 1, 0, 0, {rpmhigh}, 0
    shift_cut_reshift= scalar, U08, 837, "s", 0.01, 0, 0, 2.55, 2
;open-loop PWM. all arrays
    pwm_opt_on_a      = bits, U08, 838, [0:0], "Off", "On"
    pwm_opt_var_a     = bits, U08, 838, [1:1], "On-Off", "Variable"
    pwm_opt_freq_a    = bits, U08, 838, [2:4], "INVALID", "78Hz", "39Hz", "26Hz", "19.5Hz", "15.6Hz", "13Hz", "11.1Hz"
    pwm_opt_load_a    = bits, U08, 838, [5:7], "INVALID", "MAP", "% baro", "TPS", "MAFMAP", "CLT", "INVALID", "MAT" ; ITB hidden
    pwm_opt_on_b      = bits, U08, 839, [0:0], "Off", "On"
    pwm_opt_var_b     = bits, U08, 839, [1:1], "On-Off", "Variable"
    pwm_opt_freq_b    = bits, U08, 839, [2:4], "INVALID", "78Hz", "39Hz", "26Hz", "19.5Hz", "15.6Hz", "13Hz", "11.1Hz"
    pwm_opt_load_b    = bits, U08, 839, [5:7], "INVALID", "MAP", "% baro", "TPS", "MAFMAP", "CLT", "INVALID", "MAT"
    pwm_opt_on_c      = bits, U08, 840, [0:0], "Off", "On"
    pwm_opt_var_c     = bits, U08, 840, [1:1], "On-Off", "Variable"
    pwm_opt_freq_c    = bits, U08, 840, [2:4], "INVALID", "78Hz", "39Hz", "26Hz", "19.5Hz", "15.6Hz", "13Hz", "11.1Hz"
    pwm_opt_load_c    = bits, U08, 840, [5:7], "INVALID", "MAP", "% baro", "TPS", "MAFMAP", "CLT", "INVALID", "MAT"
    pwm_opt_on_d      = bits, U08, 841, [0:0], "Off", "On"
    pwm_opt_var_d     = bits, U08, 841, [1:1], "On-Off", "Variable"
    pwm_opt_freq_d    = bits, U08, 841, [2:4], "INVALID", "78Hz", "39Hz", "26Hz", "19.5Hz", "15.6Hz", "13Hz", "11.1Hz"
    pwm_opt_load_d    = bits, U08, 841, [5:7], "INVALID", "MAP", "% baro", "TPS", "MAFMAP", "CLT", "INVALID", "MAT"
    pwm_opt_on_e      = bits, U08, 842, [0:0], "Off", "On"
    pwm_opt_var_e     = bits, U08, 842, [1:1], "On-Off", "Variable"
    pwm_opt_freq_e    = bits, U08, 842, [2:4], "INVALID", "78Hz", "39Hz", "26Hz", "19.5Hz", "15.6Hz", "13Hz", "11.1Hz"
    pwm_opt_load_e    = bits, U08, 842, [5:7], "INVALID", "MAP", "% baro", "TPS", "MAFMAP", "CLT", "INVALID", "MAT"
    pwm_opt_on_f      = bits, U08, 843, [0:0], "Off", "On"
    pwm_opt_var_f     = bits, U08, 843, [1:1], "On-Off", "Variable"
    pwm_opt_freq_f    = bits, U08, 843, [2:4], "INVALID", "78Hz", "39Hz", "26Hz", "19.5Hz", "15.6Hz", "13Hz", "11.1Hz"
    pwm_opt_load_f    = bits, U08, 843, [5:7], "INVALID", "MAP", "% baro", "TPS", "MAFMAP", "CLT", "INVALID", "MAT"

    pwm_opt2_a        = bits, U08, 844, [0:5], "INVALID", "IAC1", "IAC2", "FIDLE", "D15", "Nitrous 1", "Nitrous 2", "Tacho", "Idle", "Boost", "VVT", "Inj Bank 1", "Inj Bank 2", "D14", "D16", "JS11", "Inj A", "Inj B", "Inj C", "Inj D", "Inj E", "Inj F", "Inj G", "Inj H", "PT4", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "CANPWM1", "CANPWM2", "CANPWM3", "CANPWM4", "CANPWM5", "CANPWM6", "CANPWM7", "CANPWM8", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID"
    pwm_opt2_b        = bits, U08, 845, [0:5], "INVALID", "IAC1", "IAC2", "FIDLE", "D15", "Nitrous 1", "Nitrous 2", "Tacho", "Idle", "Boost", "VVT", "Inj Bank 1", "Inj Bank 2", "D14", "D16", "JS11", "Inj A", "Inj B", "Inj C", "Inj D", "Inj E", "Inj F", "Inj G", "Inj H", "PT4", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "CANPWM1", "CANPWM2", "CANPWM3", "CANPWM4", "CANPWM5", "CANPWM6", "CANPWM7", "CANPWM8", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID"
    pwm_opt2_c        = bits, U08, 846, [0:5], "INVALID", "IAC1", "IAC2", "FIDLE", "D15", "Nitrous 1", "Nitrous 2", "Tacho", "Idle", "Boost", "VVT", "Inj Bank 1", "Inj Bank 2", "D14", "D16", "JS11", "Inj A", "Inj B", "Inj C", "Inj D", "Inj E", "Inj F", "Inj G", "Inj H", "PT4", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "CANPWM1", "CANPWM2", "CANPWM3", "CANPWM4", "CANPWM5", "CANPWM6", "CANPWM7", "CANPWM8", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID"
    pwm_opt2_d        = bits, U08, 847, [0:5], "INVALID", "IAC1", "IAC2", "FIDLE", "D15", "Nitrous 1", "Nitrous 2", "Tacho", "Idle", "Boost", "VVT", "Inj Bank 1", "Inj Bank 2", "D14", "D16", "JS11", "Inj A", "Inj B", "Inj C", "Inj D", "Inj E", "Inj F", "Inj G", "Inj H", "PT4", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "CANPWM1", "CANPWM2", "CANPWM3", "CANPWM4", "CANPWM5", "CANPWM6", "CANPWM7", "CANPWM8", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID"
    pwm_opt2_e        = bits, U08, 848, [0:5], "INVALID", "IAC1", "IAC2", "FIDLE", "D15", "Nitrous 1", "Nitrous 2", "Tacho", "Idle", "Boost", "VVT", "Inj Bank 1", "Inj Bank 2", "D14", "D16", "JS11", "Inj A", "Inj B", "Inj C", "Inj D", "Inj E", "Inj F", "Inj G", "Inj H", "PT4", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "CANPWM1", "CANPWM2", "CANPWM3", "CANPWM4", "CANPWM5", "CANPWM6", "CANPWM7", "CANPWM8", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID"
    pwm_opt2_f        = bits, U08, 849, [0:5], "INVALID", "IAC1", "IAC2", "FIDLE", "D15", "Nitrous 1", "Nitrous 2", "Tacho", "Idle", "Boost", "VVT", "Inj Bank 1", "Inj Bank 2", "D14", "D16", "JS11", "Inj A", "Inj B", "Inj C", "Inj D", "Inj E", "Inj F", "Inj G", "Inj H", "PT4", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "CANPWM1", "CANPWM2", "CANPWM3", "CANPWM4", "CANPWM5", "CANPWM6", "CANPWM7", "CANPWM8", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID"
    pwm_onabove_a     = scalar, U08, 850, "%", 1, 0, 0, 100, 0
    pwm_onabove_b     = scalar, U08, 851, "%", 1, 0, 0, 100, 0
    pwm_onabove_c     = scalar, U08, 852, "%", 1, 0, 0, 100, 0
    pwm_onabove_d     = scalar, U08, 853, "%", 1, 0, 0, 100, 0
    pwm_onabove_e     = scalar, U08, 854, "%", 1, 0, 0, 100, 0
    pwm_onabove_f     = scalar, U08, 855, "%", 1, 0, 0, 100, 0
    pwm_offbelow_a    = scalar, U08, 856, "%", 1, 0, 0, 100, 0
    pwm_offbelow_b    = scalar, U08, 857, "%", 1, 0, 0, 100, 0
    pwm_offbelow_c    = scalar, U08, 858, "%", 1, 0, 0, 100, 0
    pwm_offbelow_d    = scalar, U08, 859, "%", 1, 0, 0, 100, 0
    pwm_offbelow_e    = scalar, U08, 860, "%", 1, 0, 0, 100, 0
    pwm_offbelow_f    = scalar, U08, 861, "%", 1, 0, 0, 100, 0

    dualfuel_sw_on = bits,  U08, 862, [0:0], "Off", "On"
    dualfuel_sw_fuel = bits,U08, 862, [1:1], "Off", "On"
    dualfuel_sw_spk = bits, U08, 862, [2:2], "Off", "On"
    dualfuel_sw_afr = bits, U08, 862, [3:3], "Off", "On"
    dualfuel_sw_rf = bits,  U08, 862, [4:4], "Off", "On"
    dualfuel_sw_stoich=bits,U08, 862, [5:5], "Off", "On"
    dualfuel_sw_wue = bits, U08, 862, [6:6], "Off", "On"
    dualfuel_sw_ase = bits, U08, 862, [7:7], "Off", "On"
    dualfuel_sw2_prime=bits,U08, 863, [0:0], "Off", "On"
    dualfuel_sw2_crank=bits,U08, 863, [1:1], "Off", "On"
    dualfuel_sw2_injp =bits,U08, 863, [2:2], "Off", "On"
    dualfuel_sw2_smpw =bits,U08, 863, [3:3], "Off", "On"
    dualfuel_sw2_ob =bits  ,U08, 863, [4:4], "Off", "On"
    dualfuel_sw2_boosw=bits,U08, 863, [5:5], "Off", "On"
    opentime2_opt1_master = bits, U08, 864, [7:7], "Same", "Individual"
    opentime2_opt1    = bits, U08, 864, [0:1], "Curve 1", "Curve 2", "Curve 3", "Curve 4"
    opentime2_opt2    = bits, U08, 865, [0:1], "Curve 1", "Curve 2", "Curve 3", "Curve 4"
    opentime2_opt3    = bits, U08, 866, [0:1], "Curve 1", "Curve 2", "Curve 3", "Curve 4"
    opentime2_opt4    = bits, U08, 867, [0:1], "Curve 1", "Curve 2", "Curve 3", "Curve 4"
    opentime2_opt5    = bits, U08, 868, [0:1], "Curve 1", "Curve 2", "Curve 3", "Curve 4"
    opentime2_opt6    = bits, U08, 869, [0:1], "Curve 1", "Curve 2", "Curve 3", "Curve 4"
    opentime2_opt7    = bits, U08, 870, [0:1], "Curve 1", "Curve 2", "Curve 3", "Curve 4"
    opentime2_opt8    = bits, U08, 871, [0:1], "Curve 1", "Curve 2", "Curve 3", "Curve 4"
    opentime2_opta    = bits, U08, 872, [0:1], "Curve 1", "Curve 2", "Curve 3", "Curve 4"
    opentime2_opta_pwm= bits, U08, 872, [4:4], "Off", "On"
    opentime2_optb    = bits, U08, 873, [0:1], "Curve 1", "Curve 2", "Curve 3", "Curve 4"
    opentime2_optb_pwm= bits, U08, 873, [4:4], "Off", "On"
    opentime2_optb_own= bits, U08, 873, [5:5], "Off", "On"

    opentime2_opt11   = bits, U08, 874, [0:1], "Curve 1", "Curve 2", "Curve 3", "Curve 4"
    opentime2_opt12   = bits, U08, 875, [0:1], "Curve 1", "Curve 2", "Curve 3", "Curve 4"
    opentime2_opt13   = bits, U08, 876, [0:1], "Curve 1", "Curve 2", "Curve 3", "Curve 4"
    opentime2_opt14   = bits, U08, 877, [0:1], "Curve 1", "Curve 2", "Curve 3", "Curve 4"
    opentime2_opt15   = bits, U08, 878, [0:1], "Curve 1", "Curve 2", "Curve 3", "Curve 4"
    opentime2_opt16   = bits, U08, 879, [0:1], "Curve 1", "Curve 2", "Curve 3", "Curve 4"
;    opentime2_opt17   = bits, U08, 880, [0:1], "Curve 1", "Curve 2", "Curve 3", "Curve 4"
;    opentime2_opt18   = bits, U08, 881, [0:1], "Curve 1", "Curve 2", "Curve 3", "Curve 4"

    smallpw2_opt1_master = bits, U08, 864, [7:7], "Off", "On"
    smallpw2_opt1    = bits, U08, 882, [0:1], "Curve 1", "Curve 2", "Curve 3", "Curve 4"
    smallpw2_opt2    = bits, U08, 883, [0:1], "Curve 1", "Curve 2", "Curve 3", "Curve 4"
    smallpw2_opt3    = bits, U08, 884, [0:1], "Curve 1", "Curve 2", "Curve 3", "Curve 4"
    smallpw2_opt4    = bits, U08, 885, [0:1], "Curve 1", "Curve 2", "Curve 3", "Curve 4"
    smallpw2_opt5    = bits, U08, 886, [0:1], "Curve 1", "Curve 2", "Curve 3", "Curve 4"
    smallpw2_opt6    = bits, U08, 887, [0:1], "Curve 1", "Curve 2", "Curve 3", "Curve 4"
    smallpw2_opt7    = bits, U08, 888, [0:1], "Curve 1", "Curve 2", "Curve 3", "Curve 4"
    smallpw2_opt8    = bits, U08, 889, [0:1], "Curve 1", "Curve 2", "Curve 3", "Curve 4"
    smallpw2_opta    = bits, U08, 890, [0:1], "Curve 1", "Curve 2", "Curve 3", "Curve 4"
    smallpw2_optb    = bits, U08, 891, [0:1], "Curve 1", "Curve 2", "Curve 3", "Curve 4"

    smallpw2_opt11    = bits, U08, 892, [0:1], "Curve 1", "Curve 2", "Curve 3", "Curve 4"
    smallpw2_opt12    = bits, U08, 893, [0:1], "Curve 1", "Curve 2", "Curve 3", "Curve 4"
    smallpw2_opt13    = bits, U08, 894, [0:1], "Curve 1", "Curve 2", "Curve 3", "Curve 4"
    smallpw2_opt14    = bits, U08, 895, [0:1], "Curve 1", "Curve 2", "Curve 3", "Curve 4"
    smallpw2_opt15    = bits, U08, 896, [0:1], "Curve 1", "Curve 2", "Curve 3", "Curve 4"
    smallpw2_opt16    = bits, U08, 897, [0:1], "Curve 1", "Curve 2", "Curve 3", "Curve 4"
;    smallpw2_opt17    = bits, U08, 898, [0:1], "Curve 1", "Curve 2", "Curve 3", "Curve 4"
;    smallpw2_opt18    = bits, U08, 899, [0:1], "Curve 1", "Curve 2", "Curve 3", "Curve 4"

    dualfuel_pin     = bits, U08, 900, [0:4], "INVALID", "Tableswitch", "PE0/JS7", "PE1", "JS10", "JS11", "JS5 (ADC6)", "JS4 (ADC7)", "Nitrous In", "Launch in", "Datalog In", "PT4 Spare in", "PT2 Cam in", "PE2 Flex", "INVALID", "INVALID", "CANIN1", "CANIN2", "CANIN3", "CANIN4", "CANIN5", "CANIN6", "CANIN7", "CANIN8", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID"
    dualfuel_opt_temp= bits, U08, 901, [0:0], "Off", "On"
    dualfuel_opt_press=bits, U08, 901, [1:1], "Off", "On"
    dualfuel_opt_mode = bits,U08, 901, [2:2], "Switching",  "Dual table"
    dualfuel_opt_out = bits,U08, 901, [3:3], "Shared outputs+relay", "Different outputs"

#if PW_4X
    inj2Open1         = scalar,  U16,    902,             "ms",       0.004,   0.00000,  0.00,   25.50,      3 ; * (  1 byte)
    inj2Open2         = scalar,  U16,    904,             "ms",       0.004,   0.00000,  0.00,   25.50,      3 ; * (  1 byte)
    inj2Open3         = scalar,  U16,    906,             "ms",       0.004,   0.00000,  0.00,   25.50,      3 ; * (  1 byte)
    inj2Open4         = scalar,  U16,    908,             "ms",       0.004,   0.00000,  0.00,   25.50,      3 ; * (  1 byte)
    inj2Open5         = scalar,  U16,    910,             "ms",       0.004,   0.00000,  0.00,   25.50,      3 ; * (  1 byte)
    inj2Open6         = scalar,  U16,    912,             "ms",       0.004,   0.00000,  0.00,   25.50,      3 ; * (  1 byte)
    inj2Open7         = scalar,  U16,    914,             "ms",       0.004,   0.00000,  0.00,   25.50,      3 ; * (  1 byte)
    inj2Open8         = scalar,  U16,    916,             "ms",       0.004,   0.00000,  0.00,   25.50,      3 ; * (  1 byte)
    inj2Opena         = scalar,  U16,    918,             "ms",       0.004,   0.00000,  0.00,   25.50,      3 ; * (  1 byte)
    inj2Openb         = scalar,  U16,    920,             "ms",       0.004,   0.00000,  0.00,   25.50,      3 ; * (  1 byte)
;next 8 not yet used
    inj2Open11         = scalar,  U16,    922,             "ms",       0.004,   0.00000,  0.00,   25.50,      3
    inj2Open12         = scalar,  U16,    924,             "ms",       0.004,   0.00000,  0.00,   25.50,      3
    inj2Open13         = scalar,  U16,    926,             "ms",       0.004,   0.00000,  0.00,   25.50,      3
    inj2Open14         = scalar,  U16,    928,             "ms",       0.004,   0.00000,  0.00,   25.50,      3
    inj2Open15         = scalar,  U16,    930,             "ms",       0.004,   0.00000,  0.00,   25.50,      3
    inj2Open16         = scalar,  U16,    932,             "ms",       0.004,   0.00000,  0.00,   25.50,      3
    inj2Open17         = scalar,  U16,    934,             "ms",       0.004,   0.00000,  0.00,   25.50,      3
    inj2Open18         = scalar,  U16,    936,             "ms",       0.004,   0.00000,  0.00,   25.50,      3
#else
    inj2Open1         = scalar,  U16,    902,             "ms",       0.001,   0.00000,  0.00,   25.50,      3 ; * (  1 byte)
    inj2Open2         = scalar,  U16,    904,             "ms",       0.001,   0.00000,  0.00,   25.50,      3 ; * (  1 byte)
    inj2Open3         = scalar,  U16,    906,             "ms",       0.001,   0.00000,  0.00,   25.50,      3 ; * (  1 byte)
    inj2Open4         = scalar,  U16,    908,             "ms",       0.001,   0.00000,  0.00,   25.50,      3 ; * (  1 byte)
    inj2Open5         = scalar,  U16,    910,             "ms",       0.001,   0.00000,  0.00,   25.50,      3 ; * (  1 byte)
    inj2Open6         = scalar,  U16,    912,             "ms",       0.001,   0.00000,  0.00,   25.50,      3 ; * (  1 byte)
    inj2Open7         = scalar,  U16,    914,             "ms",       0.001,   0.00000,  0.00,   25.50,      3 ; * (  1 byte)
    inj2Open8         = scalar,  U16,    916,             "ms",       0.001,   0.00000,  0.00,   25.50,      3 ; * (  1 byte)
    inj2Opena         = scalar,  U16,    918,             "ms",       0.001,   0.00000,  0.00,   25.50,      3 ; * (  1 byte)
    inj2Openb         = scalar,  U16,    920,             "ms",       0.001,   0.00000,  0.00,   25.50,      3 ; * (  1 byte)
;next 8 not yet used
    inj2Open11         = scalar,  U16,    922,             "ms",       0.001,   0.00000,  0.00,   25.50,      3
    inj2Open12         = scalar,  U16,    924,             "ms",       0.001,   0.00000,  0.00,   25.50,      3
    inj2Open13         = scalar,  U16,    926,             "ms",       0.001,   0.00000,  0.00,   25.50,      3
    inj2Open14         = scalar,  U16,    928,             "ms",       0.001,   0.00000,  0.00,   25.50,      3
    inj2Open15         = scalar,  U16,    930,             "ms",       0.001,   0.00000,  0.00,   25.50,      3
    inj2Open16         = scalar,  U16,    932,             "ms",       0.001,   0.00000,  0.00,   25.50,      3
    inj2Open17         = scalar,  U16,    934,             "ms",       0.001,   0.00000,  0.00,   25.50,      3
    inj2Open18         = scalar,  U16,    936,             "ms",       0.001,   0.00000,  0.00,   25.50,      3
#endif

      inj2PwmT        = scalar,  U08,    938,             "ms",       0.12800,   0.128,  0.00,   32.64,      1 ; * (  1 byte)
      inj2PwmPd       = scalar,  U08,    939,             "us",       1.00000,   0.00000, 40.00,  100.00,      0 ; * (  1 byte)
      inj2PwmP        = scalar,  U08,    940,             "%",        1.00000,   0.00000,  0.00,  100.00,      0 ; * (  1 byte)
      inj2PwmT2       = scalar,  U08,    941,             "ms",       0.12800,   0.128,  0.00,   32.64,      1 ; * (  1 byte)
      inj2PwmPd2      = scalar,  U08,    942,             "us",       1.00000,   0.00000, 40.00,  100.00,      0 ; * (  1 byte)
      inj2PwmP2       = scalar,  U08,    943,             "%",        1.00000,   0.00000,  0.00,  100.00,      0 ; * (  1 byte)
    dualfuel_temp_sens =  bits, U08, 944, [0:3], "Sensor 1", "Sensor 2","Sensor 3","Sensor 4","Sensor 5","Sensor 6","Sensor 7","Sensor 8","Sensor 9","Sensor 10","Sensor 11","Sensor 12","Sensor 13","Sensor 14","Sensor 15","Sensor 16"
    dualfuel_press_sens = bits, U08, 945, [0:3], "Sensor 1", "Sensor 2","Sensor 3","Sensor 4","Sensor 5","Sensor 6","Sensor 7","Sensor 8","Sensor 9","Sensor 10","Sensor 11","Sensor 12","Sensor 13","Sensor 14","Sensor 15","Sensor 16"
;     unused variables for trans controller to adjust us
;      FuelAdj 946
;      SpkAdj, 948
;      IdleAdj, 950
;      SprAdj; 952

; These two aren't used:
;    dualfuel_pri = bits, U08, 954, [0:1], "V3 inj1" "INVALID" "V3 inj1+2" "MS3X"
;    dualfuel_sec = bits, U08, 955, [0:1],  "INVALID" "V3 inj2" "V3 inj1+2" "MS3X"
    ITB_load_mappoint = scalar, S16, 956, "% baro", 0.1000, 0, 30, 100.0, 1
    ITB_load_idletpsthresh = scalar, S16, 958, "%", 0.1000, 0, -10, 100, 0
    idle_voltage_comp_voltage = array, S16, 960, [6], "V", 0.1000, 0, 9, 17, 1
    idle_voltage_comp_delta = array, S16, 972, [6], "%", 0.39063, 0.00000, -20, 20, 1


   page = 3 ; 8
      boost_ctl_load_targets   = array,  S16, 0, [8x8], "%", 0.1, 0, 0, {loadhigh}, 1
      boost_ctl_loadtarg_tps_bins=array, S16, 128, [8], "%", 0.1, 0, 0, 100, 1
      boost_ctl_loadtarg_rpm_bins=array, U16, 144, [8], "rpm", 1, 0, 0, {rpmhigh}, 0
      boost_ctl_pwm_targets    = array,  U08, 160, [8x8], "%", 1, 0, 0, 100, 0
      boost_ctl_pwmtarg_tps_bins=array,  S16, 224, [8], "%", 0.1, 0, 0, 100, 1
      boost_ctl_pwmtarg_rpm_bins=array,  U16, 240, [8], "rpm", 1, 0, 0, {rpmhigh}, 0
      primePWTable              =array,  S16, 256,    [   10], "ms",       0.10000,   0.00000,  0.00,   65.00,      1 ; * ( 20 bytes)
      crankPctTable             =array,  U16, 276,    [   10], "%",       1,   1,  1,   10000,      0 ; * ( 20 bytes)
      asePctTable               =array,  S16, 296,    [   10], "%",        1.00000,   0.00000,  0.00,  400.00,      0 ; * (  2 bytes)
      aseCntTable               =array,  S16, 316,    [   10], "cycles",   1.00000,   0.00000,  0.00, 2500.00,      0 ; * (  2 bytes)

#if CELSIUS
      matTemps                  =array,  S16, 336,    [    6], "°C",       0.05555,  -320.000,-40.00,  150.00,      1 ; * ( 12 bytes)
#else
      matTemps                  =array,  S16, 336,    [    6], "°F",       0.10000,   0.00000,-40.00,  300.00,      1
#endif
      matRetard                 =array,  U08, 348,    [    6], "deg",      0.10000,   0.00000,  0.00,    25.5,      1 ; * (  6 bytes)

      EAEAWCRPMbins   = array,   U16,    354,    [   12], "rpm",      1.00000,   0.00000,0,       {rpmhigh},       0 ; * (24 bytes)
      EAESOCRPMbins   = array,   U16,    378,    [   12], "rpm",      1.00000,   0.00000,0,	  {rpmhigh},       0 ; * (24 bytes)
      EAEAWCKPAbins   = array,   U16,    402,    [   12], "kpa",      0.10000,   0.00000,0,       {loadhigh},         0 ; * (24 bytes)
      EAESOCKPAbins   = array,   U16,    426,    [   12], "kpa",      0.10000,   0.00000,0,       {loadhigh},         0 ; * (24 bytes)
      EAEBAWC	      = array,   U08,    450,    [   12], "%",        1.00000,   0.00000,0,       100,         0 ; * (12 bytes)
      EAEBSOC	      = array,   U08,    462,    [   12], "%",        0.10000,   0.00000,0,       25.5,         1 ; * (12 bytes)
      EAEAWN	      = array,   U08,    474,    [   12], "%",        1.00000,   0.00000,0,       200,         0 ; * (12 bytes)
      EAESON	      = array,   U08,    486,    [   12], "%",        1.00000,   0.00000,0,	  200,         0 ; * (12 bytes)
      EAEAWW	      = array,   U08,    498,    [   12], "%",        1.00000,   0.00000,0,	  200,         0
      EAESOW	      = array,   U08,    510,    [   12], "%",        1.00000,   0.00000,0,	  200,         0

      ; Supplemental corrections for barometer and MAT.
      baroCorrVals    = array ,  S16,    522,    [    6], "kPa",      0.10000,   0.00000,  0.00,  110.00,      1 ; * ( 24 bytes)
#if CELSIUS
      matCorrTemps    = array ,  S16,    534,    [    6], "°C",       0.05555,  -320.000,-40.00,  150.00,      1 ; * ( 12 bytes)
#else
      matCorrTemps    = array ,  S16,    534,    [    6], "°F",       0.10000,   0.00000,-40.00,  300.00,      1
#endif
; moved later and to S16
;      XXXbaroCorrDelta   = array ,  S08,    546,    [    6], "%",        1.00000,   0.00000,-120.0,   120.0,      1 ; * (  6 bytes)
;      XXXmatCorrDelta    = array ,  S08,    552,    [    6], "%",        1.00000,   0.00000,-120.0,   120.0,      1 ; * (  6 bytes)

#if CELSIUS
      temp_table_p5   = array,  S16,     558,    [   10], "°C",	      0.05555,   -320.000, -40.00, {clthighlim},     0
#else
      temp_table_p5   = array,  S16,     558,    [   10], "°F",       0.10000,   0.000,-40.00, {clthighlim},      1
#endif

#if CELSIUS
	#if EXPANDED_CLT_TEMP
      EAEAWWCLTbins   = array,  S16,     578,    [   12], "deg",       0.05555,   -320.000, -40.00, 230.00,     0
      EAESOWCLTbins   = array,  S16,     602,    [   12], "deg",       0.05555,   -320.000, -40.00, 230.00,     0
	#else
      EAEAWWCLTbins   = array,  S16,     578,    [   12], "deg",       0.05555,   -320.000, -40.00, 150.00,     0
      EAESOWCLTbins   = array,  S16,     602,    [   12], "deg",       0.05555,   -320.000, -40.00, 150.00,     0
	#endif
#else
	#if EXPANDED_CLT_TEMP
      EAEAWWCLTbins   = array,  S16,     578,    [   12], "deg",       0.10000,   0.000,-40.00, 450.00,      1
      EAESOWCLTbins   = array,  S16,     602,    [   12], "deg",       0.10000,   0.000,-40.00, 450.00,      1
	#else
      EAEAWWCLTbins   = array,  S16,     578,    [   12], "deg",       0.10000,   0.000,-40.00, 300.00,      1
      EAESOWCLTbins   = array,  S16,     602,    [   12], "deg",       0.10000,   0.000,-40.00, 300.00,      1
	#endif
#endif

      pwmidle_target_rpms = array, U16, 626,    [ 8 ], "rpms",      1, 0.00000, 0.00, 2000, 0;
#if CELSIUS
	#if EXPANDED_CLT_TEMP
      pwmidle_clt_temps = array,  S16, 642,   [8],  "°C",   0.05555,  -320.000,-40.00,  230.00,      1 ;

	#else
      pwmidle_clt_temps = array,  S16, 642,   [8],  "°C",   0.05555,  -320.000,-40.00,  150.00,      1 ;
	#endif
#else
	#if EXPANDED_CLT_TEMP
      pwmidle_clt_temps = array,  S16, 642,   [8],  "°F",       0.10000,  0.00000,-40.00,  450.00,      1
	#else
      pwmidle_clt_temps = array,  S16, 642,   [8],  "°F",       0.10000,  0.00000,-40.00,  300.00,      1
	#endif
#endif

;padding 20
#if CELSIUS
	#if EXPANDED_CLT_TEMP
      RevLimLookup    = array ,  S16,    678,    [    8], "°C",       0.05555,  -320.000,-40.00,  230.00,      1 ; * ( 16 bytes) 
	#else
      RevLimLookup    = array ,  S16,    678,    [    8], "°C",       0.05555,  -320.000,-40.00,  150.00,      1 ; * ( 16 bytes)
	#endif
#else
	#if EXPANDED_CLT_TEMP
      RevLimLookup    = array ,  S16,    678,    [    8], "°F",       0.10000,   0.00000,-40.00,  450.00,      1 ; * ( 16 bytes) 
	#else
      RevLimLookup    = array ,  S16,    678,    [    8], "°F",       0.10000,   0.00000,-40.00,  300.00,      1 ; * ( 16 bytes) 
	#endif
#endif

      RevLimRpm1      = array ,  U16,    694,    [    8], "RPM",      1.00000,   0.00000,  0.00,{rpmhigh},      0 ; * ( 16 bytes
;these are not presently used, but might re-appear
      Xknk_rpm         = array ,  U16,    710,    [    6], "rpm",      1.0,       0.0,      0.0,    {rpmhigh},       0 ; * (  2 bytes)
      Xknk_thresh      = array ,  U16,    722,    [    6], "v",        0.01,      0.0,      0.0,    5.00,       2 ; * (  2 bytes)

      RotarySplitTable = array, S16,  734,    [8x8], "deg",  0.10000, 0.00000, -60, 20, 1
      RotarySplitLoad = array, U16,   862, [ 8 ], "%", 0.10000, 0.00000, 0, {loadhigh}, 0
      RotarySplitRPM = array, U16,  878, [ 8 ], "RPM", 1, 0.00000, 0, {rpmhigh}, 0

      NoiseFilterRpm = array, U16, 894, [  4], "RPM",      1, 0.00000, 0.00, {rpmhigh},  0
      NoiseFilterLen = array, U16, 902, [  4], "usec",     1.0, 0.00000, 0.00, 43000, 1

      VariableLagTPSBins = array,  U08,  910, [4], "%/sec", 1, 0.000000, 0.00, 255.00, 0
      VariableLagMapLags = array,  U08,  914, [4], "Lag", 1, 0.000000, 0.00, 255.00, 0
      pwmidle_crank_dutyorsteps_duty = array, U16, 918, [4], "%", 0.39063, 0.00000, 0, 100, 1
      pwmidle_crank_dutyorsteps_steps = array, U16, 918, [4], "steps", 1, 0, 0, 512, 0

#if CELSIUS
	#if EXPANDED_CLT_TEMP
      pwmidle_crank_clt_temps = array, S16, 926, [4], "°C", 0.05555,  -320.000,-40.00,  230.00,      1
	#else
      pwmidle_crank_clt_temps = array, S16, 926, [4], "°C", 0.05555,  -320.000,-40.00,  150.00,      1
	#endif
#else
	#if EXPANDED_CLT_TEMP
      pwmidle_crank_clt_temps = array, S16, 926, [4], "°F",       0.10000,   0.00000,-40.00,  450.00,      1
	#else
      pwmidle_crank_clt_temps = array, S16, 926, [4], "°F",       0.10000,   0.00000,-40.00,  300.00,      1	
	#endif
#endif
      matclt_pct    = array, U16,    934,    [6],    "%",    0.010, 0,       0,      60,   1
      matclt_rpm    = array, U16,    946,    [6],    "rpm",  1,       0,       0,      {rpmhigh}, 0
      ;user defined
; these are not used by the code and are provided for users to use and learn from
; if you want to add more... you also have to make matching changes in ms2_extra.h
; and ms2_extra_main.c
; note that it you add an 'int' that two bytes are consumed and two of the following
; spare array will need to be removed!
    user_value1      = scalar, U16, 958, "",   1, 0, 0, 65535, 0
    user_value2      = scalar, U16, 960, "",   1, 0, 0, 65535, 0
    user_conf0       = bits, U08, 962, [0:0], "Off", "On"
    user_conf1       = bits, U08, 962, [1:2], "Mode 0", "Mode 1", "Mode 2", "Mode 3"
;spare 10 bytes
;end user defined
;pad1
      baroCorrDelta   = array ,  S16,    974,    [    6], "%",        0.10000,   0.00000,-120.0,   120.0,      1 ; * (  6 bytes)
      matCorrDelta    = array ,  S16,    986,    [    6], "%",        0.10000,   0.00000,-120.0,   120.0,      1 ; * (  6 bytes)
; space

page = 4 ; 9   - injector channel trims
      inj_trima   = array ,  S08,    000,    [6x6], "%",      0.20000,   0.00000, -25.4,   25.4,      1 ; * (36 bytes)
      inj_trimb   = array ,  S08,    036,    [6x6], "%",      0.20000,   0.00000, -25.4,   25.4,      1 ; * (36 bytes)
      inj_trimc   = array ,  S08,    072,    [6x6], "%",      0.20000,   0.00000, -25.4,   25.4,      1 ; * (36 bytes)
      inj_trimd   = array ,  S08,    108,    [6x6], "%",      0.20000,   0.00000, -25.4,   25.4,      1 ; * (36 bytes)
      inj_trime   = array ,  S08,    144,    [6x6], "%",      0.20000,   0.00000, -25.4,   25.4,      1 ; * (36 bytes)
      inj_trimf   = array ,  S08,    180,    [6x6], "%",      0.20000,   0.00000, -25.4,   25.4,      1 ; * (36 bytes)
      inj_trimg   = array ,  S08,    216,    [6x6], "%",      0.20000,   0.00000, -25.4,   25.4,      1 ; * (36 bytes)
      inj_trimh   = array ,  S08,    252,    [6x6], "%",      0.20000,   0.00000, -25.4,   25.4,      1 ; * (36 bytes)
      inj_trimi   = array ,  S08,    288,    [6x6], "%",      0.20000,   0.00000, -25.4,   25.4,      1 ; * (36 bytes)
      inj_trimj   = array ,  S08,    324,    [6x6], "%",      0.20000,   0.00000, -25.4,   25.4,      1 ; * (36 bytes)
      inj_trimk   = array ,  S08,    360,    [6x6], "%",      0.20000,   0.00000, -25.4,   25.4,      1 ; * (36 bytes)
      inj_triml   = array ,  S08,    396,    [6x6], "%",      0.20000,   0.00000, -25.4,   25.4,      1 ; * (36 bytes)
      inj_trimm   = array ,  S08,    432,    [6x6], "%",      0.20000,   0.00000, -25.4,   25.4,      1 ; * (36 bytes)
      inj_trimn   = array ,  S08,    468,    [6x6], "%",      0.20000,   0.00000, -25.4,   25.4,      1 ; * (36 bytes)
      inj_trimo   = array ,  S08,    504,    [6x6], "%",      0.20000,   0.00000, -25.4,   25.4,      1 ; * (36 bytes)
      inj_trimp   = array ,  S08,    540,    [6x6], "%",      0.20000,   0.00000, -25.4,   25.4,      1 ; * (36 bytes)

      inj_trim_rpm = array,  U16,    576,    [6], "rpm",      1,   0.00000, 0,   {rpmhigh},      0 ; * (12 bytes)

      inj_trim_load  =array, U16,    588,    [6], "%",        0.1,   0.0000, 0,   {loadhigh},        1 ; * (12 bytes)

      inj_timing = array, S16,       600,    [12x12], "deg",  0.10000, 0.00000, -360.0, 720.0, 1
      inj_timing_rpm = array, U16,   888,    [12],    "rpm",  1,       0,       0,      {rpmhigh}, 0
      inj_timing_load = array, S16,  912,    [12],    "%",    0.10000, 0,       0,      {loadhigh},   1
      maxafr1_load   = array, U16,    936,    [6],    "%",    0.10000, 0,       0,      {loadhigh},   1
      maxafr1_rpm    = array, U16,    948,    [6],    "rpm",  1,       0,       0,      {rpmhigh}, 0
#if LAMBDA
      maxafr1_diff    = array, U08,    960,    [6x6], "Lambda",  0.006803,   0.00000,  0.00,    0.14,      3
#else
      maxafr1_diff    = array, U08,    960,    [6x6], "AFR",      0.10000,   0.00000,  0.00,   2.00,      1
#endif
      dwellrpm_dwell = array, U08,    996,    [6], "ms", 0.1, 0, 1, 8, 1
      dwellrpm_rpm   = array, U16,   1002,    [6], "RPM", 1, 0, 0, 15000, 0

page = 5   ; 10
      boost_ctl_load_targets2   = array,  S16, 0, [8x8], "%", 0.1, 0, 0, {loadhigh}, 1
      boost_ctl_loadtarg_tps_bins2=array, S16, 128, [8], "%", 0.1, 0, 0, 100, 1
      boost_ctl_loadtarg_rpm_bins2=array, U16, 144, [8], "rpm", 1, 0, 0, {rpmhigh}, 0
      boost_ctl_pwm_targets2    = array,  U08, 160, [8x8], "%", 1, 0, 0, 100, 0
      boost_ctl_pwmtarg_tps_bins2=array,  S16, 224, [8], "%", 0.1, 0, 0, 100, 1
      boost_ctl_pwmtarg_rpm_bins2=array,  U16, 240, [8], "rpm", 1, 0, 0, {rpmhigh}, 0

      boost_timed_pct = array,  U08,    256, [ 6 ], "%", 1, 0, 0, 100, 0 
      boost_timed_time= array,  U16,    262, [ 6 ], "s", 0.001, 0, 0, 15, 1
      boostvss_duty   = array,  U08,    274, [ 6 ], "%", 1, 0, 0, 100, 0
      boostvss_target = array,  U16,    280, [ 6 ], "kPa", 0.1, 0, 0, {loadhigh}, 1
#if MPH
      boostvss_speed  = array,  U16,    292, [ 6 ], "MPH", 0.22369, 0, 0, 1000, 0
#else
      boostvss_speed  = array,  U16,    292, [ 6 ], "KPH", 0.3600, 0, 0, 1600, 0
#endif


      map_sample_rpms = array, U16, 304, [ 8 ], "rpm", 1, 0, 0, {rpmhigh}, 0 
      map_sample_timing = array, S16, 320, [ 8 ], "deg", 0.10000, 0, -360, 720, 1
#if LAMBDA
      afrTable1       = array ,  U08,    336,    [12x12], "Lambda",  0.006803,   0.00000,  0.00,    2.00,      3 ; * (144 bytes)
      afrTable2       = array ,  U08,    480,    [12x12], "Lambda",  0.006803,   0.00000,  0.00,    2.00,      3 ; * (144 bytes)
#else
      afrTable1       = array ,  U08,    336,    [12x12], "AFR",      0.10000,   0.00000,  9.00,   20.00,      1
      afrTable2       = array ,  U08,    480,    [12x12], "AFR",      0.10000,   0.00000,  9.00,   20.00,      1
#endif
      wueBins         = array ,  U08,    624,    [   10], "%",        1.00000,   0.00000,  0.00,  255.00,      0 ; * ( 10 bytes)
;gap
      iacstepTable    = array ,  S16,    642,    [   10], "steps",    1.00000,   0.00000,  0.00,  500.00,      0 ; * ( 20 bytes)

      arpm_table1     = array ,  U16,    662,    [   12], "RPM",      1.00000,   0.00000,  0.00,{rpmhigh},      0 ; * ( 24 bytes)
      arpm_table2     = array ,  U16,    686,    [   12], "RPM",      1.00000,   0.00000,  0.00,{rpmhigh},      0 ; * ( 24 bytes)
      amap_table1     = array ,  S16,    710,    [   12], "%",      0.10000,   0.00000,  0.00,  {loadhigh},      1 ; * ( 24 bytes)
      amap_table2     = array ,  S16,    734,    [   12], "%",      0.10000,   0.00000,  0.00,  {loadhigh},      1 ; * ( 24 bytes)

#if CELSIUS
      tempTable       = array ,  S16,    758,    [   10], "°C",       0.05555,  -320.000,-40.00,  {clthighlim},      1 ; * ( 20 bytes) Temperature bins for cranking, cold AE and WUE
  #else
      tempTable       = array ,  S16,    758,    [   10], "°F",       0.10000,   0.00000,-40.00,  {clthighlim},      1
  #endif
;gap
      dwellvolts      = array ,  U08,    794,    [    6], "V",        0.10000,   0.00000,6,   18,      1 ; * (  6 bytes)
      dwellcorr       = array ,  U08,    800,    [    6], "%",       2,   0.00000,20,   512,      0 ; * (  6 bytes)
      cold_adv_table  = array ,  S16,    806,    [   10], "deg",      0.10000,   0.00000,-10.00,   10.00,      1 ; * ( 20 bytes)
      ipwmTable       = array ,  S16,    826,    [   10], "%",        0.39063,   0.00000,  0.00,  100.00,      1
;846
      opentimepct0       = array,   U16,    846,    [    6], "%",       0.1,   0.00000,  0.00,   500,      1
      opentimepct1       = array,   U16,    858,    [    6], "%",       0.1,   0.00000,  0.00,   500,      1
      opentimepct2       = array,   U16,    870,    [    6], "%",       0.1,   0.00000,  0.00,   500,      1
      opentimepct3       = array,   U16,    882,    [    6], "%",       0.1,   0.00000,  0.00,   500,      1
      opentimev       = array,   U16,    894,    [    6], "V",        0.100,   0.00000,  6,      19.2,         1

#if PW_4X
      smallpw0       = array,   U16,    906,    [    6], "ms",       0.004,   0.00000,  0.00,   2,      3
      smallpw1       = array,   U16,    918,    [    6], "ms",       0.004,   0.00000,  0.00,   2,      3
      smallpw2       = array,   U16,    930,    [    6], "ms",       0.004,   0.00000,  0.00,   2,      3
      smallpw3       = array,   U16,    942,    [    6], "ms",       0.004,   0.00000,  0.00,   2,      3
      smallpwpw      = array,   U16,    954,    [    6], "ms",       0.004,   0.00000,  0.00,   2,      3
#else
      smallpw0       = array,   U16,    906,    [    6], "ms",       0.001,   0.00000,  0.00,   2,      3
      smallpw1       = array,   U16,    918,    [    6], "ms",       0.001,   0.00000,  0.00,   2,      3
      smallpw2       = array,   U16,    930,    [    6], "ms",       0.001,   0.00000,  0.00,   2,      3
      smallpw3       = array,   U16,    942,    [    6], "ms",       0.001,   0.00000,  0.00,   2,      3
      smallpwpw      = array,   U16,    954,    [    6], "ms",       0.001,   0.00000,  0.00,   2,      3
#endif

      waterinj_rpm      = array,   U16,    966,    [    8], "RPM",      1,   0.00000,  0.00,   {rpmhigh},      0
      waterinj_map      = array,   U16,    982,    [    4], "kPa",      0.1, 0.00000,  0.00,   {loadhigh},        0
      waterinj_duty     = array,   U08,    990,    [8 x 4], "%",        1,   0,        0,      100,        0

page = 6 ; 11   - spark channel trims
      spk_trima   = array ,  S08,    000,    [6x6], "%",      0.10000,   0.00000, -12.7,   12.7,      1 ; * (36 bytes)
      spk_trimb   = array ,  S08,    036,    [6x6], "%",      0.10000,   0.00000, -12.7,   12.7,      1 ; * (36 bytes)
      spk_trimc   = array ,  S08,    072,    [6x6], "%",      0.10000,   0.00000, -12.7,   12.7,      1 ; * (36 bytes)
      spk_trimd   = array ,  S08,    108,    [6x6], "%",      0.10000,   0.00000, -12.7,   12.7,      1 ; * (36 bytes)
      spk_trime   = array ,  S08,    144,    [6x6], "%",      0.10000,   0.00000, -12.7,   12.7,      1 ; * (36 bytes)
      spk_trimf   = array ,  S08,    180,    [6x6], "%",      0.10000,   0.00000, -12.7,   12.7,      1 ; * (36 bytes)
      spk_trimg   = array ,  S08,    216,    [6x6], "%",      0.10000,   0.00000, -12.7,   12.7,      1 ; * (36 bytes)
      spk_trimh   = array ,  S08,    252,    [6x6], "%",      0.10000,   0.00000, -12.7,   12.7,      1 ; * (36 bytes)
      spk_trimi   = array ,  S08,    288,    [6x6], "%",      0.10000,   0.00000, -12.7,   12.7,      1 ; * (36 bytes)
      spk_trimj   = array ,  S08,    324,    [6x6], "%",      0.10000,   0.00000, -12.7,   12.7,      1 ; * (36 bytes)
      spk_trimk   = array ,  S08,    360,    [6x6], "%",      0.10000,   0.00000, -12.7,   12.7,      1 ; * (36 bytes)
      spk_triml   = array ,  S08,    396,    [6x6], "%",      0.10000,   0.00000, -12.7,   12.7,      1 ; * (36 bytes)
      spk_trimm   = array ,  S08,    432,    [6x6], "%",      0.10000,   0.00000, -12.7,   12.7,      1 ; * (36 bytes)
      spk_trimn   = array ,  S08,    468,    [6x6], "%",      0.10000,   0.00000, -12.7,   12.7,      1 ; * (36 bytes)
      spk_trimo   = array ,  S08,    504,    [6x6], "%",      0.10000,   0.00000, -12.7,   12.7,      1 ; * (36 bytes)
      spk_trimp   = array ,  S08,    540,    [6x6], "%",      0.10000,   0.00000, -12.7,   12.7,      1 ; * (36 bytes)

      spk_trim_rpm  = array, U16,    576,    [6], "rpm",      1,   0.00000, 0,   {rpmhigh},      0 ; * (12 bytes)
      spk_trim_load = array, U16,    588,    [6], "%",        0.1,   0.0000, 0,   {loadhigh},        1 ; * (12 bytes)
      XAcc           =array, U16,    600,    [5], "%",  0.10000,   0.00000, 5.00, 90,        1 ; * ( 10 bytes)
      TauAcc         =array, U16,    610,    [5], "msec",1.00000,  0.00000, 2.00, 20000,     0 ; * ( 10 bytes)
      XDec           =array, U16,    620,    [5], "%",   0.10000,  0.00000, 5.00,    90,     1 ; * ( 10 bytes)
      TauDec         =array, U16,    630,    [5], "msec",1.00000,  0.00000, 2.00, 20000,     0 ; * ( 10 bytes)
      XTrpms         =array, U16,    640,    [5], "rpm",1.00000,   0.00000, 0.00, {rpmhigh},     0 ; * ( 10 bytes)
      XClt           =array, U16,    650,    [10], "%", 1.00000,   0.00000, 0.00,   600,     0 ; * ( 20 bytes)
      TauClt         =array, U16,    670,    [10], "%", 1.00000,   0.00000, 0.00,   600,     0 ; * ( 20 bytes)
#if CELSIUS
      XClt_temps   = array,  S16,    690,    [   10], "°C",	   0.05555,   -320.000, -40.00, {clthighlim},     0
      TauClt_temps = array,  S16,    710,    [   10], "°C",	   0.05555,   -320.000, -40.00, {clthighlim},     0
#else
      XClt_temps   = array,  S16,    690,    [   10], "°F",      0.10000,   0.000,-40.00, {clthighlim},      1
      TauClt_temps = array,  S16,    710,    [   10], "°F",      0.10000,   0.000,-40.00, {clthighlim},      1
#endif
;progressive nitrous tables
      n2o1_time     = array, U16,    730,    [6], "s", 0.001, 0, 0, 15, 2
      n2o1_rpm      = array, U16,    742,    [6], "RPM", 1, 0, 0, {rpmhigh}, 0
      n2o1_duty     = array, U08,    754,    [6], "%", 1, 0, 0, 100, 1
#if PW_4X
      n2o1_pw       = array, S16,    760,    [6], "ms", 0.004, 0, -20, 80, 3
      n2o2_pw       = array, S16,    814,    [6], "ms", 0.004, 0, -20, 80, 3
#else
      n2o1_pw       = array, S16,    760,    [6], "ms", 0.001, 0, -5, 20, 3
      n2o2_pw       = array, S16,    814,    [6], "ms", 0.001, 0, -5, 20, 3
#endif
      n2o1_retard   = array, U16,    772,    [6], "deg", 0.1, 0, 0, 30, 1
      n2o2_time     = array, U16,    784,    [6], "s", 0.001, 0, 0, 15, 2
      n2o2_rpm      = array, U16,    796,    [6], "RPM", 1, 0, 0, {rpmhigh}, 0
      n2o2_duty     = array, U08,    808,    [6], "%", 1, 0, 0, 100, 1
;      n2o2_pw       = array, S16,    814,    [6], "ms", 0.001, 0, -5, 20, 3
      n2o2_retard   = array, U16,    826,    [6], "deg", 0.1, 0, 0, 30, 1
; staged tables
      staged_percents=array, U08,    838,  [8x8], "%", 1, 0, 0, 100, 0
      staged_rpms   = array, U16,    902,  [8], "rpm", 1, 0, 0, {rpmhigh}, 0
      staged_loads  = array, S16,    918,  [8], "%",   0.1, 0, 0, 250, 1
      MAFFlow       = array, U16,    934,  [12], "g/sec", 0.01000,   0.00000,  0.00,   650.0,      1
      MAFCor        = array, U08,    958,  [12], "%", 1.00000,   0.00000,  0.00,   255.0,      0
      launch_time   = array, U16,    970,    [6], "s", 0.001, 0, 0, 15, 2
      launch_retard = array, U16,    982,    [6], "deg", 0.1, 0, 0, 30, 1

page = 7 ; 12
      veTable1        = array ,  U16,    000,    [16x16], "%",        0.10000,   0.00000,  0.00,  255.00,      1 ; * (512 bytes)
      veTable2	      = array ,  U16,    512,    [16x16], "%",        0.10000,   0.00000,  0.00,  255.00,      1 ;

page = 8 ; 13
      advanceTable1   = array ,  S16,    000,    [16x16], "deg",      0.10000,   0.00000,-10.00,   90.00,      1 ; * (512 bytes)
      advanceTable2   = array ,  S16,    512,    [16x16], "deg",      0.10000,   0.00000,-10.00,   90.00,      1 ; * (512 bytes)

page = 9 ; 18
      veTable3	      = array ,  U16,    000,    [16x16], "%",        0.10000,   0.00000,  0.00,  255.00,      1 ;
      advanceTable3   = array ,  S16,    512,    [16x16], "deg",      0.10000,   0.00000,-10.00,   90.00,      1 ; * (288 bytes)

page = 10 ; 19
      frpm_table1     = array ,  U16,    000,    [   16], "RPM",      1.00000,   0.00000,  0.00,{rpmhigh},      0 ; * ( 24 bytes)
      frpm_table2     = array ,  U16,    032,    [   16], "RPM",      1.00000,   0.00000,  0.00,{rpmhigh},      0 ; * ( 24 bytes)
      frpm_table3     = array ,  U16,    064,    [   16], "RPM",      1.00000,   0.00000,  0.00,{rpmhigh},      0 ; * ( 24 bytes)

      fmap_table1     = array ,  S16,    096,    [   16], "%",        0.10000,   0.00000,  0.00,  {loadhigh},      1 ; * ( 24 bytes)
      fmap_table2     = array ,  S16,    128,    [   16], "%",        0.10000,   0.00000,  0.00,  {loadhigh},      1 ; * ( 24 bytes)
      fmap_table3     = array ,  S16,    160,    [   16], "%",        0.10000,   0.00000,  0.00,  {loadhigh},      1 ; * ( 24 bytes)

      srpm_table1     = array ,  U16,    192,    [   16], "RPM",      1.00000,   0.00000,  0.00,{rpmhigh},      0 ; * ( 24 bytes)
      srpm_table2     = array ,  U16,    224,    [   16], "RPM",      1.00000,   0.00000,  0.00,{rpmhigh},      0 ; * ( 24 bytes)
      srpm_table3     = array ,  U16,    256,    [   16], "RPM",      1.00000,   0.00000,  0.00,{rpmhigh},      0 ; * ( 24 bytes)

      smap_table1     = array ,  S16,    288,    [   16], "%",        0.10000,   0.00000,  0.00,  {loadhigh},      1 ; * ( 24 bytes)
      smap_table2     = array ,  S16,    320,    [   16], "%",        0.10000,   0.00000,  0.00,  {loadhigh},      1 ; * ( 24 bytes)
      smap_table3     = array ,  S16,    352,    [   16], "%",        0.10000,   0.00000,  0.00,  {loadhigh},      1 ; * ( 24 bytes)
      EAEAWCRPMbins2  = array,   U16,    384,    [   12], "rpm",      1.0000,    0.00000,  0.00,  {rpmhigh},       0 ; * ( 24 bytes)
      EAESOCRPMbins2  = array,   U16,    408,    [   12], "rpm",      1.0000,    0.00000,  0.00,  {rpmhigh},       0 ; * ( 24 bytes)
      EAEAWCKPAbins2  = array,   U16,    432,    [   12], "%",        0.1000,    0.00000,  0.00,  {loadhigh},      1
      EAESOCKPAbins2  = array,   U16,    456,    [   12], "%",        0.1000,    0.00000,  0.00,  {loadhigh},      1
      EAEBAWC2 = array,          U08,    480,    [   12], "%",        1.0000,    0.00000,  0.00,  100.00,      0
      EAEBSOC2 = array,          U08,    492,    [   12], "%",        0.10000,   0.00000,  0.00,  25.5,        1
      EAEAWN2      = array,   U08,       504,    [   12], "%",        1.00000,   0.00000,0,	  200,         0 ; * (12 bytes)
      EAESON2      = array,   U08,       516,    [   12], "%",        1.00000,   0.00000,0,	  200,         0
      EAEAWW2 =  array,          U08,    528,    [   12], "%",        1.0000,    0.00000,  0.00,  100,         0
      EAESOW2 =  array,          U08,    540,    [   12], "%",        1.0000,    0.00000,  0.00,  100,         0
#if CELSIUS
  #if EXPANDED_CLT_TEMP
      EAEAWWCLTbins2   = array,  S16,     552,    [   12], "deg",       0.05555,   -320.000, -40.00, 230.00,     0
      EAESOWCLTbins2   = array,  S16,     576,    [   12], "deg",       0.05555,   -320.000, -40.00, 230.00,     0
	#else
      EAEAWWCLTbins2   = array,  S16,     552,    [   12], "deg",       0.05555,   -320.000, -40.00, 150.00,     0
      EAESOWCLTbins2   = array,  S16,     576,    [   12], "deg",       0.05555,   -320.000, -40.00, 150.00,     0
	#endif
#else
	#if EXPANDED_CLT_TEMP
      EAEAWWCLTbins2   = array,  S16,     552,    [   12], "deg",       0.10000,   0.000,-40.00, 450.00,      1
      EAESOWCLTbins2   = array,  S16,     576,    [   12], "deg",       0.10000,   0.000,-40.00, 450.00,      1
	#else
      EAEAWWCLTbins2   = array,  S16,     552,    [   12], "deg",       0.10000,   0.000,-40.00, 300.00,      1
      EAESOWCLTbins2   = array,  S16,     576,    [   12], "deg",       0.10000,   0.000,-40.00, 300.00,      1
	#endif
#endif
      ITB_load_loadvals= array,  S16,     600,    [   12], "%",         0.10000,   0.000, 0,     100.00,      1

      ITB_load_switchpoints = array,S16,  624,  [   12], "%",         0.10000,   0.000, 0,     100.00,      1
      ITB_load_rpms = array,     U16,     648,    [   12], "rpm",       1.0000,    0.000, 0,     {rpmhigh},       0 
      idleve_table1 = array,     U16,     672,  [4x4], "%",           0.10000,    0.000, 0,   200,    1
      idleve_table2 = array,     U16,     704,  [4x4], "%",           0.10000,    0.000, 0,   200,    1
      idleve_loads1 = array,     S16,     736,  [4 ],  "%",           0.10000,    0.000, 0,   255,    1
      idleve_loads2 = array,     S16,     744,  [4 ],  "%",           0.10000,    0.000, 0,   255,    1
      idleve_rpms1 = array,      U16,     752,  [4 ],  "rpm",         1.00000,    0.000, 0,   {rpmhigh},  0
      idleve_rpms2 = array,      U16,     760,  [4 ],  "rpm",         1.00000,    0.000, 0,   {rpmhigh},  0 
;TC
#if MPH
      tc_perfect_vss  = array, U16, 768, [ 10 ],  "mph", 0.22369, 0.00000, 0, 200, 1 
#else
      tc_perfect_vss  = array, U16, 768, [ 10 ],  "kph", 0.3600, 0.00000, 0, 300, 1 
#endif
      tc_perfect_time = array, U16, 788, [ 10 ],  "s", 0.001024, 0.00000, 0, 30, 1
      tc_react_x      = array, U16, 808, [ 4 ],  "slip% x 0.01s", 0.1, 0.00000, 0, 10000, 1 
      tc_retard       = array, U16, 816, [ 4 ],  "deg", 0.1, 0.00000, 0, 30, 1 

      tc_spkcut       = array, U08, 824, [ 4 ],  "cut%", 1, 0.00000, 0, 100, 0 
      tc_addfuel      = array, U08, 828, [ 4 ],  "add%", 1, 0.00000, 0, 100, 1 
      tc_nitrous      = array, U08, 832, [ 4 ],  "cut%", 1, 0.00000, 0, 100, 1 
      tc_boost        = array, U08, 836, [ 4 ],  "cut%", 1, 0.00000, 0, 100, 1 
;840
      knock_rpms  = array, U16, 840, [10], "rpm", 1, 0, 0, {rpmhigh}, 0
      knock_thresholds= array, U16, 860, [10], "%", 0.1, 0, 0, 100, 1
      knock_starts= array, S16, 880, [10], "deg", 0.1, 0, -50, 50, 1
      knock_durations  = array, S16, 900, [10], "deg", 0.1, 0, 0, 50, 1
;920
      pwmidle_cl_initialvalue_rpms = array, U16, 920, [5], "rpm", 1, 0, 0, {rpmhigh}, 0
#if CELSIUS
      pwmidle_cl_initialvalue_matorclt = array, S16, 930, [5], "°C", 0.05555, -320, -40, 230, 0
#else
      pwmidle_cl_initialvalue_matorclt = array, S16, 930, [5], "°F", 0.10000, 0.000, -40, 450, 0
#endif
      pwmidle_cl_initialvalues_duties = array, U08, 940, [5 x 5], "%", 0.39063, 0.00000, 0, 100, 1
      pwmidle_cl_initialvalues_steps = array, U08, 940, [5 x 5], "steps", 1, 0, 0, 255, 0
;pad
#if CELSIUS
      knock_clts   = array,  S16,     966,    [   4], "°C",	      0.05555,   -320.000, -40.00, {clthighlim},     0
#else
      knock_clts   = array,  S16,     966,    [   4], "°F",       0.10000,   0.000,-40.00, {clthighlim},      1
#endif
      knock_upscale  = array, U16, 974, [4], "%", 0.1, 0, 100, 600, 1

page = 11 ; 21
      pwm_rpms_a     = array,  U16, 0, [6], "rpm", 1, 0, 0, {rpmhigh}, 0
      pwm_rpms_b     = array,  U16, 12, [6], "rpm", 1, 0, 0, {rpmhigh}, 0
      pwm_rpms_c     = array,  U16, 24, [6], "rpm", 1, 0, 0, {rpmhigh}, 0
      pwm_rpms_d     = array,  U16, 36, [6], "rpm", 1, 0, 0, {rpmhigh}, 0
      pwm_rpms_e     = array,  U16, 48, [6], "rpm", 1, 0, 0, {rpmhigh}, 0
      pwm_rpms_f     = array,  U16, 60, [6], "rpm", 1, 0, 0, {rpmhigh}, 0
      pwm_loadvals_a = array,  S16, 72, [6], "%", 0.1, 0, 0, 1000, 1
      pwm_loadvals_b = array,  S16, 84, [6], "%", 0.1, 0, 0, 1000, 1
      pwm_loadvals_c = array,  S16, 96, [6], "%", 0.1, 0, 0, 1000, 1
      pwm_loadvals_d = array,  S16, 108, [6], "%", 0.1, 0, 0, 1000, 1
      pwm_loadvals_e = array,  S16, 120, [6], "%", 0.1, 0, 0, 1000, 1
      pwm_loadvals_f = array,  S16, 132, [6], "%", 0.1, 0, 0, 1000, 1
      pwm_duties_a   = array,  U08, 144, [6x6], "%", 1, 0, 0, 100, 0
      pwm_duties_b   = array,  U08, 180, [6x6], "%", 1, 0, 0, 100, 0
      pwm_duties_c   = array,  U08, 216, [6x6], "%", 1, 0, 0, 100, 0
      pwm_duties_d   = array,  U08, 252, [6x6], "%", 1, 0, 0, 100, 0
      pwm_duties_e   = array,  U08, 288, [6x6], "%", 1, 0, 0, 100, 0
      pwm_duties_f   = array,  U08, 324, [6x6], "%", 1, 0, 0, 100, 0
      primePWTable2  = array,  S16, 360,    [   10], "ms",       0.10000,   0.00000,  0.00,   65.00,      1 ; * ( 20 bytes)
      crankPctTable2 = array,  U16, 380,    [   10], "%",       1,   1,  1,   10000,      0 ; * ( 20 bytes)
      asePctTable2   = array,  S16, 400,    [   10], "%",        1.00000,   0.00000,  0.00,  400.00,      0 ; * (  2 bytes)
      aseCntTable2   = array,  S16, 420,    [   10], "cycles",   1.00000,   0.00000,  0.00, 2500.00,      0 ; * (  2 bytes)
      wueBins2       = array,  U08, 440,    [   10], "%",        1.00000,   0.00000,  0.00,  255.00,      0 ; * ( 10 bytes)
#if CELSIUS
      temp_table_p21   = array,  S16,     450,    [   10], "°C",	      0.05555,   -320.000, -40.00, {clthighlim},     0
#else
      temp_table_p21   = array,  S16,     450,    [   10], "°F",       0.10000,   0.000,-40.00, {clthighlim},      1
#endif
      frpm_table4     = array ,  U16,    470,    [   16], "RPM",      1.00000,   0.00000,  0.00,{rpmhigh},      0 ; * ( 24 bytes)
      fmap_table4     = array ,  S16,    502,    [   16], "%",        0.10000,   0.00000,  0.00,  {loadhigh},      1 ; * ( 24 bytes)
      srpm_table4     = array ,  U16,    534,    [   16], "RPM",      1.00000,   0.00000,  0.00,{rpmhigh},      0 ; * ( 24 bytes)
      smap_table4     = array ,  S16,    566,    [   16], "%",        0.10000,   0.00000,  0.00,  {loadhigh},      1 ; * ( 24 bytes)
#if CELSIUS
      dualfuel_temp   = array,  S16,     598,    [   10], "°C",	      0.05555,   -320.000, -40.00, {clthighlim},     0
#else
      dualfuel_temp   = array,  S16,     598,    [   10], "°F",       0.10000,   0.000,-40.00, {clthighlim},      1
#endif
      dualfuel_temp_adj=array,  S16,     618,    [   10], "%",       0.10000,   0.000,-200.00, 200.00,      1
      dualfuel_press  = array,  S16,     638,    [   10], "kPa",     0.10000,   0.000,   0.00, 200.00,      1
      dualfuel_press_adj=array, S16,     658,    [   10], "%",       0.10000,   0.000,-200.00, 200.00,      1
      inj_timing_sec=array, S16,         678,    [12x12], "deg",     0.10000,   0.000,   -360,    720,      1
      inj_timing_sec_load=array, S16,    966,    [   12], "%",       0.10000,   0.000,      0,    {loadhigh},      1
      inj_timing_sec_rpm=array,  U16,    990,    [   12], "rpm",     1,         0,          0,  {rpmhigh},      0

page = 12 ; 22
      veTable4	      = array ,  U16,    000,    [16x16], "%",        0.10000,   0.00000,  0.00,  200.00,      1 ;
      advanceTable4   = array ,  S16,    512,    [16x16], "deg",      0.10000,   0.00000,-10.00,   90.00,      1 ; * (288 bytes)

page = 13 ; 23
      ; Generic Spare Port Settings constants
      psEnabled       = array ,  U08,      0,    [   48], "on/off",   1.00000,   0.00000,   0.00,    1.00,     0,   noSizeMutation ; * (  2 bytes)
      psCondition     = array ,  U08,     48,    [ 48x2], "",         1.00000,   0.00000,-128.00,  127.00,     0,   noSizeMutation ; * (  2 bytes)
      psConnector     = array ,  U08,    144,    [   48], "",         1.00000,   0.00000,-128.00,  127.00,     0,   noSizeMutation ; * (  2 bytes)
      psInitValue     = array ,  U08,    192,    [   48], "",         1.00000,   0.00000,-128.00,  127.00,     0,   noSizeMutation ; * (  2 bytes)
      psPortValue     = array ,  U08,    240,    [   48], "",         1.00000,   0.00000,-128.00,  127.00,     0,   noSizeMutation ; * (  2 bytes)
      psOutSize       = array ,  U08,    288,    [ 48x2], "",         1.00000,   0.00000,-128.00,  127.00,     0,   noSizeMutation ; * (  2 bytes)
      psOutOffset     = array ,  U16,    384,    [ 48x2], "",         1.00000,   0.00000,   0.00, 32767.0,     0,   noSizeMutation ; * (  2 bytes)
      psThreshold     = array ,  U16,    576,    [ 48x2], "",         1.00000,   0.00000,-32768.0,32767.0,     0,   noSizeMutation ; * (  4 bytes)
      psHysteresis    = array ,  U16,    768,    [ 48x2], "",         1.00000,   0.00000,-32768.0,32767.0,     0,   noSizeMutation ; * (  4 bytes)
;next is 960

page = 14 ; 24
      narrowband_tgts = array, U16,      0,       [12x12], "V",       0.00488,   0.00000,       0,      1,     3
      narrowband_tgts_rpms = array, U16, 288,     [   12], "rpm",      1.00000,   0.00000,       0,  {rpmhigh},     0
      narrowband_tgts_loads = array, S16,312,     [   12], "%",       0.10000,   0.00000,       0,  {loadhigh},       1
      als_opt_fc    = bits,     U08,    336,    [0:0], "Off", "On"
      als_opt_sc    = bits,     U08,    336,    [1:1], "Off", "On"
      als_opt_idle  = bits,     U08,    336,    [2:2], "Off", "On"
      als_opt_fuel  = bits,     U08,    336,    [3:3], "Off", "On"
      als_opt_pwmout= bits,     U08,    336,    [4:4], "Off", "On"
      als_opt_ri    = bits,     U08,    336,    [5:5], "Off", "On"
      als_maxtime   = scalar,   U08,    337,    "s",         0.1, 0, 1, 25.5, 1
;      als_mintps    = scalar,   S16,    338,    "%",    0.10000,   0.00000, 0,      100,         1
      als_maxtps    = scalar,   S16,    340,    "%",    0.10000,   0.00000, 0,      100,         1
      als_iac_duty  = scalar,   U08,    342,    "%",      0.39063, 0.00000, 0, 100, 1
      als_iac_steps = scalar,   U08,    342,    "steps",  1, 0, 0, 255, 0
      als_in_pin     = bits,    U08,    343, [0:4], "Off", "Tableswitch", "PE0/JS7", "PE1", "JS10", "JS11", "JS5 (ADC6)", "JS4 (ADC7)", "Nitrous In", "Launch in", "Datalog In", "PT4 Spare in", "PT2 Cam in", "PE2 Flex", "INVALID", "INVALID", "CANIN1", "CANIN2", "CANIN3", "CANIN4", "CANIN5", "CANIN6", "CANIN7", "CANIN8", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID"
      als_out_pin    = bits,    U08,    344, [0:5], "Off", "IAC1", "IAC2", "FIDLE", "D15", "Nitrous 1", "Nitrous 2", "Tacho", "Idle", "Boost", "VVT", "Inj Bank 1", "Inj Bank 2", "D14", "D16", "JS11", "Inj A", "Inj B", "Inj C", "Inj D", "Inj E", "Inj F", "Inj G", "Inj H", "PT4", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "CANPWM1", "CANPWM2", "CANPWM3", "CANPWM4", "CANPWM5", "CANPWM6", "CANPWM7", "CANPWM8", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID"
      als_pwm_duty  = scalar,   U08,    345,   "%", 1, 0, 0, 100, 0
      als_pausetime = scalar,   U08,    346,    "s",         0.1, 0, 0, 25.5, 1
; pad
#if CELSIUS
      als_minclt    = scalar,   S16,    348,    "°C",      0.05555,   -320.000, -40.00, 150.00,     1
      als_maxclt    = scalar,   S16,    350,    "°C",      0.05555,   -320.000, -40.00, 150.00,     1
#else
      als_minclt    = scalar,   S16,    348,    "°F",       0.10000,   0.000,-40.00, 300.00,      1
      als_maxclt    = scalar,   S16,    350,    "°F",       0.10000,   0.000,-40.00, 300.00,      1
#endif
;ALS tables
      als_rpms      = array,    U16,    352, [6], "rpm", 1, 0, 0, {rpmhigh}, 0
      als_tpss      = array,    U16,    364, [6], "%", 0.1, 0, 0, 100, 0
      als_timing    = array,    S16,    376, [6x6], "degrees", 0.10000,0.00000,-50.00, 50.00,1;
      als_addfuel   = array,    S16,    448, [6x6], "%", 0.1, 0, 0, 100, 1
      als_fuelcut   = array,    U08,    520, [6x6], "%", 1, 0, 0, 100, 0
      als_sparkcut  = array,    U08,    556, [6x6], "%", 1, 0, 0, 100, 0

      als_minrpm    = scalar,    U16,    592, "rpm", 1, 0, 0, {rpmhigh}, 0
      als_maxrpm    = scalar,    U16,    594, "rpm", 1, 0, 0, {rpmhigh}, 0
#if CELSIUS
      als_maxmat    = scalar,   S16,    596,    "°C",      0.05555,   -320.000, -40.00, 150.00,     1
#else
      als_maxmat    = scalar,   S16,    596,    "°F",       0.10000,   0.000,-40.00, 300.00,      1
#endif
    vvt_onoff_ang   = scalar,   S16,    598, "degrees", 0.10000,0.00000,0, 720.00,1;
    vvt_opt1_on     = bits,     U08,    600, [0:1], "Off", "1", "2", "4"
    vvt_opt1_dir_intake    = bits,     U08,    600, [2:2], "Advance", "Retard"
    vvt_opt1_int    = bits,     U08,    600, [3:3], "Synced to cam", "Timed"
    vvt_opt1_tst    = bits,     U08,    600, [4:6], "Off", "VVT1", "VVT2", "VVT3", "VVT4", "INVALID", "INVALID", "INVALID" ; 0, 1, 2, 3, 4
    vvt_opt1_dir_exhaust   = bits,     U08,    600, [7:7], "Advance", "Retard"
    vvt_hold_duty  = scalar,   U08,    601,   "%", 0.394, 0, 0, 100, 1
    vvt_out1       = bits,     U08,    602, [0:3], "Off", "Boost", "Idle", "VVT", "Nitrous1", "Nitrous2", "Fidle", "Inj Bank 1", "Inj Bank 2", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID"
    vvt_out2       = bits,     U08,    603, [0:3], "Off", "Boost", "Idle", "VVT", "Nitrous1", "Nitrous2", "Fidle", "Inj Bank 1", "Inj Bank 2", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID"
    vvt_out3       = bits,     U08,    604, [0:3], "Off", "Boost", "Idle", "VVT", "Nitrous1", "Nitrous2", "Fidle", "Inj Bank 1", "Inj Bank 2", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID"
    vvt_out4       = bits,     U08,    605, [0:3], "Off", "Boost", "Idle", "VVT", "Nitrous1", "Nitrous2", "Fidle", "Inj Bank 1", "Inj Bank 2", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID"
    vvt_ctl_ms             = scalar, U16, 606, "ms", 1, 0.00000, 10, 500, 0
    vvt_ctl_Kp             = scalar, U08, 608, "%", 1, 0.00000, 0, 200, 0
    vvt_ctl_Ki             = scalar, U08, 609, "%", 1, 0.00000, 0, 200, 0
    vvt_ctl_Kd             = scalar, U08, 610, "%", 1, 0.00000, 0, 200, 0
    vvt_test_duty   = scalar,   U08,    611,   "%", 0.39063, 0.00000, 0, 100, 1
    vvt_min_ang1     = scalar,    S16,   612, "abs.deg.", 0.10000,0.00000,0, 720.00,1;
    vvt_min_ang2     = scalar,    S16,   614, "abs.deg.", 0.10000,0.00000,0, 720.00,1;
    vvt_min_ang3     = scalar,    S16,   616, "abs.deg.", 0.10000,0.00000,0, 720.00,1;
    vvt_min_ang4     = scalar,    S16,   618, "abs.deg.", 0.10000,0.00000,0, 720.00,1;
    vvt_max_ang1     = scalar,    S16,   620, "abs.deg.", 0.10000,0.00000,0, 720.00,1;
    vvt_max_ang2     = scalar,    S16,   622, "abs.deg.", 0.10000,0.00000,0, 720.00,1;
    vvt_max_ang3     = scalar,    S16,   624, "abs.deg.", 0.10000,0.00000,0, 720.00,1;
    vvt_max_ang4     = scalar,    S16,   626, "abs.deg.", 0.10000,0.00000,0, 720.00,1;
    vvt_opt2_pid    = bits,     U08,    628, [0:0], "On/off", "PID"

    vvt_opt2_use_hold_intake = bits,   U08,    628, [1:1], "Off", "On"
    vvt_opt2_use_hold_exhaust = bits,  U08,    628, [2:2], "Off", "On"
    vvt_opt2_cam2pol = bits,    U08,    628, [4:4], "Falling Edge", "Rising Edge"
    vvt_opt2_cam3pol = bits,    U08,    628, [5:5], "Falling Edge", "Rising Edge"
    vvt_opt2_cam4pol = bits,    U08,    628, [6:6], "Falling Edge", "Rising Edge"
    vvt_opt2_cam1pol = bits,    U08,    628, [7:7], "Falling Edge", "Rising Edge"
      vvt_opt3_cam2 = bits,     U08,    629, [0:1], "PT4", "MS3X cam PT2", "JS10 PT5", "Datalog PT6"
      vvt_opt3_cam3 = bits,     U08,    629, [2:3], "PT4", "MS3X cam PT2", "JS10 PT5", "Datalog PT6"
      vvt_opt3_cam4 = bits,     U08,    629, [4:5], "PT4", "MS3X cam PT2", "JS10 PT5", "Datalog PT6"
      vvt_opt3_cam1 = bits,     U08,    629, [6:6], "Main cam", "INVALID" ; for display only
      vvt_timing_load   = array, S16,    630,    [   8], "%",       0.10000,   0.000,      0,    {loadhigh},      1
      vvt_timing_rpm    = array, U16,    646,    [   8], "rpm",     1,         0,          0,  {rpmhigh},      0
      vvt_timing1       = array, S16,    662,    [8x8], "deg",     0.10000,   0.000,   -360,    720,      1
      vvt_timing2       = array, S16,    790,    [8x8], "deg",     0.10000,   0.000,   -360,    720,      1
      vvt_tth1          = scalar, U08,    918,   "",     1,         0,          0,     8,      0
      vvt_tth2          = scalar, U08,    919,   "",     1,         0,          0,     8,      0
      vvt_tth3          = scalar, U08,    920,   "",     1,         0,          0,     8,      0
      vvt_tth4          = scalar, U08,    921,   "",     1,         0,          0,     8,      0
      vvt_coldpos1         = scalar,    S16,   922, "degrees", 0.10000,0.00000,0, 720.00,1;
      vvt_coldpos2         = scalar,    S16,   924, "degrees", 0.10000,0.00000,0, 720.00,1;

      tclu_opt_vss        = bits,     U08,    926, [0:1], "Off", "VSS1", "VSS2", "INVALID"
      tclu_opt_gear       = bits,     U08,    926, [2:2], "Off", "On"
      tclu_brakepin       = bits,    U08,    927, [0:4], "Off", "Tableswitch", "PE0/JS7", "PE1", "JS10", "JS11", "JS5 (ADC6)", "JS4 (ADC7)", "Nitrous In", "Launch in", "Datalog In", "PT4 Spare in", "PT2 Cam in", "PE2 Flex", "INVALID", "INVALID", "CANIN1", "CANIN2", "CANIN3", "CANIN4", "CANIN5", "CANIN6", "CANIN7", "CANIN8", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID"
      tclu_enablepin      = bits,    U08,    928, [0:4], "Off", "Tableswitch", "PE0/JS7", "PE1", "JS10", "JS11", "JS5 (ADC6)", "JS4 (ADC7)", "Nitrous In", "Launch in", "Datalog In", "PT4 Spare in", "PT2 Cam in", "PE2 Flex", "INVALID", "INVALID", "CANIN1", "CANIN2", "CANIN3", "CANIN4", "CANIN5", "CANIN6", "CANIN7", "CANIN8", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID"
      tclu_outpin         = bits,     U08,    929, [0:5], "Off", "IAC1", "IAC2", "FIDLE", "D15", "Nitrous 1", "Nitrous 2", "Tacho", "Idle", "Boost", "VVT", "Inj Bank 1", "Inj Bank 2", "D14", "D16", "JS11", "Inj A", "Inj B", "Inj C", "Inj D", "Inj E", "Inj F", "Inj G", "Inj H", "PT4", "IGN (JS10)", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "CANOUT1", "CANOUT2", "CANOUT3", "CANOUT4", "CANOUT5", "CANOUT6", "CANOUT7", "CANOUT8", "CANOUT9", "CANOUT10", "CANOUT11", "CANOUT12", "CANOUT13", "CANOUT14", "CANOUT15", "CANOUT16"
      tclu_gearmin        = scalar, U08,    930,   "",     1,         0,          0,     8,      0
      tclu_delay        = scalar,   U08,    931, "s", 0.1, 0, 0, 10, 1
#if MPH
      tclu_vssmin       = scalar,  U16,    932, "MPH", 0.22369, 0, 0, 1000, 0
#else
      tclu_vssmin       = scalar,  U16,    932, "KPH", 0.3600, 0, 0, 1600, 0
#endif
      tclu_tpsmin      = scalar,   S16,    934, "%", 0.1, 0, 0, 100, 1
      tclu_tpsmax      = scalar,   S16,    936, "%", 0.1, 0, 0, 100, 1
      tclu_mapmin      = scalar,   U16,    938, "%", 0.1, 0, 0, {loadhigh}, 1
      tclu_mapmax      = scalar,   U16,    940, "%", 0.1, 0, 0, {loadhigh}, 1
      vvt_opt4_decode  = bits,     U08,    942, [0:1], "Standard", "BMW V10", "INVALID", "INVALID"

      vvt_opt5_add1    = bits,     U08,    943, [0:1], "Off", "Cam 1", "Cam 2", "INVALID"
      vvt_opt5_add2    = bits,     U08,    943, [2:2], "Commanded", "Actual"
      vvt_opt5_err   = bits,     U08,    943, [3:3], "Yes","No"
      vvt_opt5_vvt1  = bits,     U08,    943, [4:4], "Intake","Exhaust"
      vvt_opt5_vvt2  = bits,     U08,    943, [5:5], "Intake","Exhaust"
      vvt_opt5_vvt3  = bits,     U08,    943, [6:6], "Intake","Exhaust"
      vvt_opt5_vvt4  = bits,     U08,    943, [7:7], "Intake","Exhaust"
      vvt_hold_duty_exh  = scalar,   U08,    944,   "%", 0.394, 0, 0, 100, 1
      vvt_ctl_Kp_exh   = scalar, U08, 945, "%", 1, 0.00000, 0, 200, 0
      vvt_ctl_Ki_exh   = scalar, U08, 946, "%", 1, 0.00000, 0, 200, 0
      vvt_ctl_Kd_exh   = scalar, U08, 947, "%", 1, 0.00000, 0, 200, 0
      vvt_cam1tth1      = scalar, U08, 948, "", 1, 0.00000, 0, 255, 0
      vvt_cam1tth2      = scalar, U08, 949, "", 1, 0.00000, 0, 255, 0
      vvt_cam2tth1      = scalar, U08, 950, "", 1, 0.00000, 0, 255, 0
      vvt_cam2tth2      = scalar, U08, 951, "", 1, 0.00000, 0, 255, 0
      vvt_cam3tth1      = scalar, U08, 952, "", 1, 0.00000, 0, 255, 0
      vvt_cam3tth2      = scalar, U08, 953, "", 1, 0.00000, 0, 255, 0
      vvt_cam4tth1      = scalar, U08, 954, "", 1, 0.00000, 0, 255, 0
      vvt_cam4tth2      = scalar, U08, 955, "", 1, 0.00000, 0, 255, 0
      vvt_opt6_freq     = bits,   U08, 956, [0:3], "1021Hz", "766Hz", "613Hz", "511Hz", "383Hz", "306Hz", "204Hz", "153Hz", "99Hz", "75Hz", "50Hz", "48Hz", "30Hz", "20Hz", "15Hz", "12Hz"
;pad
      als_rifuelcut   = array,    U08,    958, [6x6], "%", 1, 0, 0, 100, 0
      als_rirpms      = array,    U16,    994, [6], "rpm", 1, 0, 0, {rpmhigh}, 0
      als_ritpss      = array,    U16,    1006, [6], "%", 0.1, 0, 0, 100, 0
; 6 spare

[ConstantsExtensions]
    requiresPowerCycle = nCylinders
    requiresPowerCycle = ICIgnCapture
    requiresPowerCycle = engineType
    requiresPowerCycle = spkout_hi_lo
;    requiresPowerCycle = triggerOffset
    requiresPowerCycle = triggerTeeth
    requiresPowerCycle = No_Miss_Teeth
    requiresPowerCycle = IdleCtl
    requiresPowerCycle = IAC_tinitial_step
    requiresPowerCycle = hardware_spk
    requiresPowerCycle = hardware_cam
    requiresPowerCycle = hardware_fuel
    requiresPowerCycle = hardware_injij
    requiresPowerCycle = baroCorr
    requiresPowerCycle = egoType
;    requiresPowerCycle = alternate
    requiresPowerCycle = twoStroke
    requiresPowerCycle = nInjectors
    requiresPowerCycle = OddFireang
    requiresPowerCycle = algorithm
    requiresPowerCycle = algorithm2
    requiresPowerCycle = IgnAlgorithm
    requiresPowerCycle = IgnAlgorithm2
    requiresPowerCycle = AfrAlgorithm
    requiresPowerCycle = opt142_rtc
    requiresPowerCycle = mycan_id
    requiresPowerCycle = flexFuel
    requiresPowerCycle = flexport
    requiresPowerCycle = dwellmode
    requiresPowerCycle = knk_option
    requiresPowerCycle = knkDirection
    requiresPowerCycle = knkpull
    requiresPowerCycle = knk_option_an
    requiresPowerCycle = knkport
    requiresPowerCycle = spk_conf2_gm
    requiresPowerCycle = spk_conf2_tfi
    requiresPowerCycle = spk_conf2_oddodd
    requiresPowerCycle = spk_conf2_ngc
    requiresPowerCycle = spk_conf2_dli
    requiresPowerCycle = spk_config_campol
    requiresPowerCycle = spk_config_camcrank
    requiresPowerCycle = spk_config_trig2
    requiresPowerCycle = spk_config_trig2l
    requiresPowerCycle = spk_config_resetcam
    requiresPowerCycle = spk_mode0
    requiresPowerCycle = spk_mode3
    requiresPowerCycle = rtbaroport
    requiresPowerCycle = map2port
    requiresPowerCycle = ego2port
    requiresPowerCycle = mapport
    requiresPowerCycle = mapport_t
    requiresPowerCycle = mapport_f
    requiresPowerCycle = knkport_an
    requiresPowerCycle = feature4_0igntrig
    requiresPowerCycle = tsw_pin_f
    requiresPowerCycle = tsw_pin_s
    requiresPowerCycle = tacho_opt3f
    requiresPowerCycle = launch_opt_on
    requiresPowerCycle = launch_opt_pins
    requiresPowerCycle = N2Oopt_pins
    requiresPowerCycle = pwmidle_freq_scale
    requiresPowerCycle = boost_ctl_pins_pwm
    requiresPowerCycle = boost_ctl_pins
    requiresPowerCycle = boost_ctl_pwm_scale
    requiresPowerCycle = boost_ctl_pwm
    requiresPowerCycle = afrload
    requiresPowerCycle = eaeload
    requiresPowerCycle = log_style_led
    requiresPowerCycle = log_style2_but
    requiresPowerCycle = log_style_on
    requiresPowerCycle = log_style3_adc
    requiresPowerCycle = sequential
    requiresPowerCycle = boost_feats_tsw
    requiresPowerCycle = launch_3step_in
    requiresPowerCycle = maxafr_opt1_led
    requiresPowerCycle = vss1_pos
    requiresPowerCycle = vss2_pos
    requiresPowerCycle = launch_var_on
    requiresPowerCycle = reluctorteeth1
    requiresPowerCycle = reluctorteeth2
    requiresPowerCycle = vss_opt1
    requiresPowerCycle = vss_opt2
    requiresPowerCycle = vss1_an
    requiresPowerCycle = vss2_an
    requiresPowerCycle = tsw_pin_ob
    requiresPowerCycle = ss_opt1
    requiresPowerCycle = ss_opt2
    requiresPowerCycle = n2o1n_pins
    requiresPowerCycle = n2o1f_pins
    requiresPowerCycle = n2o2n_pins
    requiresPowerCycle = n2o2f_pins
    requiresPowerCycle = water_freq_on
    requiresPowerCycle = water_pins_pump
    requiresPowerCycle = water_pins_valve
    requiresPowerCycle = water_pins_in_shut
    requiresPowerCycle = egt_num
    requiresPowerCycle = accXport
    requiresPowerCycle = accYport
    requiresPowerCycle = accZport
    requiresPowerCycle = egt1port
    requiresPowerCycle = egt2port
    requiresPowerCycle = egt3port
    requiresPowerCycle = egt4port
    requiresPowerCycle = egt5port
    requiresPowerCycle = egt6port
    requiresPowerCycle = egt7port
    requiresPowerCycle = egt8port
    requiresPowerCycle = egt9port
    requiresPowerCycle = egt10port
    requiresPowerCycle = egt11port
    requiresPowerCycle = egt12port
    requiresPowerCycle = egt13port
    requiresPowerCycle = egt14port
    requiresPowerCycle = egt15port
    requiresPowerCycle = egt16port
    requiresPowerCycle = MAFOption
    requiresPowerCycle = MAFOption_t
    requiresPowerCycle = MAFOption_f
    requiresPowerCycle = vssout_opt
    requiresPowerCycle = vssout_optunits
    requiresPowerCycle = gear_method
    requiresPowerCycle = gear_port_an
    requiresPowerCycle = ac_idleup_io_in
    requiresPowerCycle = ac_idleup_settings
    requiresPowerCycle = ac_idleup_io_out
    requiresPowerCycle = fanctl_settings_on
    requiresPowerCycle = fanctl_settings_pin
    requiresPowerCycle = staged_extended_opts_use_v3
    requiresPowerCycle = staged_extended_opts_simult
    requiresPowerCycle = boost_ctl_settings_on2
    requiresPowerCycle = boost_ctl_settings_cl2
    requiresPowerCycle = boost_ctl_pins_pwm2
    requiresPowerCycle = boost_ctl_pins2
    requiresPowerCycle = boost_ctl_sensor2
    requiresPowerCycle = egoport1
    requiresPowerCycle = egoport2
    requiresPowerCycle = egoport3
    requiresPowerCycle = egoport4
    requiresPowerCycle = egoport5
    requiresPowerCycle = egoport6
    requiresPowerCycle = egoport7
    requiresPowerCycle = egoport8
    requiresPowerCycle = egoport9
    requiresPowerCycle = egoport10
    requiresPowerCycle = egoport11
    requiresPowerCycle = egoport12
    requiresPowerCycle = egoport13
    requiresPowerCycle = egoport14
    requiresPowerCycle = egoport15
    requiresPowerCycle = egoport16
    requiresPowerCycle = tc_opt_on
    requiresPowerCycle = tc_opt_method
    requiresPowerCycle = tc_enin
    requiresPowerCycle = fueltemp1
    requiresPowerCycle = sensor01_source
    requiresPowerCycle = sensor02_source
    requiresPowerCycle = sensor03_source
    requiresPowerCycle = sensor04_source
    requiresPowerCycle = sensor05_source
    requiresPowerCycle = sensor06_source
    requiresPowerCycle = sensor07_source
    requiresPowerCycle = sensor08_source
    requiresPowerCycle = sensor09_source
    requiresPowerCycle = sensor10_source
    requiresPowerCycle = sensor11_source
    requiresPowerCycle = sensor12_source
    requiresPowerCycle = sensor13_source
    requiresPowerCycle = sensor14_source
    requiresPowerCycle = sensor15_source
    requiresPowerCycle = sensor16_source
    requiresPowerCycle = shift_cut_on
    requiresPowerCycle = shift_cut_gear
    requiresPowerCycle = shift_cut_in
    requiresPowerCycle = shift_cut_out
    requiresPowerCycle = pwm_opt_on_a
    requiresPowerCycle = pwm_opt_on_b
    requiresPowerCycle = pwm_opt_on_c
    requiresPowerCycle = pwm_opt_on_d
    requiresPowerCycle = pwm_opt_on_e
    requiresPowerCycle = pwm_opt_on_f
    requiresPowerCycle = pwm_opt2_a
    requiresPowerCycle = pwm_opt2_b
    requiresPowerCycle = pwm_opt2_c
    requiresPowerCycle = pwm_opt2_d
    requiresPowerCycle = pwm_opt2_e
    requiresPowerCycle = pwm_opt2_f
    requiresPowerCycle = dualfuel_sw_on
    requiresPowerCycle = dualfuel_pin
    requiresPowerCycle = dualfuel_opt_mode
    requiresPowerCycle = dualfuel_opt_out
    requiresPowerCycle = dualfuel_temp_sens
    requiresPowerCycle = dualfuel_press_sens
    requiresPowerCycle = als_opt_pwmout
    requiresPowerCycle = als_in_pin
    requiresPowerCycle = als_out_pin
    requiresPowerCycle = vvt_opt1_on
    requiresPowerCycle = vvt_out1
    requiresPowerCycle = vvt_out2
    requiresPowerCycle = vvt_out3
    requiresPowerCycle = vvt_out4
    requiresPowerCycle = vvt_opt2_cam1pol
    requiresPowerCycle = vvt_opt2_cam2pol
    requiresPowerCycle = vvt_opt2_cam3pol
    requiresPowerCycle = vvt_opt2_cam4pol
    requiresPowerCycle = vvt_opt3_cam2
    requiresPowerCycle = vvt_opt3_cam3
    requiresPowerCycle = vvt_opt3_cam4
    requiresPowerCycle = tclu_brakepin
    requiresPowerCycle = tclu_enablepin
    requiresPowerCycle = tclu_outpin
    requiresPowerCycle = vvt_opt4_decode
    requiresPowerCycle = vvt_opt6_freq
    requiresPowerCycle = knk_pin_out
    requiresPowerCycle = timedout1_in
    requiresPowerCycle = timedout1_out
    requiresPowerCycle = tstop_out
    requiresPowerCycle = NoiseFilterOpts

    defaultValue = tsCanId, "CAN ID 0"
    defaultValue = rpmhigh, 9000
    defaultValue = rpmwarn, 3000
    defaultValue = rpmdang, 5000
    defaultValue = loadhigh, 400
;    defaultValue = clt_exp, "Normal"

[SettingContextHelp]
; constantName = "Help Text"

;Cancel out/replace MS2/BG words shipped with TS
    nCylinders = ""
    reqFuel = "Global fuel constant. Use the ReqFuel calculator. (Technically related to a pulsewidth at 100%VE)"
    nCylinders = ""
    no_skip_pulses = "The number of tach input pulses at start-up that are ignored before ignition calculations and wheel decoding begins."
    ICIgnCapture = ""
    spkout_hi_lo = "Spark output polarity. Typically 'inverted' for 99% of MS3X installs. Be sure to read documentation carefully to avoid melting your coils!"
    max_coil_dur = ""
    max_spk_dur = ""
    dwellAcc = ""
    RevLimMaxRtd = ""
    crankingRPM = ""
    cold_adv_table = ""
    triggerOffset = "For 'Basic Trigger', this means the angle BTDC at which your input trigger occurs. For 'Trigger Wheel' this is not used. For all other wheel modes this allows a +/-20 degree adjustment of the built-in reference angle."
    RevLimRpm1 = ""
    RevLimRpm2 = ""
    afrTable1 = ""
    afrTable2 = ""
    wueBins = ""
    taeBins = ""
    maeBins = ""
    iacstepTable = ""
    ipwmTable = ""
    tempTable = ""
    taeRates = ""
    maeRates = ""
    map0 = ""
    mapmax = ""
    clt0 = ""
    cltmult = ""
    mat0 = ""
    matmult = ""
    tpsMin = ""
    tpsMax = ""
    batt0 = ""
    battmax = ""
    ego0 = ""
    egomult = ""
    baro0 = ""
    baromax = ""
    bcor0 = ""
    bcormult = ""
    crankTolerance = ""
    pulseTolerance = ""
    IdleCtl = ""
    IACtstep = ""
    IACminstep = ""
    IACStart = ""
    IdleHyst = ""
    IACcrankxt = ""
    IACcoldtmp = ""
    IACcoldpos = ""
    IACcoldxt = ""
    taeColdA = ""
    taeColdM = ""
    tpsThresh = ""
    mapThresh = ""
    taeTime = ""
    tdePct = ""
    floodClear = ""
    TPSOXLimit = ""
    tpsProportion = ""
    baroCorr = ""
    egoType = ""
    egoCount = ""
    egoDelta = ""
    egoLimit = ""
    tempUnits = ""
    MAFOption = ""
    fastIdleT = ""
    egoTemp = ""
    egoRPM = ""
    divider = ""
    alternate = ""
    injOpena = "Injector dead time. Typically 0.7ms for low-z and 0.9ms for high-z"
    injOpen1 = "Injector dead time. Typically 0.9ms for high-z"
    injPwmT = ""
    injPwmPd = ""
    injPwmP = ""
    twoStroke = ""
    injType = "Not used"
    nInjectors = "Number of primary injectors"
    rpmLF = ""
    mapLF = ""
    tpsLF = ""
    egoLF = ""
    adcLF = ""
    AMCOption = ""
    algorithm = ""
    baud = ""
    MAPOXLimit = ""
    mycan_id = ""
    psEnabled = ""
    psCondition = ""
    psConnector = ""
    psInitValue = ""
    psPortValue = ""
    psOutSize = ""
    psOutOffset = ""
    psThreshold = ""
    psHysteresis = ""
    aeTaperTime = ""
    aeEndPW = ""
    egoAlgorithm = ""
    egoKP = ""
    egoKI = ""
    egoKD = ""
    flexFuel = ""
    fuelFreq = ""
    fuelFreq0 = ""
    fuelFreq1 = ""
    fuelCorr = ""
    fuelCorr0 = ""
    fuelCorr1 = ""
    knkDirection = ""
    knk_maxrtd = ""
    knk_step1 = ""
    knk_step2 = ""
    knk_trtd = ""
    knk_tadv = ""
    knk_dtble_adv = ""
    knk_ndet = ""
    knk_maxmap = ""
    knk_lorpm = ""
    knk_hirpm = ""
    triggerTeeth = ""
    No_Miss_Teeth = ""
    ICISR_tmask = ""
    ICISR_pmask = ""
    ae_lorpm = ""
    ae_hirpm = ""
    fuelSpkDel = ""
    fuelSpkDel0 = ""
    fuelSpkDel1 = ""
    veTable1 = ""
    veTable2 = ""
    asePctTable = ""
    aseCntTable = ""
    matTemps = ""
    matRetard = ""
    baroCorrVals = ""
    matCorrTemps = ""
    baroCorrDelta = ""
    matCorrDelta = ""
    MAFFlow = ""
    MAFCor = ""
    firea = "Firing order is used for trim and per-cylinder corrections. It does not change the injectors and coils wiring sequence. See the manual."

[Menu]

   ;----------------------------------------------------------------------------
   ;  There are five pre-defined values that may be used to define your menus.
   ;  The first four allow access to the "standard" dialog boxes, the last one
   ;  merely draws a separator (horizontal line) in the menu.
   ;
   ;     std_constants
   ;     std_enrichments
   ;     std_realtime
   ;     std_warmup
   ;     std_accel
   ;
   ;     std_separator
   ;
   ;  Additionally, to support MegaSquirt-II firmware, there are two standard
   ;  dialogs to generate its three embedded tables.  The first of these acts
   ;  like Roger Enns' EasyTherm, but only works for MS-II.  The second one
   ;  generates the internal AFR table required for proper closed loop operation
   ;  in MS-II.  Use these without page numbers, as they will just be ignored
   ;  in any case.
   ;
   ;     std_ms2gentherm
   ;     std_ms2geno2
   ;
   ;  If you use any of the std_constants, std_enrichments or std_warmup
   ;  editors, they may be optionally suffixed with a page number (only
   ;  useful for multi-page code variants), which causes them to edit the
   ;  specified page.  If you leave off the page specifier, they edit logical
   ;  page one as specified in the Constants section.
   ;
   ;  There are four special menu names, which when used append to the standard
   ;  menus of the same name instead of creating a new one.  The menu names
   ;  are "File", "Communications", "Tools" and "Help".
   ;
   ;----------------------------------------------------------------------------

   menuDialog = main
      menu = "Basic/Load Settings"
        subMenu = base,   "Engine and sequential settings"
    	subMenu = generalsettings2,   "General Settings"
        subMenu = revlimiter2, "Rev Limiter"
        subMenu = std_separator
        subMenu = tacho,          "Tacho output"
        subMenu = fan_control,      "Fan Control"
        subMenu = tcluparams, "Torque Convertor Lockup"
        subMenu = std_separator
        subMenu = barometerCorr,   "Barometric Correction"
        subMenu = map_sample_dialog,  "MAP Sample Settings"
        subMenu = std_separator
        subMenu = ITBcombined, "ITB load settings", 0, { algorithm == 6 || algorithm2 == 6 || IgnAlgorithm == 6 || IgnAlgorithm2 == 6 || afrload == 6 || eaeload == 6 }
        subMenu = mafcombined,      "MAF Options" ;, 0, { algorithm == 5 || algorithm2 == 5 } display always to allow datalogging
        subMenu = std_separator
        subMenu = std_realtime,    "&Realtime Display"
        subMenu = iopinlist, "I/O pins in use"
        subMenu = limitsettings, "Gauge and Settings limits"

      menu = "F&uel Settings"
        subMenu = injsettings,   "Injector Dead-time/PWM"
#if CYL_12_16_SUPPORT
        subMenu = injsettingsb,   "Injector Dead-time/PWM (9-16)"
#endif
        subMenu = smallpw, "Injector small pulsewidths"
#if CYL_12_16_SUPPORT
        subMenu = smallpwb, "Injector small pulsewidths (9-16)"
#endif
        subMenu = inj_timing_tbl,  "Injector Timing Table", 0, { sequential != 0 }
        subMenu = inj_timing_sec_tbl, "Secondary Injector Timing Table", 0, { sequential != 0 && (dualfuel_sw_on || staged_first_param) }
    	subMenu = stagedCombined,  "Staged Injection"
        subMenu = flexFuelSettings,"Fuel Sensor settings (Flex)"
        subMenu = std_separator
        subMenu = egoControl,      "AFR/&EGO Control"
#if CYL_12_16_SUPPORT
        subMenu = egocont9_16, "AFR/EGO (9-16)"
#endif
        subMenu = afrTable1Tbl,    "A&FR Table 1",         0
        subMenu = afrTable2Tbl,    "AF&R Table 2",         0, { (!dualfuel_sw_on && tsw_pin_afr) || (dualfuel_sw_on && dualfuel_sw_afr) || ( N2Oopt_2 && N2Oopt_4) }

        subMenu = narrowband_tgts_tbl, "Narrowband EGO targets", 0, { egoType == 1 }
        subMenu = maxafr, "AFR safety system"
        subMenu = std_separator
        subMenu = veTable1Tbl,     "Fuel VE Table &1", 0, { ((algorithm != 5) || ((algorithm == 5) && (feature7_maftrim))) }
        subMenu = veTable2Tbl,     "Fuel VE Table &2",          0, { (algorithm2 != 0) }
        subMenu = veTable3Tbl,     "Fuel VE Table 3", 0, { ((algorithm != 5) || ((algorithm == 5) && (feature7_maftrim))) && ((!dualfuel_sw_on && f5_0_tsf) || (dualfuel_sw_on && dualfuel_sw_fuel) || (dualfuel_sw_on && dualfuel_opt_mode)) }
        subMenu = veTable4Tbl,     "Fuel VE Table 4", 0, { (algorithm2 != 0) && ((!dualfuel_sw_on && f5_0_tsf) || (dualfuel_sw_on && dualfuel_sw_fuel) || (dualfuel_sw_on && dualfuel_opt_mode)) }
        subMenu = std_separator
        subMenu = tablesw,         "Table Switch/Dual Fuel"
        subMenu = dualfuel_temp_curve, "Temperature adjustment",   0, { (dualfuel_sw_on && dualfuel_opt_temp) }
        subMenu = dualfuel_press_curve, "Pressure adjustment",   0, { (dualfuel_sw_on && dualfuel_opt_press) }
        subMenu = injsettings2,   "Alt. Injector Dead-time/PWM 2",    0, { (dualfuel_sw_on && dualfuel_sw2_injp) || staged_first_param }
        subMenu = injsettingsb2,   "Alt. Injector Dead-time/PWM 2 (9-16)",    0, { (dualfuel_sw_on && dualfuel_sw2_injp) || staged_first_param }
        subMenu = smallpw2, "Alt. Injector small pulsewidths 2",   0, { (dualfuel_sw_on && dualfuel_sw2_smpw) || staged_first_param }
        subMenu = smallpw2b, "Alt. Injector small pulsewidths 2 (9-16)",   0, { (dualfuel_sw_on && dualfuel_sw2_smpw) || staged_first_param }

        subMenu = std_separator

        subMenu = inj_trim1Tbl, "Injector 1 Trim", 7, { (hardware_fuel==0) && sequential_trim_on_off }
        subMenu = inj_trim2Tbl, "Injector 2 Trim", 7, { (hardware_fuel==0) && sequential_trim_on_off }
        subMenu = inj_trimad, "Cyl 1-4 Trims", 7, { hardware_fuel && sequential_trim_on_off }
        subMenu = inj_trimeh, "Cyl 5-8 Trims", 7, { hardware_fuel && (nInjectors > 4) && sequential_trim_on_off }
#if CYL_12_16_SUPPORT
        subMenu = inj_trimil, "Cyl 9-12 Trims", 7, { hardware_fuel && (nInjectors > 8) && sequential_trim_on_off }
        subMenu = inj_trimmp, "Cyl 13-16 Trims", 7, { hardware_fuel && (nInjectors > 12) && sequential_trim_on_off }
#endif

      menu = "&Ignition Settings"
        subMenu = combinedignition, "Ignition Options/Wheel Decoder"
        subMenu = std_separator
        subMenu = dwellSettings,   "D&well battery correction", 0, { spk_mode0 != 31 }
        subMenu = dwellrpm_curve,  "Dwell vs rpm", 0, {spk_mode0 > 1 && dwellmode == 2 && spk_conf2_dwell}
        subMenu = std_separator
        subMenu = coldAdvance,     "&Cold Advance", 0, { spk_mode0 != 31 }
        subMenu = matBasedRetard,  "MAT-&Based Timing Retard", 0, { spk_mode0 != 31 }
        subMenu = std_separator
        subMenu = noisefiltering2,  "Noise Filtering", 0
        subMenu = knockSettings,   "&Knock Sensor Settings"
        subMenu = knockSettings4,  "Knock Sensor Parameters", 0, {knk_option && (knk_option_an == 3)}
        subMenu = knockSettings2,   "Knock Window Settings", 0, {knk_option}
        subMenu = knockupscale_curve, "Knock Coolant Scaling", 0, {knk_option}
        subMenu = std_separator
        subMenu = ignitionTbl1,     "&Ignition Table 1", 0, { (spk_mode0 != 31) }
        subMenu = ignitionTbl2,     "Ignition Table 2", 0, { (IgnAlgorithm2 !=0) && (spk_mode0 != 31)}
        subMenu = ignitionTbl3,     "Ignition Table 3", 0, { (!dualfuel_sw_on && f5_0_tss) || (dualfuel_sw_on && dualfuel_sw_spk) }
        subMenu = ignitionTbl4,     "Ignition Table 4", 0, { (IgnAlgorithm2 !=0) && ((!dualfuel_sw_on && f5_0_tss) || (dualfuel_sw_on && dualfuel_sw_spk)) }
        subMenu = std_separator
        subMenu = RotaryTrailingSettings, "Rotary Settings", 0, { (spk_mode0 != 31) }
        subMenu = RotarySplitTbl,  "Rotary Split Table", 0, { (twoStroke == 3) && (spk_mode0 != 31) }
        subMenu = std_separator
        subMenu = spk_trimad, "Cyl 1-4 Trims", 8, { spk_mode3_trim }
        subMenu = spk_trimeh, "Cyl 5-8 Trims", 8, { spk_mode3_trim && (nCylinders > 4)}
#if CYL_12_16_SUPPORT
        subMenu = spk_trimil, "Cyl 9-12 Trims", 8, { spk_mode3_trim && (nCylinders > 8)}
        subMenu = spk_trimmp, "Cyl 13-16 Trims", 8, { spk_mode3_trim && (nCylinders > 12)}
#endif
      menu = "&Startup/Idle"
        subMenu = crsettings,      "Cranking/startup settings",  0
        subMenu = primingPW,       "Pri&ming Pulse",       0
        subMenu = primingPW2,       "Pri&ming Pulse 2",       0, { (dualfuel_sw_on && dualfuel_sw2_prime) }
        subMenu = crankingPW,      "Cra&nking Pulse",      0
        subMenu = crankingPW2,      "Cra&nking Pulse 2",      0, { (dualfuel_sw_on && dualfuel_sw2_crank) }
        subMenu = asePct,          "A&SE Percentage",      0
        subMenu = asePct2,          "A&SE Percentage 2",      0, { (dualfuel_sw_on && dualfuel_sw_ase) }
        subMenu = aseTaper,        "AS&E Taper",           0
        subMenu = aseTaper2,        "AS&E Taper 2",           0, { (dualfuel_sw_on && dualfuel_sw_ase) }
        subMenu = warmup_curve,      "&Warmup Enrichment",       0
        subMenu = warmup_curve2,    "&Warmup Enrichment 2",   0, { (dualfuel_sw_on && dualfuel_sw_wue) }

        subMenu = std_separator
        subMenu = combinedidle,     "I&dle Control"
        subMenu = pwmidle_crank_dutyorsteps_dutycurve, "PWM idle cranking duty", 0, {IdleCtl == 4 || IdleCtl == 6}
        subMenu = pwmidle_crank_dutyorsteps_stepscurve, "IAC idle cranking steps", 0, {IdleCtl == 2 || IdleCtl == 3 || IdleCtl == 5 || IdleCtl == 7 || IdleCtl == 8}
        subMenu = iacBins,         "I&dle Steps",          0, { IdleCtl == 2 || IdleCtl == 3 || IdleCtl == 5 }
        subMenu = ipwBins,         "I&dle PWM duty Table",0, { IdleCtl == 4 }
        subMenu = combinedCLidle, "Closed-loop idle settings", 0, { IdleCtl == 6 || IdleCtl == 7 || IdleCtl == 8 }
        subMenu = pwmidle_target_curve, "Closed-loop idle target curve", 0, { IdleCtl == 6 || IdleCtl == 7 || IdleCtl == 8 || idle_special_ops_timing_assist } 
        subMenu = pwmidle_cl_initialvalues_dty, "Closed-loop idle initial values (duty)", 0, { pwmidle_cl_opts_initvaluetable && IdleCtl == 6 }
        subMenu = pwmidle_cl_initialvalues_stps, "Closed-loop idle initial values (steps)", 0, { pwmidle_cl_opts_initvaluetable && (IdleCtl == 7 || IdleCtl == 8) }
        subMenu = idle_voltage_comp_curve, "PWM idle voltage compensation", 0, { IdleCtl == 4 || IdleCtl == 6 }
        subMenu = ac_idleup,        "Air Conditioning Idleup", 0
        subMenu = std_separator
        subMenu = idleAdvance,  "Idle Advance Settings"
        subMenu = cl_idle_timing_curve, "Idle RPM Timing Correction Curve", 0, { idle_special_ops_timing_assist }
        subMenu = idleVe,       "Idle VE Settings"

      menu = "Accel Enrich"
         subMenu = accelsettings,   "Accel Enrich settings"
         subMenu = new_AE_settings, "New Accel-pump accel enrichment settings",0, { AE_options & 0x1 } 
         subMenu = std_accel,       "&Acceleration Wizard",0, { !(AE_options & 0x1) }
         subMenu = std_separator
         subMenu = EAEBAWCcurve,   "EAE Adhere-to-walls coefficient", 0, { EAEOption == 1 || EAEOption == 2 }
	 subMenu = EAEBSOCcurve,   "EAE Sucked-from-walls coefficient", 0, { EAEOption == 1 || EAEOption == 2 }
	 subMenu = EAEAWNcurve,   "EAE Adhere-to-walls rpm correction", 0, { EAEOption == 1  || EAEOption == 2 }
	 subMenu = EAESONcurve,   "EAE Sucked-from-walls rpm correction", 0, { EAEOption == 1 || EAEOption == 2 }
         subMenu = EAEAWWcurve,   "EAE Adhere-to-walls CLT correction", 0, { EAEOption == 1 || EAEOption == 2 }
         subMenu = EAESOWcurve,   "EAE Sucked-from-walls CLT correction", 0, { EAEOption == 1 || EAEOption == 2 }
	 subMenu = EAElagcomp,    "EAE lag compensation settings", 0, {EAEOption == 2}
;         subMenu = combineEAE,    "Combined EAE Curves", 0,  { EAEOption  == 1 || EAEOption == 2 }
;         subMenu = std_separator
;         subMenu = EAEmanycurves,    "Combined EAE Curves", 0,  { EAEOption  == 1 || EAEOption == 2 }
         subMenu = std_separator
         subMenu = EAEBAWCcurve2,   "EAE Adhere-to-walls coefficient 2", 0, { (EAEOption == 1 || EAEOption == 2) && (staged_first_param ) }
	 subMenu = EAEBSOCcurve2,   "EAE Sucked-from-walls coefficient 2", 0, { (EAEOption == 1 || EAEOption == 2) && (staged_first_param ) }
	 subMenu = EAEAWNcurve2,   "EAE Adhere-to-walls rpm correction 2", 0, { (EAEOption == 1  || EAEOption == 2) && (staged_first_param ) }
	 subMenu = EAESONcurve2,   "EAE Sucked-from-walls rpm correction 2", 0, { (EAEOption == 1 || EAEOption == 2) && (staged_first_param ) }
         subMenu = EAEAWWcurve2,   "EAE Adhere-to-walls CLT correction 2", 0, { (EAEOption == 1 || EAEOption == 2) && (staged_first_param ) }
         subMenu = EAESOWcurve2,   "EAE Sucked-from-walls CLT correction 2", 0, { (EAEOption == 1 || EAEOption == 2) && (staged_first_param ) }
         subMenu = std_separator
         subMenu = XAccTable,     "Puddling Factors (&accel)",  0, { EAEOption == 3 || EAEOption == 4 }
         subMenu = XDecTable,       "Puddling Factors (&decel)",      0, { EAEOption == 3 || EAEOption == 4 }
         subMenu = TauAccTable,     "Time Factors (a&ccel)",          0, { EAEOption == 3 || EAEOption == 4 }
         subMenu = TauDecTable,     "Time Factors (d&ecel)",          0, { EAEOption == 3 || EAEOption == 4 }
         subMenu = XCltTable,       "&X (Puddling) Temp. Corrections",0, { EAEOption == 4 }    

         subMenu = TCltTable,       "&Tau (Time) Temp. Corrections",  0, { EAEOption == 4 }
         subMenu = xTauSettings,    "&MAPdot Settings",               0, { EAEOption == 3 || EAEOption == 4 }    

      menu = "Advanced Engine"
        subMenu = ms3_port_edit,   "Spare &Output port Settings"
        subMenu = std_separator
        subMenu = boost, "Boost Control Settings"
        subMenu = boostctlDutys, "Boost Control Duty Table", 0, { (boost_ctl_settings_on) && (!boost_ctl_settings_cl)}
        subMenu = boostctlTargs, "Boost Control Target Table", 0, { (boost_ctl_settings_on == 1) && (boost_ctl_settings_cl == 1) }
        subMenu = boostctlDutys2, "Boost Control Duty Table 2", 0, { boost_ctl_settings_on && (((!boost_ctl_settings_cl) && (boost_feats_tsw || dualfuel_sw2_boosw)) || (boost_ctl_settings_on2 && !boost_ctl_settings_cl2)) }
        subMenu = boostctlTargs2, "Boost Control Target Table 2", 0, { boost_ctl_settings_on && ((boost_ctl_settings_cl && (boost_feats_tsw || dualfuel_sw2_boosw)) || (boost_ctl_settings_on2 && boost_ctl_settings_cl2)) }
        subMenu = boost_timed_curve, "Boost delay",0, { boost_ctl_settings_on && launch_opt_on && boost_feats_timed }
        subMenu = boostvss_duty_curve, "Boost Control vs Speed", 0, { (boost_ctl_settings_on) && (!boost_ctl_settings_cl) && boost_vss}
        subMenu = boostvss_target_curve, "Boost Control vs Speed", 0, { (boost_ctl_settings_on) && (boost_ctl_settings_cl)&& boost_vss}
        subMenu = boostctlSettings2, "Boost 2 Control Settings", 0 , {boost_ctl_settings_on}
        subMenu = std_separator
        subMenu = vvtparams, "VVT Settings"
        subMenu = vvt_timing1_tbl, "VVT intake table", 0, {vvt_opt1_on && vvt_opt2_pid}
        subMenu = vvt_timing2_tbl, "VVT exhaust table", 0, {(vvt_opt1_on > 1) && vvt_opt2_pid && (vvt_opt5_vvt1 || vvt_opt5_vvt2 || vvt_opt1_on > 2)}
        subMenu = pwm_duties_Tbl_vvt, "VVT on/off table", 0, {vvt_opt1_on && !vvt_opt2_pid}
        subMenu = std_separator
        subMenu = manifoldTempCorr,"MAT Correction table", 0, {feature7_mafmat || ((algorithm != 4) && (algorithm != 5) && (algorithm2 != 4) && (algorithm2 != 5))}
        subMenu = MATCorrval,      "MAT Correction value", 0,  {(algorithm != 4) && (algorithm != 5) && (algorithm2 != 4) && (algorithm2 != 5)}
        subMenu = matclt_curve,   "MAT/CLT correction", 0, {(algorithm != 4) && (algorithm != 5) && (algorithm2 != 4) && (algorithm2 != 5)}
        subMenu = std_separator
        subMenu = injseq, "MS2/extra 2.x semi-seq settings", 0, { sequential == 0 }

      menu = "Advanced Engine 2"
        subMenu = speedsensors, "Speed and gear Sensors"
        subMenu = egt, "EGT/Thermocouple settings"
        subMenu = sensors, "Generic Sensor inputs"
        subMenu = accelerometer, "Accelerometer parameters"
        subMenu = tcsettings, "Traction Control Settings"

        subMenu = tc_perfect_curve, "Perfect Run", 0, {tc_opt_on && (tc_opt_method == 0)}
        subMenu = tc_curves, "Traction Control Reactions", 0, {tc_opt_on}
        subMenu = std_separator
        subMenu = launch,          "Launch / 2-step / 3-step"
        subMenu = launch_retard_time, "Timed retard after launch", 0, {launch_opt_on && launch_opt_retard}
        subMenu = antilag,      "Turbo anti-lag (ALS)"
        subMenu = antilagtables,  "Turbo anti-lag tables", 0, {als_in_pin}
        subMenu = als_rifuelcut_tbl, "Turbo anti-lag Roving Idle", 0, {als_in_pin && als_opt_ri && hardware_fuel && sequential}
        subMenu = ShiftSettings, "Bike shift cut"
        subMenu = nitrous,    "&Nitrous System"
        subMenu = nitrous_curves_time,    "Nitrous - Time-based Progressive",0, {N2Oopt_2 && N2Oopt2_prog && N2Oopt2_prog_time}
        subMenu = nitrous_curves_rpm,    "Nitrous - RPM-based Progressive", 0, {N2Oopt_2 && N2Oopt2_prog && !N2Oopt2_prog_time}
        subMenu = waterinj,        "Water Injection"
        subMenu = std_separator
        subMenu = gen_pwm_a, "Generic PWM output A"
        subMenu = gen_pwm_b, "Generic PWM output B"
        subMenu = gen_pwm_c, "Generic PWM output C"
        subMenu = gen_pwm_d, "Generic PWM output D"
        subMenu = gen_pwm_e, "Generic PWM output E", 0, {!(vvt_opt1_on)}
        subMenu = gen_pwm_f, "Generic PWM output F", 0, {!(als_in_pin && als_opt_pwmout)}
      
;      subMenu = userdefined, "User defined menu" ; uncomment this line to enable

   menuDialog = main
      menu = "3D &Tuning Maps"
         subMenu = veTable1Map,     "Fuel VE Table &1",0, { (algorithm != 5) }
         subMenu = veTable2Map,     "Fuel VE Table &2",          0, { (algorithm2 != 0) && (algorithm2 != 5) }
         subMenu = veTable3Map,     "Fuel VE Table &3",          0, { (!dualfuel_sw_on && f5_0_tsf) || (dualfuel_sw_on && dualfuel_sw_fuel) || (dualfuel_sw_on && dualfuel_opt_mode) }
         subMenu = veTable4Map,     "Fuel VE Table &4",          0, { ((!dualfuel_sw_on && f5_0_tsf) || (dualfuel_sw_on && dualfuel_sw_fuel) || (dualfuel_sw_on && dualfuel_opt_mode)) && (algorithm2 != 0) }

         subMenu = afrTable1Map,    "A&FR Table 1",         0, { egoType > 1              }
         subMenu = afrTable2Map,    "AF&R Table 2",         0, { (egoType > 1) && ((!dualfuel_sw_on && tsw_pin_afr) || (dualfuel_sw_on && dualfuel_sw_afr)) }
         subMenu = std_separator    ;----------------------------------------------
         subMenu = ignitionMap1,     "&Ignition Map1", 0, {(spk_mode0 != 31)}
         subMenu = ignitionMap2,     "Ignition Map2", 0, { (IgnAlgorithm2 != 0) && (spk_mode0 != 31)}
         subMenu = ignitionMap3,     "Ignition Map3", 0, { (!dualfuel_sw_on && f5_0_tss) || (dualfuel_sw_on && dualfuel_sw_fuel) }
         subMenu = ignitionMap4,     "Ignition Map4", 0, { (!dualfuel_sw_on && f5_0_tss) || (dualfuel_sw_on && dualfuel_sw_fuel) }
	 subMenu = RotarySplitMap,   "Rotary Split Map", 0, {(twoStroke == 3) && (spk_mode0 != 31)}
	 subMenu = std_separator    ;----------------------------------------------
	 subMenu = boostctlDtyMap,   "Boost Control Duty Map", 0, {boost_ctl_settings_on && boost_ctl_settings_cl == 0}
	 subMenu = boostctlTargMap,  "Boost Control Target Map", 0, {boost_ctl_settings_on && boost_ctl_settings_cl}
	 subMenu = boostctlDtyMap2,   "Boost Control Duty Map 2", 0, {boost_ctl_settings_on && boost_ctl_settings_cl == 0}
	 subMenu = boostctlTargMap2,  "Boost Control Target Map 2", 0, {boost_ctl_settings_on && boost_ctl_settings_cl}
         subMenu = std_separator
         subMenu = inj_timing_map,  "Sequential Injector Timing Map", 0, { sequential != 0 }
         subMenu = inj_timing_sec_map, "Sequential Injector Secondary Timing Map", 0, { sequential != 0 && (dualfuel_sw_on || staged_first_param) }

       menu = "C&AN bus/Testmodes"
         subMenu = canparams, "CAN parameters"
         subMenu = canbroadcast, "CAN broadcasting"
         subMenu = canvss, "CAN VSS, gear"
         subMenu = realtimeclock, "Real time clock"
         subMenu = std_separator    ;----------------------------------------------
         subMenu = codetest, "Code development"
         subMenu = outputtest, "Output test mode"
         subMenu = iactest, "Idle valve test"

   menuDialog = main
      menu = "T&ools"

         subMenu = sensorCal,       "Calibrate MAP/Baro"
         subMenu = battcalib,       "Calibrate Battery Voltage"
         subMenu = std_separator    ;----------------------------------------------
         subMenu = flash_unlock, "Un/Lock calibrations"
         subMenu = std_ms2gentherm, "Calibrate T&hermistor Tables", 0, {flashlock}
         subMenu = std_ms2geno2,    "Calibrate &AFR Table", 0, {flashlock}
          subMenu = mafTableBurner,  "Calibrate &MAF Table", 0, {flashlock}
         subMenu = std_separator    ;----------------------------------------------
         subMenu = std_trigwiz,     "Tri&gger Wizard", 0,{ (spk_mode0 != 31) && (spk_mode0 != 4) }

      menu = "Data Logging"
          subMenu = sdcard_datalog, "SD Card Datalogging"
          subMenu = std_ms3SdConsole, "Browse / Import SD Card"

      menu = "Communications"
         subMenu = setbaud, "Megasquirt baud rate", 0

      menu = "Help"
         subMenu = helpGeneral,     "Megasquirt 3 Info"
;         subMenu = sensorHelp,      "Sensor Calibration"
;-------------------------------------------------------------------------------

[VerbiageOverride]
; text over-rides for internal TS dialogs.
; Not all dialogs support this yet, let Phil Tobin know if you need a specific one.
; Requires 0.999.9h upwards
"Engine Stroke" = "Engine Stroke/Rotary"
"Number of Cylinders" = "No. Cylinders/Rotors" 

[UserDefined]
    dialog = limitsettings, "Limit settings"
        field = "These are the limits for gauges and tuning settings"
        field = "they do not alter engine behaviour"
        field = "rpm - max", rpmhigh
        field = "rpm - warn level", rpmwarn
        field = "rpm - danger level", rpmdang
        field = "load/kPa - max", loadhigh

    dialog = iopinlist, "Pin I/O / Option List"
        displayOnlyField = "Main fuel outputs",               hardware_fuel
        displayOnlyField = "Inj1, Inj2", hardware_fuel, {hardware_fuel== 0}
        displayOnlyField = "MS3X InjA, InjB etc.", hardware_fuel, {hardware_fuel}
        displayOnlyField = "Spark hardware in use", hardware_spk
        displayOnlyField = "LED D14, D16, D15, JS11 etc.", hardware_spk, {hardware_spk== 0}
        displayOnlyField = "MS3X SpkA, SpkB etc.", hardware_spk, {hardware_spk}
        displayOnlyField = "Cam input (if used)", hardware_cam
        displayOnlyField = "Tertiary tach input", spk_mode3_tach3, {spk_mode0 == 47}
        displayOnlyField = "(** Spare ports not shown **)"
        displayOnlyField = "EGO 1 port", egoport1
        displayOnlyField = "EGO 2 port", egoport2, {egonum > 1}
        displayOnlyField = "EGO 3 port", egoport3, {egonum > 2}
        displayOnlyField = "EGO 4 port", egoport4, {egonum > 3}
        displayOnlyField = "EGO 5 port", egoport5, {egonum > 4}
        displayOnlyField = "EGO 6 port", egoport6, {egonum > 5}
        displayOnlyField = "EGO 7 port", egoport7, {egonum > 6}
        displayOnlyField = "EGO 8 port", egoport8, {egonum > 7}
#ifdef CYL_12_16_SUPPORT
        displayOnlyField = "EGO 9 port",  egoport9,  {egonum > 8}
        displayOnlyField = "EGO 10 port", egoport10, {egonum > 9}
        displayOnlyField = "EGO 11 port", egoport11, {egonum > 10}
        displayOnlyField = "EGO 12 port", egoport12, {egonum > 11}
        displayOnlyField = "EGO 13 port", egoport13, {egonum > 12}
        displayOnlyField = "EGO 14 port", egoport14, {egonum > 13}
        displayOnlyField = "EGO 15 port", egoport15, {egonum > 14}
        displayOnlyField = "EGO 16 port", egoport16, {egonum > 15}
#endif
        displayOnlyField = "PWM Idle Output", pwmidle_freq_pin, { (IdleCtl == 1) || (IdleCtl == 4) || (IdleCtl == 6) }
        displayOnlyField = "PWM idle 3 wire mode", pwmidle_freq_pin3, { ((IdleCtl == 4) || (IdleCtl == 6)) && pwmidle_freq_pin3 }
        displayOnlyField = "Fan control Output", fanctl_settings_pin, { fanctl_settings_on }
        displayOnlyField = "AC Idleup Output", ac_idleup_io_out, { ac_idleup_settings && ac_idleup_io_out }
        displayOnlyField = "AC Idleup Input", ac_idleup_io_in, { ac_idleup_settings }
        displayOnlyField = "Realtime baro port",    rtbaroport, {baroCorr == 2}
        displayOnlyField = "MAP Voltage input", mapport, {mapport_t == 0}
        displayOnlyField = "MAP Frequency input", mapport_f, {mapport_t == 1}
        displayOnlyField = "MAP 2nd port",    map2port, {mapport_t == 0}
        displayOnlyField = "MAF Voltage input", MAFOption, {(MAFOption_t == 0) && MAFOption}
        displayOnlyField = "MAF Frequency input", MAFOption_f, {(MAFOption_t == 1) && MAFOption}
        displayOnlyField = "Flex Sensor port",              flexport,    { flexFuel > 0 }
        displayOnlyField = "Flex Temperature input",        fueltemp1, {fueltemp1}
        displayOnlyField = "Tacho Output",  tacho_opt3f, { tacho_opt80 }
        displayOnlyField = "AC Idleup Output", ac_idleup_io_out, { ac_idleup_settings }
        displayOnlyField = "VVT1 output",       vvt_out1,       {vvt_opt1_on}
        displayOnlyField = "VVT2 output",       vvt_out2,       {vvt_opt1_on > 1}
        displayOnlyField = "VVT3 output",       vvt_out3,       {vvt_opt1_on > 2}
        displayOnlyField = "VVT4 output",       vvt_out4,       {vvt_opt1_on > 3}
        displayOnlyField = "VVT1 input",       vvt_opt3_cam1,       {0}
        displayOnlyField = "VVT2 input",       vvt_opt3_cam2,       {vvt_opt1_on > 1}
        displayOnlyField = "VVT3 input",       vvt_opt3_cam3,       {vvt_opt1_on > 2}
        displayOnlyField = "VVT4 input",       vvt_opt3_cam4,       {vvt_opt1_on > 3}
        displayOnlyField = "Fuel Table Switching Input", tsw_pin_f, { f5_0_tsf && (f5_0_tsf_opt == 0) && !(dualfuel_sw_on && dualfuel_sw_fuel)}
        displayOnlyField = "Spark Table Switching Input", tsw_pin_s, { f5_0_tss && (f5_0_tss_opt == 0) }
        displayOnlyField = "Req Fuel Switching", tsw_pin_rf, { !(dualfuel_sw_on && dualfuel_sw_rf)}
        displayOnlyField = "AFR table Switching", tsw_pin_afr, { !(dualfuel_sw_on && dualfuel_sw_afr)}
        displayOnlyField = "Stoich Switching", tsw_pin_stoich, { !(dualfuel_sw_on && dualfuel_sw_stoich)}


        displayOnlyField = "Dual fuel Input", dualfuel_pin, { dualfuel_sw_on && !dualfuel_opt_mode }
        displayOnlyField = "Knock input pin",      knkport, { knk_option && !knk_option_an }
        displayOnlyField = "Internal knock module uses D14,D15,D16,JS11,PM2", knk_option_an, {(knk_option_an == 2)}
        displayOnlyField = "Overboost switching", tsw_pin_ob, { OverBoostOption > 0 }
        displayOnlyField = "Boost Table Switching", boost_feats_tsw, {boost_ctl_settings_on}
        displayOnlyField = "Boost Control output (high,mid)",     boost_ctl_pins_pwm, {boost_ctl_settings_on && (boost_ctl_pwm < 2)}
        displayOnlyField = "Boost Control output (slow)",                boost_ctl_pins, {boost_ctl_settings_on && (boost_ctl_pwm == 2)}
        displayOnlyField = "Boost Control2 output (high,mid)",     boost_ctl_pins_pwm2, {boost_ctl_settings_on && boost_ctl_settings_on2 && (boost_ctl_pwm < 2)}
        displayOnlyField = "Boost Control2 output (slow)",         boost_ctl_pins2, {boost_ctl_settings_on && boost_ctl_settings_on2 && (boost_ctl_pwm == 2)}
        displayOnlyField = "Gen PWM A output", pwm_opt2_a, {pwm_opt_on_a}
        displayOnlyField = "Gen PWM B output", pwm_opt2_b, {pwm_opt_on_b}
        displayOnlyField = "Gen PWM C output", pwm_opt2_c, {pwm_opt_on_c}
        displayOnlyField = "Gen PWM D output", pwm_opt2_d, {pwm_opt_on_d}
        displayOnlyField = "Gen PWM E output", pwm_opt2_e, {pwm_opt_on_e}
        displayOnlyField = "Gen PWM F output", pwm_opt2_f, {pwm_opt_on_f}
        displayOnlyField = "Generic Sensor 01 Input", sensor01_source
        displayOnlyField = "Generic Sensor 02 Input", sensor02_source
        displayOnlyField = "Generic Sensor 03 Input", sensor03_source
        displayOnlyField = "Generic Sensor 04 Input", sensor04_source
        displayOnlyField = "Generic Sensor 05 Input", sensor05_source
        displayOnlyField = "Generic Sensor 06 Input", sensor06_source
        displayOnlyField = "Generic Sensor 07 Input", sensor07_source
        displayOnlyField = "Generic Sensor 08 Input", sensor08_source
        displayOnlyField = "Generic Sensor 09 Input", sensor09_source
        displayOnlyField = "Generic Sensor 10 Input", sensor10_source
        displayOnlyField = "Generic Sensor 11 Input", sensor11_source
        displayOnlyField = "Generic Sensor 12 Input", sensor12_source
        displayOnlyField = "Generic Sensor 13 Input", sensor13_source
        displayOnlyField = "Generic Sensor 14 Input", sensor14_source
        displayOnlyField = "Generic Sensor 15 Input", sensor15_source
        displayOnlyField = "Generic Sensor 16 Input", sensor16_source
        displayOnlyField = "WI Pump output", water_pins_pump, {water_freq_on}
        displayOnlyField = "WI Valve output", water_pins_valve, {water_freq_on && water_freq_type}
        displayOnlyField = "VSS1 Analogue sensor", vss1_an
        displayOnlyField = "VSS1 digi Input", vss_opt1, {!vss1_an}
        displayOnlyField = "VSS1 CAN PWM port", vss1_pwmseq, {vss_opt1 ==15 && !vss1_an}
        displayOnlyField = "VSS2 Analogue sensor", vss1_an
        displayOnlyField = "VSS2 digi Input", vss_opt1, {!vss1_an}
        displayOnlyField = "VSS2 CAN PWM port", vss1_pwmseq, {vss_opt1 ==15 && !vss1_an}
        displayOnlyField = "Shaft Sensor 1", ss_opt1
        displayOnlyField = "Shaft Sensor 2", ss_opt2
        displayOnlyField = "VSS output", vssout_opt
        displayOnlyField = "Gear pos. Input", gear_port_an, { (gear_method == 2) }
        displayOnlyField = "Bike Shifter input", shift_cut_in, { shift_cut_on }
        displayOnlyField = "Bike Shifter output", shift_cut_out, { shift_cut_on }
        displayOnlyField = "Accelerometer X input", accXport
        displayOnlyField = "Accelerometer Y input", accYport
        displayOnlyField = "Accelerometer Z input", accZport
        displayOnlyField = "SDcard Datalog button", log_style2_but, {log_style_on > 1}
        displayOnlyField = "SDcard LED indicator", log_style_led, {log_style_on}
        displayOnlyField = "SDcard Stream input", log_style3_adc, {log_style_block == 1}
        displayOnlyField = "Nitrous Stage 1 output - nitrous",           n2o1n_pins,     { N2Oopt_2 }
        displayOnlyField = "Nitrous Stage 1 output - fuel",              n2o1f_pins,     { N2Oopt_2 }
        displayOnlyField = "Nitrous Enable input on:",                   N2Oopt_pins,    { N2Oopt_2 }
        displayOnlyField = "Nitrous Stage 2 output - nitrous",           n2o2n_pins,     { N2Oopt_2 && N2Oopt_3 }
        displayOnlyField = "Nitrous Stage 2 output - fuel",              n2o2f_pins,     { N2Oopt_2 && N2Oopt_3 }
        displayOnlyField = "AFR safety Warning output", maxafr_opt1_led, { maxafr_opt1_on || egt_conf_action }
        displayOnlyField = "EGT 1 channel",  egt1port, { (egt_num > 0) }
        displayOnlyField = "EGT 2 channel",  egt2port, { (egt_num > 1) }
        displayOnlyField = "EGT 3 channel",  egt3port, { (egt_num > 2) }
        displayOnlyField = "EGT 4 channel",  egt4port, { (egt_num > 3) }
        displayOnlyField = "EGT 5 channel",  egt5port, { (egt_num > 4) }
        displayOnlyField = "EGT 6 channel",  egt6port, { (egt_num > 5) }
        displayOnlyField = "EGT 7 channel",  egt7port, { (egt_num > 6) }
        displayOnlyField = "EGT 8 channel",  egt8port, { (egt_num > 7) }
        displayOnlyField = "EGT 9 channel",  egt9port, { (egt_num > 8) }
        displayOnlyField = "EGT 10 channel", egt10port, { (egt_num > 9) }
        displayOnlyField = "EGT 11 channel", egt11port, { (egt_num > 10) }
        displayOnlyField = "EGT 12 channel", egt12port, { (egt_num > 11) }
        displayOnlyField = "EGT 13 channel", egt13port, { (egt_num > 12) }
        displayOnlyField = "EGT 14 channel", egt14port, { (egt_num > 13) }
        displayOnlyField = "EGT 15 channel", egt15port, { (egt_num > 14) }
        displayOnlyField = "EGT 16 channel", egt16port, { (egt_num > 15) }
        displayOnlyField = "Internal RTC uses PM1 and PM3", opt142_rtc, {opt142_rtc == 1}
        displayOnlyField = "Launch Input",  launch_opt_pins, { launch_opt_on >0 }
        displayOnlyField = "Variable launch input",        launch_var_on, { launch_opt_on >0 }
        displayOnlyField = "3-step input", launch_3step_in, {launch_opt_on >0 }
        displayOnlyField = "Anti-lag enable input",        als_in_pin
        displayOnlyField = "ALS On/off output",                als_out_pin, {als_in_pin}
        displayOnlyField = "ALS PWM output",   als_opt_pwmout, {als_in_pin}
        displayOnlyField = "ALS Output",              pwm_opt2_f, {als_in_pin && als_opt_pwmout}
        displayOnlyField = "Torque convertor lockup", tclu_outpin
        displayOnlyField = "TCLU Enable input", tclu_enablepin, {tclu_outpin}
        displayOnlyField = "TCLU Brake switch", tclu_brakepin, {tclu_outpin}


    dialog = tcsettings, "Traction Control"
        field = "Traction control", tc_opt_on
        field = "Method", tc_opt_method, {tc_opt_on}
        field = "Enable input", tc_enin, {tc_opt_on}
        field = "Minimum TPS", tc_mintps, {tc_opt_on}
        field = "Minimum MAP", tc_minmap, {tc_opt_on && (tc_opt_method == 1)}
        field = "Minimum VSS", tc_minvss, {tc_opt_on }
        field = "VSS1 = driven, VSS2 = undriven wheels"
;        field = "Maximum VSS", tc_maxvss, {tc_opt_on }
        field = "Slip threshold", tc_slipthresh, {tc_opt_on && (tc_opt_method == 1)}
        field = "Nitrous control", tc_opt_n2o, {tc_opt_on }
        field = "Add fuel to:", tc_opt_bank, {tc_opt_on }
        field = "When staging bank 1 = primary, bank 2 = secondary"

    dialog = tc_top, "", xAxis
        panel = tc_retard_curve
        panel = tc_spkcut_curve

    dialog = tc_btm, "", xAxis
        panel = tc_addfuel_curve
        panel = tc_nitrous_curve

    dialog = tc_curves, "Traction Control Reactions", yAxis
        panel = tc_top
        panel = tc_btm

    dialog = tcluparams, "Torque Convertor Lockup"
        field = "Output pin", tclu_outpin
        field = "Enable input", tclu_enablepin, {tclu_outpin}
        field = "Brake switch", tclu_brakepin, {tclu_outpin}
        field = "Minimum TPS", tclu_tpsmin, {tclu_outpin}
        field = "Maximum TPS", tclu_tpsmax, {tclu_outpin}
        field = "Minimum MAP", tclu_mapmin, {tclu_outpin}
        field = "Maximum MAP", tclu_mapmax, {tclu_outpin}
        field = "Use VSS", tclu_opt_vss, {tclu_outpin}
        field = "Minimum speed", tclu_vssmin, {tclu_outpin && tclu_opt_vss}
        field = "Use gear value", tclu_opt_gear, {tclu_outpin}
        field = "Minimum gear", tclu_gearmin, {tclu_outpin && tclu_opt_gear}
        field = "Activation delay", tclu_delay,  {tclu_outpin}


    dialog = vvtct, ""
        field = "."
        field = "Input"
        field = "Polarity"
        field = "No. Teeth"
        field = "Output"
        field = "Minimum"
        field = "Maximum"
        field = "Int./exh."
        field = "Tooth 1"
        field = "Tooth 2"

    dialog = vvtc1, ""
        field = "#CAM1"
        field = "",         vvt_opt3_cam1,  {vvt_opt1_on}
        field = "",         vvt_opt2_cam1pol, {vvt_opt1_on && ((spk_config_trig2l & 0x3) == 0x3) && (spk_mode0 == 4) && (spk_config_trig2 == 3) && (vvt_opt4_decode ==0 )}
        field = "",  vvt_tth1,       {(vvt_opt1_on > 0) && (spk_mode0 == 4)}
        field = "",       vvt_out1,       {vvt_opt1_on}
        field = "",   vvt_min_ang1,   {vvt_opt1_on && vvt_opt2_pid}
        field = "",   vvt_max_ang1,   {vvt_opt1_on && vvt_opt2_pid}
        field = "",   vvt_opt5_vvt1,   {vvt_opt1_on && vvt_opt2_pid}
        field = "",   vvt_cam1tth1, {vvt_opt4_decode == 1}
        field = "",   vvt_cam1tth2, {vvt_opt4_decode == 1}

    dialog = vvtc2, ""
        field = "#CAM2"
        field = "",         vvt_opt3_cam2,  {vvt_opt1_on > 1}
        field = "",      vvt_opt2_cam2pol, {vvt_opt1_on > 1}
        field = "",  vvt_tth2,       {(vvt_opt1_on > 1) && (spk_mode0 == 4)} 
        field = "",        vvt_out2,       {vvt_opt1_on > 1}
        field = "",   vvt_min_ang2,   {(vvt_opt1_on > 1) && vvt_opt2_pid}
        field = "",   vvt_max_ang2,   {(vvt_opt1_on > 1) && vvt_opt2_pid}
        field = "",   vvt_opt5_vvt2,   {vvt_opt1_on && vvt_opt2_pid}
        field = "",   vvt_cam2tth1, {0}
        field = "",   vvt_cam2tth2, {0}

    dialog = vvtc3, ""
        field = "#CAM3"
        field = "",         vvt_opt3_cam3,  {vvt_opt1_on > 2}
        field = "",      vvt_opt2_cam3pol, {vvt_opt1_on > 2}
        field = "",  vvt_tth3,       {(vvt_opt1_on > 2) && (spk_mode0 == 4)} 
        field = "",        vvt_out3,       {vvt_opt1_on > 2}
        field = "",   vvt_min_ang3,   {(vvt_opt1_on > 2) && vvt_opt2_pid}
        field = "",   vvt_max_ang3,   {(vvt_opt1_on > 2) && vvt_opt2_pid}
        field = "",   vvt_opt5_vvt3,   {vvt_opt1_on && vvt_opt2_pid}
        field = "",   vvt_cam3tth1, {vvt_opt4_decode == 1}
        field = "",   vvt_cam3tth2, {vvt_opt4_decode == 1}

    dialog = vvtc4, ""
        field = "#CAM4"
        field = "",         vvt_opt3_cam4,  {vvt_opt1_on > 2}
        field = "",      vvt_opt2_cam4pol, {vvt_opt1_on > 2}
        field = "",  vvt_tth4,       {(vvt_opt1_on > 2) && (spk_mode0 == 4)}
        field = "",       vvt_out4,       {vvt_opt1_on > 2}
        field = "",   vvt_min_ang4,   {(vvt_opt1_on > 2) && vvt_opt2_pid}
        field = "",   vvt_max_ang4,   {(vvt_opt1_on > 2) && vvt_opt2_pid}
        field = "",   vvt_opt5_vvt4,   {vvt_opt1_on && vvt_opt2_pid}
        field = "",   vvt_cam4tth1, {0}
        field = "",   vvt_cam4tth2, {0}

    dialog = vvtcams, "Cam settings", xAxis
        panel = vvtct
        panel = vvtc1
        panel = vvtc2
        panel = vvtc3
        panel = vvtc4

    dialog = vvtinext, ""
        field = "."
        field = "More duty means"
        field = "Use hold duty"
        field = "Hold/neutral duty"
        field = "Proportional Gain"
        field = "Integral Gain"
        field = "Differential Gain"

    dialog = vvtinexi, ""
        field = "#Intake"
        field = "", vvt_opt1_dir_intake,   {vvt_opt1_on && vvt_opt2_pid}
        field = "", vvt_opt2_use_hold_intake, {vvt_opt1_on && vvt_opt2_pid}
        field = "", vvt_hold_duty,  {vvt_opt1_on && vvt_opt2_pid && vvt_opt2_use_hold_intake}
        field = "", vvt_ctl_Kp,     {vvt_opt1_on && vvt_opt2_pid}
        field = "", vvt_ctl_Ki,     {vvt_opt1_on && vvt_opt2_pid}
        field = "", vvt_ctl_Kd,     {vvt_opt1_on && vvt_opt2_pid}

    dialog = vvtinexe, ""
        field = "#Exhaust"
        field = "", vvt_opt1_dir_exhaust,   { vvt_opt2_pid && (vvt_opt5_vvt1 || vvt_opt5_vvt2 || vvt_opt1_on > 2) }
        field = "", vvt_opt2_use_hold_exhaust, { vvt_opt2_pid && (vvt_opt5_vvt1 || vvt_opt5_vvt2 || vvt_opt1_on > 2) }
        field = "", vvt_hold_duty_exh,      { vvt_opt2_pid && (vvt_opt5_vvt1 || vvt_opt5_vvt2 || vvt_opt1_on > 2) && vvt_opt2_use_hold_exhaust }
        field = "", vvt_ctl_Kp_exh,         { vvt_opt2_pid && (vvt_opt5_vvt1 || vvt_opt5_vvt2 || vvt_opt1_on > 2) }
        field = "", vvt_ctl_Ki_exh,         { vvt_opt2_pid && (vvt_opt5_vvt1 || vvt_opt5_vvt2 || vvt_opt1_on > 2) } 
        field = "", vvt_ctl_Kd_exh,         { vvt_opt2_pid && (vvt_opt5_vvt1 || vvt_opt5_vvt2 || vvt_opt1_on > 2) }

    dialog = vvtinex, "PID parameters", xAxis
        panel = vvtinext
        panel = vvtinexi
        panel = vvtinexe

    dialog = vvtl, ""
        field = "No. VVTs",            vvt_opt1_on
        field = "Cam decoder",         vvt_opt4_decode,{vvt_opt1_on && (spk_mode0 == 4)}
        field = "Frequency",           vvt_opt6_freq, {vvt_opt1_on && vvt_out1}
        field = "On/off or PID",       vvt_opt2_pid,   {vvt_opt1_on}

        field = "Adjust inj. timing based on",       vvt_opt5_add1,   {vvt_opt1_on}
        field = "Commanded vs. actual",       vvt_opt5_add2,   {vvt_opt1_on && vvt_opt5_add1}
        field = "Inj. timing adjustment",       vvt_onoff_ang,  {vvt_opt1_on && !vvt_opt2_pid && vvt_opt5_add1}

        field = "#TEST"
        field = "Test output",                  vvt_opt1_tst,   {vvt_opt1_on}
        field = "Test duty",                    vvt_test_duty,  {vvt_opt1_on && vvt_opt1_tst}

    dialog = vvtr, ""


        field = "Control interval",             vvt_opt1_int,   {vvt_opt1_on && vvt_opt2_pid}
        field = "Control interval time",        vvt_ctl_ms,     {vvt_opt1_on && vvt_opt2_pid && vvt_opt1_int}
        field = "Range check measured angles",  vvt_opt5_err,   {vvt_opt1_on && vvt_opt2_pid}
        panel = vvtinex

    dialog = vvtparams2, "VVT settings", xAxis
        panel = vvtl

        panel = vvtr

    dialog = vvtparams, "VVT settings", yAxis
        panel = vvtparams2
        panel = vvtcams



    dialog = spk_trimaTblTitle, "Cyl #1" 
        panel = spk_trimaTbl
    dialog = spk_trimbTblTitle, "Cyl #2"
        panel = spk_trimbTbl
    dialog = spk_trimcTblTitle, "Cyl #3"
        panel = spk_trimcTbl
    dialog = spk_trimdTblTitle, "Cyl #4"
        panel = spk_trimdTbl

    dialog = spk_trimadt, "", xAxis
        panel = spk_trimaTblTitle
        panel = spk_trimbTblTitle
    dialog = spk_trimadb, "", xAxis
        panel = spk_trimcTblTitle
        panel = spk_trimdTblTitle

    dialog = spk_trimad,"Spark trims 1-4"
        panel = spk_trimadt
        panel = spk_trimadb


    dialog = spk_trimeTblTitle, "Cyl #5" 
        panel = spk_trimeTbl
    dialog = spk_trimfTblTitle, "Cyl #6"
        panel = spk_trimfTbl
    dialog = spk_trimgTblTitle, "Cyl #7"
        panel = spk_trimgTbl
    dialog = spk_trimhTblTitle, "Cyl #8"
        panel = spk_trimhTbl

    dialog = spk_trimeht, "", xAxis
        panel = spk_trimeTblTitle
        panel = spk_trimfTblTitle
    dialog = spk_trimehb, "", xAxis
        panel = spk_trimgTblTitle
        panel = spk_trimhTblTitle

    dialog = spk_trimeh,"Spark trims 5-8"
        panel = spk_trimeht
        panel = spk_trimehb

#if CYL_12_16_SUPPORT
    dialog = spk_trimiTblTitle, "Cyl #9" 
        panel = spk_trimiTbl
    dialog = spk_trimjTblTitle, "Cyl #10"
        panel = spk_trimjTbl
    dialog = spk_trimkTblTitle, "Cyl #11"
        panel = spk_trimkTbl
    dialog = spk_trimlTblTitle, "Cyl #12"
        panel = spk_trimlTbl

    dialog = spk_trimilt, "", xAxis
        panel = spk_trimiTblTitle
        panel = spk_trimjTblTitle
    dialog = spk_trimilb, "", xAxis
        panel = spk_trimkTblTitle
        panel = spk_trimlTblTitle

    dialog = spk_trimil,"Spark trims 9-12"
        panel = spk_trimilt
        panel = spk_trimilb


    dialog = spk_trimmTblTitle, "Cyl #13" 
        panel = spk_trimmTbl
    dialog = spk_trimnTblTitle, "Cyl #14"
        panel = spk_trimnTbl
    dialog = spk_trimoTblTitle, "Cyl #15"
        panel = spk_trimoTbl
    dialog = spk_trimpTblTitle, "Cyl #16"
        panel = spk_trimpTbl

    dialog = spk_trimmpt, "", xAxis
        panel = spk_trimmTblTitle
        panel = spk_trimnTblTitle
    dialog = spk_trimmpb, "", xAxis
        panel = spk_trimoTblTitle
        panel = spk_trimpTblTitle

    dialog = spk_trimmp,"Spark trims 13-16"
        panel = spk_trimmpt


        panel = spk_trimmpb

#endif

    dialog = inj_trimaTblTitle, "Cyl #1" 
        panel = inj_trimaTbl, Center
    dialog = inj_trimbTblTitle, "Cyl #2"
        panel = inj_trimbTbl
    dialog = inj_trimcTblTitle, "Cyl #3"
        panel = inj_trimcTbl
    dialog = inj_trimdTblTitle, "Cyl #4"
        panel = inj_trimdTbl

    dialog = inj_trimadt, "", xAxis
        panel = inj_trimaTblTitle
        panel = inj_trimbTblTitle
    dialog = inj_trimadb, "", xAxis
        panel = inj_trimcTblTitle
        panel = inj_trimdTblTitle

    dialog = inj_trimad,"Injector trims 1-4", yAxis
        panel = inj_trimadt
        panel = inj_trimadb



    dialog = inj_trimeTblTitle, "Cyl #5"
        panel = inj_trimeTbl, Center
    dialog = inj_trimfTblTitle, "Cyl #6"
        panel = inj_trimfTbl
    dialog = inj_trimgTblTitle, "Cyl #7"
        panel = inj_trimgTbl
    dialog = inj_trimhTblTitle, "Cyl #8"
        panel = inj_trimhTbl

    dialog = inj_trimeht, "", xAxis
        panel = inj_trimeTblTitle
        panel = inj_trimfTblTitle
    dialog = inj_trimehb, "", xAxis
        panel = inj_trimgTblTitle
        panel = inj_trimhTblTitle


    dialog = inj_trimeh,"Injector trims 5-8", yAxis
        panel = inj_trimeht
        panel = inj_trimehb

#if CYL_12_16_SUPPORT
    dialog = inj_trimiTblTitle, "Cyl #9"
        panel = inj_trimiTbl
    dialog = inj_trimjTblTitle, "Cyl #10"
        panel = inj_trimjTbl
    dialog = inj_trimkTblTitle, "Cyl #11"
        panel = inj_trimkTbl
    dialog = inj_trimlTblTitle, "Cyl #12"
        panel = inj_trimlTbl

    dialog = inj_trimilt, "", xAxis
        panel = inj_trimiTblTitle
        panel = inj_trimjTblTitle
    dialog = inj_trimilb, "", xAxis
        panel = inj_trimkTblTitle
        panel = inj_trimlTblTitle

    dialog = inj_trimil,"Injector trims 9-12"
        panel = inj_trimilt
        panel = inj_trimilb


    dialog = inj_trimmTblTitle, "Cyl #13"
        panel = inj_trimmTbl
    dialog = inj_trimnTblTitle, "Cyl #14"
        panel = inj_trimnTbl
    dialog = inj_trimoTblTitle, "Cyl #15"
        panel = inj_trimoTbl
    dialog = inj_trimpTblTitle, "Cyl #16"
        panel = inj_trimpTbl

    dialog = inj_trimmpt, "", xAxis
        panel = inj_trimmTblTitle
        panel = inj_trimnTblTitle
    dialog = inj_trimmpb, "", xAxis
        panel = inj_trimoTblTitle
        panel = inj_trimpTblTitle

    dialog = inj_trimmp,"Injector trims 13-16"
        panel = inj_trimmpt
        panel = inj_trimmpb
#endif

    dialog = antilag, "Anti Lag"
        field = "#Caution! Anti-lag is very hard on your turbo"
        field = "# and engine. Use at your risk."
        field = "Anti-lag enable input",        als_in_pin
;        field = "Minimum TPS",                  als_mintps, {als_in_pin}
        field = "Maximum TPS",                  als_maxtps, {als_in_pin}
        field = "Minimum RPM",                  als_minrpm, {als_in_pin}
        field = "Maximum RPM",                  als_maxrpm, {als_in_pin}
        field = "Maximum MAT",                  als_maxmat, {als_in_pin}
        field = "Maximum ALS time",             als_maxtime, {als_in_pin}
        field = "Time between activations",     als_pausetime,{als_in_pin}
        field = "Minimum CLT",                  als_minclt, {als_in_pin}
        field = "Maximum CLT",                  als_maxclt, {als_in_pin}
        field = "Enable cyclic fuel cut",       als_opt_fc, {als_in_pin && hardware_fuel && sequential}
        field = "Fuel cut likely unsafe with Staging"
        field = "Enable cyclic spark cut",      als_opt_sc, {als_in_pin}
        field = "-"
        field = "Enable roving idle fuel cut",  als_opt_ri, {als_in_pin}
        field = "-"
        field = "Use idle valve",               als_opt_idle, {als_in_pin}
        field = "Idle valve Duty",              als_iac_duty,  { als_in_pin && als_opt_idle && (IdleCtl == 4 || IdleCtl == 6) }
        field = "Idle valve Steps",             als_iac_steps, { als_in_pin && als_opt_idle && (IdleCtl == 2 || IdleCtl == 3 || IdleCtl == 5 || IdleCtl == 7 || IdleCtl == 8)}
        field = "-"
        field = "On/off output",                als_out_pin, {als_in_pin}
        field = "-"
        field = "PWM output (generic PWM F)",   als_opt_pwmout, {als_in_pin}
        field = "Output port/pin",              pwm_opt2_f, {als_in_pin && als_opt_pwmout}
        field = "Output duty",                  als_pwm_duty, {als_in_pin && als_opt_pwmout}
        field = "Frequency",                    pwm_opt_freq_f, {als_in_pin && als_opt_pwmout}
        field = ""

    dialog = als_left1, "Added fuel %age"
        panel = als_addfuel_tbl

    dialog = als_left2, "ALS Timing"
        panel = als_timing_tbl

    dialog = als_right1, "Spark cut %"
        panel = als_sparkcut_tbl, North, {als_opt_sc}

    dialog = als_right2, "Fuel cut %"
        panel = als_fuelcut_tbl, South, {als_opt_fc && hardware_fuel && sequential}}

    dialog = antilag_left, ""
        panel = als_left1, North
        panel = als_left2, South

    dialog = antilag_right, "", border
        panel = als_right1, North
        panel = als_right2, South

    dialog = antilagtables, "Anti-lag tables", border
        panel = antilag_left, West
        panel = antilag_right, East

    dialog = flash_unlock, "Un/Lock calibrations"
        field = "Sensor Calibrations", flashlock
        field = "Always re-lock after use"

    dialog = gen_pwm_left_a, ""
        field = "Enable generic PWM A", pwm_opt_on_a
        field = "Output port/pin", pwm_opt2_a, {pwm_opt_on_a}
        field = "On-off or variable", pwm_opt_var_a, {pwm_opt_on_a}
        field = "On above duty", pwm_onabove_a, {pwm_opt_on_a && !(pwm_opt_var_a)}
        field = "Off below duty", pwm_offbelow_a, {pwm_opt_on_a && !(pwm_opt_var_a)}
        field = "Frequency", pwm_opt_freq_a, {pwm_opt_on_a && pwm_opt_var_a}
        field = "Load Y axis", pwm_opt_load_a, {pwm_opt_on_a}
        field = "CLT/MAT units", sensor_temp, {0}

    dialog = gen_pwm_a, "Generic PWM A", border
        panel = gen_pwm_left_a, West
        panel = pwm_duties_Tbl_a, Center

    dialog = gen_pwm_left_b, ""
        field = "Enable generic PWM B", pwm_opt_on_b
        field = "Output port/pin", pwm_opt2_b, {pwm_opt_on_b}
        field = "On-off or variable", pwm_opt_var_b, {pwm_opt_on_b}
        field = "On above duty", pwm_onabove_b, {pwm_opt_on_b && !(pwm_opt_var_b)}
        field = "Off below duty", pwm_offbelow_b, {pwm_opt_on_b && !(pwm_opt_var_b)}
        field = "Frequency", pwm_opt_freq_b, {pwm_opt_on_b && pwm_opt_var_b}
        field = "Load Y axis", pwm_opt_load_b, {pwm_opt_on_b}
        field = "CLT/MAT units", sensor_temp, {0}

    dialog = gen_pwm_b, "Generic PWM B", border
        panel = gen_pwm_left_b, West
        panel = pwm_duties_Tbl_b, Center

    dialog = gen_pwm_left_c, ""
        field = "Enable generic PWM C", pwm_opt_on_c
        field = "Output port/pin", pwm_opt2_c, {pwm_opt_on_c}
        field = "On-off or variable", pwm_opt_var_c, {pwm_opt_on_c}
        field = "On above duty", pwm_onabove_c, {pwm_opt_on_c && !(pwm_opt_var_c)}
        field = "Off below duty", pwm_offbelow_c, {pwm_opt_on_c && !(pwm_opt_var_c)}
        field = "Frequency", pwm_opt_freq_c, {pwm_opt_on_c && pwm_opt_var_c}
        field = "Load Y axis", pwm_opt_load_c, {pwm_opt_on_c}
        field = "CLT/MAT units", sensor_temp, {0}

    dialog = gen_pwm_c, "Generic PWM C", border
        panel = gen_pwm_left_c, West
        panel = pwm_duties_Tbl_c, Center

    dialog = gen_pwm_left_d, ""
        field = "Enable generic PWM D", pwm_opt_on_d
        field = "Output port/pin", pwm_opt2_d, {pwm_opt_on_d}
        field = "On-off or variable", pwm_opt_var_d, {pwm_opt_on_d}
        field = "On above duty", pwm_onabove_d, {pwm_opt_on_d && !(pwm_opt_var_d)}
        field = "Off below duty", pwm_offbelow_d, {pwm_opt_on_d && !(pwm_opt_var_d)}
        field = "Frequency", pwm_opt_freq_d, {pwm_opt_on_d && pwm_opt_var_d}
        field = "Load Y axis", pwm_opt_load_d, {pwm_opt_on_d}
        field = "CLT/MAT units", sensor_temp, {0}

    dialog = gen_pwm_d, "Generic PWM D", border
        panel = gen_pwm_left_d, West
        panel = pwm_duties_Tbl_d, Center

    dialog = gen_pwm_left_e, ""
        field = "Enable generic PWM E", pwm_opt_on_e
        field = "Output port/pin", pwm_opt2_e, {pwm_opt_on_e}
        field = "On-off or variable", pwm_opt_var_e, {pwm_opt_on_e}
        field = "On above duty", pwm_onabove_e, {pwm_opt_on_e && !(pwm_opt_var_e)}
        field = "Off below duty", pwm_offbelow_e, {pwm_opt_on_e && !(pwm_opt_var_e)}
        field = "Frequency", pwm_opt_freq_e, {pwm_opt_on_e && pwm_opt_var_e}
        field = "Load Y axis", pwm_opt_load_e, {pwm_opt_on_e}
        field = "CLT/MAT units", sensor_temp, {0}

    dialog = gen_pwm_e, "Generic PWM E", border
        panel = gen_pwm_left_e, West
        panel = pwm_duties_Tbl_e, Center

    dialog = gen_pwm_left_f, ""
        field = "Enable generic PWM F", pwm_opt_on_f
        field = "Output port/pin", pwm_opt2_f, {pwm_opt_on_f}
        field = "On-off or variable", pwm_opt_var_f, {pwm_opt_on_f}
        field = "On above duty", pwm_onabove_f, {pwm_opt_on_f && !(pwm_opt_var_f)}
        field = "Off below duty", pwm_offbelow_f, {pwm_opt_on_f && !(pwm_opt_var_f)}
        field = "Frequency", pwm_opt_freq_f, {pwm_opt_on_f && pwm_opt_var_f}
        field = "Load Y axis", pwm_opt_load_f, {pwm_opt_on_f}
        field = "CLT/MAT units", sensor_temp, {0}

    dialog = gen_pwm_f, "Generic PWM F", border
        panel = gen_pwm_left_f, West
        panel = pwm_duties_Tbl_f, Center

    dialog = map_sample_dialog_south, "MAP sample general settings"
       field = "MAP sample method", mapsample_opt2
       field = "Map Sample Window",     map_sample_duration, { !mapsample_opt2 }
       field = "No. sample events", mapsample_opt1, { !mapsample_opt2 }

    dialog = map_sample_dialog, "MAP Sampling Settings", border
        panel = mapsample_curve, Center, { !mapsample_opt2 }
        panel = map_sample_dialog_south, South

   dialog = ShiftSettings, "Shifter System"
    field = "Shifter Spark cut system", shift_cut_on
    field = "Mode", shift_cut_auto, { shift_cut_on }
    field = "Button input", shift_cut_in, { shift_cut_on }
    field = "Solenoid output", shift_cut_out, { shift_cut_on }
    field = "RPM >", shift_cut_rpm, { shift_cut_on }	 
    field = "And TPS >", shift_cut_tps, { shift_cut_on }
    field = "Delay before spark cut", shift_cut_delay, { shift_cut_on }
    field = "Spark cut time (base)", shift_cut_time, { shift_cut_on }
    field = "Gear based delay", shift_cut_gear, { shift_cut_on }
    field = "Additional delay 1-2", shift_cut_add12, { shift_cut_on && shift_cut_gear }
    field = "Additional delay 2-3", shift_cut_add23, { shift_cut_on && shift_cut_gear }
    field = "Additional delay 3-4", shift_cut_add34, { shift_cut_on && shift_cut_gear }
    field = "Additional delay 4-5", shift_cut_add45, { shift_cut_on && shift_cut_gear }
    field = "Additional delay 5-6", shift_cut_add56, { shift_cut_on && shift_cut_gear }
    field = "Solenoid delay", shift_cut_soldelay,  { shift_cut_on && shift_cut_on}
    field = "Re-shift hold-off time", shift_cut_reshift
    field = "Automatic mode shift points"
    field = "Shift rpm 1-2", shift_cut_rpm12, { shift_cut_on && shift_cut_auto }
    field = "Shift rpm 2-3", shift_cut_rpm23, { shift_cut_on && shift_cut_auto && shift_cut_gear}
    field = "Shift rpm 3-4", shift_cut_rpm34, { shift_cut_on && shift_cut_auto && shift_cut_gear}
    field = "Shift rpm 4-5", shift_cut_rpm45, { shift_cut_on && shift_cut_auto && shift_cut_gear}
    field = "Shift rpm 5-6", shift_cut_rpm56, { shift_cut_on && shift_cut_auto && shift_cut_gear}

   dialog = fan_control, "Fan Control"
        field = "Fan Control On", fanctl_settings_on
        field = "Fan Control Idles up?", fanctl_settings_idleup, { fanctl_settings_on }
        field = "Output Pin", fanctl_settings_pin, { fanctl_settings_on }
        field = "Idleup Delay", fanctl_idleup_delay, { fanctl_settings_on && fanctl_settings_idleup }
        field = "Idleup Duty", fanctl_idleup_adder_duty, { fanctl_settings_on && fanctl_settings_idleup && (IdleCtl == 4 || IdleCtl == 6) }
        field = "Idleup Steps", fanctl_idleup_adder_steps, { fanctl_settings_on && fanctl_settings_idleup && (IdleCtl == 2 || IdleCtl == 3 || IdleCtl == 5 || IdleCtl == 7 || IdleCtl == 8) }
        field = "Idleup target increase", fan_idleup_cl_targetadder, { ac_idleup_settings && (IdleCtl == 6 || IdleCtl == 7 || IdleCtl == 8) }
        field = "Fan On Temperature", fanctl_ontemp, { fanctl_settings_on }
        field = "Fan Off Temperature", fanctl_offtemp, { fanctl_settings_on }
        field = "Allow fan when engine off", fanctl_opt2_engineoff, { fanctl_settings_on }
        field = "Fan on with AC on?", fan_ctl_settings_acfan, { fanctl_settings_on && ac_idleup_settings }
        field = "Fan shutoff"
        field = "TPS shutoff", fan_idleup_tps_offpoint, { fanctl_settings_on }
        field = "TPS hysteresis", fan_idleup_tps_hyst, { fanctl_settings_on }
        field = "VSS shutoff", fan_idleup_vss_offpoint, { fanctl_settings_on && (vss_opt1 || vss1_an) }
        field = "VSS hyst", fan_idleup_vss_hyst, { fanctl_settings_on && (vss_opt1 || vss1_an) }

    dialog = ac_idleup, "Air Conditioning Idleup"
        field = "AC Idleup On", ac_idleup_settings
        field = "Idleup Output", ac_idleup_io_out, { ac_idleup_settings }
        field = "Idleup Input", ac_idleup_io_in, { ac_idleup_settings }
        field = "Idleup Delay", ac_idleup_delay, { ac_idleup_settings }
        field = "Compressor delay since last on", ac_delay_since_last_on, { ac_idleup_settings }
        field = "Idleup Duty", ac_idleup_adder_duty, { (IdleCtl == 4 || IdleCtl == 6) && ac_idleup_settings }
        field = "Idleup Steps", ac_idleup_adder_steps, { (IdleCtl == 2 || IdleCtl == 3 || IdleCtl == 5 || IdleCtl == 7 || IdleCtl == 8) && ac_idleup_settings }
        field = "Idleup target increase", ac_idleup_cl_targetadder, { ac_idleup_settings && (IdleCtl == 6 || IdleCtl == 7 || IdleCtl == 8) }
        field = "Idleup CL max decel load adder", ac_idleup_cl_lockout_mapadder, { ac_idleup_settings && (IdleCtl == 6 || IdleCtl == 7 || IdleCtl == 8) }
        field = "AC compressor shutoff"
        field = "TPS shutoff", ac_idleup_tps_offpoint, { ac_idleup_settings }
        field = "TPS hysteresis", ac_idleup_tps_hyst, { ac_idleup_settings }
        field = "VSS shutoff", ac_idleup_vss_offpoint, { ac_idleup_settings && (vss_opt1 || vss1_an) }
        field = "VSS hysteresis", ac_idleup_vss_hyst, { ac_idleup_settings && (vss_opt1 || vss1_an) }

        dialog = sensor_source, "", yAxis
            field = "Sensor - source"
            field = "01", sensor01_source
            field = "02", sensor02_source
            field = "03", sensor03_source
            field = "04", sensor04_source
            field = "05", sensor05_source
            field = "06", sensor06_source
            field = "07", sensor07_source
            field = "08", sensor08_source

        dialog = sensor_sourceb, "", yAxis
            field = "Sensor - source"
            field = "09", sensor09_source
            field = "10", sensor10_source
            field = "11", sensor11_source

            field = "12", sensor12_source
            field = "13", sensor13_source
            field = "14", sensor14_source
            field = "15", sensor15_source
            field = "16", sensor16_source

        dialog = sensor_trans, "", yAxis
            field = "Transformation"
            field = "", sensor01_trans, {sensor01_source}
            field = "", sensor02_trans, {sensor02_source}
            field = "", sensor03_trans, {sensor03_source}
            field = "", sensor04_trans, {sensor04_source}
            field = "", sensor05_trans, {sensor05_source}
            field = "", sensor06_trans, {sensor06_source}
            field = "", sensor07_trans, {sensor07_source}
            field = "", sensor08_trans, {sensor08_source}

        dialog = sensor_transb, "", yAxis
            field = "Transformation"
            field = "", sensor09_trans, {sensor09_source}
            field = "", sensor10_trans, {sensor10_source}
            field = "", sensor11_trans, {sensor11_source}
            field = "", sensor12_trans, {sensor12_source}
            field = "", sensor13_trans, {sensor13_source}
            field = "", sensor14_trans, {sensor14_source}
            field = "", sensor15_trans, {sensor15_source}
            field = "", sensor16_trans, {sensor16_source}

        dialog = sensor_val0, "", yAxis
            field = "0V value"
            field = "", sensor01_val0, {sensor01_source && (sensor01_trans == 1)}
            field = "", sensor02_val0, {sensor02_source && (sensor02_trans == 1)}
            field = "", sensor03_val0, {sensor03_source && (sensor03_trans == 1)}
            field = "", sensor04_val0, {sensor04_source && (sensor04_trans == 1)}
            field = "", sensor05_val0, {sensor05_source && (sensor05_trans == 1)}
            field = "", sensor06_val0, {sensor06_source && (sensor06_trans == 1)}
            field = "", sensor07_val0, {sensor07_source && (sensor07_trans == 1)}
            field = "", sensor08_val0, {sensor08_source && (sensor08_trans == 1)}

        dialog = sensor_val0b, "", yAxis
            field = "0V value"
            field = "", sensor09_val0, {sensor09_source && (sensor09_trans == 1)}
            field = "", sensor10_val0, {sensor10_source && (sensor10_trans == 1)}
            field = "", sensor11_val0, {sensor11_source && (sensor11_trans == 1)}
            field = "", sensor12_val0, {sensor12_source && (sensor12_trans == 1)}
            field = "", sensor13_val0, {sensor13_source && (sensor13_trans == 1)}
            field = "", sensor14_val0, {sensor14_source && (sensor14_trans == 1)}
            field = "", sensor15_val0, {sensor15_source && (sensor15_trans == 1)}
            field = "", sensor16_val0, {sensor16_source && (sensor16_trans == 1)}

        dialog = sensor_max, "", yAxis
            field = "5V value"
            field = "", sensor01_max, {sensor01_source && (sensor01_trans == 1)}
            field = "", sensor02_max, {sensor02_source && (sensor02_trans == 1)}
            field = "", sensor03_max, {sensor03_source && (sensor03_trans == 1)}
            field = "", sensor04_max, {sensor04_source && (sensor04_trans == 1)}
            field = "", sensor05_max, {sensor05_source && (sensor05_trans == 1)}
            field = "", sensor06_max, {sensor06_source && (sensor06_trans == 1)}
            field = "", sensor07_max, {sensor07_source && (sensor07_trans == 1)}
            field = "", sensor08_max, {sensor08_source && (sensor08_trans == 1)}

        dialog = sensor_maxb, "", yAxis
            field = "5V value"
            field = "", sensor09_max, {sensor09_source && (sensor09_trans == 1)}
            field = "", sensor10_max, {sensor10_source && (sensor10_trans == 1)}
            field = "", sensor11_max, {sensor11_source && (sensor11_trans == 1)}
            field = "", sensor12_max, {sensor12_source && (sensor12_trans == 1)}
            field = "", sensor13_max, {sensor13_source && (sensor13_trans == 1)}
            field = "", sensor14_max, {sensor14_source && (sensor14_trans == 1)}
            field = "", sensor15_max, {sensor15_source && (sensor15_trans == 1)}
            field = "", sensor16_max, {sensor16_source && (sensor16_trans == 1)}

        dialog = sensor_lag, "", yAxis
            field = "Lag factor"
            field = "", sensor01LF, {sensor01_source}
            field = "", sensor02LF, {sensor02_source}

            field = "", sensor03LF, {sensor03_source}
            field = "", sensor04LF, {sensor04_source}
            field = "", sensor05LF, {sensor05_source}
            field = "", sensor06LF, {sensor06_source}
            field = "", sensor07LF, {sensor07_source}
            field = "", sensor08LF, {sensor08_source}

        dialog = sensor_lagb, "", yAxis
            field = "Lag factor"
            field = "", sensor09LF, {sensor09_source}
            field = "", sensor10LF, {sensor10_source}
            field = "", sensor11LF, {sensor11_source}
            field = "", sensor12LF, {sensor12_source}
            field = "", sensor13LF, {sensor13_source}
            field = "", sensor14LF, {sensor14_source}
            field = "", sensor15LF, {sensor15_source}
            field = "", sensor16LF, {sensor16_source}

        dialog = sensors_top, "Sensors 1-8", xAxis
           panel = sensor_source
           panel = sensor_trans
           panel = sensor_val0
           panel = sensor_max
           panel = sensor_lag

        dialog = sensors_btm, "Sensors 9-16", xAxis
           panel = sensor_sourceb
           panel = sensor_transb
           panel = sensor_val0b
           panel = sensor_maxb
           panel = sensor_lagb

        dialog = sensors_data, "", yAxis
           panel = sensors_top
           panel = sensors_btm

        dialog = sensors_temp, "", xAxis
           field = "Allow input sharing", opt142_gs_share
           field = "CLT/MAT units", sensor_temp

        dialog = sensors, "Generic Sensor Input", border
           panel = sensors_data, North
           panel = sensors_temp, South

        dialog = ITB_settings, "ITB settings"
           field = "Percent Baro switchpoint", ITB_load_mappoint
           field = "Idle TPS threshold", ITB_load_idletpsthresh

        dialog = ITBcombined, "ITB load settings", border
           panel = ITB_settings, South 
           panel = ITB_load_switchpoint_curve, West 
           panel = ITB_load_loadvals_curve, East

        dialog = mafdialog1, "", yAxis
            field = "Sensor type", MAFOption_t
            field = "Voltage input port", MAFOption, {MAFOption_t == 0}
            field = "MAT correction curve", feature7_mafmat
            field = "Use VE1 as trim table", feature7_maftrim, {algorithm == 5}

        dialog = mafdialog4, "", yAxis
            field = "See also Tools->Calibrate MAF table."
            displayOnlyField = "Primary or secondary fuel needs to be set to MAF or MAFMAP ->", algorithm, { ((algorithm != 5) && (algorithm2 != 5) && (algorithm != 4) && (algorithm2 != 4)) }

        dialog = mafdialog2, "", yAxis
            field = "Frequency input port", MAFOption_f, {MAFOption_t == 1}
            field = "Low frequency", maf_freq0, {MAFOption_t == 1}
            field = "High frequency", maf_freq1, {MAFOption_t == 1}

        dialog = mafdialog3, "", xAxis
            panel = mafdialog1, West
            panel = mafdialog2, East

        dialog = mafdialog, "MAF Settings", yAxis
            panel = mafdialog3, North
            panel = mafdialog4, South

        dialog = mafcombined, "", border
            panel = mafdialog, North
            panel = MAFtable1, South

        dialog = battcalib, "Battery Voltage Calibration"
            field = "Supply voltage at zero ADC count", batt0
            field = "Supply voltage at max ADC count", battmax
            field = ""
            field = "Typical values are 0.0V and 29.7V"

        dialog = waterinj_topl, ""
            field = "Enable water/meth injection", water_freq_on
            field = "Pump output", water_pins_pump, {water_freq_on}
            field = "Valve style", water_freq_type, {water_freq_on}
            field = "Frequency", water_freq, {water_freq_on && (water_freq_type ==2)}
            field = "Valve output", water_pins_valve, {water_freq_on && water_freq_type}
        dialog = waterinj_topr, ""
            field = "Enable when.."
            field = "TPS >", water_tps, {water_freq_on}
            field = "RPM >", water_rpm, {water_freq_on}
            field = "MAP >", water_map, {water_freq_on}
            field = "MAT >", water_mat, {water_freq_on}
            field = ""
            field = "Use maxAFR shutdown", water_pins_in_shut, {water_freq_on && maxafr_opt1_on}

        dialog = waterinj_top, "", border
            panel = waterinj_topl, West
            panel = waterinj_topr, East

        dialog = waterinj, "Water Injection", border
            panel = waterinj_top, North
            panel = waterinjTbl, Center

       dialog = vss1, "Vehicle speed sensor 1"
          field = "Analogue sensor", vss1_an
          field = "Full scale speed", vss1_an_max, {vss1_an}
          field = "Input", vss_opt1, {!vss1_an}
          field = "Wheel diameter", wheeldia1, {vss_opt1 && !vss1_an && (vss_opt1 != 14) && (vss1_pos < 2)}
          field = "VSS position/type", vss1_pos
          field = "Pulses", vss1_can_scale, {vss_opt1 && !vss1_an && (vss_opt1 != 14) && (vss1_pos > 1)}
          field = "Speed sensor #teeth", reluctorteeth1, {vss_opt1 && !vss1_an && (vss_opt1 != 14) && (vss1_pos < 2)}
          field = "PWM port", vss1_pwmseq, {vss_opt1 ==15 && !vss1_an}
          field = "Scaler", vss1_can_scale, {vss_opt1 ==14 && !vss1_an}
          field = "Smoothing lag factor", vss1LF ;, {(vss1_an) || (vss1_opt) }

       dialog = vss2, "Vehicle speed sensor 2"
          field = "Analogue sensor", vss2_an
          field = "Full scale speed", vss2_an_max, {vss2_an}

          field = "Input", vss_opt2, {!vss2_an}
          field = "Wheel diameter", wheeldia2, {vss_opt2 && !vss2_an && (vss_opt2 != 14) && (vss2_pos < 2)}
          field = "VSS position", vss2_pos
          field = "Pulses", vss2_can_scale, {vss_opt2 && !vss2_an && (vss_opt2 != 14) && (vss2_pos > 1)}
          field = "Speed sensor #teeth", reluctorteeth2, {vss_opt2 && !vss2_an && (vss_opt2 != 14) && (vss2_pos < 2)}
          field = "PWM port", vss2_pwmseq, {vss_opt2 ==15 && !vss2_an}
          field = "Scaler", vss2_can_scale, {vss_opt2 ==14 && !vss1_an}
          field = "Smoothing lag factor", vss2LF ;, {(vss2_an) || (vss_opt2) }

       dialog = ss, "Shaft Speed Sensors"
          field = "Sensor 1", ss_opt1
          field = "Speed sensor #teeth", reluctorteeth3, {ss_opt1 && ss_opt1<15}
          field = "Smoothing lag factor", ss1LF ;, {ss_opt2 && ss_opt2<15}
    ;      field = "Remote CANid", ss1_can_id, {ss_opt1 ==15 &&0}
    ;      field = "Remote CAN offset", ss1_can_offset, {ss_opt1 ==15 &&0}
          field = ""
          field = ""
          field = "Sensor 2", ss_opt2
          field = "Speed sensor #teeth", reluctorteeth4, {ss_opt2 && ss_opt2<15}
          field = "Smoothing lag factor", ss2LF ;, {ss_opt2 && ss_opt2<15}

    ;      field = "Remote CANid", ss2_can_id, {ss_opt2 ==15 &&0}
    ;      field = "Remote CAN offset", ss2_can_offset, {ss_opt2 ==15 &&0}
          field = ""
          field = ""
          field = ""
          field = ""

       dialog = vssout, "VSS output"

        field = "VSS output", vssout_opt
        field = "VSSout units", vssout_optunits, { vssout_opt }
        field = "Scale", vssout_scale, { vssout_opt }

       dialog = vssdotlag, "VSSdot smoothing"
        field = "Sample interval", vssdot_int
        field = "Lag factor", vssdotLF

       dialog = gears, "Gear detection"
        field = "Final drive ratio", fdratio1
        field = "Method", gear_method
        field = "Number of gears", gear_no, {gear_method}
        field = "1st ratio", gear1ratio, { (gear_method == 1) }
        field = "2nd ratio", gear2ratio, { (gear_method == 1) && (gear_no > 1) } ; would be pretty pointless otherwise!
        field = "3rd ratio", gear3ratio, { (gear_method == 1) && (gear_no > 2) }
        field = "4th ratio", gear4ratio, { (gear_method == 1) && (gear_no > 3) }
        field = "5th ratio", gear5ratio, { (gear_method == 1) && (gear_no > 4) }
        field = "6th ratio", gear6ratio, { (gear_method == 1) && (gear_no > 5) }
        field = ""
        field = "Input port", gear_port_an, { (gear_method == 2) }
        field = "Neutral voltage",  gear0v, { (gear_method == 2) }
        field = "1st gear voltage", gear1v, { (gear_method == 2) }
        field = "2nd gear voltage", gear2v, { (gear_method == 2) && (gear_no > 1) }
        field = "3rd gear voltage", gear3v, { (gear_method == 2) && (gear_no > 2) }
        field = "4th gear voltage", gear4v, { (gear_method == 2) && (gear_no > 3) }
        field = "5th gear voltage", gear5v, { (gear_method == 2) && (gear_no > 4) }
        field = "6th gear voltage", gear6v, { (gear_method == 2) && (gear_no > 5) }

       dialog = ssnorth, "", border
            panel = vss1, West
            panel = vss2, East

       dialog = vssoutdot, "", border
            panel = vssout, North
            panel = vssdotlag, South

       dialog = sssouth, "", border
            panel = ss, West
            panel = vssoutdot, East

    ;   dialog = speedsensors, "Speed Sensors", border
       dialog = speedsensorsmain, "", yAxis
            panel = ssnorth
            panel = sssouth

       dialog = speedsensors, "Speed and Gear Sensors", border
            panel = speedsensorsmain, West
            panel = gears, East

       dialog = accelerometer, "Accelerometer input"
        field = "X input", accXport
        field = "Y input", accYport
        field = "Z input", accZport
        field = "X -1g calib.", accXcal1, { accXport }
        field = "X +1g calib.", accXcal2, { accXport }
        field = "Y -1g calib.", accYcal1, { accYport }
        field = "Y +1g calib.", accYcal2, { accYport }
        field = "Z -1g calib.", accZcal1, { accZport }
        field = "Z +1g calib.", accZcal2, { accZport }
        field = "Lag factor", accxyzLF

       dialog = xTauSettings, "X-Tau MAPdot Settings"
          topicHelp = "http://www.megamanual.com/mt28.htm#um"
          field = "#MAPdot Thresholds for transition to X, Tau Decel Tables"
          field = "Start Transition",  MapThreshXTD
          field = "Finish Transition",  MapThreshXTD2

       dialog = sdcard_top, ""
          field = "SD card logging:", log_style_on
          field = "Datalog button", log_style2_but, {log_style_on > 1}
          field = "LED indicator", log_style_led, {log_style_on}
          field = "Log data block size", log_style_block, {log_style_on}
          field = "Sampling", log_style2_samp, {(log_style_block != 1) && log_style_on }
          field = "Sample interval", log_int, {(log_style_block != 1) && log_style_on }
          field = "Log file max duration", log_length, {log_style_on}
          field = "Stream input", log_style3_adc, {log_style_block == 1}
          field = "SPI comms speed", log_style_ledspd, {log_style_on}

       dialog = sdcard_btm, ""
          logFieldSelector = dataLogFieldSelector, "Log Field Selection", logFieldOffset, logFieldLength

       dialog = sdcard_datalog, "SD Card Datalogging", yAxis
          panel = sdcard_top
          panel = dataLogFieldSelector


       dialog = MATCorrval, "MAT correction value"
          field = "This value allows you to scale down the built in air"
          field = "density (MAT) correction. "
          field = "100% means that the PV=nRT ideal gas law is followed."
          field = "Lower values give less aggressive correction."
          field = "0% is not allowed as it ignores the physics completely."
          field = "(0% is interpreted as 100% for backwards compatability)"
          field = "This value and the table are used at the same time"
          field = "MAT correction scaling",              airden_scaling

       dialog = N2OSystem_topl, ""
          field = "Nitrous Control",                    N2Oopt_2
          field = "Enable N2O when above",              N2ORpm,         { N2Oopt_2 }
          field = "And Coolant Temp above",             N2OClt,         { N2Oopt_2 }
          field = "And TPS >",                          N2OTps,         { N2Oopt_2 }
          field = "Max RPM",                            N2ORpmMax,      { N2Oopt_2 }
          field = "Enrich which bank",     N2Oopt_01,      { N2Oopt_2 }

       dialog = N2OSystem_topr, ""
          field = "On/Off vs Progressive mode",         N2Oopt2_prog,   { N2Oopt_2 }
          field = "Time-based or RPM-based", N2Oopt2_prog_time, { N2Oopt_2 && N2Oopt2_prog }
          field = "Solenoid frequency", N2Oopt2_prog_freq, { N2Oopt_2 && N2Oopt2_prog }
          field = "AFR safety uses AFR2 targets", N2Oopt_4, { N2Oopt_2 }

          field = ""
          field = "READ THE MANUAL BEFORE USING NITROUS"

       dialog = N2OSystem1, "Nitrous System Stage 1"
          field = "Stage 1 output - nitrous",           n2o1n_pins,     { N2Oopt_2 }
          field = "Stage 1 output - fuel",              n2o1f_pins,     { N2Oopt_2 }
          field = "Enable input on:",                   N2Oopt_pins,    { N2Oopt_2 }
          field = "Additional Fuel PW @ N2O min rpm",   N2OPWLo,        { N2Oopt_2 && !N2Oopt2_prog}
          field = "Additional Fuel PW @ N2O max rpm",   N2OPWHi,        { N2Oopt_2 && !N2Oopt2_prog }
          field = "Retard Ignition by",                 N2OAngle,       { N2Oopt_2 && !N2Oopt2_prog}
          field = "Nitrous delay after launch",         N2Odel_launch,  { N2Oopt_2 && launch_opt_on }
          field = "Nitrous delay after flat shift",     N2Odel_flat,    { N2Oopt_2 && launch_opt_on }
          field = ""
          field = ""
    ;not yet implemented field = "Nitrous fuel hold on",N2Oholdon,      { N2Oopt_2 }

       dialog = N2OSystem2, "Nitrous System Stage 2"
          field =   "Nitrous stage 2",                  N2Oopt_3,       { N2Oopt_2 }
          field = "Stage 2 output - nitrous",           n2o2n_pins,     { N2Oopt_2 && N2Oopt_3 }
          field = "Stage 2 output - fuel",              n2o2f_pins,     { N2Oopt_2 && N2Oopt_3 }
          field = "Enable stage 2 above",               N2O2Rpm,        { N2Oopt_2 && N2Oopt_3 && !N2Oopt2_prog }
          field = "Max RPM",                            N2O2RpmMax,     { N2Oopt_2 && N2Oopt_3 && !N2Oopt2_prog }
          field = "delay after stage1",                 N2O2delay,      { N2Oopt_2 && N2Oopt_3 && (!N2Oopt2_prog || !N2Oopt2_prog_time) }
          field = "Retard Ignition by",                 N2O2Angle,      { N2Oopt_2 && N2Oopt_3 && !N2Oopt2_prog }
          field = "Additional Fuel PW @ N2O min rpm",   N2O2PWLo,       { N2Oopt_2 && N2Oopt_3 && !N2Oopt2_prog }
          field = "Additional Fuel PW @ N2O Max RPM",   N2O2PWHi,       { N2Oopt_2 && N2Oopt_3 && !N2Oopt2_prog }

       dialog = N2OSystem_top, "", border
          panel = N2OSystem_topl, West
          panel = N2OSystem_topr, East

       dialog = N2OSystems, "", border
          panel = N2OSystem1, West
          panel = N2OSystem2, East

       dialog = nitrous, "Nitrous oxide control", border
          panel = N2OSystem_top, North
          panel = N2OSystems, South

       dialog = n2o1_curves_time, ""
          panel = n2o1_duty_time
          panel = n2o1_pw_time
          panel = n2o1_retard_time

       dialog = n2o2_curves_time, ""
          panel = n2o2_duty_time
          panel = n2o2_pw_time
          panel = n2o2_retard_time

       dialog = nitrous_curves_time, "Time-based Progressive Nitrous Oxide Charts", border
          panel = n2o1_curves_time, West
          panel = n2o2_curves_time, East

       dialog = n2o1_curves_rpm, ""
          panel = n2o1_duty_rpm
          panel = n2o1_pw_rpm
          panel = n2o1_retard_rpm

       dialog = n2o2_curves_rpm, ""
          panel = n2o2_duty_rpm
          panel = n2o2_pw_rpm
          panel = n2o2_retard_rpm

       dialog = nitrous_curves_rpm, "RPM-based Progressive Nitrous Oxide Charts", border
          panel = n2o1_curves_rpm, West
          panel = n2o2_curves_rpm, East

;combined curves
       dialog = n2o_retard_empty, ""
          field = ""
 
       dialog = n2o_curves_rpm_t, "", xAxis
          panel = n2o_duty_rpm
          panel = n2o_pw_rpm

       dialog = n2o_curves_rpm_b, "", xAxis
          panel = n2o_retard_rpm
          panel = n2o_retard_empty

       dialog = nitrous_curves_rpm_many, "RPM-based Progressive Nitrous Oxide Charts", border
          panel = n2o_curves_rpm_t, North
          panel = n2o_curves_rpm_b, South

       dialog = overboost, "Overboost Protection"
       field = "Overboost protection", OverBoostOption
       field = "Maximum Boost",   OverBoostKpa, { OverBoostOption > 0 }
       field = "Hysteresis",      OverBoostHyst, { OverBoostOption > 0 }
       field = "Overboost switching", tsw_pin_ob, { OverBoostOption > 0 }
       field = "Alt. Maximum Boost",   OverBoostKpa2, { (tsw_pin_ob && (OverBoostOption > 0)) || dualfuel_sw2_ob }
       field = ""
       field = "Cut X sparks",    overboostcutx, { OverBoostOption > 1 }
       field = "From Y events",   overboostcuty, { OverBoostOption > 1 }

       dialog = boostfeat, ""
         field = "Boost Table Switching", boost_feats_tsw, {boost_ctl_settings_on}
         field = "Boost Table Switching Gear", boost_gear_switch, { boost_feats_tsw == 15 }
         field = ""
         field = "Boost timed from launch", boost_feats_timed, {boost_ctl_settings_on && launch_opt_on}
         field = ""
         field = "Specific Launch duty/target", boost_feats_launch, {boost_ctl_settings_on && launch_opt_on}
         field = "Launch boost duty", boost_launch_duty, {boost_ctl_settings_on && launch_opt_on && boost_feats_launch && boost_ctl_settings_cl == 0}
         field = "Launch boost target", boost_launch_target, {boost_ctl_settings_on && launch_opt_on && boost_feats_launch && boost_ctl_settings_cl}
         field = ""
         field = "Boost vs speed", boost_vss, {boost_ctl_settings_on}
         field = "Above TPS", boost_vss_tps, {boost_ctl_settings_on && boost_vss}

        dialog = boostctlSettings, "Boost Control Settings"
          field = "Boost control Enabled",		  boost_ctl_settings_on
          field = "Solenoid Freq. Range",       boost_ctl_pwm, {boost_ctl_settings_on}
          field = "Solenoid Frequency (mid)", boost_ctl_pwm_scale, { boost_ctl_settings_on && (boost_ctl_pwm == 1)}
          field = "Note, the mid frequency is shared with PWM idle"
          field = "Boost Control Pin (high,mid)",     boost_ctl_pins_pwm, {boost_ctl_settings_on && (boost_ctl_pwm < 2)}
          field = "Solenoid Frequency (slow)",		  boost_ctl_settings_freq, {boost_ctl_settings_on && (boost_ctl_pwm == 2)}
          field = "Boost Control Pin (slow)",                boost_ctl_pins, {boost_ctl_settings_on && (boost_ctl_pwm == 2)}
          field = "Output polarity",                  boost_ctl_settings_invert, {boost_ctl_settings_on}
          field = "Control Interval",                 boost_ctl_ms, {boost_ctl_settings_on}
          field = ""
          field = "Closed Duty",                      boost_ctl_closeduty, {boost_ctl_settings_on}
          field = "Open Duty",                        boost_ctl_openduty, {boost_ctl_settings_on}
          field = "Boost Control Lower CLT threshold",boost_ctl_clt_threshold, {boost_ctl_settings_on}
          field = "Boost Control Lower Limit",        boost_ctl_lowerlimit, {boost_ctl_settings_on && boost_ctl_settings_cl }
          field = ""
          field = "Algorithm",			  boost_ctl_settings_cl, {boost_ctl_settings_on && boost_ctl_settings_on}
          field = "Proportional Gain",                boost_ctl_Kp, {boost_ctl_settings_on && boost_ctl_settings_cl}
          field = "Integral Gain",                    boost_ctl_Ki, {boost_ctl_settings_on && boost_ctl_settings_cl}
          field = "Differential Gain",                boost_ctl_Kd, {boost_ctl_settings_on && boost_ctl_settings_cl}

          dialog = boosteast, ""
           panel = overboost, North
           panel = boostfeat, South

          dialog = boost, "Boost Control", border
           panel = boostctlSettings, West
           panel = boosteast, East

        dialog = boostctlSettings2, "Boost Control Settings 2"
          field = "Boost control Enabled",		      boost_ctl_settings_on2, {boost_ctl_settings_on}
          field = "Target duty and boost tables 2 are used."
          field = "Boost vs vss or time or tableswitch not supported."
          field = "Frequencies same as channel 1"
          field = "Boost Control Pin (high,mid)",     boost_ctl_pins_pwm2, {boost_ctl_settings_on && boost_ctl_settings_on2 && (boost_ctl_pwm < 2)}
          field = "Boost Control Pin (slow)",         boost_ctl_pins2, {boost_ctl_settings_on && boost_ctl_settings_on2 && (boost_ctl_pwm == 2)}
          field = ""
          field = "Closed Duty",                      boost_ctl_closeduty2, {boost_ctl_settings_on && boost_ctl_settings_on2 && boost_ctl_settings_cl2}
          field = "Open Duty",                        boost_ctl_openduty2, {boost_ctl_settings_on && boost_ctl_settings_on2 && boost_ctl_settings_cl2}
          field = "Boost Control Lower Limit",        boost_ctl_lowerlimit2, {boost_ctl_settings_on && boost_ctl_settings_cl2 }
          field = ""
          field = "Algorithm",			              boost_ctl_settings_cl2, {boost_ctl_settings_on && boost_ctl_settings_on2}
          field = "Proportional Gain",                boost_ctl_Kp2, {boost_ctl_settings_on && boost_ctl_settings_on2 && boost_ctl_settings_cl2}
          field = "Integral Gain",                    boost_ctl_Ki2, {boost_ctl_settings_on && boost_ctl_settings_on2 && boost_ctl_settings_cl2}
          field = "Differential Gain",                boost_ctl_Kd2, {boost_ctl_settings_on && boost_ctl_settings_on2 && boost_ctl_settings_cl2}
          field = "MAP sensor to target",             boost_ctl_sensor2, {boost_ctl_settings_on && boost_ctl_settings_on2 && boost_ctl_settings_cl2}
          field = "Must be defined in Generic Sensors"        

       dialog = maxafrset, ""
          field = "Enable AFR Safety", maxafr_opt1_on
           field = "Warning output", maxafr_opt1_led, { maxafr_opt1_on || egt_conf_action }
           field = "Load axis", maxafr_opt1_load, { maxafr_opt1_on }
           field = "Check above load", maxafr_en_load, { maxafr_opt1_on }
           field = "Check above RPM", maxafr_en_rpm,   { maxafr_opt1_on }
           field = "Wait for", maxafr_en_time, { maxafr_opt1_on }
           field = "Kill spark for", maxafr_spkcut_time, { maxafr_opt1_on || egt_conf_action}
           field = "Then kill fuel until..." ;, "", { maxafr_opt1_on || egt_conf_action}
           field = "TPS below", maxafr_ret_tps, { maxafr_opt1_on || egt_conf_action}
           field = "MAP below", maxafr_ret_map, { maxafr_opt1_on || egt_conf_action}
           field = "RPM below", maxafr_ret_rpm, { maxafr_opt1_on || egt_conf_action}

       dialog = maxafrTbls, "AFR difference table", border
           panel = maxafr1Tbl, West

       dialog = maxafr, "Maximum AFR Safety System", border
           panel = maxafrset, West
           panel = maxafrTbls, East

         dialog = egtwestn, "Configuration"
           field = "No. EGT inputs", egt_num
           field = ""
           field = "Calibration - see documentation"
           field = "Temp at 0V", egtcal_temp0, {egt_num}
           field = "Temp at 5V", egtcal_tempmax, {egt_num}

         dialog = egtwests, "Actions"
           field = "EGT actions", egt_conf_action
           field = "Warning LED same as AFR safety"
           field = "Warn temperature", egt_warn, {egt_conf_action}
           field = "Added fuel", egt_addfuel, {egt_conf_action}
           field = "Add to", egt_conf_bank, {egt_conf_action}
           field = "Shutdown engine", egt_conf_shutdown, {egt_conf_action}
           field = "Time > warn temp", egt_time, {egt_conf_action && egt_conf_shutdown}
           field = "Max temperature", egt_max, {egt_conf_action && egt_conf_shutdown}
           field = "See AFR safety for shutdown options"

         dialog = egtwest, "", yAxis
           panel = egtwestn, North
           panel = egtwests, South

         dialog = egteast, "Data capture"
           field = "EGT 1 channel",  egt1port, { (egt_num > 0) }
           field = "EGT 2 channel",  egt2port, { (egt_num > 1) }
           field = "EGT 3 channel",  egt3port, { (egt_num > 2) }
           field = "EGT 4 channel",  egt4port, { (egt_num > 3) }
           field = "EGT 5 channel",  egt5port, { (egt_num > 4) }
           field = "EGT 6 channel",  egt6port, { (egt_num > 5) }
           field = "EGT 7 channel",  egt7port, { (egt_num > 6) }
           field = "EGT 8 channel",  egt8port, { (egt_num > 7) }
           field = "EGT 9 channel",  egt9port, { (egt_num > 8) }
           field = "EGT 10 channel", egt10port, { (egt_num > 9) }
           field = "EGT 11 channel", egt11port, { (egt_num > 10) }
           field = "EGT 12 channel", egt12port, { (egt_num > 11) }
           field = "EGT 13 channel", egt13port, { (egt_num > 12) }
           field = "EGT 14 channel", egt14port, { (egt_num > 13) }
           field = "EGT 15 channel", egt15port, { (egt_num > 14) }
           field = "EGT 16 channel", egt16port, { (egt_num > 15) }

         dialog = egt, "EGT / Thermocouple inputs", border
           panel = egtwest, West
           panel = egteast, East

         dialog = injseq, "Injector Sequence"
           field = "!FOR EXPERT USE ONLY"
           field = ""
           field = "Enable initial values", feature3_3
           field = "Injector sequence start", trig_init, {feature3_3 }
           field = "Injector time mask", inj_time_mask, {feature3_3 }

          dialog = canwest,  ""
           field = "My CAN ID",  mycan_id

               field = "Enable PWM polling", enable_pollPWM
           field = "Remote CAN Id", can_poll_id, { enable_pollPWM }
               field = "Remote table number for PWM data", poll_tablePWM, { enable_pollPWM }
               field = "Remote table offset for PWM data", poll_offsetPWM, { enable_pollPWM }
           field = "Remote clock", canpwm_clk, { enable_pollPWM }
           field = "Remote prescale", canpwm_pre, { enable_pollPWM }
           field = "Remote divider", canpwm_div, { enable_pollPWM }
           field = ""
           field = "Enable ADC polling", enable_pollADC

          dialog = caneast,  ""
           field = "Digital ports"
           field = "Remote CAN Id", can_poll_id_ports, { enable_pollports_digin || enable_pollports_digout}
               field = "Table", poll_tableports, { enable_pollports_digin || enable_pollports_digout}
           field = "Enable input port", enable_pollports_digin
               field = "Offset", can_poll_digin_offset, { enable_pollports_digin}
           field = "Enable output port", enable_pollports_digout
               field = "Offset", can_poll_digout_offset, { enable_pollports_digout}
           field = ""
           field = "Enable PWM outputs", enable_pwmout
           field = "Remote CAN Id", can_pwmout_id, { enable_pwmout }
               field = "Table", can_pwmout_tab, { enable_pwmout }
               field = "Offset", can_pwmout_offset, { enable_pwmout }

    ;CAN adcs
        dialog = canadc_opt, "", yAxis
            field = "CAN ADC group on/off"
            field = "CAN ADC  1- 4", canadc_opt1, { enable_pollADC }
            field = "CAN ADC  5- 8", canadc_opt2, { enable_pollADC }
            field = "CAN ADC  9-12", canadc_opt3, { enable_pollADC }
            field = "CAN ADC 13-16", canadc_opt4, { enable_pollADC }
            field = "CAN ADC 17-20", canadc_opt5, { enable_pollADC }
            field = "CAN ADC 21-24", canadc_opt6, { enable_pollADC }

        dialog = canadc_id, "", yAxis
            field = "CAN Id"
            field = "", canadc_id1, { canadc_opt1 && enable_pollADC }
            field = "", canadc_id2, { canadc_opt2 && enable_pollADC }
            field = "", canadc_id3, { canadc_opt3 && enable_pollADC }
            field = "", canadc_id4, { canadc_opt4 && enable_pollADC }

            field = "", canadc_id5, { canadc_opt5 && enable_pollADC }
            field = "", canadc_id6, { canadc_opt6 && enable_pollADC }

        dialog = canadc_tab, "", yAxis
            field = "Table"
            field = "", canadc_tab1, { canadc_opt1 && enable_pollADC }
            field = "", canadc_tab2, { canadc_opt2 && enable_pollADC }
            field = "", canadc_tab3, { canadc_opt3 && enable_pollADC }
            field = "", canadc_tab4, { canadc_opt4 && enable_pollADC }
            field = "", canadc_tab5, { canadc_opt5 && enable_pollADC }
            field = "", canadc_tab6, { canadc_opt6 && enable_pollADC }

        dialog = canadc_off, "", yAxis
            field = "Offset"
            field = "", canadc_off1, { canadc_opt1 && enable_pollADC }
            field = "", canadc_off2, { canadc_opt2 && enable_pollADC }
            field = "", canadc_off3, { canadc_opt3 && enable_pollADC }
            field = "", canadc_off4, { canadc_opt4 && enable_pollADC }
            field = "", canadc_off5, { canadc_opt5 && enable_pollADC }
            field = "", canadc_off6, { canadc_opt6 && enable_pollADC }

        dialog = canadcs, "CAN ADC selection", xAxis

            panel = canadc_opt
            panel = canadc_id
            panel = canadc_tab
            panel = canadc_off

          dialog = can_top, "", xAxis
            panel = canwest
            panel = caneast

          dialog = canparams, "CAN Parameters", border
            panel = can_top, North
            panel = canadcs, South

      dialog = canbroadcast,  "CAN Broadcasting"
       field = "Enable broadcasting", can_bcast1_on
       field = "Broadcast interval", can_bcast_int, { can_bcast1_on }
       field = "0x280 rpm * 4", can_bcast1_280x4, { can_bcast1_on }
       field = "0x280 rpm * 1", can_bcast1_280x1, { can_bcast1_on }
       field = "0x289 coolant", can_bcast1_289, { can_bcast1_on }

        dialog = canvss1, "CAN VSS and gear selection"
          field = "This is for polling the actual vehicle speed"
          field = "mph/kph from a remote device."
          field = "For a pulse input use the CAN PWM instead"
          field = "Remote CAN id", vss1_can_id
          field = "Remote CAN table", vss1_can_table
          field = ""
          field = "VSS1 offset", vss1_can_offset, {vss_opt1 == 0x0e}
          field = "Data size", vss1_can_size, {vss_opt1 == 0x0e}
          field = ""
          field = "VSS2 offset", vss2_can_offset, {vss_opt2 == 0x0e}
          field = "Data size", vss2_can_size, {vss_opt2 == 0x0e}
          field = ""
          field = "Gear# offset", gear_can_offset, {(gear_method & 0x03) == 0x03}

        dialog = canrtc, "Real time clock"
          field = "Enable real time clock", opt142_rtc
          field = "Remote CAN id", can_poll_id_rtc, {opt142_rtc == 2}
          field = "Table", poll_table_rtc, {opt142_rtc == 2 }
          field = "Offset", poll_offset_rtc, {opt142_rtc == 2}

        dialog = canego, "Innovate EGO data via CAN"
          field = "Fetch Innovate EGO data", can_poll2_ego
          field = "Remote CAN id", can_ego_id, {can_poll2_ego}
          field = "Table", can_ego_table, {can_poll2_ego}
          field = "Offset", can_ego_offset, {can_poll2_ego}

          dialog = canvss, "CAN VSS & RTC & EGO Parameters", yAxis
            panel = canvss1
            panel = canego

          dialog = realtimeclock, "", yAxis
            panel = canrtc
            panel = std_ms3Rtc
     
          dialog = tablesw1, "Table Switching"
          field = "Fuel Table Switching",         f5_0_tsf, { !(dualfuel_sw_on && dualfuel_sw_fuel) }
          field = "Switch source",        f5_0_tsf_opt,  { f5_0_tsf && !(dualfuel_sw_on && dualfuel_sw_fuel)}
          field = "Input pin", tsw_pin_f, { f5_0_tsf && (f5_0_tsf_opt == 0) && !(dualfuel_sw_on && dualfuel_sw_fuel)}
          field = "rpm greater than",     tsf_rpm,  { f5_0_tsf && (f5_0_tsf_opt == 1) && !(dualfuel_sw_on && dualfuel_sw_fuel)}
          field = "kPa greater than",    tsf_kpa,  { f5_0_tsf && (f5_0_tsf_opt == 2) && !(dualfuel_sw_on && dualfuel_sw_fuel)}
          field = "TPS greater than",    tsf_tps,  { f5_0_tsf && (f5_0_tsf_opt == 3) && !(dualfuel_sw_on && dualfuel_sw_fuel)}
          field = ""
          field = "Spark Table Switching",         f5_0_tss, { !(dualfuel_sw_on && dualfuel_sw_spk) }
          field = "Switch source",        f5_0_tss_opt,  { f5_0_tss && !(dualfuel_sw_on && dualfuel_sw_spk)}
          field = "Input pin", tsw_pin_s, { f5_0_tss && (f5_0_tss_opt == 0) }
          field = "rpm greater than",     tss_rpm,  { f5_0_tss && (f5_0_tss_opt == 1) && !(dualfuel_sw_on && dualfuel_sw_spk)}
          field = "kPa greater than",    tss_kpa,  { f5_0_tss && (f5_0_tss_opt == 2) && !(dualfuel_sw_on && dualfuel_sw_spk)}
          field = "TPS greater than",    tss_tps,  { f5_0_tss && (f5_0_tss_opt == 3) && !(dualfuel_sw_on && dualfuel_sw_spk)}
          field = ""
          field = "Req Fuel Switching", tsw_pin_rf, { !(dualfuel_sw_on && dualfuel_sw_rf)}
          field = "Alternate ReqFuel (lower number)", ReqFuel_alt, { tsw_pin_rf || (dualfuel_sw_on && dualfuel_sw_rf)}
          field = ""
          field = "AFR table Switching", tsw_pin_afr, { !(dualfuel_sw_on && dualfuel_sw_afr)}
          field = ""
          field = "Stoich Switching", tsw_pin_stoich, { !(dualfuel_sw_on && dualfuel_sw_stoich)}
          field = "Alternate Stoich", stoich_alt, { tsw_pin_stoich || (dualfuel_sw_on && dualfuel_sw_stoich)}
          field = ""
          field = "Boost control table switching is on the boost control menu"

        dialog = dualfuel, "Dual Fuel switching"
            field = "Dual fuel enable", dualfuel_sw_on
            field = "Mode", dualfuel_opt_mode, { dualfuel_sw_on }
            field = "Outputs mode", dualfuel_opt_out, { dualfuel_sw_on && !dualfuel_opt_mode }
            field = "Secondary outputs", staged_extended_opts_use_v3, { dualfuel_sw_on && (dualfuel_opt_out || dualfuel_opt_mode) }
;was { ((dualfuel_opt_out || dualfuel_opt_mode) && hardware_fuel && ((nCylinders <= 4)) || ((nCylinders > 4) && (sequential == 1))) }
            field = "Secondary v3 alternate", staged_extended_opts_simult, { ((dualfuel_opt_out || dualfuel_opt_mode) && staged_extended_opts_use_v3) || ((nCylinders > 4) && (dualfuel_opt_out || dualfuel_opt_mode) && hardware_fuel && !(sequential & 0x1)) }
            field = "Input pin", dualfuel_pin, { dualfuel_sw_on && !dualfuel_opt_mode }
            field = "Alt. fuel tables", dualfuel_sw_fuel, { dualfuel_sw_on && !dualfuel_opt_mode }
            field = "Alt. spark tables", dualfuel_sw_spk, { dualfuel_sw_on && !dualfuel_opt_mode }
            field = "Alt. AFR tables", dualfuel_sw_afr, { dualfuel_sw_on && !dualfuel_opt_mode }
            field = "Alt. ReqFuel", dualfuel_sw_rf, { dualfuel_sw_on && !dualfuel_opt_mode }
            field = "Alt. Stoich", dualfuel_sw_stoich, { dualfuel_sw_on && !dualfuel_opt_mode }
            field = "Alt. warmup", dualfuel_sw_wue, { dualfuel_sw_on && !dualfuel_opt_mode }
            field = "Alt. afterstart", dualfuel_sw_ase, { dualfuel_sw_on && !dualfuel_opt_mode }
            field = "Alt. priming", dualfuel_sw2_prime, { dualfuel_sw_on && !dualfuel_opt_mode }
            field = "Alt. cranking pulse", dualfuel_sw2_crank, { dualfuel_sw_on && !dualfuel_opt_mode }
            field = "Alt. injector params", dualfuel_sw2_injp, { dualfuel_sw_on && !dualfuel_opt_mode }
            field = "Alt. small pulsewidths", dualfuel_sw2_smpw, { dualfuel_sw_on && !dualfuel_opt_mode }
            field = "Alt. overboost", dualfuel_sw2_ob, { dualfuel_sw_on && !dualfuel_opt_mode }
            field = "Alt. boost table", dualfuel_sw2_boosw, { dualfuel_sw_on && !dualfuel_opt_mode }
            field = ""
            field = "Enable Temperature Adjustment", dualfuel_opt_temp, { dualfuel_sw_on && !dualfuel_opt_mode }
            field = "Temperature on", dualfuel_temp_sens, { dualfuel_sw_on && dualfuel_opt_temp}
            field = "Enable Pressure Adjustment", dualfuel_opt_press, { dualfuel_sw_on && !dualfuel_opt_mode }
            field = "Gauge Pressure in kPa on", dualfuel_press_sens, { dualfuel_sw_on && dualfuel_opt_press}
            field = "Pressure used = Gauge + Baro - MAP"

        dialog = tablesw, "Table Switching and Dual Fuel", xAxis
            panel = tablesw1, West
            panel = dualfuel, East

          dialog = outputtest_l, "Output test modes", yAxis
           field = "Enter 12345, TAB, Burn", testmodelock
           field = "Only Burn once. Turn off power when finished"
           field = "-"
           field = "Fuel pump", testop_fp
           field = "Test mode", testmode
           field = "Output interval", testint
           field = "Coil testing mode", testop_coil, { testmode == 1 }
           field = "Coil output to test", testsel_coil, {testmode == 1}
           field = "Dwell", testdwell, { testmode == 1 }
           field = "Injector testing mode", testop_inj, { testmode == 2 }
           field = "Injector channel to test", testsel_inj, {testmode == 2}
           field = "Pulsewidth", testpw, { testmode == 2 }
           field = "Total number of injections", testinjcnt, {testmode == 2}
           field = "-"
           field = "Note: The following only applies to Inj1 and Inj2"
           field = "Injector PWM parameters", testop_pwm, { testmode == 2 }
           field = "PWM Current Limit",          testinjPwmP, { testmode == 2 && testop_pwm }
           field = "PWM Time Threshold",         testinjPwmT, { testmode == 2 && testop_pwm }
           field = "Injector PWM Period",        testinjPwmPd , { testmode == 2 && testop_pwm }

          dialog = outputtest_r, "Reference gauges", yAxis
;            panel = vmcurve, North
;            panel = s5curve, South
            gauge = voltMeter, North
            gauge = injcountGauge, South

          dialog = outputtest, "", xAxis
            panel = outputtest_l, West
            panel = outputtest_r, East

          dialog = iactest, "Idle valve test"
           field = "Idle testing enable", iactestlock
           field = ""
           field = "Move to home position", iactest, {iactestlock}
           field = "iac home step", iachometest, {iactestlock && ( IdleCtl == 2 || IdleCtl == 3 || IdleCtl == 5 || IdleCtl == 7 || IdleCtl == 8 ) }
           field = "iac step", iacpostest
           field = "Set the steps before enabling testing"
           field = "For PWM valves enter 0-100, for stepper use 0-255"

          dialog = codetest, "Code dev test options"
           field = "iac pos test", iacpostest
;           field = "tooth to debug", dbgtooth
           field = "Pulsewidth scaling", feature3_pw4x
           field = "Nitrous-in pulldown", feature3_n2oin
           field = "S16 debug", s16_debug
           field = "U08 debug 134", u08_debug134

          dialog = EAElagcomp, "EAE lag compensation"
           field = "Source",  EAElagsource
           field = "Threshold", EAElagthresh
           field = "Max RPM", EAElagRPMmax
     
      dialog = accelsettings, "Accel enrich settings"
          field = "Use Normal Accel or new Accel-pump Accel", AE_options
          field = "#Accel enrich down-scaling with RPM"
          field = "Low RPM Threshold",       ae_lorpm
          field = "High RPM Threshold",      ae_hirpm
          field = ""
          field = "Enhanced Accel Enrichment",            EAEOption

          dialog = RotaryTrailingSettings, "Rotary Settings"
          field = "See also Rotary Split Table"
          field = "Output mode", RotarySplitModeFD, { (twoStroke == 3) && (nCylinders == 2) }
          field = "Allow negative split?", RotarySplitModeNeg, { twoStroke == 3 }
          field = "Trailing Dwell time", dwelltime_trl, { (twoStroke == 3) && (spk_mode0 >1) && (dwellmode==0) }

          dialog = noisefiltering, "", yAxis
          field = "See the web help for more information about noise filtering"
          field = "#GLOBAL TIMER NOISE FILTER DELAY"
          field = "Noise filter period", dlyct
    ; note that use of this depends on whether the wheel is single/double edged
          field = "#PRIMARY TACH (crank)"
          field = "Noise Filter Enabled", NoiseFilterOpts
          field = "Use noise filter curve to tune"
          field = "Tach period rejection", NoiseFilterOpts1
          field = "Tach interrupt masking", NoiseFilterOpts2, {NoiseFilterOpts == 0}
          field = "Time",                     ICISR_tmask, {NoiseFilterOpts1 || NoiseFilterOpts2}
          field = "Percentage",               ICISR_pmask, {NoiseFilterOpts1 || NoiseFilterOpts2}
    ;      field = "Polarity checking", NoiseFilterOpts3, {NoiseFilterOpts == 0}

    ; note that use of this depends on whether the wheel uses a cam and/or if it is single/double edged
          field = "#SECONDARY TACH (cam)"
          field = "Noise Filter Enabled",    secondtrigopts;
          field = "Noise Filter Time Period",      TC5_required_width, { secondtrigopts & 0x1 }
          field = "Tach period rejection", secondtrigopts1
          field = "Tach interrupt masking", secondtrigopts2, { secondtrigopts == 0 }
          field = "Time",                     IC2ISR_tmask, {secondtrigopts1 || secondtrigopts2}
          field = "Percentage",               IC2ISR_pmask, {secondtrigopts1 || secondtrigopts2}
    ;      field = "Polarity checking", secondtrigopts3, { secondtrigopts == 0 }

          dialog = noisefilterpad
          field = "Note, a power cycle is required after enabling/disabling"
          field = " the noise filters"
            field = ""
            field = ""
            field = ""
            field = ""

          dialog = Eastnoisefilter, "", yAxis
            panel = NoiseFiltercurve
           panel = noisefilterpad, South

          dialog = noisefiltering2, "Noise Filtering", xAxis
            panel = noisefiltering, West
            panel = Eastnoisefilter, East


          dialog = launchwest, ""
          field = "Launch control option:",        launch_opt_on
          field = ""
          field = "Input on:",  launch_opt_pins, { launch_opt_on >0 }
          field = "Launch retard above", launch_sft_lim, {launch_opt_on >0}
          field = "Retard to", launch_sft_deg, {launch_opt_on >0}
          field = "Launch fuel add/remove", launch_opt_bank, { launch_opt_on >0 }
          field = "Fuel addition", launch_addfuel, {launch_opt_bank && launch_opt_on >0}
          field = "Enable Launch when TPS above  ", launch_tps, { launch_opt_on >0}
          field = "Launch hard limit", launch_hrd_lim, {launch_opt_on >0}
          field = "Limiter method", launchlimopt, { launch_opt_on >0}
          field = "Cut X sparks", launchcutx, { (launchlimopt & 1) && (launch_opt_on >0) }
          field = "from Y events", launchcuty, { (launchlimopt & 1) && (launch_opt_on >0) }
          field = "Cut fuel above", launch_fcut_rpm, { (launchlimopt & 1) && (launch_opt_on >0) }
          field = "Flat shift arming rpm",          flats_arm,   { launch_opt_on >1 }
          field = "Flat shift mode retard above",   flats_sft,   { launch_opt_on >1 }
          field = "Retard to :  ",                  flats_deg,   { launch_opt_on >1 }
          field = "Flat shift hard rev limit",      flats_hrd,   { launch_opt_on >1 }
          field = ""
          field = "Timed retard after launch",      launch_opt_retard,   { launch_opt_on }

          dialog = launchnortheast, "Variable Launch"
          field = "Variable launch input",        launch_var_on, { launch_opt_on >0 }
          field = " -minimum setting", launch_var_low, {launch_var_on && launch_opt_on >0 }
          field = " -maximum setting", launch_var_up, {launch_var_on && launch_opt_on >0 }
          field = " -soft limit lower by", launch_var_sof, {launch_var_on && launch_opt_on >0 }

          dialog = launchsoutheast, "3-step / burnout limiter"
          field = "3-step input", launch_3step_in, {launch_opt_on >0 }
          field = " -Retard above", launch_sft_lim3, {launch_3step_in && launch_opt_on >0}
          field = " -Retard to", launch_sft_deg3, {launch_3step_in && launch_opt_on >0}
          field = " -Hard limit", launch_hrd_lim3, {launch_3step_in && launch_opt_on >0}

          dialog = launchtbtstop, "Transbrake, throttle stop"
          field = "Transbrake button input", timedout1_in
          field = "Transbrake output", timedout1_out, {timedout1_in}
          field = "Delay", timedout1_offdelay, {timedout1_in && timedout1_out}
          field = "" 
          field = "Throttle stop output", tstop_out
          field = "On delay after launch", tstop_delay, {tstop_out}
          field = "Keep on for", tstop_hold, {tstop_out}


          dialog = launcheast, "", yAxis
          panel = launchnortheast
          panel = launchtbtstop
          panel = launchsoutheast

          dialog = launch, "Launch control/ 2-step / 3-step", border
          panel = launchwest, West
          panel = launcheast, East

          dialog = tacho, "Tachometer output"
    ;      topicHelp = tachohelp
          field = "Tacho output enabled",         tacho_opt80
          field = ""
          field = "Output on:",  tacho_opt3f, { tacho_opt80 }
          field = "Speed", tacho_opt40, { tacho_opt80 }

          dialog = overrun, "Over Run Fuel Cut"
    ;      topicHelp = Chelp8
          field = "Over Run Fuel Cut",         OvrRunC
          field = "Cut fuel when:"
          field = "RPM greater than:",         fc_rpm,  { OvrRunC }
          field = "and KPa lower than:  ",     fc_kpa,  { OvrRunC }
          field = "and TPS lower than:  ",     fc_tps,  { OvrRunC }
          field = "and coolant greater than:", fc_clt,  { OvrRunC }
          field = "after delay",              fc_delay, { OvrRunC }
          field = ""
          field = "Delay EGO after fuel return:", fc_ego_delay, { OvrRunC }
          field = "Return fuel when RPM less than:", fc_rpm_lower, { OvrRunC }

          dialog = staging, "Staged Injection"
          field = "!Staged injection first parameter", staged_first_param
          field = "!Primary injector size",     staged_pri_size, { staged_first_param }

          field = "!Secondary injector size",   staged_sec_size, { staged_first_param }
          field = "Transition fully to secondaries", staged_extended_opts_pw1off, { staged_first_param }
          field = "Secondary outputs",  staged_extended_opts_use_v3, { staged_first_param }
          field = "Secondary v3 alternate", staged_extended_opts_simult, { (staged_extended_opts_use_v3 && staged_first_param) || ((nCylinders > 4) && (staged_first_param) && (hardware_fuel) && !(sequential & 0x1)) }
          field = ""
          field = "Gradual transition", staged_transition_on, { staged_first_param && ((staged_first_param & 0x7) != 5) }
          field = "Transition events", staged_transition_events, { (staged_first_param && staged_transition_on) && ((staged_first_param & 0x7) != 5) }
          field = "Primary reduction delay", staged_primary_delay, { (staged_first_param && staged_transition_on) && ((staged_first_param & 0x7) != 5) }
          field = "Secondary enrichment", staged_secondary_enrichment, { (staged_first_param && staged_transition_on) && ((staged_first_param & 0x7) != 5) }
          field = ""
          field = "Primary staging threshold", staged_param_1, { staged_first_param && ((staged_first_param & 0x7) != 5) }
          field = "Primary staging hysteresis", staged_hyst_1, { staged_first_param && ((staged_first_param & 0x7) != 5) }
          field = ""
          field = "Second parameter", staged_second_param, { staged_first_param && ((staged_first_param & 0x7) != 5) }
          field = "Secondary staging threshold", staged_param_2, { staged_second_param }
          field = "Secondary staging hysteresis", staged_hyst_2, { staged_second_param }
          field = "Secondary staging logic", staged_second_logic, { staged_second_param }

       dialog = stagedCombined, "Staged Settings", border
          panel = staging, West
          panel = stagedTable, Center, { (staged_first_param & 0x7) == 5 }

       dialog = crsettings, "Cranking settings"

          field = "Cranking RPM",          crankingRPM
          field = ""
          field = "Flood clear TPS", floodClear
          field = "Above this throttle no fuel is injected"
          field = "Cranking fuel pulse rate ", altcrank
          field = ""
          field = "Engines with lots of cylinders such as V12 may find"
          field = "that the injecting fuel on every tach event gives"
          field = "difficult hot starting. This option allows the fuel"
          field = "to be injected on alternate events (with twice the"
          field = "pulse width)"
          field = "Priming pulse delay", primedelay
          field = "Ignore MAT correction during ASE", feature3_matase
          field = "ASE count units", feature3_aseunit

       dialog = generalSettings, "General Settings"
    ;      topicHelp = "http://www.megasquirt.info/megatune.htm#sg"

             field = "Barometric Correction", baroCorr
             field = "Realtime baro port",    rtbaroport, {baroCorr == 2}
             field = "Upper limit", baro_upper, {baroCorr}
             field = "Lower limit", baro_lower, {baroCorr}
             field = "Default baro", baro_default, {baroCorr < 2}
            field = "MAP Sensor type", mapport_t
            field = "Voltage input port", mapport, {mapport_t == 0}
            field = "Frequency input port", mapport_f, {mapport_t == 1}
            field = "Low frequency", map_freq0, {mapport_t == 1}
            field = "High frequency", map_freq1, {mapport_t == 1}
            field = "2nd MAP port",    map2port
            field = "(See also Tools->Calibrate MAP/Baro)"
             field = "MegaView Temp. Units", tempUnits

          field = "#Input Smoothing Lag Factors"
             field = "MAP Averaging Lag Factor",    mapLF
             field = "RPM Averaging Lag Factor",    rpmLF
             field = "TPS Averaging Lag Factor",    tpsLF
             field = "Lambda Averaging Lag Factor", egoLF
             field = "CLT/MAT/Battery Lag Factor",  adcLF
          field = "Auto-zero TPS", feature3_tps

          dialog = secondaryLoad, "Load parameters"
          field = "Primary Fuel Load",      algorithm
          field = "Secondary Fuel Load",      algorithm2
          field = "Secondary Fuel",		  loadCombine, {algorithm2 != 0 }
          field = "Multiply MAP (caution!)",    loadMult
          field = "99% of installs should use Multiply"
          field = ""
          field = "Incorporate AFRTarget", loadStoich
          field = "Stoichiometric AFR", stoich ;, { loadStoich } needed for lambda calc even if not incl AFR
          field = ""
          field = "Primary Ignition Load",    IgnAlgorithm
          field = "Secondary Ignition Load",  IgnAlgorithm2
          field = "NOTE: secondary ignition table is always additive"
          field = ""
          field = "AFR table load", afrload
          field = "EAE curve load", eaeload

        dialog = eastgeneral, ""
          panel = secondaryLoad, North
          panel = overrun, South

       dialog = generalsettings2, "General settings", border
          panel = generalSettings, West
          panel = eastgeneral, East

       dialog = revlimiter, ""
        field = "SPARK RETARD"
        field = "Mode",  RevLimOption_retard
        field = "Retard above",        RevLimNormal1, { RevLimOption_retard && (RevLimCLTbased == 0) }
        field = "Maximum Retard",        RevLimMaxRtd, { RevLimOption_retard == 1 }
        field = "Retard to",        RevLimRtdAng, { RevLimOption_retard == 2}
        field = ""
        field = "SPARK CUT"
        field = "Enable spark cut limiting", RevLimOption_spkcut
        field = "Spark cut above",        RevLimNormal3, { RevLimOption_spkcut }
        field = "Cut X sparks",    RevLimcutx, { RevLimOption_spkcut }
        field = "from Y events",         RevLimcuty, { RevLimOption_spkcut }
        field = ""
        field = "FUEL CUT"
        field = "Hard Fuel cut limit",        RevLimNormal2
        field = "Hysteresis",        RevLimNormal2_hyst
        field = ""
        field = "COOLANT TEMP LIMITER"
        field = "Rev Limiter CLT based", RevLimCLTbased 
        field = "Rev Limit Adder",       RevLimRpm2, { RevLimCLTbased & 1 }
        field = "Rev Limit TPS bypass",  TpsBypassCLTRevlim, { RevLimCLTbased & 1 }
        field = "RPM when in TPS bypass", RevLimTPSbypassRPM, { RevLimCLTbased & 1 }
        field = "Beyond upper temperature, nomal limits above are used"

       dialog = revlimiter2, "Rev limiter", border
         panel = revlimiter, West
         panel = revlimiterBins, Center, { RevLimCLTbased & 1 }

       dialog = flexn, ""
        field = "#Spark/fuel"
        field = "Sensor frequency"
        field = "Ethanol mix"
        field = "Fuel Correction"
        field = "Timing Correction"
        field = "#Temp sense"
        field = "Sensor PW"
        field = "Fuel temp"

       dialog = flexl, ""
        field = "Low"
        field = "", fuelFreq0,   { flexFuel }
        field = "", flex_pct0,   { flexFuel }
        field = "", fuelCorr0,   { flexFuel }
        field = "", fuelSpkDel0, { flexFuel }
        field = "Low"
        field = "", ff_tpw0, { flexFuel && (fueltemp1 == 1)}
        field = "", ff_temp0, { flexFuel && (fueltemp1 == 1)}
        
       dialog = flexh, ""
        field = "High"
        field = "", fuelFreq1,   { flexFuel }
        field = "", flex_pct1,   { flexFuel }
        field = "", fuelCorr1,   { flexFuel }
        field = "", fuelSpkDel1, { flexFuel }
        field = "High"
        field = "", ff_tpw1, { flexFuel && (fueltemp1 == 1)}
        field = "", ff_temp1, { flexFuel && (fueltemp1 == 1)}

        dialog = ff_table1, "", xAxis
        panel = flexn

        panel = flexl
        panel = flexh

       dialog = flexFuelSettings, "Fuel Sensor Settings", yAxis
          field = "Flex Fuel Sensor",         flexFuel
          field = "Sensor port",              flexport,    { flexFuel > 0 }
        panel = ff_table1
          field = "Temperature input",        fueltemp1

       dialog = sequentialOptions, "Sequential Fuel Injection"
            field = "Main fuel outputs",               hardware_fuel
            field = "Sequential On",               sequential
            field = "Angle specifies:",            sequential_angle_spec, { sequential != 0 }
            field = "Injector Trim",             sequential_trim_on_off
#if CYL_12_16_SUPPORT
            field = "Injector I/J outputs",      hardware_injij, { nCylinders > 8}
#endif

       dialog = firingorder1, "Firing Order"
          field = "A.", firea  
          field = "B.", fireb, { nCylinders > 1}
          field = "C.", firec, { nCylinders > 2}
          field = "D.", fired, { nCylinders > 3}
          field = "E.", firee, { nCylinders > 4}
          field = "F.", firef, { nCylinders > 5}
          field = "G.", fireg, { nCylinders > 6}
          field = "H.", fireh, { nCylinders > 7}

#if CYL_12_16_SUPPORT
       dialog = firingorder2, "Firing Order"
          field = "I.", firei, { nCylinders > 8}  
          field = "J.", firej, { nCylinders > 9}
          field = "K.", firek, { nCylinders > 10}
          field = "L.", firel, { nCylinders > 11}
          field = "M.", firem, { nCylinders > 12}
          field = "N.", firen, { nCylinders > 13}
          field = "O.", fireo, { nCylinders > 14}
          field = "P.", firep, { nCylinders > 15}
#endif
        field = ""

    dialog = firingorder, "", xAxis
        panel = firingorder1, West
#if CYL_12_16_SUPPORT 
        panel = firingorder2, East
#endif

      dialog = seqfo, "", border
         panel = sequentialOptions, North
         panel = firingorder, South

      dialog = base3, "", yAxis
        field = "Engine size", enginesize
        field = "Injector size each", staged_pri_size

      dialog = base2, "", yAxis
        panel = std_injection, North
        panel = base3, South
        
      dialog = base, "Engine and Sequential Settings", border
         panel = base2, West
         panel = seqfo, East

       dialog = ot_ot2, "", yAxis
          field = "MS3X parameters"
          field = "Dead time"
          field = "@ 13.2V"
          field = "A", inj2Open1
          field = "B", inj2Open2, {opentime2_opt1_master}
          field = "C", inj2Open3, {opentime2_opt1_master}
          field = "D", inj2Open4, {opentime2_opt1_master}
          field = "E", inj2Open5, {opentime2_opt1_master}
          field = "F", inj2Open6, {opentime2_opt1_master}
          field = "G", inj2Open7, {opentime2_opt1_master}
          field = "H", inj2Open8, {opentime2_opt1_master}

       dialog = ot_curve2, "", yAxis
          field = "", opentime2_opt1_master
          field = "Voltage dead"
          field = "time curve"
          field = "", opentime2_opt1
          field = "", opentime2_opt2, {opentime2_opt1_master}
          field = "", opentime2_opt3, {opentime2_opt1_master}
          field = "", opentime2_opt4, {opentime2_opt1_master}
          field = "", opentime2_opt5, {opentime2_opt1_master}
          field = "", opentime2_opt6, {opentime2_opt1_master}
          field = "", opentime2_opt7, {opentime2_opt1_master}
          field = "", opentime2_opt8, {opentime2_opt1_master}

       dialog = injchar_ms3x_2, "MS3X Injectors", xAxis
          panel = ot_ot2
          panel = ot_curve2

       dialog = injchar_v3_2, "Mainboard Injectors", yAxis
          field = "BANK 1 Dead time @ 13.2V", inj2Opena
          field = "Correction curve", opentime2_opta
          field = "PWM current limiting", opentime2_opta_pwm
          field = "PWM Current Limit",          inj2PwmP, {opentime2_opta_pwm}

          field = "PWM Time Threshold",         inj2PwmT, {opentime2_opta_pwm}
          field = "Injector PWM Period",       inj2PwmPd, {opentime2_opta_pwm}
          field = ""
          field = "BANK 2 different settings", opentime2_optb_own
          field = "Dead time", inj2Openb, {opentime2_optb_own}
          field = "Correction curve", opentime2_optb, {opentime2_optb_own}
          field = "PWM current limiting", opentime2_optb_pwm, {opentime2_optb_own}
          field = "PWM Current Limit",          inj2PwmP2, {opentime2_optb_own && opentime2_optb_pwm}
          field = "PWM Time Threshold",         inj2PwmT2, {opentime2_optb_own && opentime2_optb_pwm}
          field = "Injector PWM Period",       inj2PwmPd2, {opentime2_optb_own && opentime2_optb_pwm}

       dialog = injCharswest2, "", yAxis
          panel = injchar_ms3x_2, North
          panel = injchar_v3_2, South

      dialog = injsettings2, "", border
         panel = injCharswest2, West

       dialog = ot_ot, "", yAxis
          field = "MS3X parameters"
          field = "Dead time"
          field = "@ 13.2V"
          field = "A", injOpen1
          field = "B", injOpen2, {opentime_opt1_master}
          field = "C", injOpen3, {opentime_opt1_master}
          field = "D", injOpen4, {opentime_opt1_master}
          field = "E", injOpen5, {opentime_opt1_master}
          field = "F", injOpen6, {opentime_opt1_master}
          field = "G", injOpen7, {opentime_opt1_master}
          field = "H", injOpen8, {opentime_opt1_master}

       dialog = ot_curve, "", yAxis
          field = "", opentime_opt1_master
          field = "Voltage dead"
          field = "time curve"
          field = "", opentime_opt1
          field = "", opentime_opt2, {opentime_opt1_master}
          field = "", opentime_opt3, {opentime_opt1_master}
          field = "", opentime_opt4, {opentime_opt1_master}
          field = "", opentime_opt5, {opentime_opt1_master}
          field = "", opentime_opt6, {opentime_opt1_master}
          field = "", opentime_opt7, {opentime_opt1_master}
          field = "", opentime_opt8, {opentime_opt1_master}

       dialog = injchar_ms3x, "MS3X Injectors", xAxis
          panel = ot_ot
          panel = ot_curve

       dialog = injchar_v3, "Mainboard Injectors", yAxis
          field = "BANK 1 Dead time @ 13.2V", injOpena
          field = "Correction curve", opentime_opta
          field = "PWM current limiting", opentime_opta_pwm
          field = "PWM Current Limit",          injPwmP, {opentime_opta_pwm}
          field = "PWM Time Threshold",         injPwmT, {opentime_opta_pwm}
          field = "Injector PWM Period",       injPwmPd, {opentime_opta_pwm}
          field = ""
          field = "BANK 2 different settings", opentime_optb_own

          field = "Dead time", injOpenb, {opentime_optb_own}
          field = "Correction curve", opentime_optb, {opentime_optb_own}
          field = "PWM current limiting", opentime_optb_pwm, {opentime_optb_own}
          field = "PWM Current Limit",          injPwmP2, {opentime_optb_own && opentime_optb_pwm}
          field = "PWM Time Threshold",         injPwmT2, {opentime_optb_own && opentime_optb_pwm}
          field = "Injector PWM Period",       injPwmPd2, {opentime_optb_own && opentime_optb_pwm}

       dialog = injCharswest, "", yAxis
          panel = injchar_ms3x, North
          panel = injchar_v3, South

      dialog = injcurveswest, "", yAxis
         panel = opencurve0, North
         panel = opencurve2, South

      dialog = injcurveseast, "", yAxis
         panel = opencurve1, North
         panel = opencurve3, South

      dialog = injcurves, "", xAxis
         panel = injcurveswest
         panel = injcurveseast

      dialog = injsettings, "", border
         panel = injCharswest, West
         panel = injcurves, Center

; 9-16
       dialog = ot_otb, "", yAxis
          field = "Dead time"
          field = "@ 13.2V"
          field = "I", injOpena,  {opentime_opt1_master}
          field = "J", injOpenb, {opentime_opt1_master}
          field = "K", injOpen11, {opentime_opt1_master}
          field = "L", injOpen12, {opentime_opt1_master}
          field = "M", injOpen13, {opentime_opt1_master}
          field = "N", injOpen14, {opentime_opt1_master}
          field = "O", injOpen15, {opentime_opt1_master}
          field = "P", injOpen16, {opentime_opt1_master}

       dialog = ot_curveb, "", yAxis
          field = "Voltage dead"
          field = "time curve"
          field = "", opentime_opta, {opentime_opt1_master}
          field = "", opentime_optb, {opentime_opt1_master}
          field = "", opentime_opt11, {opentime_opt1_master}
          field = "", opentime_opt12, {opentime_opt1_master}
          field = "", opentime_opt13, {opentime_opt1_master}
          field = "", opentime_opt14, {opentime_opt1_master}
          field = "", opentime_opt15, {opentime_opt1_master}
          field = "", opentime_opt16, {opentime_opt1_master}

       dialog = injsettingsb, "Injectors", xAxis
          panel = ot_otb
          panel = ot_curveb

; table-switched alternate parameters
       dialog = ot_ot2b, "", yAxis
          field = "Dead time"
          field = "@ 13.2V"
          field = "I", inj2Opena,  {opentime2_opt1_master}
          field = "J", inj2Openb, {opentime2_opt1_master}
          field = "K", inj2Open11, {opentime2_opt1_master}
          field = "L", inj2Open12, {opentime2_opt1_master}
          field = "M", inj2Open13, {opentime2_opt1_master}
          field = "N", inj2Open14, {opentime2_opt1_master}
          field = "O", inj2Open15, {opentime2_opt1_master}
          field = "P", inj2Open16, {opentime2_opt1_master}

       dialog = ot_curve2b, "", yAxis
          field = "Voltage dead"
          field = "time curve"
          field = "", opentime2_opta, {opentime2_opt1_master}
          field = "", opentime2_optb, {opentime2_opt1_master}
          field = "", opentime2_opt11, {opentime2_opt1_master}
          field = "", opentime2_opt12, {opentime2_opt1_master}
          field = "", opentime2_opt13, {opentime2_opt1_master}
          field = "", opentime2_opt14, {opentime2_opt1_master}
          field = "", opentime2_opt15, {opentime2_opt1_master}
          field = "", opentime2_opt16, {opentime2_opt1_master}

       dialog = injsettingsb2, "Injectors", xAxis
          panel = ot_ot2b
          panel = ot_curve2b

       dialog = smallpwwest2, ""
          field = "Enable non-linear small pulsewidths", smallpw2_opt1_master
          field = "(This is for the alternate injectors from dual-fuel)"

          field = "MS3X injector A", smallpw2_opt1, { smallpw2_opt1_master }

          field = "MS3X injector B", smallpw2_opt2, { smallpw2_opt1_master }
          field = "MS3X injector C", smallpw2_opt3, { smallpw2_opt1_master }
          field = "MS3X injector D", smallpw2_opt4, { smallpw2_opt1_master }
          field = "MS3X injector E", smallpw2_opt5, { smallpw2_opt1_master }
          field = "MS3X injector F", smallpw2_opt6, { smallpw2_opt1_master }
          field = "MS3X injector G", smallpw2_opt7, { smallpw2_opt1_master }
          field = "MS3X injector H", smallpw2_opt8, { smallpw2_opt1_master }
          field = ""
          field = "Mainboard Bank 1", smallpw2_opta, { smallpw2_opt1_master }
          field = ""
          field = "Mainboard Bank 2", smallpw2_optb, { smallpw2_opt1_master }

      dialog = smallpw2, "Non-Linear small pulsewidths 2", border
         panel = smallpwwest2, West

       dialog = smallpwwest, ""
          field = "Enable non-linear small pulsewidths", smallpw_opt1_master
          field = "!CAUTION!"
          field = "Unless you have specific injector data these"
          field = "'curves' must be a straight line from 0-2"
          field = "Ensure the start and end points are equal"
          field = "(e.g. 0.000, 0.000 and 2.000, 2.000)"
          field = "Select the pulsewidth curve for each injector"

          field = "MS3X injector A", smallpw_opt1, { smallpw_opt1_master && ((hardware_fuel) ) }
          field = "MS3X injector B", smallpw_opt2, { smallpw_opt1_master && ((hardware_fuel) && (nInjectors > 1)) }
          field = "MS3X injector C", smallpw_opt3, { smallpw_opt1_master && ((hardware_fuel) && (nInjectors > 2)) }
          field = "MS3X injector D", smallpw_opt4, { smallpw_opt1_master && ((hardware_fuel) && (nInjectors > 3)) }
          field = "MS3X injector E", smallpw_opt5, { smallpw_opt1_master && ((hardware_fuel) && (nInjectors > 4)) }
          field = "MS3X injector F", smallpw_opt6, { smallpw_opt1_master && ((hardware_fuel) && (nInjectors > 5)) }
          field = "MS3X injector G", smallpw_opt7, { smallpw_opt1_master && ((hardware_fuel) && (nInjectors > 6)) }
          field = "MS3X injector H", smallpw_opt8, { smallpw_opt1_master && ((hardware_fuel) && (nInjectors > 7)) }
          field = ""
          field = "Mainboard Bank 1", smallpw_opta, { smallpw_opt1_master }
          field = ""
          field = "Mainboard Bank 2", smallpw_optb, { smallpw_opt1_master }

      dialog = smallcurveswest, "", yAxis
         panel = smallcurve0
         panel = smallcurve2

      dialog = smallcurveseast, "", yAxis
         panel = smallcurve1
         panel = smallcurve3

      dialog = smallcurves, "", xAxis
         panel = smallcurveswest
         panel = smallcurveseast

      dialog = smallpw, "Non-Linear small pulsewidths", border
         panel = smallpwwest, West
         panel = smallcurves, Center

       dialog = smallpwb, ""
          field = "Injector I", smallpw_opta,  { smallpw_opt1_master && ((hardware_fuel) && (nInjectors > 8)) }
          field = "Injector J", smallpw_optb,  { smallpw_opt1_master && ((hardware_fuel) && (nInjectors > 9)) }
          field = "Injector K", smallpw_opt11, { smallpw_opt1_master && ((hardware_fuel) && (nInjectors > 10)) }
          field = "Injector L", smallpw_opt12, { smallpw_opt1_master && ((hardware_fuel) && (nInjectors > 11)) }
;          field = "Injector M", smallpw_opt13, { smallpw_opt1_master && ((hardware_fuel) && (nInjectors > 12)) }
;          field = "Injector N", smallpw_opt14, { smallpw_opt1_master && ((hardware_fuel) && (nInjectors > 13)) }
;          field = "Injector O", smallpw_opt15, { smallpw_opt1_master && ((hardware_fuel) && (nInjectors > 14)) }
;          field = "Injector P", smallpw_opt16, { smallpw_opt1_master && ((hardware_fuel) && (nInjectors > 15)) }

       dialog = smallpw2b, ""
          field = "Injector I", smallpw2_opta,  { smallpw2_opt1_master && ((hardware_fuel) && (nInjectors > 8)) }
          field = "Injector J", smallpw2_optb,  { smallpw2_opt1_master && ((hardware_fuel) && (nInjectors > 9)) }
          field = "Injector K", smallpw2_opt11, { smallpw2_opt1_master && ((hardware_fuel) && (nInjectors > 10)) }
          field = "Injector L", smallpw2_opt12, { smallpw2_opt1_master && ((hardware_fuel) && (nInjectors > 11)) }
;          field = "Injector M", smallpw2_opt13, { smallpw2_opt1_master && ((hardware_fuel) && (nInjectors > 12)) }
;          field = "Injector N", smallpw2_opt14, { smallpw2_opt1_master && ((hardware_fuel) && (nInjectors > 13)) }
;          field = "Injector O", smallpw2_opt15, { smallpw2_opt1_master && ((hardware_fuel) && (nInjectors > 14)) }
;          field = "Injector P", smallpw2_opt16, { smallpw2_opt1_master && ((hardware_fuel) && (nInjectors > 15)) }

    ;   dialog = egoControl, "EGO Control"
       dialog = egoControlright, ""
          field = "Algorithm",              egoAlgorithm,       { egoType }
          field = "Ignition Events per Step",  egoCount,        { egoType && (egoAlgorithm < 3) }
          field = "Controller Step Size",      egoDelta,        { egoType && (egoAlgorithm == 0) }
          field = "Controller Auth +/-",    egoLimit,           { egoType && (egoAlgorithm < 3) }
          field = "Only correct above:",    ego_lower_bound,    { egoType && (egoAlgorithm < 3) }
          field = "and correct below:",     ego_upper_bound,    { egoType && (egoAlgorithm < 3) }

          field = "Active Above Coolant", egoTemp,              { egoType && (egoAlgorithm < 3) }
          field = "Active Above RPM",          egoRPM,          { egoType && (egoAlgorithm < 3) }
          field = "Active Below TPS",          TPSOXLimit,      { egoType && (egoAlgorithm < 3) }
          field = "Active Below Load",          MAPOXLimit,     { egoType && (egoAlgorithm < 3) }
          field = "Active Above Load",          MAPOXMin,       { egoType && (egoAlgorithm < 3) }
          field = "EGO delay after start",     ego_startdelay,  { egoType && (egoAlgorithm < 3) }
          field = "PID Proportional Gain",  egoKP,              { egoType && (egoAlgorithm == 2) }
          field = "PID Integral",           egoKI,              { egoType && (egoAlgorithm == 2) }
          field = "PID Derivative",         egoKD,              { egoType && (egoAlgorithm == 2) }

        dialog = egoports, "",yAxis
          field = "EGO channel"
          field = "EGO 1 port", egoport1
          field = "EGO 2 port", egoport2, {egonum > 1}
          field = "EGO 3 port", egoport3, {egonum > 2}
          field = "EGO 4 port", egoport4, {egonum > 3}
          field = "EGO 5 port", egoport5, {egonum > 4}
          field = "EGO 6 port", egoport6, {egonum > 5}
          field = "EGO 7 port", egoport7, {egonum > 6}
          field = "EGO 8 port", egoport8, {egonum > 7}
     
       dialog = egoports_tgt, "", yAxis
          field = "AFR target"
          field = "", egomap1t
          field = "", egomap2t, {egonum > 1}
          field = "", egomap3t, {egonum > 2}
          field = "", egomap4t, {egonum > 3}
          field = "", egomap5t, {egonum > 4}
          field = "", egomap6t, {egonum > 5}
          field = "", egomap7t, {egonum > 6}
          field = "", egomap8t, {egonum > 7}

        dialog = egoports2, "EGO ports", xAxis
           panel = egoports
    ;       panel = egoports_tgt

       dialog = egoControlleft, "", yAxis
          field = "EGO Sensor Type",           egoType
          field = "Number of sensors",         egonum, { egoType }
          field = "#Remember to Calibrate and set Project Properties"
            panel = egoports2

       dialog = egoControlmain, "", xAxis
            panel = egoControlright, West
            panel = egoControlleft, East


        dialog = egomap_inj, "", yAxis
          field = "Injector"
          field = "MS3X injA"
          field = "MS3X injB"
          field = "MS3X injC"
          field = "MS3X injD"
          field = "MS3X injE"
          field = "MS3X injF"
          field = "MS3X injG"
          field = "MS3X injH"
          field = "V3 inj1"
          field = "V3 inj2"

        dialog = egomap_ego, "", yAxis
          field = "Sensor"
          field = "", egomap1
          field = "", egomap2
          field = "", egomap3
          field = "", egomap4
          field = "", egomap5
          field = "", egomap6
          field = "", egomap7
          field = "", egomap8
          field = "", egomap9
          field = "", egomap10

        dialog = egomapping, "AFR / EGO sensor mapping", xAxis
           panel = egomap_inj
           panel = egomap_ego

       dialog = egoControl, "AFR / EGO Control", border
            panel = egoControlmain, West
            panel = egomapping, East


        dialog = egomap_inj2, "", yAxis
          field = "Injector"
          field = "injI"
          field = "injJ"
          field = "injK"
          field = "injL"
          field = "injM"
          field = "injN"
          field = "injO"
          field = "injP"

        dialog = egomap_ego2, "", yAxis
          field = "Sensor"
          field = "", egomap9
          field = "", egomap10
          field = "", egomap11
          field = "", egomap12
          field = "", egomap13
          field = "", egomap14
          field = "", egomap15
          field = "", egomap16

        dialog = egomapping2, "AFR / EGO sensor mapping", xAxis
           panel = egomap_inj2
           panel = egomap_ego2

        dialog = egoports2, "",yAxis
          field = "EGO channel"
          field = "EGO 9 port",  egoport9,  {egonum > 8}
          field = "EGO 10 port", egoport10, {egonum > 9}
          field = "EGO 11 port", egoport11, {egonum > 10}
          field = "EGO 12 port", egoport12, {egonum > 11}
          field = "EGO 13 port", egoport13, {egonum > 12}
          field = "EGO 14 port", egoport14, {egonum > 13}
          field = "EGO 15 port", egoport15, {egonum > 14}
          field = "EGO 16 port", egoport16, {egonum > 15}

        dialog = egocont9_16, "AFR / EGO(9-16)", border
           panel = egoports2, West
           panel = egomapping2, East

    ;   dialog = ignitionOptions, "Ignition Options"
       dialog = ignitionOptions, ""
    ;      field = "#General Ignition"
          field = "Spark mode(dizzy, EDIS,wheel)",                   spk_mode0  ; !
          field = "Trigger Angle/Offset",                triggerOffset, { (spk_mode0 != 31) && (spk_mode0 != 4)}
          ;, {spk_mode0 ==2 || spk_mode0 ==3 || spk_mode0 ==12 || spk_mode0 ==14}
          field = "Angle between main and return", trigret_ang, { spk_mode0 ==12}
          field = "Oddfire first angle",           OddFireang, { (engineType == 1) && (spk_mode0 < 31) };
          field = "GM HEI/DIS options",     spk_conf2_gm, {spk_mode0 ==2}
          field = "Ford TFI options",              spk_conf2_tfi, {spk_mode0 == 2}
;          field = "420A/NGC alternate cam",     spk_conf2_ngc, {(spk_mode0==6) && (nCylinders==4)}
          field = "Oddfire phasing", spk_conf2_oddodd, { (engineType == 1) && (spk_mode0==4)}
          field = "Skip Pulses",                   no_skip_pulses
          field = "Ignition Input Capture",       ICIgnCapture  ; !
          field = "Spark Output",                 spkout_hi_lo, {spk_mode0 != 31} ; 
          field = "Number of coils", spk_mode3
          field = "Spark hardware in use", hardware_spk
          field = "Cam input (if used)", hardware_cam
          field = "Tertiary tach input", spk_mode3_tach3, {spk_mode0 == 47}
          field = "Flip polarity on hi-res tach", spk_mode3_hirespol, {((spk_mode0 >= 32) && (spk_mode0 <= 39)) || (spk_mode0 == 47)}


    ;  dialog = moreIgnitionOptions, "More Ignition Options"
      dialog = moreIgnitionOptions, ""
          field = "Fixed Advance",		       timing_flags
    ;      field = "Use Prediction",                use_prediction, {spk_mode0 == 2}  ; only works for dizzy
          field = "Use Prediction",                use_prediction
          field = "Timing for Fixed Advance",      fixed_timing, { timing_flags == 1 };
          field = "Cranking Dwell",		       crank_dwell
          field = "Cranking Advance",	       crank_timing, {!(spk_mode0 == 2 && triggerOffset < 20) }
          field = ""
          field = "Toyota Multiplex",     spk_conf2_dli, {spk_mode0 > 2}
          field = "Dwell type",                    dwellmode
          field = "Use dwell vs rpm curve", spk_conf2_dwell, {dwellmode ==2}
          field = "Maximum Dwell Duration",        max_coil_dur, {(spk_mode0 >1) && (dwellmode==0) }
    ;      field = "Acceleration Compensation",     dwellAcc, {(spk_mode0 >1) && (dwellmode==0)}
          field = "Maximum Spark Duration",        max_spk_dur, {(spk_mode0 >1) && (dwellmode==0) }
          field = "Dwell time",                    dwelltime, {(spk_mode0 >1) && (dwellmode==2) && (spk_conf2_dwell==0)}
          field = "Dwell duty",                    dwellduty, {(spk_mode0 >1) && (dwellmode==1) }
          field = "NOTE: Spark hardware latency should ONLY be used if"
          field = "you notice spark retard with increasing rpms."
          field = "Spark Hardware Latency",               hw_latency
          field = "middle LED indicator",          feature4_0igntrig, { (spk_mode0 == 3) }
          field = "Overdwell protection",          feature4_0maxdwl
    ;      field = "Underdwell protection",         feature4_0mindwl
          field = ""
          field = "Spark trim", spk_mode3_trim
          field = ""
          field = "All settings on the left of this page require a power cycle"
          field = "Check them carefully as they are critical to ECU operation"

    ;  dialog = triggerWheel, "Trigger Wheel Settings"
      dialog = triggerWheel, ""
    ;      topicHelp = trighelp
          field = "Trigger wheel arrangement",     spk_config_trig2, { spk_mode0 == 4 }
          field = "Trigger Wheel Teeth",          triggerTeeth, { (spk_mode0 == 4) || (spk_mode0 == 47) }
          field = "Missing Teeth",                No_Miss_Teeth, {(spk_config_trig2 != 2) && (spk_mode0 == 4)}
          field = "Tooth #1 Angle",     Miss_ang, { (spk_mode0 == 4) || (spk_mode0 == 47) }
          field = "Main wheel speed",                   spk_config_camcrank, { spk_mode0 == 4 }
          field = "Second trigger active on",      spk_config_trig2l, {(spk_config_trig2 & 0x2) && spk_mode0 == 4}
          field = "Level for phase 1", spk_config_campol, {((spk_config_trig2l & 0x3) == 0x3) && (spk_mode0 == 4) && (spk_config_trig2 == 3)}
          field = "and every rotation of..", spk_config_resetcam, {((spk_config_trig2 & 0x3) == 0x2) && spk_mode0 == 4}

     dialog = padignition
            field = ""

     dialog = westIgnitionOptions, "", yAxis
            panel = ignitionOptions
            panel = triggerWheel

     dialog = eastIgnitionOptions, "", yAxis
            panel = moreIgnitionOptions
            panel = padignition

       dialog = combinedignition, "Combined Ignition Options", border
            panel = westIgnitionOptions, West
            panel = eastIgnitionOptions, East

       dialog = northwestidle, "", border
          field = "Algorithm",                     IdleCtl
    ;      field = ""

       dialog = northeastidle, "", border
          field = "Fast Idle Temperature",         fastIdleT,    { IdleCtl == 1 }
    ;      field = "Hysteresis",                    IdleHyst,     { IdleCtl == 1 }  ; adding this line causes one above to vanish

       dialog = westidle, "Stepper idle"
    ;      topicHelp = "http://www.megasquirt.info/megatune.htm#sd"
          field = "Time Step Size",                IACtstep,     { IdleCtl == 2 || IdleCtl == 3 || IdleCtl == 5 || IdleCtl == 7 || IdleCtl == 8 }
          field = "Initial Time Step Size",        IAC_tinitial_step,   { IdleCtl == 2 || IdleCtl == 7 }
          field = "Minimum # steps to move",       IACminstep,  { IdleCtl == 2 || IdleCtl == 3 || IdleCtl == 5 || IdleCtl == 7 || IdleCtl == 8 }
          field = "Start Value",                  IACStart,     { IdleCtl > 1 && IdleCtl != 4 && IdleCtl != 6} ; !
          field = "Crank-to-Run Taper Time",       IACcrankxt,   { IdleCtl > 1 && IdleCtl != 4 && IdleCtl != 6 && IdleCtl != 7 && IdleCtl != 8 }
          field = "Hysteresis",                    IdleHyst,     { IdleCtl > 0 && IdleCtl != 4 && IdleCtl != 6 && IdleCtl != 7 && IdleCtl != 8 }
          field = "#Time-Based After Start"
          field = "   Cold Temperature",           IACcoldtmp,   { IdleCtl > 1 && IdleCtl != 4 && IdleCtl != 6 && IdleCtl != 7 && IdleCtl != 8 }
          field = "   Cold Position",              IACcoldpos,   { IdleCtl > 1 && IdleCtl != 4 && IdleCtl != 6 && IdleCtl != 7 && IdleCtl != 8 }
          field = "   Cold Taper Time",            IACcoldxt,    { IdleCtl > 1 && IdleCtl != 4 && IdleCtl != 6 && IdleCtl != 7 && IdleCtl != 8 }

       dialog = eastidle, "PWM idle"
          field = "Warmup only mode"
          field = "Set duty vs. temp in the duty table"
          field = "Crank-to-Run Taper Time", pwmidlecranktaper, { (IdleCtl == 4) || (IdleCtl == 6) }
          field = ""
          field = "Valve mode",      pwmidleset_inv, { (IdleCtl == 4) || (IdleCtl == 6) }
          field = "Output port", pwmidle_freq_pin, { (IdleCtl == 1) || (IdleCtl == 4) || (IdleCtl == 6) }
          field = "3 wire mode", pwmidle_freq_pin3, { (IdleCtl == 4) || (IdleCtl == 6) }

          field = "Frequency", pwmidle_freq_scale, { (IdleCtl == 4) || (IdleCtl == 6) }
          field = "This frequency may be shared with boost control"

       dialog = northidle, "", border
            panel = northwestidle, West
            panel = northeastidle, East

       dialog = southidle, "", border
            panel = westidle, West
            panel = eastidle, East

       dialog = combinedidle, "Idle Control", border
            panel = northidle, North
            panel = southidle, South

       dialog = pwmidle_closedloop, "Closed Loop Idle Valve Settings"
          field = "Idle Open Duty",                  pwmidle_open_duty, { IdleCtl == 6 }
          field = "Idle Open Steps",	         pwmidle_open_steps, { IdleCtl == 7 || IdleCtl == 8 } 
          field = "Idle Valve Closed Duty",          pwmidle_closed_duty, { IdleCtl == 6 }
          field = "Idle Valve Closed Steps",         pwmidle_closed_steps, { IdleCtl == 7 || IdleCtl == 8 }
          field = "Dashpot adder",  pwmidle_dp_adder, { IdleCtl == 6 }
          field = "Dashpot adder",  pwmidle_dp_adder_steps, { IdleCtl == 7 || IdleCtl == 8 }
          field = "Dashpot decay factor", pwmidle_dp_decay_factor, { IdleCtl == 6 || IdleCtl == 7 || IdleCtl == 8 }
          field = "Use last value or table", pwmidle_cl_opts_initvaluetable
          field = "Use CLT or MAT in table lookup", pwmidle_cl_opts_initval_clt, { pwmidle_cl_opts_initvaluetable }
          field = "NOTE: Close delay of 0 means do not close"
          field = "Close delay", pwmidle_close_delay
          field = "Shift Settings"
          field = "Leave valve closed above:", pwmidle_shift_lower_rpm, { pwmidle_close_delay > 0 }
          field = "For this number of seconds:", pwmidle_shift_open_time, { pwmidle_close_delay > 0 }
          field = ""

       dialog = pwmidle_PID_activation, "Closed Loop Idle PID activation Settings"
          field = "Use VSS to activate PID",         IdleCtl_vss
          field = "Idle Activation RPM adder",       pwmidle_engage_rpm_adder, { IdleCtl_vss != 1 }
          field = "Idle Activation TPS threshold",   pwmidle_tps_threshold

       dialog = pwmidle_PID_behavior, "Closed Loop Idle PID Delays and Behavior"
          field = "Min Duty for PID",     pwmidle_min_duty, { IdleCtl == 6 }
          field = "Min Steps for PID",    pwmidle_min_steps,  { IdleCtl == 7 || IdleCtl == 8 }
          field = "RPM with valve closed", pwmidle_min_rpm
          field = "RPM with valve open",   pwmidle_max_rpm
          field = "PID delay",            pwmidle_pid_wait_timer
          field = "Crank to run delay",   pwmidlecranktaper 
          field = "PID ramp to target time", pwmidle_targ_ramptime
          field = "PID Control Interval", pwmidle_ms
          field = "Use so that engaging clutch without throttle"
          field = "Does not leave PID running"
          field = "PID disable RPMdot", pwmidle_rpmdot_disablepid, { IdleCtl_vss != 1 }

       dialog = pwmidle_PID_gains, "Closed Loop Idle PID Gains"
          field = "Proportional Gain",    pwmidle_Kp
          field = "Integral Gain",        pwmidle_Ki
          field = "Derivative Gain",      pwmidle_Kd

       dialog = pwmidle_PID_lockout, "Closed Loop Idle PID Lockout detection"
          field = "PID lockout rpmDOT threshold", pwmidle_rpmdot_threshold, { IdleCtl_vss != 1 }
          field = "PID lockout max decel load", pwmidle_decelload_threshold, { IdleCtl_vss != 1 }

          dialog = pwmidle_west_panel, "", border
            panel = pwmidle_closedloop, North
            panel = pwmidle_PID_gains, Center 
            panel = pwmidle_PID_activation, South

         dialog = pwmidle_mid_panel, "", border
            panel = pwmidle_PID_behavior, North
            panel = pwmidle_PID_lockout, Center

          dialog = combinedCLidle, "Closed-loop Idle Control", border
            panel = pwmidle_mid_panel, Center
            panel = pwmidle_west_panel, West

       dialog = new_ae_south_west, ""
           field = "Accel enrichment tpsDOT<->MAPDOT blend", accel_blend_percent
           field = "Accel MAPDOT threshold", accel_mapdot_threshold, { accel_blend_percent < 100 }
           field = "Accel tpsDOT threshold", accel_tpsdot_threshold, { accel_blend_percent > 0 }
           field = "Accel CLT multiplier", accel_CLT_multiplier

       dialog = new_ae_south_mid, ""
        field = ""

       dialog = new_ae_south_east, ""
        field = ""

       dialog = new_ae_south_south, "", xAxis
        panel = new_ae_south_west
        panel = new_ae_south_mid
        panel = new_ae_south_east
        
       dialog = new_ae_south, "", yAxis
        liveGraph = newaeGraph, "AE Graph", South
            graphLine = afr1
            graphLine = tpsDOT, "%", -2000, 2000, auto, auto
            graphLine = mapDOT, "%", -2000, 2000, auto, auto
        panel = new_ae_south_south

       dialog = new_ae_north, "", xAxis
           panel = new_accel_mapdot_curve, West, {accel_blend_percent < 100}
           panel = new_accel_tpsdot_curve, East, {accel_blend_percent > 0}

       dialog = new_AE_settings, "New Accel-pump Accel Enrichment"
           panel = new_ae_north, North
           panel = new_ae_south, South

       dialog = sensorCal, "Calibrate MAP/Baro"

    ;      topicHelp = sensorHelp
#if INI_VERSION_2
          settingSelector = "Common Sensors"
             settingOption = "MPX4115",  map0=10.6, mapmax=121.7, baro0=10.6, baromax=121.7
             settingOption = "MPX4250",  map0=10,   mapmax=260,   baro0=10,   baromax=260
             settingOption = "GM 1-BAR", map0=10,   mapmax=105,   baro0=10,   baromax=105
             settingOption = "GM 2-BAR", map0=8.8,  mapmax=208,   baro0=8.8,  baromax=208
             settingOption = "GM 3-BAR / MPXH6300", map0=1.1,  mapmax=315.5, baro0=1.1,  baromax=315.5
             settingOption = "MPXH6400", map0=3.5,  mapmax=416.5, baro0=3.5,  baromax=416.5
#endif
          field = "#MAP Sensor"
          field =    "Value at 0.0 volts",   map0
          field =    "Value at 5.0 volts",   mapmax
          field = "#Barometer Sensor (usually identical to MAP)"
          field =    "Value at 0.0 volts",   baro0
          field =    "Value at 5.0 volts",   baromax
          field = "#Barometric Correction"
          field =    "At total vacuum ",     bcor0
          field =    "Rate",                 bcormult

       dialog = knockSettings3, "Knock Sensor Settings"
          field = "Knock Control",        knk_option
          field = "Input type",           knk_option_an, { knk_option }

          field = "Knock input pin",      knkport, { knk_option && !knk_option_an }
          field = "Knock indicated by:",  knkDirection,   { knk_option && !knk_option_an }
          field = "Pullup/down on input",  knkpull,   { knk_option && !knk_option_an }
          field = "Input pin",      knkport_an, { knk_option && (knk_option_an == 1) }
          field = "Window sample type",  knk_option_wind, { knk_option && (knk_option_an == 1) }
          field = "Window output",       knk_pin_out, { knk_option && (knk_option_an < 2) }
          field = "#Detection"
          field = "Knock Count",          knk_ndet,       { knk_option > 0 }
          field = "Knock Ignored Above MAP",   knk_maxmap,     { knk_option > 0 }
          field = "RPM window low",   knk_lorpm,      { knk_option > 0 }
          field = "RPM window high",   knk_hirpm,      { knk_option > 0 }
          field = "#Retarding"
          field = "Maximum Retard",       knk_maxrtd,     { knk_option > 0 }
          field = "Retard Check Time",    knk_trtd,       { knk_option > 0 }
          field = "Retard Coarse Step Size",   knk_step1,      { knk_option > 0 }
          field = "Retard Fine Step Size",     knk_step2,      { knk_option > 0 }
          field = "#Recovery"
          field = "Advance Check Time",   knk_tadv,       { knk_option > 0 }
          field = "Advance Step Size",    knk_step_adv,   { knk_option > 0 }
          field = "Recovery Advance",     knk_dtble_adv,  { knk_option == 1 }

        dialog = ks4a, "", yAxis
            field = "Cyl#"
            field = "1"
            field = "2"
            field = "3"
            field = "4"
            field = "5"
            field = "6"
            field = "7"
            field = "8"
#if CYL_12_16_SUPPORT
            field = "9"
            field = "10"
            field = "11"
            field = "12"
            field = "13"
            field = "14"
            field = "15"
            field = "16"
#endif
        dialog = ks4b, "", yAxis
            field = "Gain"
            field = "", knock_gain01
            field = "", knock_gain02, {knock_conf_percyl && (nCylinders >1)}
            field = "", knock_gain03, {knock_conf_percyl && (nCylinders >2)}
            field = "", knock_gain04, {knock_conf_percyl && (nCylinders >3)}
            field = "", knock_gain05, {knock_conf_percyl && (nCylinders >4)}
            field = "", knock_gain06, {knock_conf_percyl && (nCylinders >5)}
            field = "", knock_gain07, {knock_conf_percyl && (nCylinders >6)}
            field = "", knock_gain08, {knock_conf_percyl && (nCylinders >7)}
#if CYL_12_16_SUPPORT
            field = "", knock_gain09, {knock_conf_percyl && (nCylinders >8)}
            field = "", knock_gain10, {knock_conf_percyl && (nCylinders >9)}
            field = "", knock_gain11, {knock_conf_percyl && (nCylinders >10)}
            field = "", knock_gain12, {knock_conf_percyl && (nCylinders >11)}
            field = "", knock_gain13, {knock_conf_percyl && (nCylinders >12)}
            field = "", knock_gain14, {knock_conf_percyl && (nCylinders >13)}
            field = "", knock_gain15, {knock_conf_percyl && (nCylinders >14)}
            field = "", knock_gain16, {knock_conf_percyl && (nCylinders >15)}
#endif

        dialog = ks4c, "", yAxis
            field = "Sensor"
            field = "", knock_sens01
            field = "", knock_sens02, {knock_conf_percyl && (nCylinders >1)}
            field = "", knock_sens03, {knock_conf_percyl && (nCylinders >2)}
            field = "", knock_sens04, {knock_conf_percyl && (nCylinders >3)}
            field = "", knock_sens05, {knock_conf_percyl && (nCylinders >4)}
            field = "", knock_sens06, {knock_conf_percyl && (nCylinders >5)}
            field = "", knock_sens07, {knock_conf_percyl && (nCylinders >6)}
            field = "", knock_sens08, {knock_conf_percyl && (nCylinders >7)}
#if CYL_12_16_SUPPORT
            field = "", knock_sens09, {knock_conf_percyl && (nCylinders >8)}
            field = "", knock_sens10, {knock_conf_percyl && (nCylinders >9)}
            field = "", knock_sens11, {knock_conf_percyl && (nCylinders >10)}
            field = "", knock_sens12, {knock_conf_percyl && (nCylinders >11)}
            field = "", knock_sens13, {knock_conf_percyl && (nCylinders >12)}
            field = "", knock_sens14, {knock_conf_percyl && (nCylinders >13)}
            field = "", knock_sens15, {knock_conf_percyl && (nCylinders >14)}
            field = "", knock_sens16, {knock_conf_percyl && (nCylinders >15)}
#endif
        dialog = ks4bot, "", xAxis
        panel = ks4a
        panel = ks4b
        panel = ks4c

       dialog = ks4top, ""
        field = "NOTE! This feature is only licensed for use"
        field = "with JSM add-on board"
        field = "Bandpass frequency (kHz)", knock_bpass
        field = "Integrator time constant (us)", knock_int
        field = "Number of sensors", knock_conf_num
        field = "Monitor per cylinder", knock_conf_percyl
        field = "Knock gain:"

       dialog = knockSettings4, "Knock sensor parameters", border
            panel = ks4top, North
            panel = ks4bot, South

       dialog = knockSettings, "Knock Sensor Settings", border
            panel = knockSettings3, West
            panel = knockthresh_curve, East

       dialog = knockSettings2, "Knock Window Settings", border
            panel = knockstart_curve, North
            panel = knockduration_curve, South
        

        dialog = idleAdvancemenu, "Idle Advance Settings"
          field = "Idle advance on", idleadvance_on
          field = "Idle RPM Timing Correction", idle_special_ops_timing_assist
          field = "Go to idle advance/Idle RPM timing correction when:"
          field = "PID idle activates", idleveadv_to_pid_idleadv, { idleadvance_on || idle_special_ops_timing_assist }
          field = "TPS is below:", idleadvance_tps, { (idleadvance_on || idle_special_ops_timing_assist) && !idleveadv_to_pid_idleadv }
          field = "and RPM is below:", idleadvance_rpm, { (idleadvance_on || idle_special_ops_timing_assist) && !idleveadv_to_pid_idleadv }
          field = "and load is above:", idleadvance_load, { (idleadvance_on || idle_special_ops_timing_assist) && !idleveadv_to_pid_idleadv }
          field = "and CLT is above:", idleadvance_clt, { (idleadvance_on || idle_special_ops_timing_assist) && !idleveadv_to_pid_idleadv }
          field = "and after delay:", idleadvance_delay, { (idleadvance_on || idle_special_ops_timing_assist) && !idleveadv_to_pid_idleadv }

    dialog = idleAdvance, "Idle Advance", border
          panel = idleAdvancemenu, West
          panel = idleAdvance_curve, East

        dialog = idleVemenu,  "Idle VE settings"
           field = "Idle VE on", idleve_on
           field = "Go to idle VE when:"
           field = "PID idle activates", idleveadv_to_pid_idleve, { idleve_on }
           field = "TPS is below:", idleve_tps, { idleve_on && !idleveadv_to_pid_idleve }
           field = "and RPM is below:", idleve_rpm, { idleve_on && !idleveadv_to_pid_idleve }
           field = "and load is above:", idleve_load, { idleve_on && !idleveadv_to_pid_idleve }
           field = "and CLT is above:", idleve_clt, { idleve_on && !idleveadv_to_pid_idleve }
           field = "and VSS zero?", idleve_vsson, { idleve_on && !idleveadv_to_pid_idleve }
           field = "and after delay:", idleve_delay, { idleve_on && !idleveadv_to_pid_idleve }


         dialog = idleVeTables, "Idle VE Tables"
           panel = idleve1Tbl, North, { idleve_on }
           panel = idleve2Tbl, South, { idleve_on && dualfuel_sw_on }

         dialog = idleVe, "Idle VE", border 
           panel = idleVemenu, West 
           panel = idleVeTables, Center 

    dialog = setbaud, "Megasquirt baud rate"
          field = "#Advanced users only."
          field = "Megasquirt baud rate", baud
          field = "9600, 19200, 38400, 57600, 115200 only"
          field = "Set this, Burn"
          field = "Then adjust tuning software comms baud rate to match"
          field = "Then powercycle Megasquirt"

    dialog = userdefined, "user defined menu"
          field = "Feature enabled", user_conf0
          field = "Mode", user_conf1, { user_conf0 }  ; <---- this bit here greys the control out if the bit isn't set
          field = "Value 1", user_value1, { user_conf0 }
          field = "Value 2", user_value2, { user_conf0 }

       help = helpGeneral, "Megasquirt 3 General Help"
          webHelp = "http://www.ms3efi.com/"
          text = "For current documentation, click the Web Help button,"
          text = "or visit http://www.ms3efi.com/."

    ;-------------------------------------------------------------------------------
#if INI_VERSION_2
    [PortEditor]
        ; spare ports
        ; map the arrays and supply the labels. 
        ; all arrays are expected to be the same length in the first dimension
        ; thus a [ 7] array will be 7 ports in length and expect 7 labels
        ; The second dimension will drive the number of conditions per array.
        ; thus a [7x2] array will have 2 conditions joined by the conditionRelationship.
        ; a [7x3] will have up to 3 conditions.
        portEditor = ms3_port_edit, "Output port Settings"
            ; 1st the array constant, then the labels in the index order. 
            enabledPorts = psEnabled, "PM3 - Injection LED D14", "PM4 - Accel LED D16", "PM5 - Warmup LED D15", "PJ0 - IAC2", "PJ1 - IAC1", "PJ7 - JS11", "PP2 - Idle", "PP3 - Boost", "PP4 - Nitrous 1", "PP5 - Nitrous 2", "PP6 - VVT", "PP7 - Fidle", "PT1 - V3 Inj 1", "PT3 - V3 Inj 2", "PT5 - JS10", "PK0 - Tacho", "PA0 - Inj A", "PA1 - Inj B", "PA2 - Inj C", "PA3 - Inj D", "PA4 - Inj E", "PA5 - Inj F", "PA6 - Inj G", "PA7 - Inj H", "PB0 - Spk A", "PB1 - Spk B", "PB2 - Spk C", "PB3 - Spk D", "PB4 - Spk E", "PB5 - Spk F", "PB6 - Spk G", "PB7 - Spk H", "CANout01",  "CANout02", "CANout03", "CANout04", "CANout05", "CANout06", "CANout07", "CANout08", "CANout09", "CANout10", "CANout11", "CANout12", "CANout13", "CANout14", "CANout15", "CANout16"
            outputOffset = psOutOffset 
            outputSize   = psOutSize 
            operators    = psCondition, "<", "=", ">" ; the actual ASCII value of the operator will be sent to the controller
            threshold    = psThreshold
            hysteresis   = psHysteresis
            powerOnValue = psInitValue
            triggerValue = psPortValue
            conditionRelationship = psConnector, " ", "|", "&"
#endif
    ;-------------------------------------------------------------------------------

    [CurveEditor]
       curve = launch_retard_time, "Retard vs time after launch"
          columnLabel = "s", "Retard"

          xAxis       = 0, 15, 6
          yAxis       = 0, 30, 7
          xBins       = launch_time
          yBins       = launch_retard

        curve = cl_idle_timing_curve, "Idle RPM timing correction curve"
            columnLabel = "RPM delta", "Timing Delta"
            xAxis = -400, 400, 8
            yAxis = -20, 20, 8
            xBins = cl_idle_timing_target_deltas
            yBins = cl_idle_timing_advance_deltas 

        curve = idle_voltage_comp_curve, ""
            columnLabel = "Voltage", "Duty"
            xAxis = 9, 17, 6
            yAxis = -10, 10, 6
            xBins = idle_voltage_comp_voltage
            yBins = idle_voltage_comp_delta

        curve = new_accel_mapdot_curve, "New Accel MAPdot Curve"
            columnLabel = "MAPDOT", ""
            xAxis = -2000, 2000, 5
            yAxis = -200, 200, 5
            xBins = accel_mapdots, mapDOT
            yBins = accel_mapdot_amts

        curve = new_accel_tpsdot_curve, "New Accel TPSdot Curve"
            columnLabel = "tpsDOT", ""
            xAxis = -1000, 1000, 5
            yAxis = -200, 200, 5
            xBins = accel_tpsdots, tpsDOT
            yBins = accel_tpsdot_amts

       curve = knockstart_curve, "Knock window start"
          columnLabel = "RPM", "deg"
          xAxis       = 0, {rpmhigh}, 6
          yAxis       = -40, 10, 6
          xBins       = knock_rpms, rpm
          yBins       = knock_starts

       curve = knockduration_curve, "Knock window duration"
          columnLabel = "RPM", "deg"
          xAxis       = 0, {rpmhigh}, 6
          yAxis       = 0, 40, 6
          xBins       = knock_rpms, rpm
          yBins       = knock_durations

       curve = knockthresh_curve, "Knock input threshold"

          columnLabel = "RPM", "%"
          xAxis       = 0, {rpmhigh}, 6
          yAxis       = 0, 100, 6
          xBins       = knock_rpms, rpm
          yBins       = knock_thresholds
          gauge       = knockinGauge

       curve = knockupscale_curve, "Knock coolant scaling"
          columnLabel = "clt", "%"
          xAxis       = {cltlowlim}, {clthighlim}, 6
          yAxis       = 100, 500, 6
          xBins       = knock_clts, coolant
          yBins       = knock_upscale
          gauge       = cltGauge

   curve = tc_perfect_curve, "Perfect vss vs. time"
      columnLabel = "Time", "VSS"
      xAxis       = 0, 20, 9
#if MPH
      yAxis       =  0, 200, 6
#else
      yAxis       =  0, 300, 6
#endif
      xBins       = tc_perfect_time, df_temp
      yBins       = tc_perfect_vss

   curve = tc_retard_curve, "Traction Control retard"
      columnLabel = "Slip x time", "Retard"
      xAxis       = 0, 100, 3
      yAxis       =  0, 30, 3
      xBins       = tc_react_x, df_temp
      yBins       = tc_retard

   curve = tc_spkcut_curve, "Traction Control spark cut"
      columnLabel = "Slip x time", "Spark"
      xAxis       = 0, 100, 3
      yAxis       =  0, 100, 3
      xBins       = tc_react_x, df_temp
      yBins       = tc_spkcut

   curve = tc_nitrous_curve, "Traction Control nitrous%"
      columnLabel = "Slip x time", "Nitrous"
      xAxis       = 0, 100, 3
      yAxis       =  0, 100, 3
      xBins       = tc_react_x, df_temp
      yBins       = tc_nitrous

   curve = tc_boost_curve, "Traction Control boost%"
      columnLabel = "Slip x time", "Boost"
      xAxis       = 0, 100, 3
      yAxis       =  0, 100, 3
      xBins       = tc_react_x, df_temp
      yBins       = tc_boost

   curve = tc_addfuel_curve, "Traction Control add fuel"
      columnLabel = "Slip x time", "Added Fuel"
      xAxis       = 0, 100, 3
      yAxis       =  0, 100, 3
      xBins       = tc_react_x, df_temp
      yBins       = tc_addfuel

       curve = dualfuel_temp_curve, "Dual fuel temperature adjustment curve"
          columnLabel = "Temperature", "adj %"
          xAxis       = -40, 220, 9
          yAxis       =  -200, 200, 6
          xBins       = dualfuel_temp, df_temp
          yBins       = dualfuel_temp_adj
    ;      gauge       = deadGauge

       curve = dualfuel_press_curve, "Dual fuel temperature adjustment curve"
          columnLabel = "Pressure", "adj %"
          xAxis       = 0, 200, 9
          yAxis       =  -200, 200, 6
          xBins       = dualfuel_press, df_press
          yBins       = dualfuel_press_adj
    ;      gauge       = cltGauge

       curve = primingPW2, "Priming Pulsewidth 2"
          columnLabel = "Coolant", "Prime PW"
          xAxis       = -40, {clthighlim}, 9
          yAxis       =   0,  20, 5
          xBins       = temp_table_p21, coolant, readonly
          yBins       = primePWTable2
          gauge       = cltGauge

       curve = crankingPW2, "Cranking Pulsewidth% 2"
          columnLabel = "Coolant", "Cranking PW%"
          xAxis       = -40, {clthighlim}, 9
          yAxis       =   0,  500, 6
          xBins       = temp_table_p21, coolant
          yBins       = crankPctTable2
          gauge       = cltGauge

       curve = asePct2, "Afterstart Enrichment Percentage 2"
          columnLabel = "Coolant", "Afterstart"
          xAxis       = -40, {clthighlim}, 9
          yAxis       =   0, 100, 6
          xBins       = temp_table_p21, coolant, readonly
          yBins       = asePctTable2
          gauge       = cltGauge

       curve = aseTaper2, "Afterstart Enrichment Taper 2"
          columnLabel = "Coolant", "Taper"
          xAxis       = -40, {clthighlim}, 9
          yAxis       =   0, 500, 6
          xBins       = temp_table_p21, coolant, readonly
          yBins       = aseCntTable2
          gauge       = cltGauge


       curve = warmup_curve2, "Warmup Enrichment Curve 2"
          columnLabel = "Coolant", "WUE %"
          xAxis       = -40, {clthighlim}, 9
          yAxis       =   0,  500, 6
          xBins       = temp_table_p21, coolant, readonly
          yBins       = wueBins2
          gauge       = cltGauge

       curve = MAFtable1, "MAF Correction Table (to alter default MAF curve)"
          columnLabel = "MAF Flow", "Correction"
          xAxis       =  0, 300, 11
          yAxis       =  0, 255, 11
          xBins       = MAFFlow, maf
          yBins       = MAFCor
          gauge       = mafGauge

       curve = dwellrpm_curve, "Dwell vs rpm"
          columnLabel = "RPM", "Dwell"
          xAxis       = 0, {rpmhigh}, 6
          yAxis       = 0, 6, 6
          xBins       = dwellrpm_rpm
          yBins       = dwellrpm_dwell

       curve = boostvss_duty_curve, "Boost duty vs speed"
          columnLabel = "Speed", "Duty"
#if MPH
          xAxis       = 0, 200, 6
#else
          xAxis       = 0, 300, 6
#endif
          yAxis       = 0, 100, 6
          xBins       = boostvss_speed
          yBins       = boostvss_duty

       curve = boostvss_target_curve, "Boost target vs speed"
          columnLabel = "Speed", "kPa"
#if MPH
          xAxis       = 0, 200, 6
#else
          xAxis       = 0, 300, 6
#endif
          yAxis       = 0, 400, 6
          xBins       = boostvss_speed
          yBins       = boostvss_target

    ; nitrous 1 vs time
       curve = n2o1_duty_time, "Nitrous1 - Duty vs time"
          columnLabel = "s", "Duty"
          xAxis       = 0, 15, 6
          yAxis       = 0, 100, 6
          xBins       = n2o1_time
          yBins       = n2o1_duty

       curve = n2o1_pw_time, "Nitrous1 - Added fuel vs time"
          columnLabel = "s", "pw"
          xAxis       = 0, 15, 6
          yAxis       = -5, 20, 6
          xBins       = n2o1_time
          yBins       = n2o1_pw

       curve = n2o1_retard_time, "Nitrous1 - Retard vs time"
          columnLabel = "s", "Retard"
          xAxis       = 0, 15, 6
          yAxis       = 0, 30, 7
          xBins       = n2o1_time
          yBins       = n2o1_retard

    ; nitrous 2 vs time
       curve = n2o2_duty_time, "Nitrous2 - Duty vs time"
          columnLabel = "s", "Duty"
          xAxis       = 0, 15, 6
          yAxis       = 0, 100, 6
          xBins       = n2o2_time
          yBins       = n2o2_duty

       curve = n2o2_pw_time, "Nitrous2 - Added fuel vs time"
          columnLabel = "s", "pw"
          xAxis       = 0, 15, 6
          yAxis       = -5, 20, 6
          xBins       = n2o2_time
          yBins       = n2o2_pw

       curve = n2o2_retard_time, "Nitrous2 - Retard vs time"
          columnLabel = "s", "Retard"
          xAxis       = 0, 15, 6
          yAxis       = 0, 30, 7
          xBins       = n2o2_time
          yBins       = n2o2_retard

    ; nitrous 1 vs rpm
       curve = n2o1_duty_rpm, "Nitrous1 - Duty vs RPM"
          columnLabel = "RPM", "Duty"
          xAxis       = 0, {rpmhigh}, 6
          yAxis       = 0, 100, 6
          xBins       = n2o1_rpm
          yBins       = n2o1_duty

       curve = n2o1_pw_rpm, "Nitrous1 - Added fuel vs RPM"
          columnLabel = "RPM", "pw"
          xAxis       = 0, {rpmhigh}, 6
          yAxis       = -5, 20, 6
          xBins       = n2o1_rpm
          yBins       = n2o1_pw

       curve = n2o1_retard_rpm, "Nitrous1 - Retard vs RPM"
          columnLabel = "RPM", "Retard"
          xAxis       = 0, {rpmhigh}, 6
          yAxis       = 0, 30, 7
          xBins       = n2o1_rpm
          yBins       = n2o1_retard

    ; nitrous 2 vs rpm
       curve = n2o2_duty_rpm, "Nitrous2 - Duty vs RPM"
          columnLabel = "RPM", "Duty"
          xAxis       = 0, {rpmhigh}, 6
          yAxis       = 0, 100, 6
          xBins       = n2o2_rpm
          yBins       = n2o2_duty

       curve = n2o2_pw_rpm, "Nitrous2 - Added fuel vs RPM"
          columnLabel = "RPM", "pw"
          xAxis       = 0, {rpmhigh}, 6
          yAxis       = -5, 20, 6
          xBins       = n2o2_rpm
          yBins       = n2o2_pw

       curve = n2o2_retard_rpm, "Nitrous2 - Retard vs RPM"
          columnLabel = "RPM", "Retard"
          xAxis       = 0, {rpmhigh}, 6
          yAxis       = 0, 30, 7
          xBins       = n2o2_rpm
          yBins       = n2o2_retard


;combined curves
       curve = n2o_duty_rpm, "Nitrous1+2 - Duty vs RPM"
          columnLabel = "RPM", "%", "%"
          xAxis       = 0, {rpmhigh}, 6
          yAxis       = 0, 100, 6
          xBins       = n2o1_rpm
          yBins       = n2o1_duty
          xAxis       = 0, {rpmhigh}, 6
          yAxis       = 0, 100, 6
          xBins       = n2o2_rpm
          yBins       = n2o2_duty
          lineLabel   = "N2O 1 Duty Cycle"
          lineLabel   = "N2O 2 Duty Cycle"

       curve = n2o_pw_rpm, "Nitrous1+2 - Added fuel vs RPM"
          columnLabel = "RPM", "pw", "pw"
          xAxis       = 0, {rpmhigh}, 6
          yAxis       = -5, 20, 6
          xBins       = n2o1_rpm
          yBins       = n2o1_pw
          xAxis       = 0, {rpmhigh}, 6
          yAxis       = -5, 20, 6
          xBins       = n2o2_rpm
          yBins       = n2o2_pw
          lineLabel   = "N2O 1 fuel PW"
          lineLabel   = "N2O 2 fuel PW"

       curve = n2o_retard_rpm, "Nitrous1+2 - Retard vs RPM"
          columnLabel = "RPM", "Retard", "Retard"
          xAxis       = 0, {rpmhigh}, 6
          yAxis       = 0, 30, 7
          xBins       = n2o1_rpm
          yBins       = n2o1_retard
          xAxis       = 0, {rpmhigh}, 6
          yAxis       = 0, 30, 7
          xBins       = n2o2_rpm
          yBins       = n2o2_retard


    ;mat/clt
       curve = matclt_curve, "%CLT used in MAT vs rpm"
          columnLabel = "rpm", "%CLT"
          xAxis       = 0, {rpmhigh}, 5
          yAxis       = 0, 20, 5
          xBins       = matclt_rpm
          yBins       = matclt_pct

    ;small pulsewidths
       curve = smallcurve0, "Small Pulsewidth Curve 1"
          columnLabel = "Original", "New"
          xAxis       = 0, 2, 5
          yAxis       = 0, 2, 5
          xBins       = smallpwpw
          yBins       = smallpw0

       curve = smallcurve1, "Small Pulsewidth Curve 2"
          columnLabel = "Original", "New"
          xAxis       = 0, 2, 5
          yAxis       = 0, 2, 5
          xBins       = smallpwpw
          yBins       = smallpw1

       curve = smallcurve2, "Small Pulsewidth Curve 3"
          columnLabel = "Original", "New"
          xAxis       = 0, 2, 5
          yAxis       = 0, 2, 5
          xBins       = smallpwpw
          yBins       = smallpw2

       curve = smallcurve3, "Small Pulsewidth Curve 4"
          columnLabel = "Original", "New"
          xAxis       = 0, 2, 5
          yAxis       = 0, 2, 5
          xBins       = smallpwpw
          yBins       = smallpw3

       curve = opencurve0, "Dead Time Voltage % Curve 1"
          columnLabel = "Voltage", ""
          xAxis       = 7.2, 19.2, 7
          yAxis       = 0, 500, 6
          xBins       = opentimev, batteryVoltage
          yBins       = opentimepct0

       curve = opencurve1, "Injector Dead Time Curve 2"
          columnLabel = "Voltage", ""
          xAxis       = 7.2, 19.2, 7
          yAxis       = 0, 500, 6
          xBins       = opentimev, batteryVoltage
          yBins       = opentimepct1

       curve = opencurve2, "Injector Dead Time Curve 3"
          columnLabel = "Voltage", ""
          xAxis       = 7.2, 19.2, 7
          yAxis       = 0, 500, 6
          xBins       = opentimev, batteryVoltage
          yBins       = opentimepct2

       curve = opencurve3, "Injector Dead Time Curve 4"
          columnLabel = "Voltage", ""
          xAxis       = 7.2, 19.2, 7
          yAxis       = 0, 500, 6
          xBins       = opentimev, batteryVoltage
          yBins       = opentimepct3

       curve = boost_timed_curve, "Boost %age after launch"
          columnLabel = "Time", ""
          xAxis       = 0, 15, 6
          yAxis       = 0, 100, 6
          xBins       = boost_timed_time
          yBins       = boost_timed_pct

       curve = mapsample_curve, "MAP sample timing"
          columnLabel = "RPM", "deg"
          xAxis       = 0, {rpmhigh}, 8
          yAxis       = 0, 180, 8
          xBins       = map_sample_rpms
          yBins       = map_sample_timing
          gauge       = tachometer

       curve = dwellSettings, "Dwell Battery Adjustment"
          columnLabel = "Voltage", "%age"
          xAxis       = 6, 16, 6
          yAxis       = 0, 500, 6
          xBins       = dwellvolts
          yBins       = dwellcorr

       curve = coldAdvance, "Cold Ignition Advance Offset"
          columnLabel = "Coolant", "Offset"
          xAxis       = -40, {clthighlim}, 9
          yAxis       = -10,  10, 5
          xBins       = tempTable, coolant, readonly
          yBins       = cold_adv_table
          gauge       = cltGauge

       curve = iacBins, "IAC Step Bins"
          columnLabel = "Coolant", "IAC Steps"
          xAxis       = -40, {clthighlim}, 9
          yAxis       =   0, 300, 7
          xBins       = tempTable, coolant, readonly
          yBins       = iacstepTable
          gauge       = cltGauge

       curve = ipwBins, "PWM Idle Duty Cycle"
          columnLabel = "Coolant", "Idle PWM duty"
          xAxis       = -40, {clthighlim}, 9
          yAxis       =   0, 100, 6
          xBins       = tempTable, coolant, readonly
          yBins       = ipwmTable
          gauge       = cltGauge

       curve = primingPW, "Priming Pulsewidth"
          columnLabel = "Coolant", "Prime PW"
          xAxis       = -40, {clthighlim}, 9
          yAxis       =   0,  20, 5
          xBins       = temp_table_p5, coolant, readonly
          yBins       = primePWTable
          gauge       = cltGauge

       curve = crankingPW, "Cranking Pulsewidth%"
          columnLabel = "Coolant", "Cranking PW%"
          xAxis       = -40, {clthighlim}, 9
          yAxis       =   0,  500, 6
          xBins       = temp_table_p5, coolant
          yBins       = crankPctTable
          gauge       = cltGauge

       curve = asePct, "Afterstart Enrichment Percentage"
          columnLabel = "Coolant", "Afterstart"
          xAxis       = -40, {clthighlim}, 9
          yAxis       =   0, 100, 6
          xBins       = temp_table_p5, coolant, readonly
          yBins       = asePctTable
          gauge       = cltGauge

       curve = aseTaper, "Afterstart Enrichment Taper"
          columnLabel = "Coolant", "Taper"
          xAxis       = -40, {clthighlim}, 9
          yAxis       =   0, 500, 6
          xBins       = temp_table_p5, coolant, readonly
          yBins       = aseCntTable
          gauge       = cltGauge

       curve = matBasedRetard, "MAT-Based Timing Retard"
          columnLabel = "MAT", "Retard"
          xAxis       = -40, {mathigh}, 9
          yAxis       =   0,  15, 7
          xBins       = matTemps, mat
          yBins       = matRetard
          gauge       = matGauge

       curve = barometerCorr, "Non-Linear Barometric Correction"
          columnLabel = "Barometer", "Correction"
          xAxis       =  60, 120, 7
          yAxis       = -30,  30, 7
          xBins       = baroCorrVals, barometer
          yBins       = baroCorrDelta
          gauge       = barometerGauge

       curve = manifoldTempCorr, "Non-Linear MAT Correction"
          columnLabel = "MAT", "Correction"
          xAxis       =  -40, 200, 9
          yAxis       =  -30,  30, 7
          xBins       = matCorrTemps, mat
          yBins       = matCorrDelta
          gauge       = matGauge

; this is just as an example.. not yet finished
       curve = EAEmanycurves, "Combined EAE Curve Graph - example to test TunerStudio features"
          columnLabel = "RPM", "Correction"
          xAxis       = 0, {rpmhigh}, 12
          yAxis       = 0, 200, 12
          xBins       = EAESOCRPMbins, rpm
          yBins       = EAESON
          xBins       = EAEAWCRPMbins, rpm
          yBins       = EAEAWN
          xBins       = EAEAWCRPMbins2, rpm
          yBins       = EAEAWN2
          xBins  = EAESOCRPMbins2, rpm ; commented out to show last yAxis tied to previous xAxis
          yBins       = EAESON2
          gauge       = EAEGauge1 ; As always gauge is optional
          
          lineLabel   = "Sucked-from-walls const"
          lineLabel   = "Adhere-to-walls coef"
          lineLabel   = "Adhere-to-walls coef 2"
          lineLabel   = "Sucked-from-walls Correction"

       curve = EAEBAWCcurve, "Enhanced Accel Enrichment Added-to-Walls coefficient"
          columnLabel = "%", "Correction"
          xAxis	  = 0, 255, 12
          yAxis       = 0, 100, 12
          xBins	  = EAEAWCKPAbins, eaeload1
          yBins	  = EAEBAWC
          gauge	  = EAEGauge1

       curve = EAEBSOCcurve, "Enhanced Accel Enrichment Sucked-from-Walls coefficient"
          columnLabel = "%", "Correction"
          xAxis	  = 0, 255, 12
          yAxis	  = 0, 25.5, 12
          xBins	  = EAESOCKPAbins, eaeload1
          yBins	  = EAEBSOC
          gauge	  = EAEGauge1

       curve = EAEAWNcurve, "Enhanced Accel Enrichment AWC RPM %"
          columnLabel = "RPM", "Correction"
          xAxis	  = 0, {rpmhigh}, 12
          yAxis	  = 0, 200, 12
          xBins 	  = EAEAWCRPMbins, rpm
          yBins	  = EAEAWN
          gauge	  = EAEGauge1

       curve = EAESONcurve, "Enhanced Accel Enrichment SOC RPM %"
          columnLabel = "RPM", "Correction"
          xAxis       = 0, {rpmhigh}, 12
          yAxis       = 0, 200, 12
          xBins	  = EAESOCRPMbins, rpm
          yBins       = EAESON
          gauge	  = EAEGauge1

       curve = EAESOWcurve, "Enhanced Accel Enrichment SOW CLT %"
          columnLabel = "CLT", "Correction"
          xAxis       = 0, {clthighlim}, 12
          yAxis       = 0, 200, 12
          xBins	  = EAESOWCLTbins, coolant
          yBins       = EAESOW
          gauge	  = EAEGauge1

       curve = EAEAWWcurve, "Enhanced Accel Enrichment AWW CLT %"
          columnLabel = "CLT", "Correction"
          xAxis       = 0, {clthighlim}, 12
          yAxis       = 0, 200, 12
          xBins	  = EAEAWWCLTbins, coolant
          yBins       = EAEAWW
          gauge	  = EAEGauge1

       curve = EAEBAWCcurve2, "Enhanced Accel Enrichment Added-to-Walls coefficient"
          columnLabel = "%", "Correction"
          xAxis	  = 0, 255, 12
          yAxis       = 0, 100, 12
          xBins	  = EAEAWCKPAbins2, fuelload
          yBins	  = EAEBAWC2
          gauge	  = EAEGauge1

       curve = EAEBSOCcurve2, "Enhanced Accel Enrichment Sucked-from-Walls coefficient"
          columnLabel = "%", "Correction"
          xAxis	  = 0, 255, 12
          yAxis	  = 0, 25.5, 12
          xBins	  = EAESOCKPAbins2, fuelload
          yBins	  = EAEBSOC2
          gauge	  = EAEGauge1

       curve = EAEAWNcurve2, "Enhanced Accel Enrichment AWC RPM %"
          columnLabel = "RPM", "Correction"
          xAxis	  = 0, {rpmhigh}, 12
          yAxis	  = 0, 200, 12
          xBins 	  = EAEAWCRPMbins2, rpm
          yBins	  = EAEAWN2
          gauge	  = EAEGauge1

       curve = EAESONcurve2, "Enhanced Accel Enrichment SOC RPM %"
          columnLabel = "RPM", "Correction"
          xAxis       = 0, {rpmhigh}, 12
          yAxis       = 0, 200, 12
          xBins	  = EAESOCRPMbins2, rpm
          yBins       = EAESON2
          gauge	  = EAEGauge1

       curve = EAESOWcurve2, "Enhanced Accel Enrichment SOW CLT %"
          columnLabel = "CLT", "Correction"
          xAxis       = 0, {clthighlim}, 12
          yAxis       = 0, 200, 12
          xBins	  = EAESOWCLTbins2, coolant
          yBins       = EAESOW2
          gauge	  = EAEGauge1

       curve = EAEAWWcurve2, "Enhanced Accel Enrichment AWW CLT %"
          columnLabel = "CLT", "Correction"
          xAxis       = 0, {clthighlim}, 12
          yAxis       = 0, 200, 12

          xBins	  = EAEAWWCLTbins2, coolant
          yBins       = EAEAWW2
          gauge	  = EAEGauge1

       curve = XAccTable, "X Accel Fuel Correction"
         topicHelp   = "http://www.megamanual.com/mt28.htm#ua"

          columnLabel = "RPM", "Correction"
          xAxis       =    0,  {rpmhigh}, 4
          yAxis       =    0,   120, 4
          xBins       = XTrpms, rpm
          yBins       = XAcc
          gauge       = EAEGauge1 
            
       curve = XDecTable, "X Decel Fuel Correction"
         topicHelp   = "http://www.megamanual.com/mt28.htm#ud"
          columnLabel = "RPM", "Correction"
          xAxis       =    0,  {rpmhigh}, 9
          yAxis       =    0,   120, 9
          xBins       = XTrpms, rpm
          yBins       = XDec
          gauge       = EAEGauge1
           
       curve = TauAccTable, "Tau Accel Fuel Correction"
         topicHelp   = "http://www.megamanual.com/mt28.htm#uc"
          columnLabel = "RPM", "time"
          xAxis       =    0,  {rpmhigh}, 9
          yAxis       =    0,  1000, 9
          xBins       = XTrpms, rpm
          yBins       = TauAcc
          gauge       = EAEGauge1
     
       curve = TauDecTable, "Tau Decel Correction"
         topicHelp   = "http://www.megamanual.com/mt28.htm#ue"
          columnLabel = "RPM", "time"
          xAxis       =    0,  {rpmhigh}, 9
          yAxis       =    0,  1000, 9
          xBins       = XTrpms, rpm
          yBins       = TauDec
          gauge       = EAEGauge1 
          
       curve = XCltTable, "X (Puddling) Temp. Correction Factors"
         topicHelp   = "http://www.megamanual.com/mt28.htm#ux"
          columnLabel = "Temperature", "Correction"
          xAxis       = -40, {clthighlim}, 9
          yAxis       =    0,   600, 9
          xBins       = XClt_temps
          yBins       = XClt
          gauge       = cltGauge 
          
       curve = TCltTable, "Tau (Time) Temp. Correction Factors"
         topicHelp   = "http://www.megamanual.com/mt28.htm#ut"
          columnLabel = "Temperature", "time"
          xAxis       = -40, {clthighlim}, 9
          yAxis       =    0,   600, 9
          xBins       = TauClt_temps
          yBins       = TauClt
          gauge       = cltGauge

       curve = NoiseFiltercurve, "Noise filter curve"
          columnLabel = "RPMS", "usec"
          xAxis	  = 0, {rpmhigh}, 4
          yAxis	  = 0, 2000, 4
          xBins	  = NoiseFilterRpm
          yBins	  = NoiseFilterLen

       curve = warmup_curve, "Warmup Enrichment Curve"
          columnLabel = "Coolant", "WUE %"
          xAxis       = -40, {clthighlim}, 9
          yAxis       =   0,  500, 6
          xBins       = tempTable, coolant
          yBins       = wueBins
          gauge       = cltGauge

       curve = idleAdvance_curve, "Idle Advance Timing"
          columnLabel = "Load %", "deg"
          xAxis = 0, 100, 4
          yAxis = -10, 90, 4
          xBins = idleadvance_loads, fuelload
          yBins = idleadvance_curve

       curve = pwmidle_target_curve, "Closed loop PWM idle target rpms"
          columnLabel = "CLT", "RPM"
          xAxis       = 0, {clthighlim}, 8
          yAxis	  = 0, 2000, 8
          xBins	  = pwmidle_clt_temps, coolant
          yBins       = pwmidle_target_rpms

       curve = revlimiterBins, "Coolant Based Rev Limit" 
    ;      topicHelp   = "http://www.megasquirt.info/megatune.htm#ap" 
          columnLabel = "Coolant", "Rev limit" 
          xAxis       = -40, {clthighlim}, 8
          yAxis		  =   0, 15000, 8 
          xBins       = RevLimLookup, coolant 
          yBins       = RevLimRpm1 
          gauge       = cltGauge

       curve = pwmidle_crank_dutyorsteps_dutycurve, "Coolant-based crank duty"
          columnLabel = "Coolant", "Duty %"
          xAxis       = -40, {clthighlim}, 4
          yAxis       = 0, 100, 4
          xBins       = pwmidle_crank_clt_temps
          yBins       = pwmidle_crank_dutyorsteps_duty
          gauge       = cltGauge

       curve = pwmidle_crank_dutyorsteps_stepscurve, "Coolant-based crank steps"
          columnLabel = "Coolant", "Steps"
          xAxis       = -40, {clthighlim}, 4
          yAxis       = 0, 512, 4
          xBins       = pwmidle_crank_clt_temps
          yBins       = pwmidle_crank_dutyorsteps_steps
          gauge       = cltGauge

        curve = ITB_load_loadvals_curve, "ITB load at TPS switchpoint"
          columnLabel = "RPM", "Load"
          xAxis       = 0, {rpmhigh}, 12
          yAxis       = 0, 100, 12
          xBins       = ITB_load_rpms, rpm
          yBins       = ITB_load_loadvals

        curve = ITB_load_switchpoint_curve, "ITB load TPS switchpoints"
          columnLabel = "RPM", "TPS %"
          xAxis       = 0, {rpmhigh}, 12
          yAxis       = 0, 100, 12
          xBins       = ITB_load_rpms, rpm
          yBins       = ITB_load_switchpoints

    [TableEditor]
       ;       table_id,    map3d_id,    "title",      page

       table = pwmidle_cl_initialvalues_dty, pwmidle_cl_initialvalues_dtymap, "Closed loop idle initial values", 19
         xBins = pwmidle_cl_initialvalue_rpms, cl_idle_targ_rpm
         yBins = pwmidle_cl_initialvalue_matorclt, pwmidle_cl_initialvalue_matorclt_follower
         zBins = pwmidle_cl_initialvalues_duties
         upDownLabel = "INCREASE","DECREASE"
         gridHeight = 2.0
         gridOrient = 250, 0, 340

       table = pwmidle_cl_initialvalues_stps, pwmidle_cl_initialvalues_stpmap, "Closed loop idle initial values", 19
         xBins = pwmidle_cl_initialvalue_rpms, cl_idle_targ_rpm
         yBins = pwmidle_cl_initialvalue_matorclt, pwmidle_cl_initialvalue_matorclt_follower
         zBins = pwmidle_cl_initialvalues_steps
         upDownLabel = "INCREASE","DECREASE"
         gridHeight = 2.0
         gridOrient = 250, 0, 340

;vvt timing
       table = vvt_timing1_tbl, vvt_timing1_map, "VVT intake relative timing", 7
          xBins       = vvt_timing_rpm, rpm
          yBins       = vvt_timing_load, fuelload
          zBins       = vvt_timing1
          upDownLabel = "ADVANCE", "RETARD"
          gridHeight  = 2.0
          gridOrient  = 250,  0, 340

       table = vvt_timing2_tbl, vvt_timing2_map, "VVT exhaust relative timing", 7
          xBins       = vvt_timing_rpm, rpm
          yBins       = vvt_timing_load, fuelload
          zBins       = vvt_timing2
          upDownLabel = "ADVANCE", "RETARD"
          gridHeight  = 2.0
          gridOrient  = 250,  0, 340

       table = als_rifuelcut_tbl, als_rifuelcut_map, "ALS roving idle fuel cut%", 14
          xBins       = als_rirpms, rpm
          yBins	      = als_ritpss, tps
          zBins       = als_rifuelcut
          upDownLabel = "HIGHER", "LOWER"
          gridHeight = 2.0
          gridOrient = 250, 0, 340

       table = als_fuelcut_tbl, als_fuelcut_map, "ALS fuel cut%", 14
          xBins       = als_rpms, rpm
          yBins	      = als_tpss, tps
          zBins       = als_fuelcut
          upDownLabel = "HIGHER", "LOWER"
          gridHeight = 2.0
          gridOrient = 250, 0, 340

       table = als_sparkcut_tbl, als_sparkcut_map, "ALS spark cut%", 14
          xBins       = als_rpms, rpm
          yBins	      = als_tpss, tps
          zBins       = als_sparkcut
          upDownLabel = "HIGHER", "LOWER"
          gridHeight = 2.0
          gridOrient = 250, 0, 340

       table = als_timing_tbl, als_timing_map, "ALS timing", 14
          xBins       = als_rpms, rpm
          yBins	      = als_tpss, tps
          zBins       = als_timing
          upDownLabel = "ADVANCE", "RETARD"
          gridHeight = 2.0
          gridOrient = 250, 0, 340

       table = als_addfuel_tbl, als_addfuel_map, "ALS added fuel %age", 14
          xBins       = als_rpms, rpm
          yBins	      = als_tpss, tps
          zBins       = als_addfuel
          upDownLabel = "HIGHER", "LOWER"
          gridHeight = 2.0
          gridOrient = 250, 0, 340

       table = pwm_duties_Tbl_a, pwm_duties_map_a, "Generic PWM A", 11
          xBins       = pwm_rpms_a, rpm
          yBins	      = pwm_loadvals_a, pwma_load
          zBins       = pwm_duties_a
          upDownLabel = "HIGHER", "LOWER"
          gridHeight = 2.0
          gridOrient = 250, 0, 340

       table = pwm_duties_Tbl_b, pwm_duties_map_b, "Generic PWM B", 2
          xBins       = pwm_rpms_b, rpm
          yBins	      = pwm_loadvals_b, pwmb_load
          zBins       = pwm_duties_b
          upDownLabel = "HIGHER", "LOWER"
          gridHeight = 2.0
          gridOrient = 250, 0, 340

       table = pwm_duties_Tbl_c, pwm_duties_map_c, "Generic PWM C", 2
          xBins       = pwm_rpms_c, rpm
          yBins	      = pwm_loadvals_c, pwmc_load
          zBins       = pwm_duties_c
          upDownLabel = "HIGHER", "LOWER"
          gridHeight = 2.0
          gridOrient = 250, 0, 340

       table = pwm_duties_Tbl_d, pwm_duties_map_d, "Generic PWM D", 2
          xBins       = pwm_rpms_d, rpm
          yBins	      = pwm_loadvals_d, pwmd_load
          zBins       = pwm_duties_d
          upDownLabel = "HIGHER", "LOWER"
          gridHeight = 2.0
          gridOrient = 250, 0, 340

       table = pwm_duties_Tbl_vvt, pwm_duties_map_vvt, "Generic PWM E / VVT", 2
          xBins       = pwm_rpms_e, rpm
          yBins	      = pwm_loadvals_e, fuelload
          zBins       = pwm_duties_e
          upDownLabel = "HIGHER", "LOWER"
          gridHeight = 2.0
          gridOrient = 250, 0, 340

       table = pwm_duties_Tbl_e, pwm_duties_map_e, "Generic PWM E", 2
          xBins       = pwm_rpms_e, rpm
          yBins	      = pwm_loadvals_e, pwme_load
          zBins       = pwm_duties_e
          upDownLabel = "HIGHER", "LOWER"
          gridHeight = 2.0
          gridOrient = 250, 0, 340

       table = pwm_duties_Tbl_f, pwm_duties_map_f, "Generic PWM F", 2
          xBins       = pwm_rpms_f, rpm
          yBins	      = pwm_loadvals_f, pwmf_load
          zBins       = pwm_duties_f
          upDownLabel = "HIGHER", "LOWER"
          gridHeight = 2.0
          gridOrient = 250, 0, 340

       table = waterinjTbl, waterinjMap, "Water Injection Duty Table ", 1
          xBins       = waterinj_rpm, rpm
          yBins       = waterinj_map, map
          zBins       = waterinj_duty
          upDownLabel = "MORE", "LESS"
          gridHeight  = 2.0
          gridOrient  = 250,   0, 340 ; Space 123 rotation of grid in degrees.

#if LAMBDA
       table = maxafr1Tbl, maxafr1Map, "Max AFR 1 in Lambda", 1
          gridHeight  = 3.0
#else
       table = maxafr1Tbl, maxafr1Map, "Max AFR difference", 1
          gridHeight  = 1.0
#endif
          xBins       = maxafr1_rpm, rpm
          yBins       = maxafr1_load, fuelload
          zBins       = maxafr1_diff
          upDownLabel = "LEANER", "RICHER"
          gridOrient  = 250,   0, 340
    
   table = veTable1Tbl, veTable1Map, "VE Table 1", 4
          ;             constant,   variable
          xBins       = frpm_table1, rpm
          yBins       = fmap_table1, fuelload
          zBins       = veTable1

          upDownLabel = "RICHER", "LEANER"
          gridHeight  = 2.0
          gridOrient  = 250,   0, 340 ; Space 123 rotation of grid in degrees.

       table = veTable2Tbl, veTable2Map, "VE Table 2", 4
          xBins       = frpm_table2, rpm
          yBins       = fmap_table2, fuelload2
          zBins       = veTable2

          upDownLabel = "RICHER", "LEANER"
          gridHeight  = 2.0
          gridOrient  = 250,   0, 340

       table = veTable3Tbl, veTable3Map, "VE Table 3", 4
          ;             constant,   variable
          xBins       = frpm_table3, rpm
          yBins       = fmap_table3, fuelload
          zBins       = veTable3

          upDownLabel = "RICHER", "LEANER"
          gridHeight  = 2.0
          gridOrient  = 250,   0, 340 ; Space 123 rotation of grid in degrees.

       table = veTable4Tbl, veTable4Map, "VE Table 4", 4
          ;             constant,   variable
          xBins       = frpm_table4, rpm
          yBins       = fmap_table4, fuelload
          zBins       = veTable4


          upDownLabel = "RICHER", "LEANER"
          gridHeight  = 2.0
          gridOrient  = 250,   0, 340 ; Space 123 rotation of grid in degrees.

       table = idleve1Tbl, idleve1Map, "Idle VE table 1", 10
          xBins       = idleve_rpms1, rpm
          yBins       = idleve_loads1, fuelload
          zBins       = idleve_table1

          upDownLabel = "RICHER", "LEANER"
          gridHeight  = 2.0
          gridOrient  = 250,   0,  340

       table = idleve2Tbl, idleve2Map, "Idle VE table 2", 10 
          xBins       = idleve_rpms2, rpm
          yBins       = idleve_loads2, fuelload
          zBins       = idleve_table2

          upDownLabel = "RICHER", "LEANER"
          gridHeight  = 2.0
          gridOrient  = 250, 0, 340

       table = stagedTable, stagedMap, "Staged Injection table", 6
          xBins       = staged_rpms, rpm
          yBins       = staged_loads, fuelload
          zBins       = staged_percents

          upDownLabel = "MORE", "LESS"
          gridHeight  = 2.0
          gridOrient = 250, 0, 340

#if LAMBDA
       table = afrTable1Tbl, afrTable1Map, "Lambda Table 1", 1
          gridHeight  = 3.0
#else
       table = afrTable1Tbl, afrTable1Map, "AFR Table 1", 1
          gridHeight  = 1.0
#endif
          xBins       = arpm_table1, rpm
          yBins       = amap_table1, afrload1
          zBins       = afrTable1
          upDownLabel = "LEANER", "RICHER"
          gridOrient  = 250,   0, 340

#if LAMBDA
       table = afrTable2Tbl, afrTable2Map, "Lambda Table 2", 1

          gridHeight  = 3.0
#else
       table = afrTable2Tbl, afrTable2Map, "AFR Table 2", 1
          gridHeight  = 1.0
#endif
          xBins       = arpm_table2, rpm
          yBins       = amap_table2, fuelload
          zBins       = afrTable2
          upDownLabel = "LEANER", "RICHER"
          gridOrient  = 250,   0, 340

       table = ignitionTbl1, ignitionMap1, "Spark Advance Table1", 3
          xBins       = srpm_table1, rpm
          yBins       = smap_table1, ignload
          zBins       = advanceTable1
          upDownLabel = "ADVANCING", "RETARDING"
          gridHeight  = 3.0
          gridOrient  = 250,   0, 340

       table = ignitionTbl2, ignitionMap2, "Spark Advance Table2", 3
          xBins       = srpm_table2, rpm
          yBins       = smap_table2, ignload2
          zBins       = advanceTable2
          upDownLabel = "ADVANCING", "RETARDING"
          gridHeight  = 3.0
          gridOrient  = 250,   0, 340

       table = ignitionTbl3, ignitionMap3, "Spark Advance Table3", 4
          xBins       = srpm_table3, rpm
          yBins       = smap_table3, ignload
          zBins       = advanceTable3
          upDownLabel = "ADVANCING", "RETARDING"
          gridHeight  = 3.0
          gridOrient  = 250,   0, 340

       table = ignitionTbl4, ignitionMap4, "Spark Advance Table4", 4
          xBins       = srpm_table4, rpm
          yBins       = smap_table4, ignload
          zBins       = advanceTable4
          upDownLabel = "ADVANCING", "RETARDING"
          gridHeight  = 3.0
          gridOrient  = 250,   0, 340

       table = RotarySplitTbl, RotarySplitMap, "Rotary Split Table", 3
          xBins	  = RotarySplitRPM, rpm
          yBins       = RotarySplitLoad, ignload
          zBins	  = RotarySplitTable
          upDownLabel = "ADVANCING", "RETARDING"
          gridHeight = 3.0
          gridOrient = 250, 0, 340

       table = boostctlDutys, boostctlDtyMap, "Boost Control Duty 1", 2
          xBins       = boost_ctl_pwmtarg_rpm_bins, rpm
          yBins	  = boost_ctl_pwmtarg_tps_bins, throttle
          zBins       = boost_ctl_pwm_targets
          upDownLabel = "HIGHER", "LOWER"
          gridHeight = 2.0
          gridOrient = 250, 0, 340

       table = boostctlTargs, boostctlTargMap, "Boost Control Targets 1", 2
          xBins       = boost_ctl_loadtarg_rpm_bins, rpm
          yBins       = boost_ctl_loadtarg_tps_bins, throttle
          zBins       = boost_ctl_load_targets
          upDownLabel = "HIGHER", "LOWER"
          gridHeight  = 2.0
          gridOrient  = 250, 0, 340

       table = boostctlDutys2, boostctlDtyMap2, "Boost Control Duty 2", 2
          xBins       = boost_ctl_pwmtarg_rpm_bins2, rpm
          yBins	  = boost_ctl_pwmtarg_tps_bins2, throttle
          zBins       = boost_ctl_pwm_targets2
          upDownLabel = "HIGHER", "LOWER"
          gridHeight = 2.0
          gridOrient = 250, 0, 340

       table = boostctlTargs2, boostctlTargMap2, "Boost Control Targets 2", 2
          xBins       = boost_ctl_loadtarg_rpm_bins2, rpm
          yBins       = boost_ctl_loadtarg_tps_bins2, throttle
          zBins       = boost_ctl_load_targets2
          upDownLabel = "HIGHER", "LOWER"
          gridHeight  = 2.0
          gridOrient  = 250, 0, 340

    ;injector trims
       table = inj_trimaTbl, inj_trimaMap, "Cyl 1 fuel trim", 7
          ;             constant,   variable
          xBins       = inj_trim_rpm, rpm
          yBins       = inj_trim_load, fuelload
          zBins       = inj_trima

          upDownLabel = "RICHER", "LEANER"
          gridHeight  = 2.0
          gridOrient  = 250,   0, 340 ; Space 123 rotation of grid in degrees.

       table = inj_trimbTbl, inj_trimbMap, "Cyl 2 fuel trim", 7
          ;             constant,   variable
          xBins       = inj_trim_rpm, rpm, readonly
          yBins       = inj_trim_load, fuelload, readonly
          zBins       = inj_trimb

          upDownLabel = "RICHER", "LEANER"
          gridHeight  = 2.0
          gridOrient  = 250,   0, 340 ; Space 123 rotation of grid in degrees.

       table = inj_trimcTbl, inj_trimcMap, "Cyl 3 fuel trim", 7
          ;             constant,   variable
          xBins       = inj_trim_rpm, rpm, readonly
          yBins       = inj_trim_load, fuelload, readonly
          zBins       = inj_trimc

          upDownLabel = "RICHER", "LEANER"
          gridHeight  = 2.0
          gridOrient  = 250,   0, 340 ; Space 123 rotation of grid in degrees.

       table = inj_trimdTbl, inj_trimdMap, "Cyl 4 fuel trim", 7
          ;             constant,   variable
          xBins       = inj_trim_rpm, rpm, readonly
          yBins       = inj_trim_load, fuelload, readonly
          zBins       = inj_trimd

          upDownLabel = "RICHER", "LEANER"
          gridHeight  = 2.0
          gridOrient  = 250,   0, 340 ; Space 123 rotation of grid in degrees.

       table = inj_trimeTbl, inj_trimeMap, "Cyl 5 fuel trim", 7
          ;             constant,   variable
          xBins       = inj_trim_rpm, rpm, readonly
          yBins       = inj_trim_load, fuelload, readonly
          zBins       = inj_trime

          upDownLabel = "RICHER", "LEANER"
          gridHeight  = 2.0
          gridOrient  = 250,   0, 340 ; Space 123 rotation of grid in degrees.

       table = inj_trimfTbl, inj_trimfMap, "Cyl 6 fuel trim", 7
          ;             constant,   variable
          xBins       = inj_trim_rpm, rpm, readonly
          yBins       = inj_trim_load, fuelload, readonly
          zBins       = inj_trimf

          upDownLabel = "RICHER", "LEANER"
          gridHeight  = 2.0
          gridOrient  = 250,   0, 340 ; Space 123 rotation of grid in degrees.

       table = inj_trimgTbl, inj_trimgMap, "Cyl 7 fuel trim", 7
          ;             constant,   variable
          xBins       = inj_trim_rpm, rpm, readonly
          yBins       = inj_trim_load, fuelload, readonly
          zBins       = inj_trimg

          upDownLabel = "RICHER", "LEANER"
          gridHeight  = 2.0
          gridOrient  = 250,   0, 340 ; Space 123 rotation of grid in degrees.

       table = inj_trimhTbl, inj_trimhMap, "Cyl 8 fuel trim", 7
          ;             constant,   variable
          xBins       = inj_trim_rpm, rpm, readonly
          yBins       = inj_trim_load, fuelload, readonly
          zBins       = inj_trimh

          upDownLabel = "RICHER", "LEANER"
          gridHeight  = 2.0
          gridOrient  = 250,   0, 340 ; Space 123 rotation of grid in degrees.


       table = inj_trim1Tbl, inj_trim1Map, "Injector Trim 1", 7
          ;             constant,   variable
          xBins       = inj_trim_rpm, rpm, readonly
          yBins       = inj_trim_load, fuelload, readonly
          zBins       = inj_trimi

          upDownLabel = "RICHER", "LEANER"
          gridHeight  = 2.0
          gridOrient  = 250,   0, 340 ; Space 123 rotation of grid in degrees.

       table = inj_trim2Tbl, inj_trim2Map, "Injector Trim 2", 7
          ;             constant,   variable
          xBins       = inj_trim_rpm, rpm, readonly
          yBins       = inj_trim_load, fuelload, readonly

          zBins       = inj_trimj

          upDownLabel = "RICHER", "LEANER"
          gridHeight  = 2.0
          gridOrient  = 250,   0, 340 ; Space 123 rotation of grid in degrees.

       table = inj_trimiTbl, inj_trimiMap, "Cyl 9 fuel trim", 7
          ;             constant,   variable
          xBins       = inj_trim_rpm, rpm
          yBins       = inj_trim_load, fuelload
          zBins       = inj_trimi

          upDownLabel = "RICHER", "LEANER"
          gridHeight  = 2.0
          gridOrient  = 250,   0, 340 ; Space 123 rotation of grid in degrees.

       table = inj_trimjTbl, inj_trimjMap, "Cyl 10 fuel trim", 7
          ;             constant,   variable
          xBins       = inj_trim_rpm, rpm, readonly
          yBins       = inj_trim_load, fuelload, readonly
          zBins       = inj_trimj

          upDownLabel = "RICHER", "LEANER"
          gridHeight  = 2.0
          gridOrient  = 250,   0, 340 ; Space 123 rotation of grid in degrees.

       table = inj_trimkTbl, inj_trimkMap, "Cyl 11 fuel trim", 7
          ;             constant,   variable
          xBins       = inj_trim_rpm, rpm, readonly
          yBins       = inj_trim_load, fuelload, readonly
          zBins       = inj_trimk

          upDownLabel = "RICHER", "LEANER"
          gridHeight  = 2.0
          gridOrient  = 250,   0, 340 ; Space 123 rotation of grid in degrees.

       table = inj_trimlTbl, inj_trimlMap, "Cyl 12 fuel trim", 7
          ;             constant,   variable
          xBins       = inj_trim_rpm, rpm, readonly
          yBins       = inj_trim_load, fuelload, readonly
          zBins       = inj_triml

          upDownLabel = "RICHER", "LEANER"
          gridHeight  = 2.0
          gridOrient  = 250,   0, 340 ; Space 123 rotation of grid in degrees.

       table = inj_trimmTbl, inj_trimmMap, "Cyl 13 fuel trim", 7
          ;             constant,   variable
          xBins       = inj_trim_rpm, rpm, readonly
          yBins       = inj_trim_load, fuelload, readonly
          zBins       = inj_trimm

          upDownLabel = "RICHER", "LEANER"
          gridHeight  = 2.0
          gridOrient  = 250,   0, 340 ; Space 123 rotation of grid in degrees.

       table = inj_trimnTbl, inj_trimnMap, "Cyl 14 fuel trim", 7
          ;             constant,   variable
          xBins       = inj_trim_rpm, rpm, readonly
          yBins       = inj_trim_load, fuelload, readonly
          zBins       = inj_trimn

          upDownLabel = "RICHER", "LEANER"
          gridHeight  = 2.0
          gridOrient  = 250,   0, 340 ; Space 123 rotation of grid in degrees.

       table = inj_trimoTbl, inj_trimoMap, "Cyl 15 fuel trim", 7
          ;             constant,   variable
          xBins       = inj_trim_rpm, rpm, readonly
          yBins       = inj_trim_load, fuelload, readonly
          zBins       = inj_trimo

          upDownLabel = "RICHER", "LEANER"
          gridHeight  = 2.0
          gridOrient  = 250,   0, 340 ; Space 123 rotation of grid in degrees.

       table = inj_trimpTbl, inj_trimpMap, "Cyl 16 fuel trim", 7
          ;             constant,   variable
          xBins       = inj_trim_rpm, rpm, readonly
          yBins       = inj_trim_load, fuelload, readonly
          zBins       = inj_trimp

          upDownLabel = "RICHER", "LEANER"
          gridHeight  = 2.0
          gridOrient  = 250,   0, 340 ; Space 123 rotation of grid in degrees.

;inj timing
       table = inj_timing_tbl, inj_timing_map, "Injector Timing", 7
          xBins       = inj_timing_rpm, rpm
          yBins       = inj_timing_load, fuelload
          zBins       = inj_timing
          upDownLabel = "ADVANCE", "RETARD"
          gridHeight  = 2.0
          gridOrient  = 250,  0, 340

       table = inj_timing_sec_tbl, inj_timing_sec_map, "Secondary Injector Timing", 7
          xBins       = inj_timing_sec_rpm, rpm
          yBins       = inj_timing_sec_load, fuelload
          zBins       = inj_timing_sec
          upDownLabel = "ADVANCE", "RETARD"
          gridHeight = 2.0
          gridOrient = 250, 0, 340


    ;spark trims
       table = spk_trimaTbl, spk_trimaMap, "Spark Trim 1", 8
          ;             constant,   variable
          xBins       = spk_trim_rpm, rpm
          yBins       = spk_trim_load, ignload
          zBins       = spk_trima
          upDownLabel = "RICHER", "LEANER"
          gridHeight  = 2.0
          gridOrient  = 250,   0, 340 ; Space 123 rotation of grid in degrees.

       table = spk_trimbTbl, spk_trimbMap, "Spark Trim 2", 8
          ;             constant,   variable
          xBins       = spk_trim_rpm, rpm
          yBins       = spk_trim_load, ignload
          zBins       = spk_trimb
          upDownLabel = "RICHER", "LEANER"
          gridHeight  = 2.0
          gridOrient  = 250,   0, 340 ; Space 123 rotation of grid in degrees.



       table = spk_trimcTbl, spk_trimcMap, "Spark Trim 3", 8
          ;             constant,   variable
          xBins       = spk_trim_rpm, rpm
          yBins       = spk_trim_load, ignload
          zBins       = spk_trimc
          upDownLabel = "RICHER", "LEANER"
          gridHeight  = 2.0
          gridOrient  = 250,   0, 340 ; Space 123 rotation of grid in degrees.

       table = spk_trimdTbl, spk_trimdMap, "Spark Trim 4", 8
          ;             constant,   variable
          xBins       = spk_trim_rpm, rpm
          yBins       = spk_trim_load, ignload
          zBins       = spk_trimd
          upDownLabel = "RICHER", "LEANER"
          gridHeight  = 2.0
          gridOrient  = 250,   0, 340 ; Space 123 rotation of grid in degrees.

       table = spk_trimeTbl, spk_trimeMap, "Spark Trim 5", 8
          ;             constant,   variable
          xBins       = spk_trim_rpm, rpm
          yBins       = spk_trim_load, ignload
          zBins       = spk_trime
          upDownLabel = "RICHER", "LEANER"
          gridHeight  = 2.0
          gridOrient  = 250,   0, 340 ; Space 123 rotation of grid in degrees.

       table = spk_trimfTbl, spk_trimfMap, "Spark Trim 6", 8
          ;             constant,   variable
          xBins       = spk_trim_rpm, rpm
          yBins       = spk_trim_load, ignload
          zBins       = spk_trimf
          upDownLabel = "RICHER", "LEANER"
          gridHeight  = 2.0
          gridOrient  = 250,   0, 340 ; Space 123 rotation of grid in degrees.

       table = spk_trimgTbl, spk_trimgMap, "Spark Trim 7", 8
          ;             constant,   variable
          xBins       = spk_trim_rpm, rpm
          yBins       = spk_trim_load, ignload
          zBins       = spk_trimg
          upDownLabel = "RICHER", "LEANER"
          gridHeight  = 2.0
          gridOrient  = 250,   0, 340 ; Space 123 rotation of grid in degrees.

       table = spk_trimhTbl, spk_trimhMap, "Spark Trim 8", 8
          ;             constant,   variable
          xBins       = spk_trim_rpm, rpm
          yBins       = spk_trim_load, ignload
          zBins       = spk_trimh
          upDownLabel = "RICHER", "LEANER"
          gridHeight  = 2.0
          gridOrient  = 250,   0, 340 ; Space 123 rotation of grid in degrees.


       table = spk_trimiTbl, spk_trimiMap, "Spark Trim 9", 8
          ;             constant,   variable
          xBins       = spk_trim_rpm, rpm
          yBins       = spk_trim_load, ignload


          zBins       = spk_trimi
          upDownLabel = "RICHER", "LEANER"
          gridHeight  = 2.0
          gridOrient  = 250,   0, 340 ; Space 123 rotation of grid in degrees.


       table = spk_trimjTbl, spk_trimjMap, "Spark Trim 10", 8
          ;             constant,   variable
          xBins       = spk_trim_rpm, rpm
          yBins       = spk_trim_load, ignload
          zBins       = spk_trimj
          upDownLabel = "RICHER", "LEANER"
          gridHeight  = 2.0
          gridOrient  = 250,   0, 340 ; Space 123 rotation of grid in degrees.

       table = spk_trimkTbl, spk_trimkMap, "Spark Trim 11", 8
          ;             constant,   variable
          xBins       = spk_trim_rpm, rpm
          yBins       = spk_trim_load, ignload
          zBins       = spk_trimk
          upDownLabel = "RICHER", "LEANER"
          gridHeight  = 2.0
          gridOrient  = 250,   0, 340 ; Space 123 rotation of grid in degrees.

       table = spk_trimlTbl, spk_trimlMap, "Spark Trim 12", 8
          ;             constant,   variable
          xBins       = spk_trim_rpm, rpm
          yBins       = spk_trim_load, ignload
          zBins       = spk_triml
          upDownLabel = "RICHER", "LEANER"
          gridHeight  = 2.0
          gridOrient  = 250,   0, 340 ; Space 123 rotation of grid in degrees.

       table = spk_trimmTbl, spk_trimmMap, "Spark Trim 13", 8
          ;             constant,   variable
          xBins       = spk_trim_rpm, rpm
          yBins       = spk_trim_load, ignload
          zBins       = spk_trimm
          upDownLabel = "RICHER", "LEANER"
          gridHeight  = 2.0
          gridOrient  = 250,   0, 340 ; Space 123 rotation of grid in degrees.

       table = spk_trimnTbl, spk_trimnMap, "Spark Trim 14", 8
          ;             constant,   variable
          xBins       = spk_trim_rpm, rpm
          yBins       = spk_trim_load, ignload
          zBins       = spk_trimn
          upDownLabel = "RICHER", "LEANER"
          gridHeight  = 2.0
          gridOrient  = 250,   0, 340 ; Space 123 rotation of grid in degrees.

       table = spk_trimoTbl, spk_trimoMap, "Spark Trim 15", 8
          ;             constant,   variable
          xBins       = spk_trim_rpm, rpm
          yBins       = spk_trim_load, ignload
          zBins       = spk_trimo
          upDownLabel = "RICHER", "LEANER"
          gridHeight  = 2.0
          gridOrient  = 250,   0, 340 ; Space 123 rotation of grid in degrees.

       table = spk_trimpTbl, spk_trimpMap, "Spark Trim 16", 8
          ;             constant,   variable
          xBins       = spk_trim_rpm, rpm
          yBins       = spk_trim_load, ignload
          zBins       = spk_trimp
          upDownLabel = "RICHER", "LEANER"
          gridHeight  = 2.0
          gridOrient  = 250,   0, 340 ; Space 123 rotation of grid in degrees.

        table = narrowband_tgts_tbl, narrowband_tgts_map, "Narrowband EGO targets", 14
          xBins       = narrowband_tgts_rpms, rpm
          yBins       = narrowband_tgts_loads, afrload1
          zBins       = narrowband_tgts
          upDownLabel = "RICHER", "LEANER"
          gridHeight  = 2.0
          gridOrient  = 250,   0, 340 ; Space 123 rotation of grid in degrees.


    ;-------------------------------------------------------------------------------

    [GaugeConfigurations]

       ;-------------------------------------------------------------------------------
       ; Define a gauge's characteristics here, then go to a specific layout
       ; block (Tuning or FrontPage) and use the name you've defined here to
       ; display that gauge in a particular position.
       ;
       ; Name  = Case-sensitive, user-defined name for this gauge configuration.
       ; Var   = Case-sensitive name of variable to be displayed, see the
       ;         OutputChannels block in this file for possible values.
       ; Title = Title displayed at the top of the gauge.
       ; Units = Units displayed below value on gauge.
       ; Lo    = Lower scale limit of gauge.
       ; Hi    = Upper scale limit of gauge.
       ; LoD   = Lower limit at which danger color is used for gauge background.
       ; LoW   = Lower limit at which warning color is used.
       ; HiW   = Upper limit at which warning color is used.
       ; HiD   = Upper limit at which danger color is used.
       ; vd    = Decimal places in displayed value
       ; ld    = Label decimal places for display of Lo and Hi, above.

       ;Name               Var            Title                 Units     Lo     Hi     LoD    LoW   HiW   HiD vd ld

    gaugeCategory = "Outputs 1"
       pulseWidth1Gauge  = pulseWidth1,   "Pulse Width 1",      "mSec",    0,  25.5,    1.0,   1.2,   20,   25, 3, 1
       pulseWidth2Gauge  = pulseWidth2,   "Pulse Width 2",      "mSec",    0,  25.5,    1.0,   1.2,   20,   25, 3, 1
       pulseWidthSeq1Gauge  = pwseq1,   "Pulse Width Seq 1",    "mSec",    0,  25.5,    1.0,   1.2,   20,   25, 3, 1
       pulseWidthSeq2Gauge  = pwseq2,   "Pulse Width Seq 2",    "mSec",    0,  25.5,    1.0,   1.2,   20,   25, 3, 1
       pulseWidthSeq3Gauge  = pwseq3,   "Pulse Width Seq 3",    "mSec",    0,  25.5,    1.0,   1.2,   20,   25, 3, 1
       pulseWidthSeq4Gauge  = pwseq4,   "Pulse Width Seq 4",    "mSec",    0,  25.5,    1.0,   1.2,   20,   25, 3, 1
       pulseWidthSeq5Gauge  = pwseq5,   "Pulse Width Seq 5",    "mSec",    0,  25.5,    1.0,   1.2,   20,   25, 3, 1
       pulseWidthSeq6Gauge  = pwseq6,   "Pulse Width Seq 6",    "mSec",    0,  25.5,    1.0,   1.2,   20,   25, 3, 1
       pulseWidthSeq7Gauge  = pwseq7,   "Pulse Width Seq 7",    "mSec",    0,  25.5,    1.0,   1.2,   20,   25, 3, 1
       pulseWidthSeq8Gauge  = pwseq8,   "Pulse Width Seq 8",    "mSec",    0,  25.5,    1.0,   1.2,   20,   25, 3, 1
#if CYL_12_16_SUPPORT
       pulseWidthSeq9Gauge  = pwseq9,   "Pulse Width Seq 9",    "mSec",    0,  25.5,    1.0,   1.2,   20,   25, 3, 1
       pulseWidthSeq10Gauge = pwseq10,  "Pulse Width Seq 10",    "mSec",    0,  25.5,    1.0,   1.2,   20,   25, 3, 1
       pulseWidthSeq11Gauge = pwseq11,  "Pulse Width Seq 11",    "mSec",    0,  25.5,    1.0,   1.2,   20,   25, 3, 1
       pulseWidthSeq12Gauge = pwseq12,  "Pulse Width Seq 12",    "mSec",    0,  25.5,    1.0,   1.2,   20,   25, 3, 1
       pulseWidthSeq13Gauge = pwseq13,  "Pulse Width Seq 13",    "mSec",    0,  25.5,    1.0,   1.2,   20,   25, 3, 1
       pulseWidthSeq14Gauge = pwseq14,  "Pulse Width Seq 14",    "mSec",    0,  25.5,    1.0,   1.2,   20,   25, 3, 1
       pulseWidthSeq15Gauge = pwseq15,  "Pulse Width Seq 15",    "mSec",    0,  25.5,    1.0,   1.2,   20,   25, 3, 1
       pulseWidthSeq16Gauge = pwseq16,  "Pulse Width Seq 16",    "mSec",    0,  25.5,    1.0,   1.2,   20,   25, 3, 1
#else
       pulseWidthSeq9Gauge  = pwseq9,   "Pulse Width V3 inj1",  "mSec",    0,  25.5,    1.0,   1.2,   20,   25, 3, 1
       pulseWidthSeq10Gauge = pwseq10,   "Pulse Width V3 inj2",  "mSec",    0,  25.5,    1.0,   1.2,   20,   25, 3, 1
#endif

    gaugeCategory = "Outputs 2"
       IACgauge          = iacstep,       "IAC position",       "steps",   0,   255,    -1,     -1,  999,  999, 0, 0
       dwellGauge        = dwell,         "Dwell",              "mSec",    0,    10,   0.5,    1.0,  6.0,  8.0, 1, 1
       dwelltrlGauge     = dwell_trl,     "Dwell (Trailing)",   "mSec",    0,    10,   0.5,    1.0,  6.0,  8.0, 1, 1
    ;  IAC step == idle pwm, when using pwm idle control.
       PWMIdlegauge      = idleDC,        "Idle PWM%",          "%",       0,   100,    -1,     -1,  999,   90, 1, 1
       advdegGauge       = advance,       "Ignition Advance",   "degrees", 0,    50,    -1,     -1,  999,  999, 1, 1
       dutyCycle1Gauge   = dutyCycle1,    "Duty Cycle 1",       "%",       0,   100,     -1,    -1,   85,   90, 1, 1
       dutyCycle2Gauge   = dutyCycle2,    "Duty Cycle 2",       "%",       0,   100,     -1,    -1,   85,   90, 1, 1
       boostdutyGauge    = boostduty,     "Boost Duty",         "%",       0,    100,   -1,     -1,  100,  100, 1, 1
       boostdutyGauge2   = boostduty2,    "Boost Duty 2",         "%",       0,    100,   -1,     -1,  100,  100, 1, 1
       injtimingpriGauge = inj_timing_pri, "Injector timing (pri)",   "degrees", 0,    50,    -1,     -1,  999,  999, 1, 1
       injtimingsecGauge = inj_timing_sec, "Injector timing (sec)",   "degrees", 0,    50,    -1,     -1,  999,  999, 1, 1

    gaugeCategory = "Outputs 3"
       nitrous_addfuel = n2o_addfuel, "Nitrous added fuel", "ms", -5, 20, 20, 20, 20, 20, 3, 3
       nitrous_retard = n2o_retard, "Nitrous retard", "deg", -5, 30, 30, 30, 30, 30, 1, 1
       nitrous1_duty = nitrous1_duty, "Nitrous 1 Duty", "%", 0, 100, 100, 100, 100, 100, 0 ,0
       nitrous2_duty = nitrous2_duty, "Nitrous 2 Duty", "%", 0, 100, 100, 100, 100, 100, 0 ,0
       nitrous_timer = nitrous_timer, "Nitrous Timer", "s", 0, 15, 15, 15, 15, 15, 3 ,3
       water_duty = water_duty, "Water Duty", "%", 0, 100, 100, 100, 100, 100, 0 ,0
       duty_pwm_a = duty_pwm_a, "Generic PWM A Duty", "%", 0, 100, 100, 100, 100, 100, 0 ,0
       duty_pwm_b = duty_pwm_b, "Generic PWM B Duty", "%", 0, 100, 100, 100, 100, 100, 0 ,0
       duty_pwm_c = duty_pwm_c, "Generic PWM C Duty", "%", 0, 100, 100, 100, 100, 100, 0 ,0
       duty_pwm_d = duty_pwm_d, "Generic PWM D Duty", "%", 0, 100, 100, 100, 100, 100, 0 ,0
       duty_pwm_e = duty_pwm_e, "Generic PWM E Duty", "%", 0, 100, 100, 100, 100, 100, 0 ,0
       duty_pwm_f = duty_pwm_f, "Generic PWM F Duty", "%", 0, 100, 100, 100, 100, 100, 0 ,0
       vvt_duty1 = vvt_duty1, "VVT 1 duty", "%", 0, 100, 100, 100, 100, 100, 1 ,1
       vvt_duty2 = vvt_duty2, "VVT 2 duty", "%", 0, 100, 100, 100, 100, 100, 1 ,1
       vvt_duty3 = vvt_duty3, "VVT 3 duty", "%", 0, 100, 100, 100, 100, 100, 1 ,1
       vvt_duty4 = vvt_duty4, "VVT 4 duty", "%", 0, 100, 100, 100, 100, 100, 1 ,1
       launch_timer = launch_timer, "Launch timer", "s", 0, 15, 15, 15, 15, 15, 3 ,3
       launch_retard = launch_retard, "Launch timed retard", "deg", -5, 30, 30, 30, 30, 30, 1, 1

    gaugeCategory = "Calculations 1"
       advBucketGauge    = veTuneValue,   "Advance Bucket",     "degrees", 0,    55,    -1,     -1,  999,  999, 1, 1
       accelEnrichGauge  = accDecEnrich,  "Accel Enrich",       "%",      50,   150,     -1,    -1,  999,  999, 0, 0
       clockGauge        = seconds,       "Clock",              "Seconds", 0,  65535,     10,    10,  65535,  65535, 0, 0
       gammaEnrichGauge  = gammaEnrich,   "Gamma Enrichment",   "%",      50,   150,     -1,    -1,  151,  151, 1, 1
       gammaairGauge     = airCorrection, "Gair/aircor",        "%",      50,   150,     -1,    -1,  151,  151, 1, 1
       Gwarmgauge = warmupEnrich,    "Gwarm",        "%",      50,   150,     -1,    -1,  151,  151, 1, 1
       Gbarogauge = baroCorrection,  "Gbaro",        "%",      50,   150,     -1,    -1,  151,  151, 1, 1
       WFGauge1 = wallfuel1, "Fuel on the walls 1", "", 0, 40000000, 0, 0, 40000000, 40000000, 0, 0
       WFGauge2 = wallfuel2, "Fuel on the walls 2", "", 0, 40000000, 0, 0, 40000000, 40000000, 0, 0
       EAEGauge1 = EAEFuelCorr1, "EAE Fuel Correction 1", "%",       0,   200,     40,    70,  130,  160, 0, 0
       EAEGauge2 = EAEFuelCorr2, "EAE Fuel Correction 2", "%",       0,   200,     40,    70,  130,  160, 0, 0
       fuelcorr  = fuelCorrection,"E85 Fuel Correction", "%",    100,   200,     99,    99,  164,  170, 0, 0 

    gaugeCategory = "Calculations 2"
       knockGauge        = knockRetard    "Knock Retard",       "deg",     0,  25.0,     -1,    -1,  5.0, 10.0, 1, 1
       timingerrGauge = timing_err, "Timing pred err", "%", -127, 127, 255,255,255,255,0,0
       lostsyncGauge = synccnt, "Lost sync counter", "", 0, 255, 255, 255, 255, 255, 0, 0
       syncreasonGauge = syncreason, "Lost sync reason", "", 0, 255, 255, 255, 255, 255, 0, 0
;       user0Gauge = user0, "User defined", "", 0, 65535, 65535, 65535, 65535, 65535, 0, 0
       veBucketGauge     = veTuneValue,   "VE Value",           "%",       0,   120,     -1,    -1,  999,  999, 0, 0
       veGauge1          = veCurr1,       "VE Current1",         "%",       0,   120,     -1,    -1,  999,  999, 1, 1
       veGauge2          = veCurr2,       "VE2 Current",         "%",       0,   120,     -1,    -1,  999,  999, 1, 1
       warmupEnrichGauge = warmupEnrich,  "Warmup Enrichment",  "%",     100,   150,     -1,    -1,  101,  105, 0, 0
       vss1dot = vss1dot, "VSS1 Acceleration", "ms-2", -25, 25, 65535, 65535, 65535, 65535, 0, 0 ; adjust to 50 if running top fuel
       vss2dot = vss2dot, "VSS2 Acceleration", "ms-2", -25, 25, 65535, 65535, 65535, 65535, 0, 0 ; adjust to 50 if running top fuel
       rpmdot = rpmdot, "rpmdot", "rpm/sec", -15000, 15000, 65535, 65535, 65535, 65535, 0, 0
       tpsdot = tpsDOT, "tpsdot", "%/sec", -15000, 15000, 65535, 65535, 65535, 65535, 0, 0
       mapdot = mapDOT, "mapdot", "kPa/sec", -15000, 15000, 65535, 65535, 65535, 65535, 0, 0
   vvttargGauge1    = vvt_target1,       "VVT 1 target",   "degrees", 0,    50,    -1,     -1,  999,  999, 1, 1
   vvttargGauge2    = vvt_target2,       "VVT 2 target",   "degrees", 0,    50,    -1,     -1,  999,  999, 1, 1
   vvttargGauge3    = vvt_target3,       "VVT 3 target",   "degrees", 0,    50,    -1,     -1,  999,  999, 1, 1
   vvttargGauge4    = vvt_target4,       "VVT 4 target",   "degrees", 0,    50,    -1,     -1,  999,  999, 1, 1
       fuelflowGauge = fuelflow,       "Fuel flow",         "cc/min",       0,   65535,     -1,    -1,  99999,  99999, 0, 0
    economy_l_km    = economy_l_km, "Fuel economy", "l/km", 0, 3, -1, -1, 9, 9, 2, 2
    economy_mpg_us  = economy_mpg_us, "Fuel economy", "mpg_us", 0, 60, -1, -1, 99, 99, 0, 0
    economy_mpg_uk  = economy_mpg_uk, "Fuel economy", "mpg_uk", 0, 60, -1, -1, 99, 99, 0, 0
       tps_accel = tps_accel, "tps_accel", "%/sec", -15000, 15000, 65535, 65535, 65535, 65535, 0, 0
       map_accel = map_accel, "map_accel", "kPa/sec", -15000, 15000, 65535, 65535, 65535, 65535, 0, 0
       total_accel = total_accel, "total_accel", "%/sec", -15000, 15000, 65535, 65535, 65535, 65535, 0, 0


    gaugeCategory = "EGT inputs"
#if CELSIUS
       egtGauge1          = egt1,           "EGT 01",                   "C",    0,  1250, 0, 0,     1250,   1250, 0, 0
       egtGauge2          = egt2,           "EGT 02",                   "C",    0,  1250, 0, 0,     1250,   1250, 0, 0
       egtGauge3          = egt3,           "EGT 03",                   "C",    0,  1250, 0, 0,     1250,   1250, 0, 0
       egtGauge4          = egt4,           "EGT 04",                   "C",    0,  1250, 0, 0,     1250,   1250, 0, 0
       egtGauge5          = egt5,           "EGT 05",                   "C",    0,  1250, 0, 0,     1250,   1250, 0, 0
       egtGauge6          = egt6,           "EGT 06",                   "C",    0,  1250, 0, 0,     1250,   1250, 0, 0
       egtGauge7          = egt7,           "EGT 07",                   "C",    0,  1250, 0, 0,     1250,   1250, 0, 0
       egtGauge8          = egt8,           "EGT 08",                   "C",    0,  1250, 0, 0,     1250,   1250, 0, 0
       egtGauge9          = egt9,           "EGT 09",                   "C",    0,  1250, 0, 0,     1250,   1250, 0, 0
       egtGauge10         = egt10,          "EGT 10",                  "C",    0,  1250, 0, 0,     1250,   1250, 0, 0
       egtGauge11         = egt11,          "EGT 11",                  "C",    0,  1250, 0, 0,     1250,   1250, 0, 0
       egtGauge12         = egt12,          "EGT 12",                  "C",    0,  1250, 0, 0,     1250,   1250, 0, 0
       egtGauge13         = egt13,          "EGT 13",                  "C",    0,  1250, 0, 0,     1250,   1250, 0, 0
       egtGauge14         = egt14,          "EGT 14",                  "C",    0,  1250, 0, 0,     1250,   1250, 0, 0
       egtGauge15         = egt15,          "EGT 15",                  "C",    0,  1250, 0, 0,     1250,   1250, 0, 0
       egtGauge16         = egt16,          "EGT 16",                  "C",    0,  1250, 0, 0,     1250,   1250, 0, 0
#else
       egtGauge1          = egt1,           "EGT 01",                   "F",    0,  2280, 0, 0,     2280,   2280, 0, 0
       egtGauge2          = egt2,           "EGT 02",                   "F",    0,  2280, 0, 0,     2280,   2280, 0, 0
       egtGauge3          = egt3,           "EGT 03",                   "F",    0,  2280, 0, 0,     2280,   2280, 0, 0
       egtGauge4          = egt4,           "EGT 04",                   "F",    0,  2280, 0, 0,     2280,   2280, 0, 0
       egtGauge5          = egt5,           "EGT 05",                   "F",    0,  2280, 0, 0,     2280,   2280, 0, 0
       egtGauge6          = egt6,           "EGT 06",                   "F",    0,  2280, 0, 0,     2280,   2280, 0, 0
       egtGauge7          = egt7,           "EGT 07",                   "F",    0,  2280, 0, 0,     2280,   2280, 0, 0
       egtGauge8          = egt8,           "EGT 08",                   "F",    0,  2280, 0, 0,     2280,   2280, 0, 0
       egtGauge9          = egt9,           "EGT 09",                   "F",    0,  2280, 0, 0,     2280,   2280, 0, 0
       egtGauge10         = egt10,          "EGT 10",                  "F",    0,  2280, 0, 0,     2280,   2280, 0, 0
       egtGauge11         = egt11,          "EGT 11",                  "F",    0,  2280, 0, 0,     2280,   2280, 0, 0
       egtGauge12         = egt12,          "EGT 12",                  "F",    0,  2280, 0, 0,     2280,   2280, 0, 0
       egtGauge13         = egt13,          "EGT 13",                  "F",    0,  2280, 0, 0,     2280,   2280, 0, 0
       egtGauge14         = egt14,          "EGT 14",                  "F",    0,  2280, 0, 0,     2280,   2280, 0, 0
       egtGauge15         = egt15,          "EGT 15",                  "F",    0,  2280, 0, 0,     2280,   2280, 0, 0
       egtGauge16         = egt16,          "EGT 16",                  "F",    0,  2280, 0, 0,     2280,   2280, 0, 0
#endif

    gaugeCategory = "Sensor inputs1"

#if CELSIUS
            #if EXPANDED_CLT_TEMP
              cltGauge          = coolant,       "Coolant Temp",       "°C",    -40,   230,    -100,     -100,   170,  200, 0, 0
            #else
              cltGauge          = coolant,       "Coolant Temp",       "°C",    -40,   150,    -100,     -100,   95,  105, 0, 0
            #endif
       matGauge          = mat,           "Manifold Air Temp",  "°C",    -40,   110,    -15,     0,   95,  100, 0, 0
#else
            #if EXPANDED_CLT_TEMP
              cltGauge          = coolant,       "Coolant Temp",       "°F",    -40,   450,      -100,    -100,  350,  400, 0, 0
            #else
              cltGauge          = coolant,       "Coolant Temp",       "°F",    -40,   300,      -100,    -100,  200,  220, 0, 0
            #endif
       matGauge          = mat,           "Manifold Air Temp",  "°F",    -40,   215,      0,    30,  200,  210, 0, 0
#endif

       voltMeter         = batteryVoltage,"Battery Voltage",    "volts",   7,    21,      8,     9,   15,   16, 2, 2
       tachometer        = rpm,           "Engine Speed",       "RPM",     0,  {rpmhigh},    300,   600, {rpmwarn}, {rpmdang}, 0, 0
       throttleGauge     = throttle,      "Throttle Position",  "%",       0,   100,     -1,     1,   90,  100, 1, 0
       mapGauge          = map,           "Engine MAP",         "kPa",     0,   255,      0,    20,  200,  245, 1, 0
       barometerGauge    = barometer,     "Barometer",          "kPa",    60,   120,      0,    20,  200,  245, 1, 0
       fuelloadGauge      = fuelload,     "Fuel Load",          "%",     0,   255,      0,    20,  200,  245, 1, 0
       fuelload2Gauge    = fuelload2,     "Secondary Fuel Load", "%",    0,   255,      0,    20,  200,  245, 1, 0
       ignloadGauge      = ignload,       "Ign Load",           "%",     0,   255,      0,    20,  200,  245, 1, 0
       ignload2Gauge     = ignload2,      "Secondary Ign Load", "%",     0,   255,      0,    20,  200,  245, 1, 0
       eaeloadGauge      = eaeload1,       "EAE Load",           "%",     0,   255,      0,    20,  200,  245, 1, 0
       afrloadGauge      = afrload1,       "AFR Load",           "%",     0,   255,      0,    20,  200,  245, 1, 0
       mafGauge = maf,  "Mass Air Flow", "g/sec",   0,   650,      0,   200,  480,  550, 1, 0
       mafMapGauge = mafmap, "MAFMAP", "kPa",       0,   400,      -1,  -1,   999,  999, 1, 0
       boostbarGauge     = boostbar,      "Boost",         "bar",    -1,     3,      -1,    -1,    5,  5,  2, 2
       boostpsigGauge    = boostpsig,     "Boost",        "psig",    -14.7, 21,      -15,    -15,  30, 30, 1, 1
       boostvacGauge     = boostvac,      "Vac/Boost",       "inHg/psig", -30, 30, -30, -30, 30, 30, 1, 1
       knockinGauge      = knock,   "Knock Input",       "%",     0,  100.0,     -1,    -1,  100.0, 100.0, 1, 1

    gaugeCategory = "Sensor inputs2"
       stream_levelGauge = stream_level, "Stream Level", "", 0, 128, 128, 128, 128, 128, 0, 0
#if MPH
       vehiclespeed1     = vss1, "Vehicle Speed 1", "MPH", 0, 200, 1000, 1000, 1000, 1000, 0, 0
       vehiclespeed2     = vss2, "Vehicle Speed 2", "MPH", 0, 200, 1000, 1000, 1000, 1000, 0, 0
#else
   vehiclespeed1     = vss1, "Vehicle Speed 1", "KPH", 0, 300, 1600, 1600, 1600, 1600, 0, 0
   vehiclespeed2     = vss2, "Vehicle Speed 2", "KPH", 0, 300, 1600, 1600, 1600, 1600, 0, 0
#endif
   shaftspeed1     = ss1, "Shaft Speed 1", "RPM", 0, 10000, 10000, 10000, 10000, 10000, 0, 0
   shaftspeed2     = ss2, "Shaft Speed 2", "RPM", 0, 10000, 10000, 10000, 10000, 10000, 0, 0
   gear  = gear, "Gear", "", -1, 6, 6, 6, 6, 6, 0 ,0
   accelx = accelx, "Accel X", "ms-2", -59, 59, 59, 59, 59, 59, 2, 2 
   accely = accely, "Accel Y", "ms-2", -59, 59, 59, 59, 59, 59, 2, 2 
   accelz = accelz, "Accel Z", "ms-2", -59, 59, 59, 59, 59, 59, 2, 2 
   vvtGauge1    = vvt_ang1,       "VVT 1 angle",   "degrees", 0,    50,    -1,     -1,  999,  999, 1, 1
   vvtGauge2    = vvt_ang2,       "VVT 2 angle",   "degrees", 0,    50,    -1,     -1,  999,  999, 1, 1
   vvtGauge3    = vvt_ang3,       "VVT 3 angle",   "degrees", 0,    50,    -1,     -1,  999,  999, 1, 1
   vvtGauge4    = vvt_ang4,       "VVT 4 angle",   "degrees", 0,    50,    -1,     -1,  999,  999, 1, 1
   fuelcompsn= fuel_pct, "Ethanol Percentage","%",      0,   100,     -1,    -1,   85,  101, 0, 0
#if CELSIUS
    fueltempGauge = fuel_temp,       "Fuel Temp",       "°C",    -40,   110,    -100,     -100,   95,  105, 0, 0
#else
    fueltempGauge = fuel_temp,       "Fuel Temp",       "°F",    -40,   240,      -100,    -100,  200,  220, 0, 0
#endif

gaugeCategory = "Sensor inputs3"
   knock01Gauge  = knock_cyl01,   "Knock cyl# 1",      "",    0,    100, 0,  0,  100, 100, 1, 0
   knock02Gauge  = knock_cyl02,   "Knock cyl# 2",      "",    0,    100, 0,  0,  100, 100, 1, 0
   knock03Gauge  = knock_cyl03,   "Knock cyl# 3",      "",    0,    100, 0,  0,  100, 100, 1, 0
   knock04Gauge  = knock_cyl04,   "Knock cyl# 4",      "",    0,    100, 0,  0,  100, 100, 1, 0
   knock05Gauge  = knock_cyl05,   "Knock cyl# 5",      "",    0,    100, 0,  0,  100, 100, 1, 0
   knock06Gauge  = knock_cyl06,   "Knock cyl# 6",      "",    0,    100, 0,  0,  100, 100, 1, 0
   knock07Gauge  = knock_cyl07,   "Knock cyl# 7",      "",    0,    100, 0,  0,  100, 100, 1, 0
   knock08Gauge  = knock_cyl08,   "Knock cyl# 8",      "",    0,    100, 0,  0,  100, 100, 1, 0
#if CYL_12_16_SUPPORT
   knock09Gauge  = knock_cyl09,   "Knock cyl# 9",      "",    0,    100, 0,  0,  100, 100, 1, 0
   knock10Gauge  = knock_cyl10,   "Knock cyl#10",      "",    0,    100, 0,  0,  100, 100, 1, 0
   knock11Gauge  = knock_cyl11,   "Knock cyl#11",      "",    0,    100, 0,  0,  100, 100, 1, 0
   knock12Gauge  = knock_cyl12,   "Knock cyl#12",      "",    0,    100, 0,  0,  100, 100, 1, 0
   knock13Gauge  = knock_cyl13,   "Knock cyl#13",      "",    0,    100, 0,  0,  100, 100, 1, 0
   knock14Gauge  = knock_cyl14,   "Knock cyl#14",      "",    0,    100, 0,  0,  100, 100, 1, 0
   knock15Gauge  = knock_cyl15,   "Knock cyl#15",      "",    0,    100, 0,  0,  100, 100, 1, 0
   knock16Gauge  = knock_cyl16,   "Knock cyl#16",      "",    0,    100, 0,  0,  100, 100, 1, 0
#endif

gaugeCategory = "AFR/EGO inputs"

#if   NARROW_BAND_EGO
   egoV1Gauge        = egov1,    "Exhaust Gas Oxygen 1", "volts",   0,   1,    1,   1,  1,  1, 2, 2
   egoV2Gauge        = egov2,    "Exhaust Gas Oxygen 2", "volts",   0,   1,    1,   1,  1,  1, 2, 2
   egoV3Gauge        = egov3,    "Exhaust Gas Oxygen 3", "volts",   0,   1,    1,   1,  1,  1, 2, 2
   egoV4Gauge        = egov4,    "Exhaust Gas Oxygen 4", "volts",   0,   1,    1,   1,  1,  1, 2, 2
   egoV5Gauge        = egov5,    "Exhaust Gas Oxygen 5", "volts",   0,   1,    1,   1,  1,  1, 2, 2
   egoV6Gauge        = egov6,    "Exhaust Gas Oxygen 6", "volts",   0,   1,    1,   1,  1,  1, 2, 2
   egoV7Gauge        = egov7,    "Exhaust Gas Oxygen 7", "volts",   0,   1,    1,   1,  1,  1, 2, 2
   egoV8Gauge        = egov8,    "Exhaust Gas Oxygen 8", "volts",   0,   1,    1,   1,  1,  1, 2, 2
#elif LAMBDA

   lambda1Gauge      = lambda1,       "Lambda 1",             "",      0.5,   1.5,    0.5,   0.7,    2,  1.1, 2, 2
   lambda2Gauge      = lambda2,       "Lambda 2",             "",      0.5,   1.5,    0.5,   0.7,    2,  1.1, 2, 2
   lambda3Gauge      = lambda3,       "Lambda 3",             "",      0.5,   1.5,    0.5,   0.7,    2,  1.1, 2, 2
   lambda4Gauge      = lambda4,       "Lambda 4",             "",      0.5,   1.5,    0.5,   0.7,    2,  1.1, 2, 2
   lambda5Gauge      = lambda5,       "Lambda 5",             "",      0.5,   1.5,    0.5,   0.7,    2,  1.1, 2, 2
   lambda6Gauge      = lambda6,       "Lambda 6",             "",      0.5,   1.5,    0.5,   0.7,    2,  1.1, 2, 2
   lambda7Gauge      = lambda7,       "Lambda 7",             "",      0.5,   1.5,    0.5,   0.7,    2,  1.1, 2, 2
   lambda8Gauge      = lambda8,       "Lambda 8",             "",      0.5,   1.5,    0.5,   0.7,    2,  1.1, 2, 2

   egoV1Gauge        = egov1,    "Exhaust Gas Oxygen 1", "volts",   0,   5,    5,   5,  5,  5, 2, 2
   egoV2Gauge        = egov2,    "Exhaust Gas Oxygen 2", "volts",   0,   5,    5,   5,  5,  5, 2, 2
   egoV3Gauge        = egov3,    "Exhaust Gas Oxygen 3", "volts",   0,   5,    5,   5,  5,  5, 2, 2
   egoV4Gauge        = egov4,    "Exhaust Gas Oxygen 4", "volts",   0,   5,    5,   5,  5,  5, 2, 2
   egoV5Gauge        = egov5,    "Exhaust Gas Oxygen 5", "volts",   0,   5,    5,   5,  5,  5, 2, 2
   egoV6Gauge        = egov6,    "Exhaust Gas Oxygen 6", "volts",   0,   5,    5,   5,  5,  5, 2, 2
   egoV7Gauge        = egov7,    "Exhaust Gas Oxygen 7", "volts",   0,   5,    5,   5,  5,  5, 2, 2
   egoV8Gauge        = egov8,    "Exhaust Gas Oxygen 8", "volts",   0,   5,    5,   5,  5,  5, 2, 2
#else

   afr1Gauge         = afr1,          "Air:Fuel Ratio 1",     "",       10,  19.4,     12,    13,   15,   16, 2, 2
   afr2Gauge         = afr2,          "Air:Fuel Ratio 2",     "",       10,  19.4,     12,    13,   15,   16, 2, 2
   afr3Gauge         = afr3,          "Air:Fuel Ratio 3",     "",       10,  19.4,     12,    13,   15,   16, 2, 2
   afr4Gauge         = afr4,          "Air:Fuel Ratio 4",     "",       10,  19.4,     12,    13,   15,   16, 2, 2
   afr5Gauge         = afr5,          "Air:Fuel Ratio 5",     "",       10,  19.4,     12,    13,   15,   16, 2, 2
   afr6Gauge         = afr6,          "Air:Fuel Ratio 6",     "",       10,  19.4,     12,    13,   15,   16, 2, 2
   afr7Gauge         = afr7,          "Air:Fuel Ratio 7",     "",       10,  19.4,     12,    13,   15,   16, 2, 2
   afr8Gauge         = afr8,          "Air:Fuel Ratio 8",     "",       10,  19.4,     12,    13,   15,   16, 2, 2

   egoV1Gauge        = egov1,    "Exhaust Gas Oxygen 1", "volts",   0,   5,    5,   5,  5,  5, 2, 2
   egoV2Gauge        = egov2,    "Exhaust Gas Oxygen 2", "volts",   0,   5,    5,   5,  5,  5, 2, 2
   egoV3Gauge        = egov3,    "Exhaust Gas Oxygen 3", "volts",   0,   5,    5,   5,  5,  5, 2, 2
   egoV4Gauge        = egov4,    "Exhaust Gas Oxygen 4", "volts",   0,   5,    5,   5,  5,  5, 2, 2
   egoV5Gauge        = egov5,    "Exhaust Gas Oxygen 5", "volts",   0,   5,    5,   5,  5,  5, 2, 2
   egoV6Gauge        = egov6,    "Exhaust Gas Oxygen 6", "volts",   0,   5,    5,   5,  5,  5, 2, 2
   egoV7Gauge        = egov7,    "Exhaust Gas Oxygen 7", "volts",   0,   5,    5,   5,  5,  5, 2, 2
   egoV8Gauge        = egov8,    "Exhaust Gas Oxygen 8", "volts",   0,   5,    5,   5,  5,  5, 2, 2
#endif

gaugeCategory = "AFR/EGO calculations"
#if   NARROW_BAND_EGO
   afr1targetGauge   = afrtgt1,       "EgoV 1 Target",     "",       0,  1,     20,    20,   20,   20, 3, 3
   afr2targetGauge   = afrtgt2,       "EgoV 2 Target",     "",       0,  1,     20,    20,   20,   20, 3, 3
   afr1errGauge      = afr1err,       "EgoV 1 Error",     "",       -1,  +1,     12,    13,   15,   16, 3, 3
   afr2errGauge      = afr2err,       "EgoV 2 Error",     "",       -1,  +1,     12,    13,   15,   16, 3, 3
#elif LAMBDA
   afr1targetGauge   = afrtgt1,       "Lambda 1 Target",     "",       0.5,  1.5,     20,    20,   20,   20, 2, 2
   afr2targetGauge   = afrtgt2,       "Lambda 2 Target",     "",       0.5,  1.5,     20,    20,   20,   20, 2, 2
   afr1errGauge      = afr1err,       "Lambda 1 Error",     "",       -2,  +2,     12,    13,   15,   16, 2, 2
   afr2errGauge      = afr2err,       "Lambda 2 Error",     "",       -2,  +2,     12,    13,   15,   16, 2, 2
#else
   afr1targetGauge   = afrtgt1,       "AFR 1 Target",     "",       10,  19.4,     20,    20,   20,   20, 2, 2
   afr2targetGauge   = afrtgt2,       "AFR 2 Target",     "",       10,  19.4,     20,    20,   20,   20, 2, 2
   afr1errGauge      = afr1err,       "AFR 1 Error",     "",       -5,  +5,     12,    13,   15,   16, 2, 2
   afr2errGauge      = afr2err,       "AFR 2 Error",     "",       -5,  +5,     12,    13,   15,   16, 2, 2

#endif
   egoCorrGauge1     = egocor1, "EGO Correction 1",   "%",      50,   150,     90,    99,  101,  110, 1, 1
   egoCorrGauge2     = egocor2, "EGO Correction 2",   "%",      50,   150,     90,    99,  101,  110, 1, 1
   egoCorrGauge3     = egocor3, "EGO Correction 3",   "%",      50,   150,     90,    99,  101,  110, 1, 1
   egoCorrGauge4     = egocor4, "EGO Correction 4",   "%",      50,   150,     90,    99,  101,  110, 1, 1
   egoCorrGauge5     = egocor5, "EGO Correction 5",   "%",      50,   150,     90,    99,  101,  110, 1, 1
   egoCorrGauge6     = egocor6, "EGO Correction 6",   "%",      50,   150,     90,    99,  101,  110, 1, 1
   egoCorrGauge7     = egocor7, "EGO Correction 7",   "%",      50,   150,     90,    99,  101,  110, 1, 1
   egoCorrGauge8     = egocor8, "EGO Correction 8",   "%",      50,   150,     90,    99,  101,  110, 1, 1

#if CYL_12_16_SUPPORT
gaugeCategory = "AFR/EGO inputs 9-16"
#if   NARROW_BAND_EGO
;
#elif LAMBDA
   lambda9Gauge       = lambda9,        "Lambda 9",              "",      0.5,   1.5,    0.5,   0.7,    2,  1.1, 2, 2
   lambda10Gauge      = lambda10,       "Lambda 10",             "",      0.5,   1.5,    0.5,   0.7,    2,  1.1, 2, 2
   lambda11Gauge      = lambda11,       "Lambda 11",             "",      0.5,   1.5,    0.5,   0.7,    2,  1.1, 2, 2
   lambda12Gauge      = lambda12,       "Lambda 12",             "",      0.5,   1.5,    0.5,   0.7,    2,  1.1, 2, 2
   lambda13Gauge      = lambda13,       "Lambda 13",             "",      0.5,   1.5,    0.5,   0.7,    2,  1.1, 2, 2
   lambda14Gauge      = lambda14,       "Lambda 14",             "",      0.5,   1.5,    0.5,   0.7,    2,  1.1, 2, 2
   lambda15Gauge      = lambda15,       "Lambda 15",             "",      0.5,   1.5,    0.5,   0.7,    2,  1.1, 2, 2
   lambda16Gauge      = lambda16,       "Lambda 16",             "",      0.5,   1.5,    0.5,   0.7,    2,  1.1, 2, 2
#else
   afr9Gauge          = afr9,           "Air:Fuel Ratio 9",      "",       10,  19.4,     12,    13,   15,   16, 2, 2
   afr10Gauge         = afr10,          "Air:Fuel Ratio 10",     "",       10,  19.4,     12,    13,   15,   16, 2, 2
   afr11Gauge         = afr11,          "Air:Fuel Ratio 11",     "",       10,  19.4,     12,    13,   15,   16, 2, 2
   afr12Gauge         = afr12,          "Air:Fuel Ratio 12",     "",       10,  19.4,     12,    13,   15,   16, 2, 2
   afr13Gauge         = afr13,          "Air:Fuel Ratio 13",     "",       10,  19.4,     12,    13,   15,   16, 2, 2
   afr14Gauge         = afr14,          "Air:Fuel Ratio 14",     "",       10,  19.4,     12,    13,   15,   16, 2, 2
   afr15Gauge         = afr15,          "Air:Fuel Ratio 15",     "",       10,  19.4,     12,    13,   15,   16, 2, 2
   afr16Gauge         = afr16,          "Air:Fuel Ratio 16",     "",       10,  19.4,     12,    13,   15,   16, 2, 2
#endif
   egoV9Gauge         = egov9,     "Exhaust Gas Oxygen 9",  "volts",   0,   5,    5,   5,  5,  5, 2, 2
   egoV10Gauge        = egov10,    "Exhaust Gas Oxygen 10", "volts",   0,   5,    5,   5,  5,  5, 2, 2
   egoV11Gauge        = egov11,    "Exhaust Gas Oxygen 11", "volts",   0,   5,    5,   5,  5,  5, 2, 2
   egoV12Gauge        = egov12,    "Exhaust Gas Oxygen 12", "volts",   0,   5,    5,   5,  5,  5, 2, 2
   egoV13Gauge        = egov13,    "Exhaust Gas Oxygen 13", "volts",   0,   5,    5,   5,  5,  5, 2, 2
   egoV14Gauge        = egov14,    "Exhaust Gas Oxygen 14", "volts",   0,   5,    5,   5,  5,  5, 2, 2
   egoV15Gauge        = egov15,    "Exhaust Gas Oxygen 15", "volts",   0,   5,    5,   5,  5,  5, 2, 2
   egoV16Gauge        = egov16,    "Exhaust Gas Oxygen 16", "volts",   0,   5,    5,   5,  5,  5, 2, 2

gaugeCategory = "AFR/EGO calculations 9-16"
   egoCorrGauge9      = egocor9,  "EGO Correction 9",    "%",      50,   150,     90,    99,  101,  110, 1, 1
   egoCorrGauge10     = egocor10, "EGO Correction 10",   "%",      50,   150,     90,    99,  101,  110, 1, 1
   egoCorrGauge11     = egocor11, "EGO Correction 11",   "%",      50,   150,     90,    99,  101,  110, 1, 1
   egoCorrGauge12     = egocor12, "EGO Correction 12",   "%",      50,   150,     90,    99,  101,  110, 1, 1
   egoCorrGauge13     = egocor13, "EGO Correction 13",   "%",      50,   150,     90,    99,  101,  110, 1, 1
   egoCorrGauge14     = egocor14, "EGO Correction 14",   "%",      50,   150,     90,    99,  101,  110, 1, 1

   egoCorrGauge15     = egocor15, "EGO Correction 15",   "%",      50,   150,     90,    99,  101,  110, 1, 1
   egoCorrGauge16     = egocor16, "EGO Correction 16",   "%",      50,   150,     90,    99,  101,  110, 1, 1
#endif

gaugeCategory = "Generic sensor inputs"
   sensor01Gauge  = sensor01,   "Sensor 01",      "",    -3000,    3000, -3277,  -3277,  3277, 3277, 1, 1
   sensor02Gauge  = sensor02,   "Sensor 02",      "",    -3000,    3000, -3277,  -3277,  3277, 3277, 1, 1
   sensor03Gauge  = sensor03,   "Sensor 03",      "",    -3000,    3000, -3277,  -3277,  3277, 3277, 1, 1
   sensor04Gauge  = sensor04,   "Sensor 04",      "",    -3000,    3000, -3277,  -3277,  3277, 3277, 1, 1
   sensor05Gauge  = sensor05,   "Sensor 05",      "",    -3000,    3000, -3277,  -3277,  3277, 3277, 1, 1
   sensor06Gauge  = sensor06,   "Sensor 06",      "",    -3000,    3000, -3277,  -3277,  3277, 3277, 1, 1
   sensor07Gauge  = sensor07,   "Sensor 07",      "",    -3000,    3000, -3277,  -3277,  3277, 3277, 1, 1
   sensor08Gauge  = sensor08,   "Sensor 08",      "",    -3000,    3000, -3277,  -3277,  3277, 3277, 1, 1
   sensor09Gauge  = sensor09,   "Sensor 09",      "",    -3000,    3000, -3277,  -3277,  3277, 3277, 1, 1
   sensor10Gauge  = sensor10,   "Sensor 10",      "",    -3000,    3000, -3277,  -3277,  3277, 3277, 1, 1
   sensor11Gauge  = sensor11,   "Sensor 11",      "",    -3000,    3000, -3277,  -3277,  3277, 3277, 1, 1
   sensor12Gauge  = sensor12,   "Sensor 12",      "",    -3000,    3000, -3277,  -3277,  3277, 3277, 1, 1
   sensor13Gauge  = sensor13,   "Sensor 13",      "",    -3000,    3000, -3277,  -3277,  3277, 3277, 1, 1
   sensor14Gauge  = sensor14,   "Sensor 14",      "",    -3000,    3000, -3277,  -3277,  3277, 3277, 1, 1
   sensor15Gauge  = sensor15,   "Sensor 15",      "",    -3000,    3000, -3277,  -3277,  3277, 3277, 1, 1
   sensor16Gauge  = sensor16,   "Sensor 16",      "",    -3000,    3000, -3277,  -3277,  3277, 3277, 1, 1

gaugeCategory = "CAN board inputs/outputs"
   canin1_8Gauge   = canin1_8,    "CAN inputs 1-8",   "",    0,  255,    255, 255,  255,   255,0, 0
   canout1_8Gauge  = canout1_8,   "CAN outputs 1-8",  "",    0,  255,    255, 255,  255,   255,0, 0
   canout9_16Gauge = canout9_16,  "CAN outputs 9-16", "",    0,  255,    255, 255,  255,   255,0, 0
   canpwmin0Gauge  = canpwmin0,   "CAN PWMin 0",      "",    0,  65535,    65535, 65535,  65535,   65535,0, 0
   canpwmin1Gauge  = canpwmin1,   "CAN PWMin 1",      "",    0,  65535,    65535, 65535,  65535,   65535,0, 0
   canpwmin2Gauge  = canpwmin2,   "CAN PWMin 2",      "",    0,  65535,    65535, 65535,  65535,   65535,0, 0
   canpwmin3Gauge  = canpwmin3,   "CAN PWMin 3",      "",    0,  65535,    65535, 65535,  65535,   65535,0, 0


gaugeCategory = "X-Code dev"
    status1Gauge  = status1,   "Status 1",      "",    0,  255,    255, 255,  255,   255, 0, 0
    status2Gauge  = status2,   "Status 2",      "",    0,  255,    255, 255,  255,   255, 0, 0
    status3Gauge  = status3,   "Status 3",      "",    0,  255,    255, 255,  255,   255, 0, 0
    status4Gauge  = status4,   "Status 4",      "",    0,  255,    255, 255,  255,   255, 0, 0
    status5Gauge  = status5,   "Status 5",      "",    0,  65535,    65535, 65535,  65535,   65535,0, 0
    injcountGauge  = status5,   "Injection Count",      "pulses",    0,  1000,    65535, 65535,  65535,   65535,0, 0
    looptimeGauge = looptime,   "Mainloop time",      "us",    0,  10000,    -1, -1,  1000,   6000, 0, 0
    sd_filenum = sd_filenum, "SDcard file number", "", 0, 9999, 9999, 9999, 9999, 9999, 0 ,0
    sd_error = sd_error, "SDcard error", "", 0, 255, 255, 255, 255, 255, 0 ,0
    sd_status = sd_status, "SDcard status", "", 0, 255, 255, 255, 255, 255, 0 ,0
    sd_phase = sd_phase, "SDcard phase", "", 0, 255, 255, 255, 255, 255, 0 ,0
    deadGauge         = deadValue,     "---",                "",        0,     1,     -1,    -1,    2,    2, 0, 0
;------------------------------------------------------------------------------

[FrontPage]
#if   NARROW_BAND_EGO
   egoLEDs         =  0.0, 1.0,  0.5 ; Voltage settings.
#elif LAMBDA
   egoLEDs         =  1.5, 0.5,  1.0 ; Lambda settings.
#else
   egoLEDs         = 19.7, 9.7, 14.7 ; Afr settings.
#endif

   ; Gauges are numbered left to right, top to bottom.
   ;
   ;    1  2  3  4
   ;    5  6  7  8

   gauge1 = tachometer
;   gauge2 = EAEGauge1
   gauge2 = throttleGauge
   gauge3 = pulseWidth1Gauge
   gauge4 = cltGauge
   gauge5 = advdegGauge
   gauge6 = fuelloadGauge
#if   NARROW_BAND_EGO
   gauge7 = egoV1Gauge
#elif LAMBDA
   gauge7 = lambda1Gauge
#else
   gauge7 = afr1Gauge
#endif
;   gauge7 = dwellGauge
   gauge8 = matGauge


   ;----------------------------------------------------------------------------
   ; Indicators
   ;               expr         off-label          on-label, off-bg, off-fg, on-bg, on-fg


   indicator = { ready              }, "Not Ready",    "Ready",         white, black, green, black
   indicator = { crank              }, "Not Cranking", "Cranking",      white, black, green, black
   indicator = { startw             }, "ASE OFF",      "ASE",           white, black, green, black
   indicator = { warmup             }, "WUE OFF",      "WUE",           white, black, green, black
   indicator = { tpsaccaen          }, "TPS Accel",    "TPS Accel",     white, black, green, black
   indicator = { mapaccaen          }, "MAP Accel",    "MAP Accel",     white, black, green, black
   indicator = { tpsaccden          }, "TPS Decel", "TPS Decel",        white, black, green, black
   indicator = { mapaccden          }, "MAP Decel", "MAP Decel",        white, black, green, black
;   indicator = { tps > floodClear && crank }, "", "FLOOD CLEAR", white, black, red,   black
;   indicator = { port0              }, "Port 0 Off",   "Port 0 On",   white, black, red,   black

   indicator = { status1 & 0b00000001}, "Need Burn",   "Need Burn",     white, black, red, black
   indicator = { status1 & 0b00000010}, "Data Lost",   "Lost Data",     white, black, red, black
   indicator = { status1 & 0b00000100}, "Config Error", "Config Error", white, black, red,   black
   indicator = { status1 & 0b00001000}, "Not synced", "Synced",         red,   black, green, black
   indicator = { status1 & 0b00100000}, "VE1/2", "VE3/4",               white, black, green, black
   indicator = { status1 & 0b01000000}, "SPK1/2", "SPK3/4",             white, black, green, black
   indicator = { status1 & 0b10000000}, "Half-sync", "Full-sync",       white, black, green, black

   indicator = { status2 & 0b00000001}, "N2O 1 off", "N2O 1 on",        white, black, green, black
   indicator = { status2 & 0b00000010}, "N2O 2 off", "N2O 2 on",        white, black, green, black
   indicator = { status2 & 0b00000100}, "No rev lim", "Rev Lim",        white, black, red, black
   indicator = { status2 & 0b00000100}, "No Launch", "Launch in",       white, black, green, black
   indicator = { status2 & 0b00010000}, "No Flat shift", "Flat shift",  white, black, green, black
   indicator = { status2 & 0b00100000}, "Spark cut", "Spark cut",       white, black, red, black
   indicator = { status2 & 0b01000000}, "Over boost", "Over boost",     white, black, red, black
   indicator = { status2 & 0b10000000}, "CL Idle off", "CL idle on",    white, black, green, black

   indicator = { status3 & 0b00000001}, "No Fuel cut", "Fuel cut",      white, black, red, black
   indicator = { status3 & 0b00000010}, "T-log", "T-log",               white, black, green, black
   indicator = { status3 & 0b00000100}, "3 step off", "3 step on",      white, black, green, black
   indicator = { status3 & 0b00001000}, "Test mode", "Test mode",       white, black, yellow, black
   indicator = { status3 & 0b00010000}, "No 3 step", "3 step in",       white, black, green, black
   indicator = { status3 & 0b00100000}, "No soft limit", "Soft limiter",white, black, red, black
   indicator = { status3 & 0b01000000}, "No bike shift", "Bike Shift",  white, black, red, black
   indicator = { status3 & 0b10000000}, "Launch Off", "Launch on",      white, black, red, black

   indicator = { status6 & 0b00000001}, "EGT warn", "EGT warn",         white, black, red, black
   indicator = { status6 & 0b00000010}, "EGT shutdown", "EGT shutdown", white, black, red, black
   indicator = { status6 & 0b00000100}, "AFR warn", "AFR warn",         white, black, red, black
   indicator = { status6 & 0b00001000}, "AFR shutdown", "AFR shutdown", white, black, red, black
   indicator = { status6 & 0b00010000}, "Idle VE", "Idle VE",           white, black, green, black
   indicator = { status6 & 0b00100000}, "Idle VE", "Idle Adv",          white, black, green, black
   indicator = { status6 & 0b01000000}, "Fan", "Fan",                   white, black, green, black
   indicator = { status6 & 0b10000000}, "MAPsample error!", "MAPsample error!", white, black, red, black

   indicator = { status7 & 0b00000001}, "VVT1 err", "VVT1 err",         white, black, red, black
   indicator = { status7 & 0b00000010}, "VVT2 err", "VVT2 err",         white, black, red, black
   indicator = { status7 & 0b00000100}, "VVT3 err", "VVT3 err",         white, black, red, black
   indicator = { status7 & 0b00001000}, "VVT4 err", "VVT4 err",         white, black, red, black
   indicator = { status7 & 0x10 },      "No Knock", "Knock",            white, black, red, black
   indicator = { status7 & 0x20 },      "AC", "AC",                     white, black, green, black

   indicator = { sd_status & 0b00010000}, "SD Err", "SD Err",           white, black, red, black
   indicator = { sd_status & 0b00001000}, "SD Log", "SD Log",           white, black, green, black
   indicator = { sd_status & 0b00000100}, "SD ready", "SD ready",       white, black, green, black
   indicator = { sd_status & 0b00000001}, "No SD", "SD in",             white, black, green, black

;-------------------------------------------------------------------------------

[RunTime]
   barHysteresis = 2.5 ; Seconds
   coolantBar    = {cltlowlim},  {clthighlim}
   matBar        = -40,  {mathigh}
   batteryBar    =   6,   15
   dutyCycleBar  =   0,  100
#if   NARROW_BAND_EGO
   egoBar        = 0.0 ,  1.0
#elif LAMBDA
   egoBar        = 0.5,   1.5
#else
   egoBar        = 9.7,  19.7
#endif
   gammaEBar     =   0,  200
   mapBar        =   0,  255
   pulseWidthBar =   0,   25.5
   rpmBar        =   0, {rpmhigh}
   throttleBar   =   0,  100

   egoCorrBar    =   0,  200
   baroCorrBar   =   0,  200
   warmupCorrBar =   0,  200
   airdenCorrBar =   0,  200
   veCorrBar     =   0,  200
   accCorrBar    =   0,  100

;-------------------------------------------------------------------------------

[Tuning]
#if   NARROW_BAND_EGO
   egoLEDs         =  0.0, 1.0,  0.5 ; Voltage settings.
#elif LAMBDA
   egoLEDs         =  1.5, 0.5,  1.0 ; Lambda settings.
#else
   egoLEDs         = 19.7, 9.7, 14.7 ; Afr settings.
#endif

;  font            = "Lucida Console", 12
;  font            = "Courier", 14
   spotDepth       =   2 ; 0 = no indicators, 1 = Z only, 2 = XYZ indicators.
   cursorDepth     =   2 ; Same as spot depth.

   ; The four radio buttons on the tuning screen select a "page" of six
   ; gauges.  The gauge numbering is the same as the front page, across
   ; then down.
   ;             1  2
   ;             3  4
   ;             5  6
   ;
   ; gaugeColumns allows you to hide or show gauges in column 2 (i.e.,
   ; gauges 2, 4 and 6).

   gaugeColumns = 2 ; Only 1 or 2 are valid.

   ;              Page 1            Page 2             Page 3            Page 4
   pageButtons  = "&EGO",           "&WUE",            "PW&1",           "PW&2"
   gauge1       = tachometer,       tachometer,        tachometer,       tachometer
   gauge2       = mapGauge,         mapGauge,          mapGauge,         mapGauge
#if   NARROW_BAND_EGO
   gauge3       = egoV1Gauge,         egoV1Gauge,          egoV1Gauge,         egoV1Gauge
#elif LAMBDA
   gauge3       = lambda1Gauge,     lambda1Gauge,      lambda1Gauge,     lambda1Gauge
#else
   gauge3       = afr1Gauge,        afr1Gauge,         afr1Gauge,        afr1Gauge
#endif

   gauge4       = egoCorrGauge1,     warmupEnrichGauge, pulseWidth1Gauge, pulseWidth2Gauge
   gauge5       = veBucketGauge,    veBucketGauge,     veBucketGauge,    veBucketGauge
   gauge6       = egoCorrGauge2, accelEnrichGauge,  dutyCycle1Gauge,  dutyCycle2Gauge

;-------------------------------------------------------------------------------

[AccelerationWizard]
   tpsDotBar = 0, 800
   mapDotBar = 0, 700

;-------------------------------------------------------------------------------

[BurstMode]
;   getCommand       = "a\x00\x06"
   getCommand       = "A"

[OutputChannels]
   deadValue        = { 0 } ; Convenient unchanging value.

#if CAN_COMMANDS
;full version that works anywhere - be sure to change the no. bytes requested
   ochGetCommand    = "r\x00\x07\x00\x00\x01\x98"
#else
; fast get via serial
   ochGetCommand       = "A"
#endif
   ochBlockSize     = 408 ;oi! change ochGetCommand as well ; SIZEOFTXBUF

   seconds          = scalar, U16,    0, "s",   1.000, 0.0
   secl = { seconds % 256 }, "s" ; For runtime screen.
#if PW_4X
   pulseWidth1      = scalar, U16,    2, "ms",   0.004, 0.0
   pulseWidth2      = scalar, U16,    4, "ms",   0.004, 0.0
#else
   pulseWidth1      = scalar, U16,    2, "ms",   0.001, 0.0
   pulseWidth2      = scalar, U16,    4, "ms",   0.001, 0.0
#endif
   pulseWidth       = { pulseWidth1 }, "ms" ; For runtime screen.

   rpm              = scalar, U16,    6, "RPM", 1.000, 0.0
   advance          = scalar, S16,    8, "deg", 0.100, 0.0

   ; unsigned char squirt,engine,afrtgt1,afrtgt2;    // afrtgt in afr x 10
   squirt           = scalar, U08,   10, "bit", 1.000, 0.0
   ; Squirt Event Scheduling Variables - bit fields for "squirt" variable above
   ; inj1:    equ    3       ; 0 = no squirt         1 = squirt
   ; inj2:    equ    5       ; 0 = no squirt         1 = squirt
   ; sched1:  equ    2       ; 0 = nothing scheduled 1 = scheduled to squirt
   ; firing1: equ    0       ; 0 = not squirting     1 = squirting
   ; sched2:  equ    4
   ; firing2: equ    1
   firing1          = bits,   U08,   10, [0:0]
   firing2          = bits,   U08,   10, [1:1]
   sched1           = bits,   U08,   10, [2:2]
   inj1             = bits,   U08,   10, [3:3]
   sched2           = bits,   U08,   10, [4:4]
   inj2             = bits,   U08,   10, [5:5]

   engine           = scalar, U08,   11, "bit", 1.000, 0.0
   ; Engine Operating/Status variables - bit fields for "engine" variable above
   ; ready:  equ     0       ; 0 = engine not ready 1 = ready to run
   ; crank:  equ     1       ; 0 = engine not cranking 1 = engine cranking
   ; startw: equ     2       ; 0 = not in startup warmup 1 = in warmup enrichment
   ; warmup: equ     3       ; 0 = not in warmup 1 = in warmup
   ; tpsaen: equ     4       ; 0 = not in TPS acceleration mode 1 = TPS acceleration mode
   ; tpsden: equ     5       ; 0 = not in deacceleration mode 1 = in deacceleration mode
   ready            = bits,   U08,   11, [0:0]
   crank            = bits,   U08,   11, [1:1]
   startw           = bits,   U08,   11, [2:2]
   warmup           = bits,   U08,   11, [3:3]
   tpsaccaen        = bits,   U08,   11, [4:4]
   tpsaccden        = bits,   U08,   11, [5:5]
   mapaccaen	  = bits,   U08,   11, [6:6]
   mapaccden        = bits,   U08,   11, [7:7]

#if NARROW_BAND_EGO
   afrtgt1          = scalar, U08,   12, "Volts", 0.00489, 0.0
   afrtgt2          = scalar, U08,   13, "Volts", 0.00489, 0.0
#elif LAMBDA
   afrtgt1raw       = scalar, U08,   12, "Lambda", 0.1, 0.0
   afrtgt2raw       = scalar, U08,   13, "Lambda", 0.1, 0.0
#else
   afrtgt1          = scalar, U08,   12, "AFR", 0.1, 0.0
   afrtgt2          = scalar, U08,   13, "AFR", 0.1, 0.0
#endif
   ; unsigned char wbo2_en1,wbo2_en2; // from wbo2 - indicates whether wb afr valid
   wbo2_en1         = scalar, U08,   14, "",    1.000, 0.0
   wbo2_en2         = scalar, U08,   15, "",    1.000, 0.0

   ; int baro,map,mat,clt,tps,batt,ego1,ego2,knock, // baro   - kpa x 10
   ;                                                // map    - kpa x 10
   ;                                                // mat, clt deg(C/F)x 10
   ;                                                // tps    - % x 10
   ;                                                // batt   - vlts x 10
   ;                                                // ego1,2 - afr x 10
   ;                                                // knock  - volts x 10
   barometer        = scalar, S16,   16, "kPa", 0.100, 0.0
   map              = scalar, S16,   18, "kPa", 0.100, 0.0
#if CELSIUS
   mat              = scalar, S16,   20, "°C",  0.05555, -320.0
   coolant          = scalar, S16,   22, "°C",  0.05555, -320.0
#else
   mat              = scalar, S16,   20, "°F",  0.100, 0.0
   coolant          = scalar, S16,   22, "°F",  0.100, 0.0
#endif
   tps              = scalar, S16,   24, "%",   0.100, 0.0
;   tpsADC           = { tps*10.23 }, "ADC" ; Fake for calibrator and file indexing.
   throttle         = { tps }, "%"
   batteryVoltage   = scalar, S16,   26, "v",   0.100, 0.0


   afr1_old         = scalar, S16,   28, "AFR", 0.100, 0.0
   afr2_old         = scalar, S16,   30, "AFR", 0.100, 0.0
   knock            = scalar, S16,   32, "%",   0.100, 0.0

   ; egocor1,egocor2,aircor,warmcor,     // all in %
   egoCorrection1   = scalar, S16,   34, "%",   0.1000, 0.0
   egoCorrection = { ( egoCorrection1 + egoCorrection2) / 2 }, "%" ; Alias for old gauges.
   egoCorrection2   = scalar, S16,   36, "%",   0.1000, 0.0
   airCorrection    = scalar, S16,   38, "%",   0.1000, 0.0
   warmupEnrich     = scalar, S16,   40, "%",   1.000, 0.0

   ; tpsaccel,tpsfuelcut,barocor,gammae, // tpsaccel - acc enrich(.1 ms units)
   ;                                     // tpsfuelcut - %
   ;                                     // barcor,gammae - %
   accelEnrich      = scalar, S16,   42, "ms", 0.100, 0.0
   tpsfuelcut       = scalar, S16,   44, "%",   1.000, 0.0
   baroCorrection   = scalar, S16,   46, "%",   0.1000, 0.0
   gammaEnrich      = scalar, S16,   48, "%",   1.000, 0.0

   ;  vecurr1,vecurr2,iacstep,cold_adv_deg;           // vecurr - %
   ;                                                  // iacstep - steps
   ;                                                  // cold_adv_deg - deg x 10
   veCurr1          = scalar, S16,   50, "%",   0.1000, 0.0
   veCurr2          = scalar, S16,   52, "%",   0.1000, 0.0
   veCurr           = { veCurr1 }, "%" ; For runtime display.
   iacstep          = scalar, S16,   54, "",    1.000, 0.0
   idleDC           = scalar, S16,   54, "%",    0.39063, 0.0
   coldAdvDeg       = scalar, S16,   56, "deg", 0.100, 0.0
   tpsDOT           = scalar, S16,   58, "%/s",   0.100, 0.0
   mapDOT           = scalar, S16,   60, "kPa/s", 1.000, 0.0

   dwell            = scalar, U16,   62, "ms",    0.1000, 0.0
   mafmap           = scalar, S16,   64, "kPa",     0.1000, 0.0
   fuelload         = scalar, S16,   66, "%",   0.100, 0.0 ; Blend of MAP and TPS, depends on algorithm
   fuelCorrection   = scalar, S16,   68, "%",     1.000, 0.0 ; Percent alcohol in fuel.

   portStatus       = scalar, U08,   70, "bit",   1.000, 0.0 ; Spare port status bits
   port0            = bits,   U08,   70, [0:0]
   port1            = bits,   U08,   70, [1:1]
   port2            = bits,   U08,   70, [2:2]
   port3            = bits,   U08,   70, [3:3]
   port4            = bits,   U08,   70, [4:4]
   port5            = bits,   U08,   70, [5:5]
   port6            = bits,   U08,   70, [6:6]

   knockRetard      = scalar, U08,   71, "deg",     0.1, 0.0
   EAEFuelCorr1	    = scalar, U16,   72, "%",  1.0, 0.0
   egoV             = scalar, S16,   74, "V", 0.01, 0.0 ; was omitted
   egoV2            = scalar, S16,   76, "V", 0.01, 0.0 ; was omitted
   status1          = scalar, U08,   78, "", 1.0, 0.0 ; status1
   status2          = scalar, U08,   79, "", 1.0, 0.0 ; status2
   status3          = scalar, U08,   80, "", 1.0, 0.0 ; status3
   status4          = scalar, U08,   81, "", 1.0, 0.0 ; status4
   looptime         = scalar, U16,   82, "us", 1.0, 0.0
   status5          = scalar, U16,   84, "us", 1, 0 ; istatus5
   tpsADC           = scalar, U16,   86, "ADC", 1, 0 ; REAL for calibrator and file indexing.
   fuelload2	    = scalar, U16,   88, "%",    0.100, 0.0
   ignload	    = scalar, S16,   90, "%",    0.100, 0.0
   ignload2	    = scalar, S16,   92, "%",    0.100, 0.0

   synccnt         = scalar,  U08,     94, "", 1, 0
   timing_err       = scalar, S08,   95, "%", 1, 0 ; accuracy of timing prediction
   wallfuel1	    = scalar, U32,   96, "uS",    0.010, 0.0
   wallfuel2	    = scalar, U32,  100, "uS", 1.000, 0.0
   sensor01	        = scalar, S16,  104, "",   0.1000, 0.0
   sensor02         = scalar, S16,  106, "",   0.1000, 0.0
   sensor03	        = scalar, S16,  108, "",   0.1000, 0.0
   sensor04	        = scalar, S16,  110, "",   0.1000, 0.0
   sensor05	        = scalar, S16,  112, "",   0.1000, 0.0
   sensor06	        = scalar, S16,  114, "",   0.1000, 0.0
   sensor07	        = scalar, S16,  116, "",   0.1000, 0.0
   sensor08	        = scalar, S16,  118, "",   0.1000, 0.0
   sensor09	        = scalar, S16,  120, "",   0.1000, 0.0
   sensor10         = scalar, S16,  122, "",   0.1000, 0.0
   sensor11         = scalar, S16,  124, "",   0.1000, 0.0
   sensor12         = scalar, S16,  126, "",   0.1000, 0.0
   sensor13         = scalar, S16,  128, "",   0.1000, 0.0
   sensor14         = scalar, S16,  130, "",   0.1000, 0.0
   sensor15         = scalar, S16,  132, "",   0.1000, 0.0
   sensor16         = scalar, S16,  134, "",   0.1000, 0.0

   canin1_8	    = scalar, U08,  136, "",   1.000, 0.0
   canout1_8    = scalar, U08,  137, "",   1.000, 0.0
   canout9_16   = scalar, U08,  138, "",   1.000, 0.0
   boostduty	    = scalar, U08,  139 , "%",  1.0, 0.0
#if PW_4X
   n2o_addfuel     = scalar, S16,  140, "ms",  0.004, 0
#else
   n2o_addfuel     = scalar, S16,  140, "ms",  0.001, 0
#endif
   n2o_retard      = scalar, S16,  142, "deg",  0.1, 0

#if PW_4X
   pwseq1           = scalar, U16,  144,  "ms", 0.004, 0,0
   pwseq2           = scalar, U16,  146,  "ms", 0.004, 0,0
   pwseq3           = scalar, U16,  148,  "ms", 0.004, 0,0
   pwseq4           = scalar, U16,  150,  "ms", 0.004, 0,0
   pwseq5           = scalar, U16,  152,  "ms", 0.004, 0,0
   pwseq6           = scalar, U16,  154,  "ms", 0.004, 0,0
   pwseq7           = scalar, U16,  156,  "ms", 0.004, 0,0
   pwseq8           = scalar, U16,  158,  "ms", 0.004, 0,0
   pwseq9           = scalar, U16,  160,  "ms", 0.004, 0,0
   pwseq10          = scalar, U16,  162,  "ms", 0.004, 0,0
   pwseq11          = scalar, U16,  164,  "ms", 0.004, 0,0
   pwseq12          = scalar, U16,  166,  "ms", 0.004, 0,0
   pwseq13          = scalar, U16,  168,  "ms", 0.004, 0,0
   pwseq14          = scalar, U16,  170,  "ms", 0.004, 0,0
   pwseq15          = scalar, U16,  172,  "ms", 0.004, 0,0
   pwseq16          = scalar, U16,  174,  "ms", 0.004, 0,0
#else
   pwseq1           = scalar, U16,  144,  "ms", 0.001, 0,0
   pwseq2           = scalar, U16,  146,  "ms", 0.001, 0,0
   pwseq3           = scalar, U16,  148,  "ms", 0.001, 0,0
   pwseq4           = scalar, U16,  150,  "ms", 0.001, 0,0
   pwseq5           = scalar, U16,  152,  "ms", 0.001, 0,0
   pwseq6           = scalar, U16,  154,  "ms", 0.001, 0,0
   pwseq7           = scalar, U16,  156,  "ms", 0.001, 0,0
   pwseq8           = scalar, U16,  158,  "ms", 0.001, 0,0
   pwseq9           = scalar, U16,  160,  "ms", 0.001, 0,0
   pwseq10          = scalar, U16,  162,  "ms", 0.001, 0,0
   pwseq11          = scalar, U16,  164,  "ms", 0.001, 0,0
   pwseq12          = scalar, U16,  166,  "ms", 0.001, 0,0
   pwseq13          = scalar, U16,  168,  "ms", 0.001, 0,0
   pwseq14          = scalar, U16,  170,  "ms", 0.001, 0,0
   pwseq15          = scalar, U16,  172,  "ms", 0.001, 0,0
   pwseq16          = scalar, U16,  174,  "ms", 0.001, 0,0
#endif
   nitrous1_duty   = scalar, U08,  176, "%", 1, 0
   nitrous2_duty   = scalar, U08,  177, "%", 1, 0

#if CELSIUS
   egt1            = scalar, S16,  178, "°C",  0.05555, -320
   egt2            = scalar, S16,  180, "°C",  0.05555, -320
   egt3            = scalar, S16,  182, "°C",  0.05555, -320
   egt4            = scalar, S16,  184, "°C",  0.05555, -320
   egt5            = scalar, S16,  186, "°C",  0.05555, -320
   egt6            = scalar, S16,  188, "°C",  0.05555, -320
   egt7            = scalar, S16,  190, "°C",  0.05555, -320
   egt8            = scalar, S16,  192, "°C",  0.05555, -320
   egt9            = scalar, S16,  194, "°C",  0.05555, -320
   egt10           = scalar, S16,  196, "°C",  0.05555, -320
   egt11           = scalar, S16,  198, "°C",  0.05555, -320
   egt12           = scalar, S16,  200, "°C",  0.05555, -320
   egt13           = scalar, S16,  202, "°C",  0.05555, -320
   egt14           = scalar, S16,  204, "°C",  0.05555, -320
   egt15           = scalar, S16,  206, "°C",  0.05555, -320
   egt16           = scalar, S16,  208, "°C",  0.05555, -320
#else
   egt1            = scalar, S16,  178, "°F", 0.1, 0
   egt2            = scalar, S16,  180, "°F", 0.1, 0
   egt3            = scalar, S16,  182, "°F", 0.1, 0
   egt4            = scalar, S16,  184, "°F", 0.1, 0
   egt5            = scalar, S16,  186, "°F", 0.1, 0
   egt6            = scalar, S16,  188, "°F", 0.1, 0
   egt7            = scalar, S16,  190, "°F", 0.1, 0
   egt8            = scalar, S16,  192, "°F", 0.1, 0
   egt9            = scalar, S16,  194, "°F", 0.1, 0
   egt10           = scalar, S16,  196, "°F", 0.1, 0
   egt11           = scalar, S16,  198, "°F", 0.1, 0

   egt12           = scalar, S16,  200, "°F", 0.1, 0
   egt13           = scalar, S16,  202, "°F", 0.1, 0
   egt14           = scalar, S16,  204, "°F", 0.1, 0

   egt15           = scalar, S16,  206, "°F", 0.1, 0
   egt16           = scalar, S16,  208, "°F", 0.1, 0
#endif
   maf             = scalar, U16,  210, "g/sec", 0.010, 0.0
   canpwmin0	    = scalar, U16,  212, "",   1.000, 0.0
   canpwmin1	    = scalar, U16,  214, "",   1.000, 0.0
   canpwmin2	    = scalar, U16,  216, "",   1.000, 0.0
   canpwmin3	    = scalar, U16,  218, "",   1.000, 0.0
   fuelflow 	    = scalar, U16,  220, "cc/min",   1, 0.0
   fuelcons 	    = scalar, U16,  222, "l/km",   1, 0.0
   EAEFuelCorr2	    = scalar, U16,  224 , "%",  1.0, 0.0
   syncreason       = scalar, U08,  226,  "", 1.0, 0.0
   sd_status        = scalar, U08,  227,  "", 1.0, 0.0
    eaeload1         = scalar, S16,  228, "%",  0.1000, 0.0
    afrload1         = scalar, S16,  230, "%",  0.1000, 0.0
    gear            = scalar, U08,  232, "", 1, 0
    status6         = scalar, U08,  233, "", 1.0, 0.0
    rpmdot          = scalar, S16,  234, "rpm/sec", 10, 0
    vss1dot         = scalar, S16,  236, "ms-2", 0.1, 0
    vss2dot         = scalar, S16,  238, "ms-2", 0.1, 0
    accelx          = scalar, S16,  240, "ms-2", 0.001, 0
    accely          = scalar, S16,  242, "ms-2", 0.001, 0
    accelz          = scalar, S16,  244, "ms-2", 0.001, 0
    duty_pwm_a      = scalar, U08,  246, "%", 1, 0
    duty_pwm_b      = scalar, U08,  247, "%", 1, 0
    duty_pwm_c      = scalar, U08,  248, "%", 1, 0
    duty_pwm_d      = scalar, U08,  249, "%", 1, 0
    duty_pwm_e      = scalar, U08,  250, "%", 1, 0
    duty_pwm_f      = scalar, U08,  251, "%", 1, 0
    afr1            = scalar, U08,  252, "AFR", 0.1, 0.0
    afr2            = scalar, U08,  253, "AFR", 0.1, 0.0
    afr3            = scalar, U08,  254, "AFR", 0.1, 0.0
    afr4            = scalar, U08,  255, "AFR", 0.1, 0.0
    afr5            = scalar, U08,  256, "AFR", 0.1, 0.0
    afr6            = scalar, U08,  257, "AFR", 0.1, 0.0
    afr7            = scalar, U08,  258, "AFR", 0.1, 0.0
    afr8            = scalar, U08,  259, "AFR", 0.1, 0.0
    afr9            = scalar, U08,  260, "AFR", 0.1, 0.0
    afr10           = scalar, U08,  261, "AFR", 0.1, 0.0
    afr11           = scalar, U08,  262, "AFR", 0.1, 0.0
    afr12           = scalar, U08,  263, "AFR", 0.1, 0.0
    afr13           = scalar, U08,  264, "AFR", 0.1, 0.0
    afr14           = scalar, U08,  265, "AFR", 0.1, 0.0
    afr15           = scalar, U08,  266, "AFR", 0.1, 0.0
    afr16           = scalar, U08,  267, "AFR", 0.1, 0.0


    egov1           = scalar, U16,  268, "V",  0.00489, 0.0
    egov2           = scalar, U16,  270, "V",  0.00489, 0.0
    egov3           = scalar, U16,  272, "V",  0.00489, 0.0
    egov4           = scalar, U16,  274, "V",  0.00489, 0.0
    egov5           = scalar, U16,  276, "V",  0.00489, 0.0
    egov6           = scalar, U16,  278, "V",  0.00489, 0.0
    egov7           = scalar, U16,  280, "V",  0.00489, 0.0
    egov8           = scalar, U16,  282, "V",  0.00489, 0.0
    egov9           = scalar, U16,  284, "V",  0.00489, 0.0
    egov10          = scalar, U16,  286, "V",  0.00489, 0.0
    egov11          = scalar, U16,  288, "V",  0.00489, 0.0
    egov12          = scalar, U16,  290, "V",  0.00489, 0.0
    egov13          = scalar, U16,  292, "V",  0.00489, 0.0
    egov14          = scalar, U16,  294, "V",  0.00489, 0.0
    egov15          = scalar, U16,  296, "V",  0.00489, 0.0
    egov16          = scalar, U16,  298, "V",  0.00489, 0.0
    egocor1         = scalar, S16,  300, "%",  0.1000, 0.0
    egocor2         = scalar, S16,  302, "%",  0.1000, 0.0
    egocor3         = scalar, S16,  304, "%",  0.1000, 0.0
    egocor4         = scalar, S16,  306, "%",  0.1000, 0.0
    egocor5         = scalar, S16,  308, "%",  0.1000, 0.0

    egocor6         = scalar, S16,  310, "%",  0.1000, 0.0
    egocor7         = scalar, S16,  312, "%",  0.1000, 0.0
    egocor8         = scalar, S16,  314, "%",  0.1000, 0.0
    egocor9         = scalar, S16,  316, "%",  0.1000, 0.0
    egocor10        = scalar, S16,  318, "%",  0.1000, 0.0
    egocor11        = scalar, S16,  320, "%",  0.1000, 0.0
    egocor12        = scalar, S16,  322, "%",  0.1000, 0.0
    egocor13        = scalar, S16,  324, "%",  0.1000, 0.0
    egocor14        = scalar, S16,  326, "%",  0.1000, 0.0
    egocor15        = scalar, S16,  328, "%",  0.1000, 0.0
    egocor16        = scalar, S16,  330, "%",  0.1000, 0.0
   stream_level     = scalar, U08,  332,  "us", 1,0
   water_duty       = scalar, U08,  333, "%", 1, 0
   dwell_trl        = scalar, U16,  334,  "ms", 0.1000, 0.0
   vss1_real        = scalar, U16,  336, "ms-1", 1, 0.0
   vss2_real        = scalar, U16,  338, "ms-1", 1, 0.0
   ss1             = scalar, U16,  340, "RPM", 1.000, 0.0
   ss2             = scalar, U16,  342, "RPM", 1.000, 0.0
   nitrous_timer   = scalar, U16,  344, "s", 0.001, 0


   sd_filenum      = scalar, U16,  346, "", 1, 0
   sd_error        = scalar, U08,  348, "", 1, 0
   sd_phase        = scalar, U08,  349, "", 1, 0
   boostduty2	   = scalar, U08,  350 , "%",  1.0, 0.0
   status7         = scalar, U08,  351,  "", 1.0, 0.0
   vvt_ang1        = scalar, S16,  352, "deg", 0.100, 0.0
   vvt_ang2        = scalar, S16,  354, "deg", 0.100, 0.0
   vvt_ang3        = scalar, S16,  356, "deg", 0.100, 0.0
   vvt_ang4        = scalar, S16,  358, "deg", 0.100, 0.0
   inj_timing_pri  = scalar, S16,  360, "deg", 0.100, 0.0
   inj_timing_sec  = scalar, S16,  362, "deg", 0.100, 0.0
   vvt_target1     = scalar, S16,  364, "deg", 0.100, 0.0
   vvt_target2     = scalar, S16,  366, "deg", 0.100, 0.0
   vvt_target3     = scalar, S16,  368, "deg", 0.100, 0.0
   vvt_target4     = scalar, S16,  370, "deg", 0.100, 0.0
   vvt_duty1       = scalar, U08,  372 , "%",    0.39063, 0.0
   vvt_duty2       = scalar, U08,  373 , "%",    0.39063, 0.0
   vvt_duty3       = scalar, U08,  374 , "%",    0.39063, 0.0
   vvt_duty4       = scalar, U08,  375 , "%",    0.39063, 0.0
   fuel_pct        = scalar, S16,  376,  "%",  0.1000, 0.0
#if CELSIUS
   fuel_temp       = scalar, S16,  378, "°C",  0.05555, -320
#else
   fuel_temp       = scalar, S16,  378, "°F", 0.1, 0
#endif
   cl_idle_targ_rpm = scalar, U16, 380, "rpm", 1, 0
   tps_accel       = scalar, S16,  382,  "%",  0.1000, 0.0
   map_accel       = scalar, S16,  384,  "%",  0.1000, 0.0
   total_accel     = scalar, S16,  386,  "%",  0.1000, 0.0
    knock_cyl01         = scalar, U08, 388, "%", 0.4, 0
    knock_cyl02         = scalar, U08, 389, "%", 0.4, 0
    knock_cyl03         = scalar, U08, 390, "%", 0.4, 0
    knock_cyl04         = scalar, U08, 391, "%", 0.4, 0
    knock_cyl05         = scalar, U08, 392, "%", 0.4, 0
    knock_cyl06         = scalar, U08, 393, "%", 0.4, 0
    knock_cyl07         = scalar, U08, 394, "%", 0.4, 0
    knock_cyl08         = scalar, U08, 395, "%", 0.4, 0
    knock_cyl09         = scalar, U08, 396, "%", 0.4, 0
    knock_cyl10         = scalar, U08, 397, "%", 0.4, 0
    knock_cyl11         = scalar, U08, 398, "%", 0.4, 0
    knock_cyl12         = scalar, U08, 399, "%", 0.4, 0
    knock_cyl13         = scalar, U08, 400, "%", 0.4, 0
    knock_cyl14         = scalar, U08, 401, "%", 0.4, 0
    knock_cyl15         = scalar, U08, 402, "%", 0.4, 0
    knock_cyl16         = scalar, U08, 403, "%", 0.4, 0
   launch_timer   = scalar, U16,  404, "s", 0.001, 0
   launch_retard  = scalar, S16,  406, "deg",  0.1, 0

   accDecEnrich     = { accelEnrich + (tpsaccden ? tpsfuelcut : 100)      }, "%"
   time             = { timeNow                                        }, "s"
   rpm100           = { rpm / 100.0                                    }

   altDiv1          = { alternate ? 2 : 1                              }
   altDiv2          = { alternate ? 2 : 1                              }

   cycleTime1       = { rpm ? (60000.0 / rpm * (2.0-(twoStroke&1))) : 0 }, "ms"
;   nSquirts1        = { nCylinders/(divider * altDiv1)}
;   dcfactor1        = { nSquirts1/altDiv1 }
;   dutyCycle1       = { cycleTime1 ? (100.0*dcfactor1*pulseWidth1/cycleTime1) : 0}, "%"
   nSquirts1        = { nCylinders/divider}
   dutyCycle1       = { cycleTime1 ? (100.0*nSquirts1/altDiv2*pulseWidth1/cycleTime1) : 0}, "%"

   cycleTime2       = { rpm ? (60000.0 / rpm * (2.0-(twoStroke&1))) : 0 }, "ms"
   nSquirts2        = { nCylinders/divider                             }
   dutyCycle2       = { cycleTime2 ? (100.0*nSquirts2/altDiv2*pulseWidth2/cycleTime2) : 0 }, "%"

#if   NARROW_BAND_EGO
   egoVoltage = { egoV }, "V"      ; For LED bars...
   afr1err = { egov1 - afrtgt1 }
   afr2err = { egov2 - afrtgt2 }
#elif LAMBDA
   lambda1          = { afr1 / stoich }, "Lambda"
   lambda2          = { afr2 / stoich }, "Lambda2"
   lambda3          = { afr3 / stoich }, "Lambda3"
   lambda4          = { afr4 / stoich }, "Lambda4"
   lambda5          = { afr5 / stoich }, "Lambda5"

   lambda6          = { afr6 / stoich }, "Lambda6"
   lambda7          = { afr7 / stoich }, "Lambda7"
   lambda8          = { afr8 / stoich }, "Lambda8"
   egoVoltage = { lambda1          }, "Lambda" ; For LED bars...
   afrtgt1 = { afrtgt1raw / stoich * (egoType == 2) } ; return zero if NB because of mixed units with target in volts
   afrtgt2 = { afrtgt2raw / stoich * (egoType == 2) }
   afr1err = { (afr1 - afrtgt1raw) / stoich * (egoType == 2)}
   afr2err = { (afr2 - afrtgt2raw) / stoich * (egoType == 2)}
#else
   egoVoltage = { afr1             }, "AFR"    ; For LED bars...
   afr1err = { afr1 - afrtgt1 }
   afr2err = { afr2 - afrtgt2 }
#endif

;    pwm_opt_load_a    = bits, U08, 838, [5:7], "INVALID", "MAP", "% baro", "TPS", "MAFMAP", "INVALID", "INVALID", "INVALID" ; ITB hidden
; Seems this doesn't work
    pwma_load = { (map * (pwm_opt_load_a == 1)) + (map*100/(barometer+(100*(barometer==0))) * (pwm_opt_load_a == 2)) + (tps * (pwm_opt_load_a == 3)) + (mafmap * (pwm_opt_load_a == 4)) + (coolant * (pwm_opt_load_a == 5)) + (mat * (pwm_opt_load_a == 7))}
    pwmb_load = { (map * (pwm_opt_load_b == 1)) + (map*100/(barometer+(100*(barometer==0))) * (pwm_opt_load_b == 2)) + (tps * (pwm_opt_load_b == 3)) + (mafmap * (pwm_opt_load_b == 4)) + (coolant * (pwm_opt_load_b == 5)) + (mat * (pwm_opt_load_b == 7))}
    pwmc_load = { (map * (pwm_opt_load_c == 1)) + (map*100/(barometer+(100*(barometer==0))) * (pwm_opt_load_c == 2)) + (tps * (pwm_opt_load_c == 3)) + (mafmap * (pwm_opt_load_c == 4)) + (coolant * (pwm_opt_load_c == 5)) + (mat * (pwm_opt_load_c == 7))}
    pwmd_load = { (map * (pwm_opt_load_d == 1)) + (map*100/(barometer+(100*(barometer==0))) * (pwm_opt_load_d == 2)) + (tps * (pwm_opt_load_d == 3)) + (mafmap * (pwm_opt_load_d == 4)) + (coolant * (pwm_opt_load_d == 5)) + (mat * (pwm_opt_load_d == 7))}
    pwme_load = { (map * (pwm_opt_load_e == 1)) + (map*100/(barometer+(100*(barometer==0))) * (pwm_opt_load_e == 2)) + (tps * (pwm_opt_load_e == 3)) + (mafmap * (pwm_opt_load_e == 4)) + (coolant * (pwm_opt_load_e == 5)) + (mat * (pwm_opt_load_e == 7))}
    pwmf_load = { (map * (pwm_opt_load_f == 1)) + (map*100/(barometer+(100*(barometer==0))) * (pwm_opt_load_f == 2)) + (tps * (pwm_opt_load_f == 3)) + (mafmap * (pwm_opt_load_f == 4)) + (coolant * (pwm_opt_load_f == 5)) + (mat * (pwm_opt_load_f == 7))}

    df_temp = { 0 }
    df_press = { 0 }

  ; Vacuum and Boost Gauges
    boostbar = { (map - barometer) / 101.33}
    boostpsig = { (map - barometer) * 0.1450}
   vacuum = { (barometer-map)*0.2953007 } ; Calculate vacuum in in-Hg.
   boostvac = { map < barometer ? -vacuum : boostpsig }

#if MPH
    vss1 = { vss1_real * 0.22369 }
    vss2 = { vss2_real * 0.22369 }
#else
    vss1 = { vss1_real * 0.36 }
    vss2 = { vss2_real * 0.36 }
#endif

; calculate instantaneous economy from fuel flow (not calculated in firmware at this time)
    economy_l_km = { vss1_real ? (fuelflow / (vss1_real * 6)) : 0 }
    economy_mpg_us  = { vss1_real ? (2.361 / economy_l_km) : 0 }
    economy_mpg_uk  = { vss1_real ? (2.825 / economy_l_km) : 0 }

    pwmidle_cl_initialvalue_matorclt_follower = { pwmidle_cl_opts_initval_clt ? coolant : mat }

#if EXPANDED_CLT_TEMP
    clt_exp = { 1 }
#else
    clt_exp = { 0 }
#endif



#if CELSIUS
    cltlowlim   = { clt_exp ? -40 : -40 }
    clthighlim  = { clt_exp ? 230 : 120 }
    cltlowdang  = { clt_exp ? 65 : 10 }
    cltlowwarn  = { clt_exp ? 93 : 65 }
    clthighwarn = { clt_exp ? 162 : 93 }
    clthighdang = { clt_exp ? 176 : 104 }
    mathigh = { 110 }
#else ; fahrenheit
    cltlowlim   = { clt_exp ? -40 : -40 }
    clthighlim  = { clt_exp ? 450 : 250 }
    cltlowdang  = { clt_exp ? 150 : 50 }
    cltlowwarn  = { clt_exp ? 200 : 150 }
    clthighwarn = { clt_exp ? 325 : 200 }
    clthighdang = { clt_exp ? 350 : 220 }
    mathigh = { 215 }
#endif


;-------------------------------------------------------------------------------
;--  The entries are saved in the datalog file in the order in which they     --
;--  appear in the list below.                                                --
;--                                                                           --
;--   Channel - Case sensitive name of output channel to be logged.           --
;--   Label   - String written to header line of log.                       --
;--   Type    - Data type of output, converted before writing.                --
;--   Format  - C-style output format of data.                                --

[Datalog]
   ;       Channel          Label          Type    Format
   ;       --------------   ----------     -----   ------
   entry = time,            "Time",        float,  "%.3f"
   entry = seconds,         "SecL",        int,    "%d"
   entry = rpm,             "RPM",         int,    "%d"
   entry = map,             "MAP",         float,  "%.1f"
   entry = boostpsig,       "Boost psi",   float,  "%.1f"
   entry = throttle,        "TP",          float,  "%.1f"
   entry = maf,             "MAF",         float,  "%.01f", { MAFOption || MAFOption_t }
   entry = mafmap,          "MAFMAP",      float,  "%.1f", { MAFOption || MAFOption_t }
#if   NARROW_BAND_EGO
   entry = egov1     ,      "O2",          float,  "%.3f", {egonum > 0}
   entry = egov2     ,      "O2 #2",          float,  "%.3f", {egonum > 1}
   entry = egov3     ,      "O2 #3",          float,  "%.3f", {egonum > 2}
   entry = egov4     ,      "O2 #4",          float,  "%.3f", {egonum > 3}
   entry = egov5     ,      "O2 #5",          float,  "%.3f", {egonum > 4}
   entry = egov6     ,      "O2 #6",          float,  "%.3f", {egonum > 5}
   entry = egov7     ,      "O2 #7",          float,  "%.3f", {egonum > 6}
   entry = egov8     ,      "O2 #8",          float,  "%.3f", {egonum > 7}
#elif LAMBDA
   entry = lambda1,         "Lambda",      float,  "%.3f", {egonum > 0}
   entry = lambda2,         "Lambda2",      float,  "%.3f", {egonum > 1}
   entry = lambda3,         "Lambda3",      float,  "%.3f", {egonum > 2}
   entry = lambda4,         "Lambda4",      float,  "%.3f", {egonum > 3}
   entry = lambda5,         "Lambda5",      float,  "%.3f", {egonum > 4}
   entry = lambda6,         "Lambda6",      float,  "%.3f", {egonum > 5}
   entry = lambda7,         "Lambda7",      float,  "%.3f", {egonum > 6}
   entry = lambda8,         "Lambda8",      float,  "%.3f", {egonum > 7}
#else
   entry = afr1,            "AFR",         float,  "%.2f", {egonum > 0}
   entry = afr2,            "AFR2",         float,  "%.2f", {egonum > 1}
   entry = afr3,            "AFR3",         float,  "%.2f", {egonum > 2}
   entry = afr4,            "AFR4",         float,  "%.2f", {egonum > 3}
   entry = afr5,            "AFR5",         float,  "%.2f", {egonum > 4}
   entry = afr6,            "AFR6",         float,  "%.2f", {egonum > 5}
   entry = afr7,            "AFR7",         float,  "%.2f", {egonum > 6}
   entry = afr8,            "AFR8",         float,  "%.2f", {egonum > 7}
#endif
   entry = mat,             "MAT",         float,  "%.1f"
   entry = coolant,         "CLT",         float,  "%.1f"
   entry = engine,          "Engine",      int,    "%d"
   entry = batteryVoltage,  "Batt V",      float,  "%.1f"

   entry = egocor1,         "egocor_Gego1",        int,    "%.1f"
   entry = egocor2,         "egocor_Gego2",        int,    "%.1f", {egonum > 1}
   entry = egocor3,         "egocor_Gego3",        int,    "%.1f", {egonum > 2}
   entry = egocor4,         "egocor_Gego4",        int,    "%.1f", {egonum > 3}
   entry = egocor5,         "egocor_Gego5",        int,    "%.1f", {egonum > 4}
   entry = egocor6,         "egocor_Gego6",        int,    "%.1f", {egonum > 5}
   entry = egocor7,         "egocor_Gego7",        int,    "%.1f", {egonum > 6}
   entry = egocor8,         "egocor_Gego8",        int,    "%.1f", {egonum > 7}

   entry = airCorrection,   "Gair",        int,    "%.1f"
   entry = warmupEnrich,    "Gwarm",       int,    "%d"
   entry = baroCorrection,  "Gbaro",       int,    "%.1f"
   entry = gammaEnrich,     "Gammae",      int,    "%d"
   entry = accDecEnrich,    "TPSacc",      int,    "%d"

   entry = veCurr1,         "Gve",         int,    "%.1f"
   entry = pulseWidth1,     "PW",          float,  "%.3f"
   entry = dutyCycle1,      "DutyCycle1",  float,  "%.1f"

   entry = veCurr2,         "Gve2",        int,    "%.1f"
   entry = pulseWidth2,     "PW2",         float,  "%.3f"
   entry = dutyCycle2,      "DutyCycle2",  float,  "%.1f"

   entry = pwseq1,          "Seq PW1",      float,  "%.3f", { sequential }
   entry = pwseq2,          "Seq PW2",      float,  "%.3f", { sequential }
   entry = pwseq3,          "Seq PW3",      float,  "%.3f", { sequential }
   entry = pwseq4,          "Seq PW4",      float,  "%.3f", { sequential }
   entry = pwseq5,          "Seq PW5",      float,  "%.3f", { sequential }
   entry = pwseq6,          "Seq PW6",      float,  "%.3f", { sequential }
   entry = pwseq7,          "Seq PW7",      float,  "%.3f", { sequential }
   entry = pwseq8,          "Seq PW8",      float,  "%.3f", { sequential }
#if CYL_12_16_SUPPORT
   entry = pwseq9,          "Seq PW9",      float,  "%.3f", { sequential }
   entry = pwseq10,         "Seq PW10",     float,  "%.3f", { sequential }
   entry = pwseq11,         "Seq PW11",     float,  "%.3f", { sequential }
   entry = pwseq12,         "Seq PW12",     float,  "%.3f", { sequential }
   entry = pwseq13,         "Seq PW13",     float,  "%.3f", { sequential }
   entry = pwseq14,         "Seq PW14",     float,  "%.3f", { sequential }
   entry = pwseq15,         "Seq PW15",     float,  "%.3f", { sequential }
   entry = pwseq16,         "Seq PW16",     float,  "%.3f", { sequential }
#endif
   entry = advance,         "SparkAdv",    float,  "%.1f"
   entry = knockRetard,     "knockRet",    float,  "%.1f"
   entry = knock,           "knockin",    float,  "%.1f"
   entry = coldAdvDeg,      "ColdAdv",     float,  "%.1f"
   entry = dwell,           "Dwell",       float,  "%.2f"

   entry = barometer,       "Barometer",         float,  "%.1f"

   entry = iacstep,         "IACstep",     int,    "%d"
   entry = idleDC, "PWM Idle Duty", float, "%.1f"
   entry = boostduty,  "Boost Duty", int, "%d", { boost_ctl_settings_on }

#if NARROW_BAND_EGO
   entry = afrtgt1,    "EgoV 1 Target", float, "%.1f"
   entry = afrtgt2,    "EgoV 2 Target", float, "%.1f"
   entry = afr1err,    "EgoV 1 Error", float, "%.1f"
   entry = afr2err,    "EgoV 2 Error", float, "%.1f"
#elif LAMBDA
   entry = afrtgt1,    "Lambda 1 Target", float, "%.1f"
   entry = afrtgt2,    "Lambda 2 Target", float, "%.1f"
   entry = afr1err,    "Lambda 1 Error", float, "%.1f"
   entry = afr2err,    "Lambda 2 Error", float, "%.1f"
#else
   entry = afrtgt1,    "AFR 1 Target", float, "%.1f"
   entry = afrtgt2,    "AFR 2 Target", float, "%.1f"
   entry = afr1err,    "AFR 1 Error", float, "%.1f"
   entry = afr2err,    "AFR 2 Error", float, "%.1f"
#endif

   entry = tpsDOT,          "tpsDOT",      float,  "%.1f"
   entry = mapDOT,          "mapDOT",      float,  "%.1f"
   entry = rpmdot,        "rpmdot", int, "%d"

;  entry = deltaT,          "deltaT",      float,  "%.0f" - never used
   entry = wallfuel1,        "WallFuel1",    int,    "%d"
   entry = wallfuel2,        "WallFuel2",   int,     "%d"


   entry = EAEFuelCorr1,     "EAE1 %",       int,    "%d"
   entry = EAEFuelCorr2,     "EAE2 %",      int, "%d"
   entry = fuelload,         "Load",        float,  "%.1f"
   entry = fuelload2,        "Secondary Load", float, "%.1f"
   entry = ignload,          "Ign load",   float,    "%.1f"
   entry = ignload2,         "Secondary Ign Load", float, "%.1f"
   entry = eaeload1,          "EAE load", float, "%.1f"
   entry = afrload1,          "AFR load", float, "%.1f"

   entry = inj_timing_pri,    "Injector timing (pri)", float, "%.1f"
   entry = inj_timing_sec,    "Injector timing (sec)", float, "%.1f"

   entry = egt1,         "EGT 1 temp", int, "%d", {egt_num > 0}
   entry = egt2,         "EGT 2 temp", int, "%d", {egt_num > 1}
   entry = egt3,         "EGT 3 temp", int, "%d", {egt_num > 2}
   entry = egt4,         "EGT 4 temp", int, "%d", {egt_num > 3}
   entry = egt5,         "EGT 5 temp", int, "%d", {egt_num > 4}
   entry = egt6,         "EGT 6 temp", int, "%d", {egt_num > 5}
   entry = egt7,         "EGT 7 temp", int, "%d", {egt_num > 6}
   entry = egt8,         "EGT 8 temp", int, "%d", {egt_num > 7}
   entry = egt9,         "EGT 9 temp", int, "%d", {egt_num > 8}
   entry = egt10,        "EGT 10 temp", int, "%d", {egt_num > 9}
   entry = egt11,        "EGT 11 temp", int, "%d", {egt_num > 10}
   entry = egt12,        "EGT 12 temp", int, "%d", {egt_num > 11}
   entry = egt13,        "EGT 13 temp", int, "%d", {egt_num > 12}
   entry = egt14,        "EGT 14 temp", int, "%d", {egt_num > 13}
   entry = egt15,        "EGT 15 temp", int, "%d", {egt_num > 14}
   entry = egt16,        "EGT 16 temp", int, "%d", {egt_num > 15}

   entry = sensor01, "sensor01", float, "%.1f", { sensor01_source }
   entry = sensor02, "sensor02", float, "%.1f", { sensor02_source }
   entry = sensor03, "sensor03", float, "%.1f", { sensor03_source }
   entry = sensor04, "sensor04", float, "%.1f", { sensor04_source }
   entry = sensor05, "sensor05", float, "%.1f", { sensor05_source }
   entry = sensor06, "sensor06", float, "%.1f", { sensor06_source }
   entry = sensor07, "sensor07", float, "%.1f", { sensor07_source }
   entry = sensor08, "sensor08", float, "%.1f", { sensor08_source }
   entry = sensor09, "sensor09", float, "%.1f";, { sensor09_source }
   entry = sensor10, "sensor10", float, "%.1f";, { sensor10_source }
   entry = sensor11, "sensor11", float, "%.1f";, { sensor11_source }
   entry = sensor12, "sensor12", float, "%.1f";, { sensor12_source }
   entry = sensor13, "sensor13", float, "%.1f";, { sensor13_source }
   entry = sensor14, "sensor14", float, "%.1f";, { sensor14_source }
   entry = sensor15, "sensor15", float, "%.1f";, { sensor15_source }
   entry = sensor16, "sensor16", float, "%.1f";, { sensor16_source }

   entry = canpwmin0, "canpwmin0", int, "%d", { enable_pollPWM }
   entry = canpwmin1, "canpwmin1", int, "%d", { enable_pollPWM }
   entry = canpwmin2, "canpwmin2", int, "%d", { enable_pollPWM }
   entry = canpwmin3, "canpwmin3", int, "%d", { enable_pollPWM }

   entry = timing_err, "timing err%", float, "%.1f"
   entry = synccnt, "Lost sync count", int, "%d"
   entry = syncreason, "Lost sync reason", int, "%d"

#if MPH
   entry = vss1,             "mph 1",         int,  "%.1f", {vss_opt1 || vss1_an}
   entry = vss2,             "mph 2",         int,  "%.1f", {vss_opt2 || vss2_an}
#else
   entry = vss1,             "kph 1",         int,  "%.1f", {vss_opt1 || vss1_an}
   entry = vss2,             "kph 2",         int,  "%.1f", {vss_opt2 || vss2_an}
#endif
   entry = ss1,             "Shaft rpm 1",         int,  "%d", { ss_opt1 }
   entry = ss2,             "Shaft rpm 2",         int,  "%d", { ss_opt2 }
   entry = n2o_addfuel,     "Nitrous added fuel",  float, "%.3f", { N2Oopt_2 }
   entry = n2o_retard,      "Nitrous timing retard by", float, "%.1f", { N2Oopt_2 }
   entry = nitrous1_duty,   "Nitrous 1 duty", int, "%d", { N2Oopt_2 }
   entry = nitrous2_duty,   "Nitrous 2 duty", int, "%d", { N2Oopt_2 }
   entry = nitrous_timer,   "Nitrous Timer", float, "%.3f", { N2Oopt_2 }
   entry = sd_filenum,      "SDcard file number", int, "%d", { log_style_on }
   entry = sd_status,      "SDcard status", int, "%d", { log_style_on }
   entry = sd_phase,      "SDcard phase", int, "%d", { log_style_on }
   entry = sd_error,      "SDcard error", int, "%d", { log_style_on }
   entry = gear,          "Gear", int, "%d", { gear_method }
   entry = vss1dot,       "vss1dot", float, "%.1f", {vss_opt1 || vss1_an}
   entry = vss2dot,       "vss2dot", float, "%.1f", {vss_opt2 || vss2_an}
   entry = accelx,        "accel X", float, "%.2f", { accXport }
   entry = accely,        "accel Y", float, "%.2f", { accYport }
   entry = accelz,        "accel Z", float, "%.2f", { accZport }
   entry = duty_pwm_a,   "Generic PWM A duty", int, "%d", { pwm_opt_on_a }
   entry = duty_pwm_b,   "Generic PWM B duty", int, "%d", { pwm_opt_on_b }
   entry = duty_pwm_c,   "Generic PWM C duty", int, "%d", { pwm_opt_on_c }
   entry = duty_pwm_d,   "Generic PWM D duty", int, "%d", { pwm_opt_on_d }
   entry = duty_pwm_e,   "Generic PWM E duty", int, "%d", { pwm_opt_on_e }
   entry = duty_pwm_f,   "Generic PWM F duty", int, "%d", { pwm_opt_on_f }
   entry = status1, "status1", int, "%d"
   entry = status2, "status2", int, "%d"
   entry = status3, "status3", int, "%d"
   entry = status4, "status4", int, "%d"
   entry = status5, "status5", int, "%d"
   entry = vvt_ang1, "VVT angle 1", int, "%.1f", { vvt_opt1_on }
   entry = vvt_ang2, "VVT angle 2", int, "%.1f", { vvt_opt1_on > 1}
   entry = vvt_ang3, "VVT angle 3", int, "%.1f", { vvt_opt1_on > 2}
   entry = vvt_ang4, "VVT angle 4", int, "%.1f", { vvt_opt1_on > 2}
   entry = vvt_target1, "VVT target 1", int, "%.1f", { vvt_opt1_on }
   entry = vvt_target2, "VVT target 2", int, "%.1f", { vvt_opt1_on > 1}
   entry = vvt_target3, "VVT target 3", int, "%.1f", { vvt_opt1_on > 2}
   entry = vvt_target4, "VVT target 4", int, "%.1f", { vvt_opt1_on > 2}
   entry = vvt_duty1, "VVT duty 1", int, "%.1f", { vvt_opt1_on }
   entry = vvt_duty2, "VVT duty 2", int, "%.1f", { vvt_opt1_on > 1}
   entry = vvt_duty3, "VVT duty 3", int, "%.1f", { vvt_opt1_on > 2}
   entry = vvt_duty4, "VVT duty 4", int, "%.1f", { vvt_opt1_on > 2}
    entry = fuelflow, "Fuel flow cc/min", int, "%d"
    entry = fuelcons, "Fuel cons. l/km", int, "%d"
    entry = tps_accel, "TPS accel", int, "%.1f", { AE_options & 0x1 }
    entry = map_accel, "MAP accel", int, "%.1f", { AE_options & 0x1 }
    entry = total_accel, "Total accel", int, "%.1f", { AE_options & 0x1 }
   entry = launch_timer,   "Launch retard timer", float, "%.3f", { launch_opt_on && launch_opt_retard }
   entry = launch_retard,  "Launch timed retard", float, "%.1f", { launch_opt_on && launch_opt_retard }

   entry = knock_cyl01, "knock cyl# 1", float, "%.1f", {(knk_option_an == 3) && knock_conf_percyl && (nCylinders > 0)}
   entry = knock_cyl02, "knock cyl# 2", float, "%.1f", {(knk_option_an == 3) && knock_conf_percyl && (nCylinders > 1)}
   entry = knock_cyl03, "knock cyl# 3", float, "%.1f", {(knk_option_an == 3) && knock_conf_percyl && (nCylinders > 2)}
   entry = knock_cyl04, "knock cyl# 4", float, "%.1f", {(knk_option_an == 3) && knock_conf_percyl && (nCylinders > 3)}
   entry = knock_cyl05, "knock cyl# 5", float, "%.1f", {(knk_option_an == 3) && knock_conf_percyl && (nCylinders > 4)}
   entry = knock_cyl06, "knock cyl# 6", float, "%.1f", {(knk_option_an == 3) && knock_conf_percyl && (nCylinders > 5)}
   entry = knock_cyl07, "knock cyl# 7", float, "%.1f", {(knk_option_an == 3) && knock_conf_percyl && (nCylinders > 6)}
   entry = knock_cyl08, "knock cyl# 8", float, "%.1f", {(knk_option_an == 3) && knock_conf_percyl && (nCylinders > 7)}
#if CYL_12_16_SUPPORT
   entry = knock_cyl09, "knock cyl#09", float, "%.1f", {(knk_option_an == 3) && knock_conf_percyl && (nCylinders > 8)}
   entry = knock_cyl10, "knock cyl#10", float, "%.1f", {(knk_option_an == 3) && knock_conf_percyl && (nCylinders > 9)}
   entry = knock_cyl11, "knock cyl#11", float, "%.1f", {(knk_option_an == 3) && knock_conf_percyl && (nCylinders > 10)}
   entry = knock_cyl12, "knock cyl#12", float, "%.1f", {(knk_option_an == 3) && knock_conf_percyl && (nCylinders > 11)}
   entry = knock_cyl13, "knock cyl#13", float, "%.1f", {(knk_option_an == 3) && knock_conf_percyl && (nCylinders > 12)}
   entry = knock_cyl14, "knock cyl#14", float, "%.1f", {(knk_option_an == 3) && knock_conf_percyl && (nCylinders > 13)}
   entry = knock_cyl15, "knock cyl#15", float, "%.1f", {(knk_option_an == 3) && knock_conf_percyl && (nCylinders > 14)}
   entry = knock_cyl16, "knock cyl#16", float, "%.1f", {(knk_option_an == 3) && knock_conf_percyl && (nCylinders > 15)}
#endif

#if INTERNAL_LOG_FIELDS
   ;internalLogField = fieldName, class, type, offset, units, scale, translate, digits
   internalLogField = "Tooth number",       scalar, U08, 1024, "#", 1.0, 0.0, 0
   internalLogField = "Synch",              scalar, U08, 1025, "", 1, 0, 0
   internalLogField = "Cumulative cycles",  scalar, U16, 1026, "#", 1.0, 0.0, 0
   internalLogField = "Cumulative teeth",   scalar, U16, 1027, "#", 1.0, 0.0, 0
   internalLogField = "coilsel",            scalar, U16, 1028, "", 1, 0, 0
   internalLogField = "dwellsel",           scalar, U16, 1029, "", 1, 0, 0
   internalLogField = "PTM",                scalar, U08, 1030, "", 1, 0, 0
   internalLogField = "PTJ",                scalar, U08, 1031, "", 1, 0, 0
   internalLogField = "PTT",                scalar, U08, 1032, "", 1, 0, 0
   internalLogField = "PORTA",              scalar, U08, 1033, "", 1, 0, 0
   internalLogField = "PORTB",              scalar, U08, 1034, "", 1, 0, 0
   internalLogField = "next_dwell.tooth",   scalar, U08, 1035, "", 1, 0, 0
   internalLogField = "next_spark.tooth",   scalar, U08, 1036, "", 1, 0, 0
   internalLogField = "next_inj0.tooth",    scalar, U08, 1037, "", 1, 0, 0
   internalLogField = "next_inj1.tooth",    scalar, U08, 1038, "", 1, 0, 0
   internalLogField = "next_inj2.tooth",    scalar, U08, 1039, "", 1, 0, 0
   internalLogField = "next_inj3.tooth",    scalar, U08, 1040, "", 1, 0, 0
   internalLogField = "next_inj4.tooth",    scalar, U08, 1041, "", 1, 0, 0
   internalLogField = "next_inj5.tooth",    scalar, U08, 1042, "", 1, 0, 0
   internalLogField = "next_inj6.tooth",    scalar, U08, 1043, "", 1, 0, 0
   internalLogField = "next_inj7.tooth",    scalar, U08, 1044, "", 1, 0, 0
   internalLogField = "fuel_ovflo",         scalar, U08, 1046, "", 1, 0, 0
   internalLogField = "wheeldec_ovflo",     scalar, U08, 1047, "", 1, 0, 0
   internalLogField = "next_dwell.time32",  scalar, U32, 1048, "", 1, 0, 0
   internalLogField = "next_spark.time32",  scalar, U32, 1049, "", 1, 0, 0
   internalLogField = "TIE",                scalar, U08, 1050, "", 1, 0, 0
   internalLogField = "TFLG1",              scalar, U08, 1051, "", 1, 0, 0
   internalLogField = "TIMTIE",             scalar, U08, 1052, "", 1, 0, 0
   internalLogField = "TIMTFLG1",           scalar, U08, 1053, "", 1, 0, 0
   internalLogField = "next_inj[0].time",   scalar, U16, 1054, "", 1, 0, 0
   internalLogField = "next_inj[1].time",   scalar, U16, 1055, "", 1, 0, 0
   internalLogField = "next_inj[2].time",   scalar, U16, 1056, "", 1, 0, 0
   internalLogField = "next_inj[3].time",   scalar, U16, 1057, "", 1, 0, 0
   internalLogField = "next_inj[4].time",   scalar, U16, 1058, "", 1, 0, 0
   internalLogField = "next_inj[5].time",   scalar, U16, 1059, "", 1, 0, 0
   internalLogField = "next_inj[6].time",   scalar, U16, 1060, "", 1, 0, 0
   internalLogField = "next_inj[7].time",   scalar, U16, 1061, "", 1, 0, 0
   internalLogField = "XGSEM",              scalar, U08, 1062, "", 1, 0, 0
   internalLogField = "pwcalc1",            scalar, U16, 1063, "", 1, 0, 0
   internalLogField = "pwcalc2",            scalar, U16, 1064, "", 1, 0, 0
   internalLogField = "next_map_start_event.tooth", scalar, U08, 1065, "", 1, 0, 0
   internalLogField = "XGCHID",             scalar, U08, 1066, "", 1, 0, 0
   internalLogField = "XGSWT",              scalar, U08, 1067, "", 1, 0, 0
   internalLogField = "xgate_deadman",      scalar, U08, 1068, "", 1, 0, 0
   internalLogField = "XGMCTL",             scalar, U08, 1069, "", 1, 0, 0
   internalLogField = "xgpc",               scalar, U16, 1070, "", 1, 0, 0
   internalLogField = "xgswe_count",        scalar, U08, 1071, "", 1, 0, 0
   internalLogField = "next_fuel",          scalar, U08, 1072, "", 1, 0, 0
   internalLogField = "inj1_cnt",           scalar, U16, 1073, "", 1, 0, 0
   internalLogField = "inj2_cnt",           scalar, U16, 1074, "", 1, 0, 0
   internalLogField = "inj3_cnt",           scalar, U16, 1075, "", 1, 0, 0
   internalLogField = "inj4_cnt",           scalar, U16, 1076, "", 1, 0, 0
   internalLogField = "inj5_cnt",           scalar, U16, 1077, "", 1, 0, 0
   internalLogField = "inj6_cnt",           scalar, U16, 1078, "", 1, 0, 0
   internalLogField = "inj7_cnt",           scalar, U16, 1079, "", 1, 0, 0
   internalLogField = "inj8_cnt",           scalar, U16, 1080, "", 1, 0, 0
#endif
;-------------------------------------------------------------------------------
