09-10-2010, 03:49 PM
|
#167 (permalink)
|
oldschool
Join Date: May 2010
Location: Illinois
Posts: 184
Thanks: 21
Thanked 35 Times in 25 Posts
|
continued again:
Quote:
;================================================= ====
; 5.7l LOAD w/back-pressure EGR (ARJU)
; This table provided a corrected value of effective
; (cyl vol/Inj flow) rate (ratio) when EGR is active.
; 1. Inj Flow is per bank, in grams/sec
; 2. Cyl vol is liters/cylinder
; 3. Ratio = cyl vol/Inj flow
; The resulting value is used to predict fuel flow using the
; speed density method. During EGR off/on transients the value is
; filtered between the value at LD2B4 and the table value for smoothing.
; 189.48 = 1461.5 * 7.713 g/sec TBI
; TABLE = 1461.5 * Volume/rate
;================================================= ====
;-------------------------------------
; EGR-ON BPW Compensation vs air-flow vs %EGR
; 02-03-2000 ARJU, 17 COL x 5 BLOCKS = 85 BYTES
; TABLE = 189.48 * Cylinder Volume
;-------------------------------------
ORG $0324 ; TABLE LIMITS
LD324 FCB 16 ; 8gm/sec MIN Air Flow Value
LD325 FCB 0 ; 0% MIN EGR Value
LD326 FCB 17 ; LINES/BLOCK
;---------------------------------------------
; 8 Air Flow Cyl Vol EGR %
;---------------------------------------------
LD327 FCB 135 ; 0.7125 0.0
LD328 FCB 135 ; 0.7125 6.3
LD329 FCB 132 ; 0.6966 12.5
LD32A FCB 128 ; 0.6755 18.8
LD32B FCB 123 ; 0.6491 25.0
LD32C FCB 123 ; 0.6491 31.3
LD32D FCB 123 ; 0.6491 37.5
LD32E FCB 123 ; 0.6491 43.8
LD32F FCB 123 ; 0.6491 50.0
LD330 FCB 123 ; 0.6491 56.3
LD331 FCB 123 ; 0.6491 62.5
LD332 FCB 123 ; 0.6491 68.8
LD333 FCB 123 ; 0.6491 75.0
LD334 FCB 123 ; 0.6491 81.3
LD335 FCB 123 ; 0.6491 87.5
LD336 FCB 123 ; 0.6491 93.8
LD337 FCB 123 ; 0.6491 100.0
;---------------------------------------------
; 16 Air Flow Cyl Vol EGR %
;---------------------------------------------
LD338 FCB 135 ; 0.7125 0.0
LD339 FCB 135 ; 0.7125 6.3
LD33A FCB 132 ; 0.6966 12.5
LD33B FCB 128 ; 0.6755 18.8
LD33C FCB 123 ; 0.6491 25.0
LD33D FCB 123 ; 0.6491 31.3
LD33E FCB 123 ; 0.6491 37.5
LD33F FCB 123 ; 0.6491 43.8
LD340 FCB 123 ; 0.6491 50.0
LD341 FCB 123 ; 0.6491 56.3
LD342 FCB 123 ; 0.6491 62.5
LD343 FCB 123 ; 0.6491 68.8
LD344 FCB 123 ; 0.6491 75.0
LD345 FCB 123 ; 0.6491 81.3
LD346 FCB 123 ; 0.6491 87.5
LD347 FCB 123 ; 0.6491 93.8
LD348 FCB 123 ; 0.6491 100.0
;---------------------------------------------
; 24 Air Flow Cyl Vol EGR %
;---------------------------------------------
LD349 FCB 135 ; 0.7125 0.0
LD34A FCB 135 ; 0.7125 6.3
LD34B FCB 132 ; 0.6966 12.5
LD34C FCB 128 ; 0.6755 18.8
LD34D FCB 123 ; 0.6491 25.0
LD34E FCB 123 ; 0.6491 31.3
LD34F FCB 123 ; 0.6491 37.5
LD350 FCB 123 ; 0.6491 43.8
LD351 FCB 123 ; 0.6491 50.0
LD352 FCB 123 ; 0.6491 56.3
LD353 FCB 123 ; 0.6491 62.5
LD354 FCB 123 ; 0.6491 68.8
LD355 FCB 123 ; 0.6491 75.0
LD356 FCB 123 ; 0.6491 81.3
LD357 FCB 123 ; 0.6491 87.5
LD358 FCB 123 ; 0.6491 93.8
LD359 FCB 123 ; 0.6491 100.0
;---------------------------------------------
; 32 Air Flow Cyl Vol EGR %
;---------------------------------------------
LD35A FCB 135 ; 0.7125 0.0
LD35B FCB 135 ; 0.7125 6.3
LD35C FCB 132 ; 0.6966 12.5
LD35D FCB 128 ; 0.6755 18.8
LD35E FCB 123 ; 0.6491 25.0
LD35F FCB 123 ; 0.6491 31.3
LD360 FCB 123 ; 0.6491 37.5
LD361 FCB 123 ; 0.6491 43.8
LD362 FCB 123 ; 0.6491 50.0
LD363 FCB 123 ; 0.6491 56.3
LD364 FCB 123 ; 0.6491 62.5
LD365 FCB 123 ; 0.6491 68.8
LD366 FCB 123 ; 0.6491 75.0
LD367 FCB 123 ; 0.6491 81.3
LD368 FCB 123 ; 0.6491 87.5
LD369 FCB 123 ; 0.6491 93.8
LD36A FCB 123 ; 0.6491 100.0
;---------------------------------------------
; 40 Air Flow Cyl Vol EGR %
;---------------------------------------------
LD36B FCB 135 ; 0.7125 0.0
LD36C FCB 135 ; 0.7125 6.3
LD36D FCB 132 ; 0.6966 12.5
LD36E FCB 128 ; 0.6755 18.8
LD36F FCB 123 ; 0.6491 25.0
LD370 FCB 123 ; 0.6491 31.3
LD371 FCB 123 ; 0.6491 37.5
LD372 FCB 123 ; 0.6491 43.8
LD373 FCB 123 ; 0.6491 50.0
LD374 FCB 123 ; 0.6491 56.3
LD375 FCB 123 ; 0.6491 62.5
LD376 FCB 123 ; 0.6491 68.8
LD377 FCB 123 ; 0.6491 75.0
LD378 FCB 123 ; 0.6491 81.3
LD379 FCB 123 ; 0.6491 87.5
LD37A FCB 123 ; 0.6491 93.8
LD37B FCB 123 ; 0.6491 100.0
;---------------------------------------------
_____________________________________________
|
and the algorithm:
Quote:
;=================================================
; REAL TIME SERVICE ROUTINE 3
;=================================================
EB59: PULX ; PULL X REGISTER FROM STACK
EB5A: LDX #$D1B3 ; POINT TO EGR PARAMETERS
EB5D: LDAB L0006 ; GET EGR STATUS IN REGISTER B
EB5F: LDAA 0,X ; GET 48c COOLANT FOR EGR ENABLE (1K PU) TABLE 3
EB61: CMPA L00E3 ; COMPARE A TO INVERSE COOLANT, 1k pu (COOLANT VALUE INVERSED)
EB63: BLS LEBA5 ; IF COOLANT FOR ENABLE LT COOLANT VALUE, BRANCH TO $EBA5 (SKIP OTHER CHECKS)
EB65: LDAA 6,X ; GET 38 Kpa MAP, HI VACUUM FOR EGR ENABLE
EB67: BITB #$10 ; TEST b4 IN $L0006 (EGR ALREADY ON/OFF ?)
EB69: BEQ LEB6D ; IF NOT b4, BRANCH TO $EB6D (SKIP LOW MAP TEST)
EB6B: LDAA 5,X ; 35 Kpa MAP, LO VACUUM FOR EGR ENABLE
EB6D: LEB6D CMPA L0031 ; COMPARE A TO VACUUM
EB6F: BLS LEB75 ; IF VACUUM VALUE GT ENABLE THRESH, BRANCH TO $EB75
EB71: ANDB #$EF ; CLEAR b4 IN $L0006 EGR STATUS (TURN EGR OFF)
EB73: BRA LEBA3 ; BRANCH ALWAYS TO $EBA3 (TURN EGR OFF)
;---------------------------------
EB75: LEB75 ORAB #$10 ; SET b4 IN $L0006 (EGR STATUS ON)
EB77: LDAA L0009 ; GET FLAG WORD
EB79: BITA #$24 ; TEST b5,b2
EB7B: BNE LEB8F ; IF b5,b2 BRANCH TO $EB8F (SKIP TPS CHECK)
EB7D: LDAA 4,X ; GET 3%, HI TPS FOR EGR ENABLE
EB7F: BITB #$20 ; TEST b5 IN $L0006 (EGR STATUS ON/OFF ?)
EB81: BEQ LEB85 ; IF NOT b5 BRANCH TO $EB85 (SKIP LOW TPS THRESH)
EB83: LDAA 3,X ; GET 2%, LOW TPS THRESH FOR EGR ENABLE
EB85: LEB85 CMPA L0049 ; COMPARE A TO CURRENT TPS VALUE
EB87: BCS LEB8D ; IF TPS GT THRESH, BRANCH TO $EB8D
EB89: ANDB #$DF ; CLEAR b5 IN $L0006 (TURN EGR OFF)
EB8B: BRA LEBA3 ; BRANCH ALWAYS TO $EBA3
;---------------------------------
EB8D: LEB8D ORAB #$20 ; SET b5 IN REGISTER B
EB8F: LEB8F LDAA L00DE ; GET STATUS WORD
EB91: BITA #$40 ; TEST b6
EB93: BNE LEBAB ; IF b6, BRANCH TO $EBAB
EB95: LDAA 2,X ; GET 0 MPH HI VSS THRESHOLD FOR EGR ENABLE
EB97: BITB #$40 ; TEST b6 IN $L0006
EB99: BEQ LEB9D ; IF NOT b6, BRANCH TO $EB9D (SKIP LO VSS THRESH)
EB9B: LDAA 1,X ; GET 0 MPH LO VSS THRESHOLD FOR EGR ENABLE
EB9D: LEB9D CMPA L0034 ; COMPARE A TO FILTERED VSS MPH/1
EB9F: BLS LEBA9 ; IF VSS GT THRESHOLD BRANCH TO $EBA9
EBA1: ANDB #$BF ; CLEAR b6 IN $L0006 (TURN EGR OFF)
EBA3: LEBA3 STAB L0006 ; UPDATE EGR STATUS
EBA5: LEBA5 CLRA ; CLEAR A REGISTER
EBA6: JMP LEC00 ; JUMP TO $EC00 (UPDATE PERCENT EGR)
;---------------------------------
;=================================================
; PERCENT EGR Vs. VACUUM LOAD vs RPM TBL = 2.56 * %EGR
; 01-31-1996 Dissassemby of ASDZ Blocks = 7
; RPM 1000, 1200, 1400, 1600, 1800, 2200, 3000
;=================================================
EBA9: LEBA9 ORAB #$40 ; SET b6
EBAB: LEBAB STAB L0006 ; UPDATE EGR STATUS
EBAD: LDX #$D1C0 ; POINT TO PERCENT EGR Vs. VACUUM LOAD vs RPM
EBB0: JSR LFA4D ; GOSUB $FA4D (Return with MAP or VACUUM in A REGISTER)
;---------------------------------
EBB3: LSRA ; RESULT/2
EBB4: TAB ; TRANSFER A REGISTER TO B REGISTER
EBB5: LDAA L001F ; GET RPM/12.5 (FILTERED)
EBB7: CMPA #144 ; COMPARE A REGISTER TO 1800 RPM
EBB9: BLS LEBCB ; IF RPM LT 1800 BRANCH TO $EBCB (3-D LOOK-UP)
EBBB: LSRA ; RPM/2
EBBC: ADDA #72 ; ADD 72 (900 RPM) TO A REGISTER
EBBE: CMPA #160 ; COMPARE TO 2000 RPM/12.5
EBC0: BLS LEBCB ; IF LT 2000 RPM BRANCH TO $EBCB (3-D LOOK-UP)
EBC2: LSRA ; RPM/2
EBC3: ADCA #80 ; ADD 80 (1000 RPM) WITH CARRY TO A REGISTER
EBC5: CMPA #80 ; COMPARE A REGISTER TO 1000 RPM
EBC7: BLS LEBCB ; IF RPM LT 1000 BRANCH TO (3-D LOOK-UP)
EBC9: LDAA #176 ; GET 4400 RPM
EBCB: LEBCB JSR LFB67 ; GOSUB 3-D LOOK-UP
;---------------------------------
EBCE: STAA L0058 ; UPDATE PERCENT EGR, (temp variable)
;=================================================
; EGR GAIN vs COOLANT VALUE = N * 128
;=================================================
EBD0: LDX #$D1F5 ; POINT TO TABLE EGR GAIN vs COOLANT
EBD3: LDAA L0021 ; GET COOLANT
EBD5: LDAB #40 ; COOLANT ARG, LOWER LIMIT
EBD7: JSR LFB37 ; GOSUB 2d LOOK-UP, WITH LOWER ARG LIMIT
EBDA: BSR LEC22 ; GOSUB (UPDATE EGR%)
;---------------------------------
EBDC: LDAA LD1BF ; GET 50% TPS HI TPS THRESHOLD EGR AFTER 50% GAIN = 0
EBDF: CMPA L0049 ; COMPARE TO CURRENT TPS VALUE
EBE1: BCS LEBA5 ; IF TPS GT THRESHOLD BRANCH TO $EBA5
;=================================================
; EGR GAIN FACTOR vs BAROMETER & MAP 3d TABLE = GAIN * 128
;=================================================
EBE3: JSR LFD18 ; GOSUB $FD18 GET PROCESSED BAROMETER VALUE IN A
EBE6: TAB ; PUT PROCESSED BARO IN BOTH A & B Registers
EBE7: LDX #$D1FE ; POINT TO EGR GAIN GAIN FACTOR vs BARO & MAP 3d
EBEA: LDAA L0026 ; GET S/D MAP
EBEC: LSRA ; REGISTER A/2
EBED: JSR LFB67 ; GOSUB 3d LOOK-UP
EBF0: BSR LEC22 ; GOSUB $EC22 (UPDATE EGR%)
;=================================================
; FILTER EGR
;=================================================
EBF2: LDAA L0080 ; GET PERCENT EGR INTO A REGISTER
EBF4: CLRB ; CLEAR B REGISTER
EBF5: PSHB ; PUSH B REGISTER ONTO STACK
EBF6: PSHA ; PUSH A REGISTER ONTO STACK
EBF7: PULX ; PULL X REGISTER FROM STACK (2 BYTES)
EBF8: LDAA L0058 ; GET PERCENT EGR (temp) INTO A
EBFA: LDAB LD1BC ; GET 0.898 EGR D.C. FILTER COEF INTO B
EBFD: JSR LFB12 ; GOSUB LAG FILTER
;---------------------------------
EC00: LEC00 STAA L0080 ; UPDATE FILTERED PERCENT EGR
;=================================================
; CHECK IF HEADS-UP ON-LINE EGR MODE
;=================================================
EC02: LDAB L0000 ; GET STATUS MODE WORD
EC04: BITB #$02 ; TEST b1
EC06: BEQ LEC0B ; BRANCH IF NOT b1
EC08: JSR L5806 ; GOTO HEADS UP <-------<<
;---------------------------------
EC0B: LEC0B LDAB #160 ;
EC0D: MUL ;
EC0E: ADCA #$00 ;
;=================================================
; VACUUM LIMITER
;=================================================
EC10: LDAB L0031 ; GET VACUUM IN B REGISTER
EC12: CMPB #192 ; COMPARE B REGISTER TO VACUUM LIMIT aprox 20 Kpa
EC14: BCC LEC2D ; IF VALUE LESS THAN BRANCH TO $EC2D
EC16: CMPB #64 ; COMPARE TO VACUUM LIMIT aprox 70 Kpa
EC18: BHI LEC1C ; IF RESULT HIGHER THAN BRANCH TO $EC1C (SKIP 70 KPA LIMIT)
EC1A: LDAB #64 ; GET VACUUM LIMIT aprox 70 Kpa INTO B REGISTER
EC1C: LEC1C NEGB ; two's complement into B register
EC1D: LSRB ; Divide B register by two
EC1E: ADDB #96 ; ADD 60 kpa TO B REGISTER
EC20: BRA LEC2F ; BRANCH ALWAYS TO $EC2F
;=================================================
; UPDATE EGR%
;=================================================
EC22: LEC22 LDAB L0058 ; GET PERCENT EGR (Temp)
EC24: MUL ; MULTIPLY A x B REGISTERS = D REGISTER
EC25: ASLD ; MULTIPLY D REGISTER BY TWO
EC26: BCC LEC2A ; IF NO OVERFLOW BRANCH TO $EC2A (SKIP MAX VALUE)
EC28: LDAA #255 ; FORCE MAX VALUE
EC2A: LEC2A STAA L0058 ; UPDATE PERCENT EGR (Temp)
EC2C: RTS ;---------------------------------
EC2D: LEC2D NEGB ; two's complement into B register
EC2E: ASLB ; MULTIPLY B REGISTER BY TWO
;=================================================
;* EGR CORRECTION vs VACUUM vs EGR Duty Cycle
;* ASDZ BP EGR TABLE = Factor * 256
;=================================================
EC2F: LEC2F LDX #$D21D ; POINT TO TABLE EGR CORRECTION vs VACUUM vs EGR D.C.
EC32: JSR LFB67 ; GO DO 3d LOOK-UP
;---------------------------------
EC35: STAA L007F ; UPDATE EGR CORRECTION (air flow for EGR)
EC37: LDAB L0006 ; GET STATUS WORD
EC39: ANDB #$7F ; CLEAR b7 EGR OFF
EC3B: LDAA L0080 ; GET PERCENT EGR
EC3D: CMPA LD1BD ; COMPARE TO 19.9% D.C. THRESHOLD FOR EGR ON
EC40: BLS LEC51 ; BRANCH IF LOWER OR SAME
EC42: LDAA L0031 ; GET VACUUM
EC44: CMPA LD1BE ; COMPARE TO 1 Kpa VACUUM THRESH FOR EGR ON, (100 Kpa)
EC47: BHI LEC51 ; IF VACUUM GT THRESHOLD BRANCH TO $EC51 (UPDATE STATUS)
EC49: LDAA L000A ; GET DIAGNOSTICS STATUS WORD
EC4B: BITA #$01 ; TEST b0 (DIAGNOSTICS STATUS) (DOING SOME TEST ?)
EC4D: BNE LEC51 ; IF RESULT NOT ZERO BRANCH TO $EC51 (SKIP TURNING EGR ON)
EC4F: ORAB #$80 ; SET b7, EGR ON
EC51: LEC51 STAB L0006 ; UPDATE STATUS WORD
EC53: JMP LE548 ; GO TO $E548
;---------------------------------
_________________________________________________
|
|
|
|