diff -r 89b82476a75f -r 795326a8c258 source/page7D/initial.asm --- a/source/page7D/initial.asm Wed May 07 07:00:37 2014 -0400 +++ b/source/page7D/initial.asm Wed May 07 07:16:33 2014 -0400 @@ -1,44 +1,44 @@ Page7D_2CAC: push af - ld a, 1 + ld a, 1 nop di nop nop im 1 di - out (14h), a + out (14h), a di call checkForFlashTrickery - pop af + pop af call p7Dsub_6FAC - jp c, relockFlashBack + jp c, relockFlashBack push af call p7Dsub_576D - pop af + pop af call Page7D_2BE6 - jp relockFlashBack + jp relockFlashBack ; =============== S U B R O U T I N E ======================================= DeleteApp: push af - ld a, 1 + ld a, 1 nop di nop nop im 1 di - out (14h), a + out (14h), a di call checkForFlashTrickery - pop af + pop af call p7Dsub_6FAC - jp c, relockFlashBack + jp c, relockFlashBack call Page7D_2BE6 - jp relockFlashBack + jp relockFlashBack ; End of function DeleteApp @@ -47,49 +47,49 @@ Page7D_2BE6: ; DeleteApp+17p ... - ld b, a - ld hl, 4000h - rst 28h -; --------------------------------------------------------------------------- - .dw 8051h -; --------------------------------------------------------------------------- - cp 0FFh - ld a, b - jr z, locret_4077 + ld b, a + ld hl, 4000h + rst 28h +; --------------------------------------------------------------------------- + .dw 8051h +; --------------------------------------------------------------------------- + cp 0FFh + ld a, b + jr z, locret_4077 call FindAppNumPages - ld b, c - push af - ld a, c - or a - jr z, p7Dloc_4078 - res 6, (iy+24h) - res 7, (iy+24h) - xor a - ld (unk_9C87), a - pop af + ld b, c + push af + ld a, c + or a + jr z, p7Dloc_4078 + res 6, (iy+24h) + res 7, (iy+24h) + xor a + ld (unk_9C87), a + pop af p7Dloc_4061: - set 0, (iy+25h) - push af - push bc - ld de, 4000h - ld b, 0 - rst 28h -; --------------------------------------------------------------------------- - .dw 80C6h -; --------------------------------------------------------------------------- - pop bc - pop af - dec a + set 0, (iy+25h) + push af + push bc + ld de, 4000h + ld b, 0 + rst 28h +; --------------------------------------------------------------------------- + .dw 80C6h +; --------------------------------------------------------------------------- + pop bc + pop af + dec a djnz p7Dloc_4061 - ld (appSearchPage+1), a + ld (appSearchPage+1), a locret_4077: ret ; --------------------------------------------------------------------------- p7Dloc_4078: - pop af + pop af ret ; End of function Page7D_2BE6 @@ -102,7 +102,7 @@ push hl call p7Dsub_4894 call p7Dsub_457C - pop hl + pop hl ret ; End of function Page7D_2BB0 @@ -119,31 +119,31 @@ push af p7Dloc_408A: - pop af + pop af push hl push bc push af call Page7D_2CD0 - ld b, a - pop af - push af - rst 28h -; --------------------------------------------------------------------------- - .dw 8021h -; --------------------------------------------------------------------------- - pop af - pop bc - pop hl - inc hl - push af - dec bc - ld a, b - or c - jr nz, p7Dloc_408A - pop af - pop de - pop hl - pop bc + ld b, a + pop af + push af + rst 28h +; --------------------------------------------------------------------------- + .dw 8021h +; --------------------------------------------------------------------------- + pop af + pop bc + pop hl + inc hl + push af + dec bc + ld a, b + or c + jr nz, p7Dloc_408A + pop af + pop de + pop hl + pop bc ret ; End of function p7Dsub_4083 @@ -163,181 +163,181 @@ push af p7Dloc_40AD: - pop af - push hl - push bc - push af - rst 28h -; --------------------------------------------------------------------------- - .dw 8051h -; --------------------------------------------------------------------------- - ld b, a - pop af - push af - ld a, (OP2) - rst 28h -; --------------------------------------------------------------------------- - .dw 8021h -; --------------------------------------------------------------------------- - pop af - pop bc - pop hl - inc hl - push af - dec bc - ld a, b - or c - jr nz, p7Dloc_40AD - pop af - pop de - pop hl - pop bc + pop af + push hl + push bc + push af + rst 28h +; --------------------------------------------------------------------------- + .dw 8051h +; --------------------------------------------------------------------------- + ld b, a + pop af + push af + ld a, (OP2) + rst 28h +; --------------------------------------------------------------------------- + .dw 8021h +; --------------------------------------------------------------------------- + pop af + pop bc + pop hl + inc hl + push af + dec bc + ld a, b + or c + jr nz, p7Dloc_40AD + pop af + pop de + pop hl + pop bc ret ; =============== S U B R O U T I N E ======================================= Page7D_2B62: - ld (unk_9C20), a + ld (unk_9C20), a push de push bc push hl call p7Dsub_4894 call p7Dsub_4566 - cp 0FFh - jr nz, p7Dloc_40E5 - ld bc, 0 - ld (OP6), bc - jr p7Dloc_4105 + cp 0FFh + jr nz, p7Dloc_40E5 + ld bc, 0 + ld (OP6), bc + jr p7Dloc_4105 ; --------------------------------------------------------------------------- p7Dloc_40E5: - ld bc, 1 - ld (OP6), bc + ld bc, 1 + ld (OP6), bc push hl call p7Dsub_4574 - add hl, bc + add hl, bc call p7Dsub_4574 - add hl, bc - pop bc - sbc hl, bc - push hl - pop bc + add hl, bc + pop bc + sbc hl, bc + push hl + pop bc call p7Dsub_4894 - ld de, 4000h + ld de, 4000h push de push bc call p7Dsub_42DF p7Dloc_4105: call p7Dsub_4894 - rst 28h -; --------------------------------------------------------------------------- - .dw 8060h -; --------------------------------------------------------------------------- - rst 28h -; --------------------------------------------------------------------------- - .dw 8057h + rst 28h +; --------------------------------------------------------------------------- + .dw 8060h +; --------------------------------------------------------------------------- + rst 28h +; --------------------------------------------------------------------------- + .dw 8057h ; --------------------------------------------------------------------------- push hl push hl call Page7D_2BEC - ex de, hl - pop hl - inc de - inc hl + ex de, hl + pop hl + inc de + inc hl p7Dloc_4117: ; Page7D_2B62:p7Dloc_4178j call p7Dsub_4566 - cp 0 - jr z, p7Dloc_415C - cp 0FFh - jp z, p7Dloc_417B + cp 0 + jr z, p7Dloc_415C + cp 0FFh + jp z, p7Dloc_417B push hl push bc push hl call p7Dsub_521D call NZIf83Plus - jr nz, p7Dloc_4131 + jr nz, p7Dloc_4131 call p7Dsub_522B p7Dloc_4131: push hl - pop bc - pop hl - sbc hl, bc - jr nc, p7Dloc_417B - pop bc - pop hl - push hl - ld (arcInfo), de + pop bc + pop hl + sbc hl, bc + jr nc, p7Dloc_417B + pop bc + pop hl + push hl + ld (arcInfo), de call p7Dsub_4574 - pop de - push de - or a - sbc hl, de - ld a, l - add a, c - ld c, a - jr nc, p7Dloc_414D - inc b + pop de + push de + or a + sbc hl, de + ld a, l + add a, c + ld c, a + jr nc, p7Dloc_414D + inc b p7Dloc_414D: - pop hl - ld de, (arcInfo) + pop hl + ld de, (arcInfo) call p7Dsub_4083 - add hl, bc - ex de, hl - add hl, bc - ex de, hl - jp p7Dloc_4117 + add hl, bc + ex de, hl + add hl, bc + ex de, hl + jp p7Dloc_4117 ; --------------------------------------------------------------------------- p7Dloc_415C: push de call p7Dsub_4574 - pop de - add hl, bc + pop de + add hl, bc call p7Dsub_4566 - cp 2 - jr nz, p7Dloc_4178 + cp 2 + jr nz, p7Dloc_4178 push de push hl call p7Dsub_4574 - pop de - sbc hl, de + pop de + sbc hl, de adc hl, bc push hl - pop bc - ex de, hl - pop de - add hl, bc + pop bc + ex de, hl + pop de + add hl, bc p7Dloc_4178: - jp p7Dloc_4117 + jp p7Dloc_4117 ; --------------------------------------------------------------------------- p7Dloc_417B: ; Page7D_2B62+6Aj call NZIf83Plus - jr nz, p7Dloc_41DF - ld a, (unk_9C20) - or a - jr z, p7Dloc_41DF - cp 1 - jr z, p7Dloc_41A4 - cp 3 - jr z, p7Dloc_41B2 - cp 4 - jr z, p7Dloc_41C0 - cp 5 - jr z, p7Dloc_41D1 + jr nz, p7Dloc_41DF + ld a, (unk_9C20) + or a + jr z, p7Dloc_41DF + cp 1 + jr z, p7Dloc_41A4 + cp 3 + jr z, p7Dloc_41B2 + cp 4 + jr z, p7Dloc_41C0 + cp 5 + jr z, p7Dloc_41D1 call p7Dsub_427F call p7Dsub_4211 call p7Dsub_425E call p7Dsub_4228 - jr p7Dloc_41E2 + jr p7Dloc_41E2 ; --------------------------------------------------------------------------- p7Dloc_41A4: @@ -345,7 +345,7 @@ call p7Dsub_4211 call p7Dsub_427C call p7Dsub_4230 - jr p7Dloc_41E2 + jr p7Dloc_41E2 ; --------------------------------------------------------------------------- p7Dloc_41B2: @@ -353,7 +353,7 @@ call p7Dsub_425E call p7Dsub_427C call p7Dsub_4238 - jr p7Dloc_41E2 + jr p7Dloc_41E2 ; --------------------------------------------------------------------------- p7Dloc_41C0: @@ -362,7 +362,7 @@ call p7Dsub_4269 call p7Dsub_428F call p7Dsub_4238 - jr p7Dloc_41E2 + jr p7Dloc_41E2 ; --------------------------------------------------------------------------- p7Dloc_41D1: @@ -370,7 +370,7 @@ call p7Dsub_425E call p7Dsub_428F call p7Dsub_4211 - jr p7Dloc_41E2 + jr p7Dloc_41E2 ; --------------------------------------------------------------------------- p7Dloc_41DF: @@ -380,32 +380,32 @@ p7Dloc_41E2: ; Page7D_2B62+E4j ... call p7Dsub_4894 - ex de, hl - ld b, 8Fh ; '�' + ex de, hl + ld b, 8Fh ; '�' call p7Dsub_456D - pop hl - ex de, hl + pop hl + ex de, hl call p7Dsub_4894 - ex de, hl + ex de, hl push de call p7Dsub_457C - pop de - ld b, 0 + pop de + ld b, 0 call p7Dsub_456D - ld bc, (OP6) - ld a, c - cp 1 - jr nz, p7Dloc_420D + ld bc, (OP6) + ld a, c + cp 1 + jr nz, p7Dloc_420D call p7Dsub_4894 - ex de, hl - pop bc - pop hl + ex de, hl + pop bc + pop hl call p7Dsub_42AE p7Dloc_420D: - pop hl - pop bc - pop de + pop hl + pop bc + pop de ret ; End of function Page7D_2B62 @@ -425,14 +425,14 @@ p7Dsub_4214: ; Page7D_2B62:p7Dloc_41C0p call p7Dsub_522B - ld bc, 66h ; 'f' + ld bc, 66h ; 'f' p7Dloc_421A: - ld de, tempSwapArea + ld de, tempSwapArea p7Dloc_421D: call Page7D_2BEC - ex de, hl + ex de, hl call p7Dsub_7700 call p7Dsub_7666 ret @@ -444,8 +444,8 @@ p7Dsub_4228: call p7Dsub_521D - ld bc, 0E8h ; '�' - jr p7Dloc_423E + ld bc, 0E8h ; '�' + jr p7Dloc_423E ; End of function p7Dsub_4228 @@ -454,8 +454,8 @@ p7Dsub_4230: call p7Dsub_5236 - ld bc, 0C8h ; '�' - jr p7Dloc_423E + ld bc, 0C8h ; '�' + jr p7Dloc_423E ; End of function p7Dsub_4230 @@ -465,11 +465,11 @@ p7Dsub_4238: ; Page7D_2B62+100p call p7Dsub_522B - ld bc, 66h ; 'f' + ld bc, 66h ; 'f' p7Dloc_423E: call Page7D_2BEC - jr p7Dloc_4249 + jr p7Dloc_4249 ; End of function p7Dsub_4238 @@ -478,10 +478,10 @@ p7Dsub_4243: call p7Dsub_522B - ld bc, 66h ; 'f' + ld bc, 66h ; 'f' p7Dloc_4249: - ld de, tempSwapArea + ld de, tempSwapArea ; End of function p7Dsub_4243 @@ -501,9 +501,9 @@ p7Dsub_4253: ; Page7D_2B86+1Ep call Page7D_2B80 - ld bc, 20h ; ' ' - ld de, 836Dh - jr p7Dsub_424C + ld bc, 20h ; ' ' + ld de, 836Dh + jr p7Dsub_424C ; End of function p7Dsub_4253 @@ -521,8 +521,8 @@ p7Dsub_4261: call p7Dsub_5236 - ld bc, 0C8h ; '�' - jr p7Dloc_421A + ld bc, 0C8h ; '�' + jr p7Dloc_421A ; End of function p7Dsub_4261 @@ -531,9 +531,9 @@ p7Dsub_4269: call p7Dsub_5236 - ld bc, 0C8h ; '�' - ld de, ramStart - jr p7Dloc_421D + ld bc, 0C8h ; '�' + ld de, ramStart + jr p7Dloc_421D ; End of function p7Dsub_4269 @@ -543,8 +543,8 @@ p7Dsub_4274: ; Page7D_2B86:p7Dloc_47D1p call p7Dsub_5236 - ld bc, 0C8h ; '�' - jr p7Dloc_4249 + ld bc, 0C8h ; '�' + jr p7Dloc_4249 ; End of function p7Dsub_4274 @@ -563,8 +563,8 @@ p7Dsub_427F: ; Page7D_2B62:p7Dloc_41DFp call p7Dsub_521D - ld bc, 0E8h ; '�' - jr p7Dloc_421A + ld bc, 0E8h ; '�' + jr p7Dloc_421A ; End of function p7Dsub_427F @@ -574,8 +574,8 @@ p7Dsub_4287: ; Page7D_2B86:p7Dloc_47D9p call p7Dsub_521D - ld bc, 0E8h ; '�' - jr p7Dloc_4249 + ld bc, 0E8h ; '�' + jr p7Dloc_4249 ; End of function p7Dsub_4287 @@ -586,8 +586,8 @@ ; Page7D_2B62+10Bp call p7Dsub_429A call p7Dsub_521D - ld bc, 0C8h ; '�' - jr p7Dloc_421A + ld bc, 0C8h ; '�' + jr p7Dloc_421A ; End of function p7Dsub_428F @@ -596,8 +596,8 @@ p7Dsub_429A: call p7Dsub_521D - ld bc, 0C8h ; '�' - jr p7Dloc_4249 + ld bc, 0C8h ; '�' + jr p7Dloc_4249 ; End of function p7Dsub_429A @@ -607,9 +607,9 @@ p7Dsub_42A2: ; Page7D_2B62:p7Dloc_41D1p call p7Dsub_523C - ld bc, 20h ; ' ' - ld de, 836Dh - jp p7Dloc_421D + ld bc, 20h ; ' ' + ld de, 836Dh + jp p7Dloc_421D ; End of function p7Dsub_42A2 @@ -622,24 +622,24 @@ push hl push de call FindSwapSector - inc a - ld de, OP1 - ld bc, 1 + inc a + ld de, OP1 + ld bc, 1 call FlashToRam - pop de - push de - ld hl, OP1 + pop de + push de + ld hl, OP1 call p7Dsub_7700 call p7Dsub_7663 - pop de - pop hl - inc hl - inc de - pop bc - dec bc - ld a, c - or b - jr nz, p7Dsub_42AE + pop de + pop hl + inc hl + inc de + pop bc + dec bc + ld a, c + or b + jr nz, p7Dsub_42AE ; End of function p7Dsub_42AE @@ -649,11 +649,11 @@ p7Dsub_42D3: call FindSwapSector push af - rst 28h -; --------------------------------------------------------------------------- - .dw 8084h -; --------------------------------------------------------------------------- - pop af + rst 28h +; --------------------------------------------------------------------------- + .dw 8084h +; --------------------------------------------------------------------------- + pop af call Page7D_2C40 ret ; End of function p7Dsub_42D3 @@ -668,36 +668,36 @@ push hl push de call p7Dsub_42D3 - pop de - pop hl - pop bc + pop de + pop hl + pop bc p7Dloc_42E8: push bc push hl push de - ld de, OP1 - ld bc, 1 + ld de, OP1 + ld bc, 1 call p7Dsub_424C - pop de - push de - ld hl, OP1 + pop de + push de + ld hl, OP1 call FindSwapSector - inc a - ld bc, 1 - rst 28h -; --------------------------------------------------------------------------- - .dw 8087h -; --------------------------------------------------------------------------- - pop de - pop hl - inc hl - inc de - pop bc - dec bc - ld a, c - or b - jr nz, p7Dloc_42E8 + inc a + ld bc, 1 + rst 28h +; --------------------------------------------------------------------------- + .dw 8087h +; --------------------------------------------------------------------------- + pop de + pop hl + inc hl + inc de + pop bc + dec bc + ld a, c + or b + jr nz, p7Dloc_42E8 ret ; End of function p7Dsub_42DF @@ -708,45 +708,45 @@ p7Dsub_430E: push bc push de - ld a, 2 + ld a, 2 call Page7D_2B62 - rst 28h -; --------------------------------------------------------------------------- - .dw 802Dh -; --------------------------------------------------------------------------- - push hl - rst 28h -; --------------------------------------------------------------------------- - .dw 8057h -; --------------------------------------------------------------------------- - ld de, 1F18h + rst 28h +; --------------------------------------------------------------------------- + .dw 802Dh +; --------------------------------------------------------------------------- + push hl + rst 28h +; --------------------------------------------------------------------------- + .dw 8057h +; --------------------------------------------------------------------------- + ld de, 1F18h call NZIf83Plus - jr nz, p7Dloc_4327 - ld de, 1DEAh + jr nz, p7Dloc_4327 + ld de, 1DEAh p7Dloc_4327: - add hl, de - pop de - or a - sbc hl, de - jr c, p7Dloc_433D - sbc hl, bc - jr c, p7Dloc_433D - rst 28h -; --------------------------------------------------------------------------- - .dw 802Dh -; --------------------------------------------------------------------------- - pop de - ex de, hl - pop bc + add hl, de + pop de + or a + sbc hl, de + jr c, p7Dloc_433D + sbc hl, bc + jr c, p7Dloc_433D + rst 28h +; --------------------------------------------------------------------------- + .dw 802Dh +; --------------------------------------------------------------------------- + pop de + ex de, hl + pop bc call p7Dsub_4083 - xor a + xor a ret ; --------------------------------------------------------------------------- p7Dloc_433D: - pop de - pop de + pop de + pop de ret ; End of function p7Dsub_430E @@ -760,134 +760,134 @@ push hl call p7Dsub_4894 push hl - pop bc - pop hl - sbc hl, bc - push hl - pop bc - pop hl + pop bc + pop hl + sbc hl, bc + push hl + pop bc + pop hl adc hl, bc push hl - pop bc + pop bc call p7Dsub_4894 - rst 28h -; --------------------------------------------------------------------------- - .dw 808Dh + rst 28h +; --------------------------------------------------------------------------- + .dw 808Dh ; --------------------------------------------------------------------------- p7Dloc_435E: push hl push bc - ld bc, 1 - ld de, tempSwapArea + ld bc, 1 + ld de, tempSwapArea call p7Dsub_424C - ld bc, 1 - ld hl, tempSwapArea - rst 28h -; --------------------------------------------------------------------------- - .dw 8090h -; --------------------------------------------------------------------------- - pop bc - pop hl - inc hl - dec bc - ld a, b - or c - jr nz, p7Dloc_435E - rst 28h -; --------------------------------------------------------------------------- - .dw 8018h + ld bc, 1 + ld hl, tempSwapArea + rst 28h +; --------------------------------------------------------------------------- + .dw 8090h +; --------------------------------------------------------------------------- + pop bc + pop hl + inc hl + dec bc + ld a, b + or c + jr nz, p7Dloc_435E + rst 28h +; --------------------------------------------------------------------------- + .dw 8018h ; --------------------------------------------------------------------------- call p7Dsub_4894 call p7Dsub_7700 call p7Dsub_55CE - jp nz, p7Dloc_43EC - ld hl, tempSwapArea + jp nz, p7Dloc_43EC + ld hl, tempSwapArea push af push bc push de push hl call p7Dsub_4894 - inc hl + inc hl call p7Dsub_4566 - and 0F0h ; '�' - ld hl, 310h - cp l - jr nz, p7Dloc_43B9 + and 0F0h ; '�' + ld hl, 310h + cp l + jr nz, p7Dloc_43B9 call p7Dsub_7700 call p7Dsub_762A call p7Dsub_4442 - jr nz, p7Dloc_43DA + jr nz, p7Dloc_43DA adc hl, bc call p7Dsub_7700 - ld de, 830h - rst 28h -; --------------------------------------------------------------------------- - .dw 8030h -; --------------------------------------------------------------------------- - jr nz, p7Dloc_43DA - jr p7Dloc_43CF + ld de, 830h + rst 28h +; --------------------------------------------------------------------------- + .dw 8030h +; --------------------------------------------------------------------------- + jr nz, p7Dloc_43DA + jr p7Dloc_43CF ; --------------------------------------------------------------------------- p7Dloc_43B9: - ld hl, 320h - cp l - jr nz, p7Dloc_43C4 - rst 28h -; --------------------------------------------------------------------------- - .dw 80CCh -; --------------------------------------------------------------------------- - jr p7Dloc_43DA + ld hl, 320h + cp l + jr nz, p7Dloc_43C4 + rst 28h +; --------------------------------------------------------------------------- + .dw 80CCh +; --------------------------------------------------------------------------- + jr p7Dloc_43DA ; --------------------------------------------------------------------------- p7Dloc_43C4: - ld de, 0A20h - rst 28h -; --------------------------------------------------------------------------- - .dw 8027h -; --------------------------------------------------------------------------- - jr nz, p7Dloc_43DA + ld de, 0A20h + rst 28h +; --------------------------------------------------------------------------- + .dw 8027h +; --------------------------------------------------------------------------- + jr nz, p7Dloc_43DA call p7Dsub_4574 p7Dloc_43CF: - dec hl - inc bc + dec hl + inc bc call p7Dsub_7700 - ld de, ramStart - rst 28h -; --------------------------------------------------------------------------- - .dw 8054h + ld de, ramStart + rst 28h +; --------------------------------------------------------------------------- + .dw 8054h ; --------------------------------------------------------------------------- p7Dloc_43DA: - pop hl - pop de - pop bc - pop af - rst 28h + pop hl + pop de + pop bc + pop af + rst 28h ; --------------------------------------------------------------------------- ; START OF FUNCTION CHUNK FOR p7Dsub_4442 - .dw 801Bh -; --------------------------------------------------------------------------- - ld de, OP1 - ld hl, 8291h - rst 28h -; --------------------------------------------------------------------------- - .dw 801Eh -; --------------------------------------------------------------------------- - jr z, p7Dloc_43F4 + .dw 801Bh +; --------------------------------------------------------------------------- + ld de, OP1 + ld hl, 8291h + rst 28h +; --------------------------------------------------------------------------- + .dw 801Eh +; --------------------------------------------------------------------------- + jr z, p7Dloc_43F4 p7Dloc_43EC: push af call p7Dsub_4894 - rst 28h -; --------------------------------------------------------------------------- - .dw 8060h -; --------------------------------------------------------------------------- - pop af + rst 28h +; --------------------------------------------------------------------------- + .dw 8060h +; --------------------------------------------------------------------------- + pop af p7Dloc_43F4: - pop hl + pop hl ret ; END OF FUNCTION CHUNK FOR p7Dsub_4442 @@ -897,54 +897,54 @@ p7Dsub_43F6: push af call p7Dsub_5525 - jr nz, P1orAret - push af - inc hl - rst 28h -; --------------------------------------------------------------------------- - .dw 805Ah -; --------------------------------------------------------------------------- - add hl, bc - pop af - push af - rst 28h -; --------------------------------------------------------------------------- - .dw 8051h -; --------------------------------------------------------------------------- - ld (unk_83E6), a - inc hl - pop af - rst 28h -; --------------------------------------------------------------------------- - .dw 8051h -; --------------------------------------------------------------------------- - ld (unk_83E7), a - pop af - rst 28h -; --------------------------------------------------------------------------- - .dw 809Fh -; --------------------------------------------------------------------------- - ld hl, tempSwapArea - rst 28h -; --------------------------------------------------------------------------- - .dw 80A2h -; --------------------------------------------------------------------------- - rst 28h -; --------------------------------------------------------------------------- - .dw 80A5h -; --------------------------------------------------------------------------- - ld de, MD5Buffer - ld hl, OP1 - rst 28h -; --------------------------------------------------------------------------- - .dw 801Eh + jr nz, P1orAret + push af + inc hl + rst 28h +; --------------------------------------------------------------------------- + .dw 805Ah +; --------------------------------------------------------------------------- + add hl, bc + pop af + push af + rst 28h +; --------------------------------------------------------------------------- + .dw 8051h +; --------------------------------------------------------------------------- + ld (unk_83E6), a + inc hl + pop af + rst 28h +; --------------------------------------------------------------------------- + .dw 8051h +; --------------------------------------------------------------------------- + ld (unk_83E7), a + pop af + rst 28h +; --------------------------------------------------------------------------- + .dw 809Fh +; --------------------------------------------------------------------------- + ld hl, tempSwapArea + rst 28h +; --------------------------------------------------------------------------- + .dw 80A2h +; --------------------------------------------------------------------------- + rst 28h +; --------------------------------------------------------------------------- + .dw 80A5h +; --------------------------------------------------------------------------- + ld de, MD5Buffer + ld hl, OP1 + rst 28h +; --------------------------------------------------------------------------- + .dw 801Eh ; --------------------------------------------------------------------------- ret ; --------------------------------------------------------------------------- P1orAret: - pop af - or a + pop af + or a ret ; End of function p7Dsub_43F6 @@ -953,24 +953,24 @@ p7Dloc_442C: push hl push af - ld c, a - ld de, 400h - rst 28h -; --------------------------------------------------------------------------- - .dw 805Dh -; --------------------------------------------------------------------------- - jr nz, locret_4441 - inc hl - ld a, c - push de - rst 28h -; --------------------------------------------------------------------------- - .dw 805Ah -; --------------------------------------------------------------------------- - pop de - ex de, hl - pop af - pop hl + ld c, a + ld de, 400h + rst 28h +; --------------------------------------------------------------------------- + .dw 805Dh +; --------------------------------------------------------------------------- + jr nz, locret_4441 + inc hl + ld a, c + push de + rst 28h +; --------------------------------------------------------------------------- + .dw 805Ah +; --------------------------------------------------------------------------- + pop de + ex de, hl + pop af + pop hl locret_4441: ret @@ -985,65 +985,65 @@ push hl push bc call p7Dsub_70D1 - ld de, 800h + ld de, 800h call p7Dsub_777E call p7Dsub_4574 - pop bc - pop de + pop bc + pop de p7Dloc_4452: push de push bc push bc push de - ld de, 810h + ld de, 810h call p7Dsub_7700 - rst 28h -; --------------------------------------------------------------------------- - .dw 8030h -; --------------------------------------------------------------------------- - pop de - ld a, c - pop bc - jr nz, p7Dloc_4489 - cp c - push hl - ld c, a - ld b, 0 - push bc - jr nz, p7Dloc_4482 - ld b, c + rst 28h +; --------------------------------------------------------------------------- + .dw 8030h +; --------------------------------------------------------------------------- + pop de + ld a, c + pop bc + jr nz, p7Dloc_4489 + cp c + push hl + ld c, a + ld b, 0 + push bc + jr nz, p7Dloc_4482 + ld b, c p7Dloc_446D: call p7Dsub_7700 call p7Dsub_4C73 - jr nz, p7Dloc_4482 - inc de - inc hl + jr nz, p7Dloc_4482 + inc de + inc hl djnz p7Dloc_446D - pop bc - pop hl - pop bc - pop de - ld a, 0 - bit 7, a + pop bc + pop hl + pop bc + pop de + ld a, 0 + bit 7, a ret ; --------------------------------------------------------------------------- p7Dloc_4482: - pop bc - pop hl - add hl, bc - pop bc - pop de - jr p7Dloc_4452 + pop bc + pop hl + add hl, bc + pop bc + pop de + jr p7Dloc_4452 ; --------------------------------------------------------------------------- p7Dloc_4489: - pop bc - pop de - ld a, 0FFh - bit 7, a + pop bc + pop de + ld a, 0FFh + bit 7, a ret ; End of function p7Dsub_4442 @@ -1055,8 +1055,8 @@ push hl push bc call p7Dsub_4442 - pop bc - pop hl + pop bc + pop hl ret ; End of function p7Dsub_4490 @@ -1070,26 +1070,26 @@ call p7Dsub_7700 call p7Dsub_4873 call p7Dsub_70D1 - jr nz, p7Dloc_44B8 + jr nz, p7Dloc_44B8 call p7Dsub_7700 push bc call p7Dsub_4873 push bc - pop hl - pop bc - or a - sbc hl, bc - jr nc, p7Dloc_44BE + pop hl + pop bc + or a + sbc hl, bc + jr nc, p7Dloc_44BE p7Dloc_44B8: - ld a, 0 - bit 7, a - jr locret_44C2 + ld a, 0 + bit 7, a + jr locret_44C2 ; --------------------------------------------------------------------------- p7Dloc_44BE: - ld a, 0FFh - bit 7, a + ld a, 0FFh + bit 7, a locret_44C2: ret @@ -1103,41 +1103,41 @@ call p7Dloc_442C push de push bc - ld de, 0A10h - rst 28h -; --------------------------------------------------------------------------- - .dw 8027h + ld de, 0A10h + rst 28h +; --------------------------------------------------------------------------- + .dw 8027h ; --------------------------------------------------------------------------- push de call p7Dsub_4574 - pop de - ld a, c - pop bc - cp c - jr nz, p7Dloc_44F7 - ex de, hl - pop hl - ld b, c + pop de + ld a, c + pop bc + cp c + jr nz, p7Dloc_44F7 + ex de, hl + pop hl + ld b, c p7Dloc_44E1: - ex de, hl + ex de, hl call p7Dsub_4566 - ld c, a - ex de, hl + ld c, a + ex de, hl call p7Dsub_4566 - cp c - jr nz, locret_44F8 - dec b - ld a, b - cp 0 - jr z, locret_44F8 - inc hl - inc de - jr p7Dloc_44E1 + cp c + jr nz, locret_44F8 + dec b + ld a, b + cp 0 + jr z, locret_44F8 + inc hl + inc de + jr p7Dloc_44E1 ; --------------------------------------------------------------------------- p7Dloc_44F7: - pop bc + pop bc locret_44F8: ret @@ -1145,42 +1145,42 @@ Page7D_2BFE: push af - ld a, 1 + ld a, 1 nop di nop nop im 1 di - out (14h), a + out (14h), a di call checkForFlashTrickery - pop af + pop af call p7Dsub_7700 call p7Dsub_4894 call p7Dsub_4574 call p7Dsub_7700 call p7Dsub_50C5 - jr nz, p7Dloc_4530 - ld de, 320h - rst 28h -; --------------------------------------------------------------------------- - .dw 8027h -; --------------------------------------------------------------------------- - jr nz, p7Dloc_4529 + jr nz, p7Dloc_4530 + ld de, 320h + rst 28h +; --------------------------------------------------------------------------- + .dw 8027h +; --------------------------------------------------------------------------- + jr nz, p7Dloc_4529 call p7Dsub_7700 - rst 28h -; --------------------------------------------------------------------------- - .dw 802Ah + rst 28h +; --------------------------------------------------------------------------- + .dw 802Ah ; --------------------------------------------------------------------------- p7Dloc_4529: call p7Dsub_4894 call p7Dsub_5083 - xor a + xor a p7Dloc_4530: - jp relockFlashBack + jp relockFlashBack ; =============== S U B R O U T I N E ======================================= @@ -1188,21 +1188,21 @@ p7Dsub_4533: call Page7D_2B80 call p7Dsub_4566 - ld (unk_8439+1), a - inc hl + ld (unk_8439+1), a + inc hl call p7Dsub_4566 - ld (unk_843B), a + ld (unk_843B), a call NZIf83Plus - ret nz - inc hl + ret nz + inc hl call p7Dsub_7700 - ld bc, 0Bh - ld de, 9C9Eh + ld bc, 0Bh + ld de, 9C9Eh call FlashToRam - ld hl, 9CA8h - ld a, 0FEh ; '�' - or (hl) - ld (hl), a + ld hl, 9CA8h + ld a, 0FEh ; '�' + or (hl) + ld (hl), a ret ; End of function p7Dsub_4533 @@ -1212,9 +1212,9 @@ p7Dsub_455C: call p7Dsub_4565 - ld e, a + ld e, a call p7Dsub_4565 - ld d, a + ld d, a ret ; End of function p7Dsub_455C @@ -1223,7 +1223,7 @@ p7Dsub_4565: - inc hl + inc hl ; End of function p7Dsub_4565 @@ -1244,9 +1244,9 @@ p7Dsub_456D: ; Page7D_2B62+12Cp ... call p7Dsub_7700 - rst 28h -; --------------------------------------------------------------------------- - .dw 8021h + rst 28h +; --------------------------------------------------------------------------- + .dw 8021h ; --------------------------------------------------------------------------- ret ; End of function p7Dsub_456D @@ -1257,13 +1257,13 @@ p7Dsub_4574: ; Page7D_2B62+25p ... - inc hl + inc hl p7Dloc_4575: call p7Dsub_7700 - rst 28h -; --------------------------------------------------------------------------- - .dw 805Ah + rst 28h +; --------------------------------------------------------------------------- + .dw 805Ah ; --------------------------------------------------------------------------- ret ; End of function p7Dsub_4574 @@ -1275,9 +1275,9 @@ p7Dsub_457C: ; Page7D_2B62+126p ... call p7Dsub_7700 - rst 28h -; --------------------------------------------------------------------------- - .dw 8024h + rst 28h +; --------------------------------------------------------------------------- + .dw 8024h ; --------------------------------------------------------------------------- ret ; End of function p7Dsub_457C @@ -1286,68 +1286,68 @@ Page7D_2BD4: push af - ld a, 1 + ld a, 1 nop di nop nop im 1 di - out (14h), a + out (14h), a di call checkForFlashTrickery - pop af + pop af push bc push de push hl push ix call p7Dsub_4533 call p7Dloc_44C3 - jr nz, p7Dloc_45D9 + jr nz, p7Dloc_45D9 call p7Dsub_4498 - jr nz, p7Dloc_45D9 + jr nz, p7Dloc_45D9 call p7Dsub_50A8 p7Dloc_45A9: call p7Dsub_4C8B - res 6, (iy+24h) - xor a - ld (unk_9C87), a + res 6, (iy+24h) + xor a + ld (unk_9C87), a call p7Dsub_70D1 - ld bc, 0 - jr nz, p7Dloc_45BF - rst 28h -; --------------------------------------------------------------------------- - .dw 802Ah + ld bc, 0 + jr nz, p7Dloc_45BF + rst 28h +; --------------------------------------------------------------------------- + .dw 802Ah ; --------------------------------------------------------------------------- p7Dloc_45BF: call p7Dsub_468A call p7Dsub_70D1 call p7Dsub_45E4 - ld a, 0 - bit 7, a + ld a, 0 + bit 7, a p7Dloc_45CC: push af call p7Dsub_4926 - pop af - pop ix - pop hl - pop de - pop bc - jp relockFlashBack + pop af + pop ix + pop hl + pop de + pop bc + jp relockFlashBack ; --------------------------------------------------------------------------- p7Dloc_45D9: call p7Dsub_4894 - rst 28h -; --------------------------------------------------------------------------- - .dw 8060h -; --------------------------------------------------------------------------- - ld a, 0FFh - or a - jr p7Dloc_45CC + rst 28h +; --------------------------------------------------------------------------- + .dw 8060h +; --------------------------------------------------------------------------- + ld a, 0FFh + or a + jr p7Dloc_45CC ; =============== S U B R O U T I N E ======================================= @@ -1355,71 +1355,71 @@ p7Dsub_45E4: push bc push de - ld a, (unk_8439+1) - ld b, a + ld a, (unk_8439+1) + ld b, a call Page7D_2B80 - ex de, hl + ex de, hl call p7Dsub_456D - ld a, (unk_843B) - ld b, a + ld a, (unk_843B) + ld b, a call p7Dsub_456D call NZIf83Plus - jr nz, p7Dloc_4609 + jr nz, p7Dloc_4609 call p7Dsub_7700 - ld bc, 0Bh - ld hl, 9C9Eh - rst 28h -; --------------------------------------------------------------------------- - .dw 8087h + ld bc, 0Bh + ld hl, 9C9Eh + rst 28h +; --------------------------------------------------------------------------- + .dw 8087h ; --------------------------------------------------------------------------- p7Dloc_4609: call p7Dsub_70D1 - jr nz, p7Dloc_464B + jr nz, p7Dloc_464B call p7Dsub_464E call p7Dsub_4574 - add hl, bc + add hl, bc call p7Dsub_70D1 - ld de, 800h + ld de, 800h call p7Dsub_777E call p7Dsub_4574 p7Dloc_4621: - ld de, 810h + ld de, 810h call p7Dsub_7700 - rst 28h -; --------------------------------------------------------------------------- - .dw 8030h -; --------------------------------------------------------------------------- - jr nz, p7Dloc_464B - push hl - push bc - ld b, c - ld (OP2), bc - ld b, 0 + rst 28h +; --------------------------------------------------------------------------- + .dw 8030h +; --------------------------------------------------------------------------- + jr nz, p7Dloc_464B + push hl + push bc + ld b, c + ld (OP2), bc + ld b, 0 call p7Dsub_7700 - ld de, 8484h - rst 28h -; --------------------------------------------------------------------------- - .dw 8054h -; --------------------------------------------------------------------------- - rst 28h -; --------------------------------------------------------------------------- - .dw 8066h -; --------------------------------------------------------------------------- - jr nz, p7Dloc_4646 + ld de, 8484h + rst 28h +; --------------------------------------------------------------------------- + .dw 8054h +; --------------------------------------------------------------------------- + rst 28h +; --------------------------------------------------------------------------- + .dw 8066h +; --------------------------------------------------------------------------- + jr nz, p7Dloc_4646 call p7Dsub_464E p7Dloc_4646: - pop bc - pop hl - add hl, bc - jr p7Dloc_4621 + pop bc + pop hl + add hl, bc + jr p7Dloc_4621 ; --------------------------------------------------------------------------- p7Dloc_464B: - pop de - pop bc + pop de + pop bc ret ; End of function p7Dsub_45E4 @@ -1433,47 +1433,47 @@ push de push hl push ix - rst 28h -; --------------------------------------------------------------------------- - .dw 8099h -; --------------------------------------------------------------------------- - ld de, 700h + rst 28h +; --------------------------------------------------------------------------- + .dw 8099h +; --------------------------------------------------------------------------- + ld de, 700h call p7Dsub_777E call p7Dsub_4574 p7Dloc_4660: - ld de, 710h + ld de, 710h call p7Dsub_705E - jr nz, p7Dloc_4683 + jr nz, p7Dloc_4683 call p7Dsub_4574 push bc push hl call p7Dsub_7700 - ld de, 838Fh - rst 28h -; --------------------------------------------------------------------------- - .dw 8054h -; --------------------------------------------------------------------------- - rst 28h -; --------------------------------------------------------------------------- - .dw 80A8h -; --------------------------------------------------------------------------- - jr z, p7Dloc_467E + ld de, 838Fh + rst 28h +; --------------------------------------------------------------------------- + .dw 8054h +; --------------------------------------------------------------------------- + rst 28h +; --------------------------------------------------------------------------- + .dw 80A8h +; --------------------------------------------------------------------------- + jr z, p7Dloc_467E call p7Dsub_51C3 p7Dloc_467E: - pop hl - pop bc - add hl, bc - jr p7Dloc_4660 + pop hl + pop bc + add hl, bc + jr p7Dloc_4660 ; --------------------------------------------------------------------------- p7Dloc_4683: - pop ix - pop hl - pop de - pop bc - pop af + pop ix + pop hl + pop de + pop bc + pop af ret ; End of function p7Dsub_464E @@ -1486,46 +1486,46 @@ call p7Dsub_4894 push hl call p7Dsub_4574 - add hl, bc + add hl, bc call p7Dsub_4574 - add hl, bc - pop bc - push bc - or a - sbc hl, bc - push hl - pop bc - pop hl - push bc - push hl - ld de, 4000h + add hl, bc + pop bc + push bc + or a + sbc hl, bc + push hl + pop bc + pop hl + push bc + push hl + ld de, 4000h call p7Dsub_42DF - pop hl - push hl - rst 28h -; --------------------------------------------------------------------------- - .dw 8060h -; --------------------------------------------------------------------------- - pop de - pop bc - ld hl, 4000h + pop hl + push hl + rst 28h +; --------------------------------------------------------------------------- + .dw 8060h +; --------------------------------------------------------------------------- + pop de + pop bc + ld hl, 4000h push bc call p7Dsub_42AE call p7Dsub_4894 - pop bc - ex de, hl - ld a, d - xor 20h ; ' ' - ld d, a + pop bc + ex de, hl + ld a, d + xor 20h ; ' ' + ld d, a call p7Dsub_430E - ret z + ret z ; End of function p7Dsub_468A ; START OF FUNCTION CHUNK FOR p7Dsub_5083 p7Dloc_46C1: call relockFlashBack - jp JErrorNo + jp JErrorNo ; END OF FUNCTION CHUNK FOR p7Dsub_5083 ; --------------------------------------------------------------------------- @@ -1533,49 +1533,49 @@ push de push bc call p7Dsub_762A - ld (OP2), bc - ld de, 8484h + ld (OP2), bc + ld de, 8484h call p7Dsub_7700 - rst 28h -; --------------------------------------------------------------------------- - .dw 8054h -; --------------------------------------------------------------------------- - rst 28h -; --------------------------------------------------------------------------- - .dw 8066h -; --------------------------------------------------------------------------- - jr nz, p7Dloc_4715 - push hl - ld de, 100h + rst 28h +; --------------------------------------------------------------------------- + .dw 8054h +; --------------------------------------------------------------------------- + rst 28h +; --------------------------------------------------------------------------- + .dw 8066h +; --------------------------------------------------------------------------- + jr nz, p7Dloc_4715 + push hl + ld de, 100h call p7Dsub_777E - jr nz, p7Dloc_4714 + jr nz, p7Dloc_4714 call p7Dsub_4574 push hl call p7Dsub_4894 - ld de, 100h + ld de, 100h call p7Dsub_777E call p7Dsub_4574 - pop de - ex de, hl + pop de + ex de, hl call p7Dsub_7700 call p7Dsub_5CFF call p7Dsub_5D1E - ex de, hl + ex de, hl call p7Dsub_7700 call p7Dsub_5CFF call p7Dsub_5D43 - ex de, hl - or a - sbc hl, bc - ld a, 0 - bit 7, a + ex de, hl + or a + sbc hl, bc + ld a, 0 + bit 7, a p7Dloc_4714: - pop hl + pop hl p7Dloc_4715: - pop bc - pop de + pop bc + pop de ret ; --------------------------------------------------------------------------- @@ -1584,33 +1584,33 @@ push de push hl call p7Dsub_7634 - inc hl - rst 28h -; --------------------------------------------------------------------------- - .dw 805Ah + inc hl + rst 28h +; --------------------------------------------------------------------------- + .dw 805Ah ; --------------------------------------------------------------------------- call p7Dsub_4490 - jp nz, p7Dloc_47A5 + jp nz, p7Dloc_47A5 call p7Dloc_46C7 - jr nz, p7Dloc_4746 - jp nc, p7Dloc_47A5 - rst 28h -; --------------------------------------------------------------------------- - .dw 8066h -; --------------------------------------------------------------------------- - jr nz, p7Dloc_4746 + jr nz, p7Dloc_4746 + jp nc, p7Dloc_47A5 + rst 28h +; --------------------------------------------------------------------------- + .dw 8066h +; --------------------------------------------------------------------------- + jr nz, p7Dloc_4746 call p7Dsub_50A8 call p7Dloc_46C7 - rst 28h -; --------------------------------------------------------------------------- - .dw 8066h + rst 28h +; --------------------------------------------------------------------------- + .dw 8066h ; --------------------------------------------------------------------------- call p7Dsub_47E3 - rst 28h -; --------------------------------------------------------------------------- - .dw 802Ah -; --------------------------------------------------------------------------- - jr p7Dloc_474C + rst 28h +; --------------------------------------------------------------------------- + .dw 802Ah +; --------------------------------------------------------------------------- + jr p7Dloc_474C ; --------------------------------------------------------------------------- p7Dloc_4746: @@ -1618,77 +1618,77 @@ call p7Dsub_5124 p7Dloc_474C: - ld de, 836Dh + ld de, 836Dh call Page7D_2B80 - ld bc, 20h ; ' ' + ld bc, 20h ; ' ' call p7Dsub_7700 - rst 28h -; --------------------------------------------------------------------------- - .dw 8054h + rst 28h +; --------------------------------------------------------------------------- + .dw 8054h ; --------------------------------------------------------------------------- call p7Dsub_521D - ld bc, 0Dh + ld bc, 0Dh sla c call p7Dsub_7700 - ld de, tempSwapArea - rst 28h -; --------------------------------------------------------------------------- - .dw 8054h + ld de, tempSwapArea + rst 28h +; --------------------------------------------------------------------------- + .dw 8054h ; --------------------------------------------------------------------------- call p7Dsub_762A - ld (appID), bc - ld de, 838Eh + ld (appID), bc + ld de, 838Eh call p7Dsub_7700 - rst 28h -; --------------------------------------------------------------------------- - .dw 8054h + rst 28h +; --------------------------------------------------------------------------- + .dw 8054h ; --------------------------------------------------------------------------- call p7Dsub_468A - ld bc, (appID) - ld b, 0 - ld (OP2), bc - ld hl, 838Eh - ld de, 8484h + ld bc, (appID) + ld b, 0 + ld (OP2), bc + ld hl, 838Eh + ld de, 8484h ldir - rst 28h -; --------------------------------------------------------------------------- - .dw 8066h + rst 28h +; --------------------------------------------------------------------------- + .dw 8066h ; --------------------------------------------------------------------------- call p7Dsub_45E4 call p7Dsub_4894 - rst 28h -; --------------------------------------------------------------------------- - .dw 8060h + rst 28h +; --------------------------------------------------------------------------- + .dw 8060h ; --------------------------------------------------------------------------- p7Dloc_479D: call p7Dsub_4926 - pop hl - pop de - pop bc - xor a + pop hl + pop de + pop bc + xor a ret ; --------------------------------------------------------------------------- p7Dloc_47A5: call p7Dsub_4894 - rst 28h -; --------------------------------------------------------------------------- - .dw 8060h + rst 28h +; --------------------------------------------------------------------------- + .dw 8060h ; --------------------------------------------------------------------------- call p7Dsub_4926 - pop hl - pop de - pop bc - ld a, 0FFh - or a + pop hl + pop de + pop bc + ld a, 0FFh + or a ret ; =============== S U B R O U T I N E ======================================= p7Dsub_47B5: - xor a + xor a ; End of function p7Dsub_47B5 @@ -1702,20 +1702,20 @@ push hl push ix call NZIf83Plus - jr nz, p7Dloc_47D9 - cp 1 - jr z, p7Dloc_47D1 - cp 3 - jr nz, p7Dloc_47D9 + jr nz, p7Dloc_47D9 + cp 1 + jr z, p7Dloc_47D1 + cp 3 + jr nz, p7Dloc_47D9 call p7Dsub_4243 call p7Dsub_4253 - jr p7Dloc_47DC + jr p7Dloc_47DC ; --------------------------------------------------------------------------- p7Dloc_47D1: call p7Dsub_4274 call p7Dsub_4253 - jr p7Dloc_47DC + jr p7Dloc_47DC ; --------------------------------------------------------------------------- p7Dloc_47D9: @@ -1724,11 +1724,11 @@ p7Dloc_47DC: ; Page7D_2B86+21j - pop ix - pop hl - pop de - pop bc - pop af + pop ix + pop hl + pop de + pop bc + pop af ret ; End of function Page7D_2B86 @@ -1742,67 +1742,67 @@ push de push af call p7Dsub_47B5 - ld de, 700h + ld de, 700h call p7Dsub_777E call p7Dsub_4574 push hl call p7Dsub_4894 - ld de, 700h + ld de, 700h call p7Dsub_777E call p7Dsub_4574 - pop de + pop de push hl push de call p7Dsub_762A push hl push bc call p7Dsub_484E - inc ix - pop bc - pop hl + inc ix + pop bc + pop hl push ix call p7Dsub_4442 - add hl, bc + add hl, bc call p7Dsub_7700 - ld de, 810h - rst 28h -; --------------------------------------------------------------------------- - .dw 8030h -; --------------------------------------------------------------------------- - jr nz, p7Dloc_4825 + ld de, 810h + rst 28h +; --------------------------------------------------------------------------- + .dw 8030h +; --------------------------------------------------------------------------- + jr nz, p7Dloc_4825 call p7Dsub_484E - jr p7Dloc_483E + jr p7Dloc_483E ; --------------------------------------------------------------------------- p7Dloc_4825: - ld hl, appID - ld a, 0FFh - ld b, 5 + ld hl, appID + ld a, 0FFh + ld b, 5 p7Dloc_482C: - ld (hl), a - inc hl + ld (hl), a + inc hl djnz p7Dloc_482C - ld hl, OP6 - ld (hl), 1 - rst 28h -; --------------------------------------------------------------------------- - .dw 8069h + ld hl, OP6 + ld (hl), 1 + rst 28h +; --------------------------------------------------------------------------- + .dw 8069h ; --------------------------------------------------------------------------- call p7Dsub_764E push hl - pop ix + pop ix p7Dloc_483E: push ix - pop bc - pop ix - pop hl - pop de + pop bc + pop ix + pop hl + pop de push bc call p7Dsub_4D5E - inc ix - jp p7Dloc_5156 + inc ix + jp p7Dloc_5156 ; End of function p7Dsub_47E3 @@ -1810,29 +1810,29 @@ p7Dsub_484E: - ld d, c - set 4, d - ld e, 7 - ld (appID), de - ld de, 838Fh + ld d, c + set 4, d + ld e, 7 + ld (appID), de + ld de, 838Fh call p7Dsub_7700 - rst 28h -; --------------------------------------------------------------------------- - .dw 8054h -; --------------------------------------------------------------------------- - ld hl, OP6 - ld (hl), 1 - rst 28h -; --------------------------------------------------------------------------- - .dw 8069h -; --------------------------------------------------------------------------- - jr z, p7Dloc_486C - dec ix + rst 28h +; --------------------------------------------------------------------------- + .dw 8054h +; --------------------------------------------------------------------------- + ld hl, OP6 + ld (hl), 1 + rst 28h +; --------------------------------------------------------------------------- + .dw 8069h +; --------------------------------------------------------------------------- + jr z, p7Dloc_486C + dec ix p7Dloc_486C: call p7Dsub_764E push hl - pop ix + pop ix ret ; End of function p7Dsub_484E @@ -1845,31 +1845,31 @@ push af push de push af - ld de, 100h - rst 28h -; --------------------------------------------------------------------------- - .dw 805Dh -; --------------------------------------------------------------------------- - jr nz, p7Dloc_488F - pop af - inc hl - rst 28h -; --------------------------------------------------------------------------- - .dw 805Ah + ld de, 100h + rst 28h +; --------------------------------------------------------------------------- + .dw 805Dh +; --------------------------------------------------------------------------- + jr nz, p7Dloc_488F + pop af + inc hl + rst 28h +; --------------------------------------------------------------------------- + .dw 805Ah ; --------------------------------------------------------------------------- call p7Dsub_7700 call p7Dsub_5CFF call p7Dsub_5D43 - jr p7Dloc_4890 + jr p7Dloc_4890 ; --------------------------------------------------------------------------- p7Dloc_488F: - pop af + pop af p7Dloc_4890: - pop de - pop af - pop hl + pop de + pop af + pop hl ret ; End of function p7Dsub_4873 @@ -1879,9 +1879,9 @@ p7Dsub_4894: ; Page7D_2B62+6p ... - rst 28h -; --------------------------------------------------------------------------- - .dw 8057h + rst 28h +; --------------------------------------------------------------------------- + .dw 8057h ; End of function p7Dsub_4894 @@ -1891,10 +1891,10 @@ Page7D_2BEC: ; p7Dsub_4214:p7Dloc_421Dp ... push af - ld a, h - xor 20h ; ' ' - ld h, a - pop af + ld a, h + xor 20h ; ' ' + ld h, a + pop af ret ; End of function Page7D_2BEC @@ -1902,19 +1902,19 @@ Page7D_2CA6: push af - ld a, 1 + ld a, 1 nop di nop nop im 1 di - out (14h), a + out (14h), a di call checkForFlashTrickery - pop af + pop af call p7Dsub_48B5 - jp relockFlashBack + jp relockFlashBack ; =============== S U B R O U T I N E ======================================= @@ -1937,19 +1937,19 @@ push hl push bc push ix - pop hl - ld bc, 0C9h ; '�' - or a - sbc hl, bc - jp nc, Page0Call_2541 - add hl, bc - ld bc, 0 - or a - sbc hl, bc - jp m, Page0Call_2541 - pop bc - pop hl - jp p7Dloc_48EB + pop hl + ld bc, 0C9h ; '�' + or a + sbc hl, bc + jp nc, Page0Call_2541 + add hl, bc + ld bc, 0 + or a + sbc hl, bc + jp m, Page0Call_2541 + pop bc + pop hl + jp p7Dloc_48EB ; End of function p7Dsub_48BC @@ -1962,28 +1962,28 @@ push de push bc call p7Dsub_521D - ld bc, 0Dh - add ix, bc + ld bc, 0Dh + add ix, bc p7Dloc_48EB: push ix - pop bc + pop bc sla c - add hl, bc + add hl, bc call p7Dsub_4566 - cp 80h ; '�' + cp 80h ; '�' scf - jr z, p7Dloc_4902 - cp 0 - jr nz, p7Dloc_4902 + jr z, p7Dloc_4902 + cp 0 + jr nz, p7Dloc_4902 call p7Dsub_4565 - cp 0 + cp 0 p7Dloc_4902: - pop bc - pop de - pop hl - pop ix + pop bc + pop de + pop hl + pop ix ret ; End of function p7Dsub_48DE @@ -1991,25 +1991,25 @@ Page7D_3E9A: push af - ld a, 1 + ld a, 1 nop di nop nop im 1 di - out (14h), a + out (14h), a di call checkForFlashTrickery - pop af + pop af call Page7D_2B56 - ld a, b - rst 28h -; --------------------------------------------------------------------------- - .dw 80CFh + ld a, b + rst 28h +; --------------------------------------------------------------------------- + .dw 80CFh ; --------------------------------------------------------------------------- call p7Dsub_4926 - jp relockFlashBack + jp relockFlashBack ; =============== S U B R O U T I N E ======================================= @@ -2021,58 +2021,58 @@ push hl push de push ix - ld a, 0 - ld (ioFlag), a + ld a, 0 + ld (ioFlag), a call p7Dsub_4AC9 - jr nz, p7Dloc_4939 + jr nz, p7Dloc_4939 call p7Dloc_4B82 p7Dloc_4939: call p7Dsub_4A5A - ld a, (ioFlag) - cp 0 - jr z, p7Dloc_498B - ld hl, aHaveExpired_ - ld a, 4Dh ; 'M' - bit 1, (iy+35h) + ld a, (ioFlag) + cp 0 + jr z, p7Dloc_498B + ld hl, aHaveExpired_ + ld a, 4Dh ; 'M' + bit 1, (iy+35h) call nz, Page0Call_3C45 call p7Dsub_7045 call Page0Call_3CD5 - ld hl, aDeleting___ - ld a, 4Eh ; 'N' - bit 1, (iy+35h) + ld hl, aDeleting___ + ld a, 4Eh ; 'N' + bit 1, (iy+35h) call nz, Page0Call_3C45 call p7Dsub_7045 call Page0Call_3CD5 call page0_B93 - ld b, 5 + ld b, 5 p7Dloc_496C: - ld c, b - ld b, 0FFh + ld c, b + ld b, 0FFh p7Dloc_496F: - ld a, 0FFh + ld a, 0FFh p7Dloc_4971: call page0_AC4 - dec a - jr nz, p7Dloc_4971 + dec a + jr nz, p7Dloc_4971 djnz p7Dloc_496F - ld b, c + ld b, c djnz p7Dloc_496C call page0_BA2 call Page0Call_2E65 - ld hl, 0 - ld (curRow), hl + ld hl, 0 + ld (curRow), hl call Page0Call_3D05 p7Dloc_498B: - pop ix - pop de - pop hl - pop bc - pop af + pop ix + pop de + pop hl + pop bc + pop af ret ; End of function p7Dsub_4926 @@ -2087,29 +2087,29 @@ push hl call p7Dsub_4565 push af - and 0F0h ; '�' - ld c, a - pop af - xor c - ld (appID), a - inc hl - ld c, a - ld b, 0 + and 0F0h ; '�' + ld c, a + pop af + xor c + ld (appID), a + inc hl + ld c, a + ld b, 0 call p7Dsub_7700 - ld de, 838Eh - rst 28h -; --------------------------------------------------------------------------- - .dw 8054h + ld de, 838Eh + rst 28h +; --------------------------------------------------------------------------- + .dw 8054h ; --------------------------------------------------------------------------- call p7Dsub_6021 - jr c, p7Dloc_49B7 + jr c, p7Dloc_49B7 call Page7D_2BE6 p7Dloc_49B7: - pop hl - pop de - pop bc - pop af + pop hl + pop de + pop bc + pop af ret ; End of function p7Dsub_4992 @@ -2119,28 +2119,28 @@ push bc push af call p7Dsub_4A21 - jr nz, p7Dloc_49D5 - pop af + jr nz, p7Dloc_49D5 + pop af call CopyFlashPage - pop bc - push af - ld a, 0 - dec c - or c - jr z, p7Dloc_49D3 - pop af - inc a - jr p7Dloc_49BC + pop bc + push af + ld a, 0 + dec c + or c + jr z, p7Dloc_49D3 + pop af + inc a + jr p7Dloc_49BC ; --------------------------------------------------------------------------- p7Dloc_49D3: - pop af + pop af ret ; --------------------------------------------------------------------------- p7Dloc_49D5: - pop bc - pop bc + pop bc + pop bc ret ; =============== S U B R O U T I N E ======================================= @@ -2148,56 +2148,56 @@ CopyFlashPage: push hl - ld hl, 4000h + ld hl, 4000h push af call Page7D_2CD0 - cp 0FFh - jr z, p7Dloc_4A1E - pop af - push af - cp 7Eh ; '~' - jr z, p7Dloc_4A1E - cp 7Fh ; '' - jr z, p7Dloc_4A1E - ld a, b - cp 7Eh ; '~' - jr z, p7Dloc_4A1E - cp 7Fh ; '' - jr z, p7Dloc_4A1E - pop af + cp 0FFh + jr z, p7Dloc_4A1E + pop af + push af + cp 7Eh ; '~' + jr z, p7Dloc_4A1E + cp 7Fh ; '' + jr z, p7Dloc_4A1E + ld a, b + cp 7Eh ; '~' + jr z, p7Dloc_4A1E + cp 7Fh ; '' + jr z, p7Dloc_4A1E + pop af p7Dloc_49F8: push bc - ld bc, 100h - ld de, ramStart + ld bc, 100h + ld de, ramStart push hl push de push af call FlashToRam - pop af - pop de - pop hl - pop bc - push af - ld a, b - ld bc, 100h - ex de, hl + pop af + pop de + pop hl + pop bc + push af + ld a, b + ld bc, 100h + ex de, hl push af call p7Dsub_7666 - pop af - ex de, hl - ld b, a - ld a, 80h ; '�' - cp h - jr z, p7Dloc_4A1E - pop af - jr p7Dloc_49F8 + pop af + ex de, hl + ld b, a + ld a, 80h ; '�' + cp h + jr z, p7Dloc_4A1E + pop af + jr p7Dloc_49F8 ; --------------------------------------------------------------------------- p7Dloc_4A1E: ; CopyFlashPage+10j ... - pop af - pop hl + pop af + pop hl ret ; End of function CopyFlashPage @@ -2207,30 +2207,30 @@ p7Dsub_4A21: push hl - ld a, 8 - ld hl, 4000h + ld a, 8 + ld hl, 4000h p7Dloc_4A27: push af - rst 28h -; --------------------------------------------------------------------------- - .dw 8051h -; --------------------------------------------------------------------------- - cp 0FEh ; '�' - jr z, p7Dloc_4A3C - pop af - inc a + rst 28h +; --------------------------------------------------------------------------- + .dw 8051h +; --------------------------------------------------------------------------- + cp 0FEh ; '�' + jr z, p7Dloc_4A3C + pop af + inc a call p7Dsub_75E1 - jr nz, p7Dloc_4A27 - ld a, 0FFh - bit 7, a - pop hl + jr nz, p7Dloc_4A27 + ld a, 0FFh + bit 7, a + pop hl ret ; --------------------------------------------------------------------------- p7Dloc_4A3C: - pop bc - pop hl + pop bc + pop hl ret ; End of function p7Dsub_4A21 @@ -2242,28 +2242,28 @@ ; Page7D_2B56+1Cp ... push hl push af - ld hl, 4000h - ld de, 8080h - or a - rst 28h -; --------------------------------------------------------------------------- - .dw 80ABh -; --------------------------------------------------------------------------- - ld c, 0 - jr nz, p7Dloc_4A57 - inc hl - inc hl - pop af - push af - rst 28h -; --------------------------------------------------------------------------- - .dw 8051h -; --------------------------------------------------------------------------- - ld c, a + ld hl, 4000h + ld de, 8080h + or a + rst 28h +; --------------------------------------------------------------------------- + .dw 80ABh +; --------------------------------------------------------------------------- + ld c, 0 + jr nz, p7Dloc_4A57 + inc hl + inc hl + pop af + push af + rst 28h +; --------------------------------------------------------------------------- + .dw 8051h +; --------------------------------------------------------------------------- + ld c, a p7Dloc_4A57: - pop af - pop hl + pop af + pop hl ret ; End of function FindAppNumPages @@ -2273,39 +2273,39 @@ p7Dsub_4A5A: call p7Dsub_7643 - ld b, c + ld b, c call p7Dsub_75EC p7Dloc_4A61: push af - ld hl, 4000h - rst 28h -; --------------------------------------------------------------------------- - .dw 8051h -; --------------------------------------------------------------------------- - cp 0FFh - jr z, p7Dloc_4A77 - cp 0 - jr z, p7Dloc_4A77 - cp 80h ; '�' - jr nz, p7Dloc_4A77 - pop af - jr p7Dloc_4A80 + ld hl, 4000h + rst 28h +; --------------------------------------------------------------------------- + .dw 8051h +; --------------------------------------------------------------------------- + cp 0FFh + jr z, p7Dloc_4A77 + cp 0 + jr z, p7Dloc_4A77 + cp 80h ; '�' + jr nz, p7Dloc_4A77 + pop af + jr p7Dloc_4A80 ; --------------------------------------------------------------------------- p7Dloc_4A77: - pop af + pop af p7Dloc_4A78: - dec a + dec a djnz p7Dloc_4A61 ret ; --------------------------------------------------------------------------- p7Dloc_4A7C: - pop af - pop bc - jr p7Dloc_4A77 + pop af + pop bc + jr p7Dloc_4A77 ; --------------------------------------------------------------------------- p7Dloc_4A80: @@ -2313,49 +2313,49 @@ push bc push af call Page0Call_3E31 - jr nz, p7Dloc_4A7C - pop af + jr nz, p7Dloc_4A7C + pop af push af call p7Dsub_5E31 - rst 28h -; --------------------------------------------------------------------------- - .dw 80A8h -; --------------------------------------------------------------------------- - jr nz, p7Dloc_4AC4 - pop af + rst 28h +; --------------------------------------------------------------------------- + .dw 80A8h +; --------------------------------------------------------------------------- + jr nz, p7Dloc_4AC4 + pop af push af call p7Dsub_52D9 - jr c, p7Dloc_4AC4 - jr z, p7Dloc_4AC4 - pop af - push af - ld b, a + jr c, p7Dloc_4AC4 + jr z, p7Dloc_4AC4 + pop af + push af + ld b, a call p7Dsub_75EC - sub b - ld bc, 0 - ld c, a - push bc - pop ix + sub b + ld bc, 0 + ld c, a + push bc + pop ix call p7Dsub_48B5 - jr c, p7Dloc_4AC4 - jr nz, p7Dloc_4AC4 - ld a, (ioFlag) - cp 0 - jr nz, p7Dloc_4ABF + jr c, p7Dloc_4AC4 + jr nz, p7Dloc_4AC4 + ld a, (ioFlag) + cp 0 + jr nz, p7Dloc_4ABF call Page0Call_2C7F - ld a, 0FFh - ld (ioFlag), a + ld a, 0FFh + ld (ioFlag), a p7Dloc_4ABF: - pop af + pop af push af call Page7D_2BE6 p7Dloc_4AC4: - pop af - pop bc - pop af - jr p7Dloc_4A78 + pop af + pop bc + pop af + jr p7Dloc_4A78 ; End of function p7Dsub_4A5A @@ -2364,106 +2364,106 @@ p7Dsub_4AC9: call p7Dsub_70D1 - jp nz, p7Dloc_4B69 - ld de, 700h + jp nz, p7Dloc_4B69 + ld de, 700h call p7Dsub_777E call p7Dsub_4574 - ld ix, 0 + ld ix, 0 p7Dloc_4ADC: - ld de, 710h + ld de, 710h call p7Dsub_705E - jp nz, p7Dloc_4B6E + jp nz, p7Dloc_4B6E push hl call p7Dsub_4574 - ld a, c - ld (appID+1), a - ld de, 838Fh + ld a, c + ld (appID+1), a + ld de, 838Fh call p7Dsub_424C - rst 28h -; --------------------------------------------------------------------------- - .dw 80A8h -; --------------------------------------------------------------------------- - pop hl - push hl - jr z, p7Dloc_4B5F - ld de, 740h + rst 28h +; --------------------------------------------------------------------------- + .dw 80A8h +; --------------------------------------------------------------------------- + pop hl + push hl + jr z, p7Dloc_4B5F + ld de, 740h call p7Dsub_705E - jr nz, p7Dloc_4B14 + jr nz, p7Dloc_4B14 call p7Dsub_7700 call p7Dsub_50C5 - jr z, p7Dloc_4B14 + jr z, p7Dloc_4B14 call p7Dsub_536F call p7Dsub_48DE - jr c, p7Dloc_4B14 - jr z, p7Dloc_4B20 + jr c, p7Dloc_4B14 + jr z, p7Dloc_4B20 p7Dloc_4B14: call p7Dsub_540C - jr z, p7Dloc_4B5F - pop hl + jr z, p7Dloc_4B5F + pop hl push hl call p7Dsub_4992 - jr p7Dloc_4B5F + jr p7Dloc_4B5F ; --------------------------------------------------------------------------- p7Dloc_4B20: - ld a, (ioFlag) - cp 0 - jr nz, p7Dloc_4B3D - pop de + ld a, (ioFlag) + cp 0 + jr nz, p7Dloc_4B3D + pop de push de push hl call p7Dsub_4B73 call p7Dsub_6021 - jr c, p7Dloc_4B51 - pop hl - pop de + jr c, p7Dloc_4B51 + pop hl + pop de push de call Page0Call_2C7F - ld a, 0FFh - ld (ioFlag), a + ld a, 0FFh + ld (ioFlag), a p7Dloc_4B3D: - pop de + pop de push de push hl call p7Dsub_4B73 call p7Dsub_6021 - jr c, p7Dloc_4B51 + jr c, p7Dloc_4B51 call Page0Call_2C8B call Page0Call_3CD5 call Page7D_2BE6 p7Dloc_4B51: - pop hl - pop de - ex de, hl + pop hl + pop de + ex de, hl push de call p7Dsub_4574 - pop de - add hl, bc - inc ix - jp p7Dloc_4ADC + pop de + add hl, bc + inc ix + jp p7Dloc_4ADC ; --------------------------------------------------------------------------- p7Dloc_4B5F: - pop hl + pop hl call p7Dsub_4574 - add hl, bc - inc ix - jp p7Dloc_4ADC + add hl, bc + inc ix + jp p7Dloc_4ADC ; --------------------------------------------------------------------------- p7Dloc_4B69: - ld a, 0FFh - bit 7, a + ld a, 0FFh + bit 7, a ret ; --------------------------------------------------------------------------- p7Dloc_4B6E: - ld a, 0 - bit 7, a + ld a, 0 + bit 7, a ret ; End of function p7Dsub_4AC9 @@ -2472,11 +2472,11 @@ p7Dsub_4B73: - ex de, hl + ex de, hl call p7Dsub_4574 - ld a, c - ld (appID), a - ld de, 838Eh + ld a, c + ld (appID), a + ld de, 838Eh call p7Dsub_424C ret ; End of function p7Dsub_4B73 @@ -2485,84 +2485,84 @@ p7Dloc_4B82: call p7Dsub_70D1 - ld de, 800h + ld de, 800h call p7Dsub_777E call p7Dsub_4574 p7Dloc_4B8E: - ld de, 810h + ld de, 810h call p7Dsub_705E - jp nz, locret_4C0B - push hl - ld de, 840h + jp nz, locret_4C0B + push hl + ld de, 840h call p7Dsub_705E - jr nz, p7Dloc_4BC9 + jr nz, p7Dloc_4BC9 call p7Dsub_7700 call p7Dsub_50C5 - jr z, p7Dloc_4BE4 + jr z, p7Dloc_4BE4 call p7Dsub_536F call p7Dsub_48DE - jr c, p7Dloc_4BC9 - jr nz, p7Dloc_4BE4 - ld a, (ioFlag) - cp 0 - jr nz, p7Dloc_4BC9 + jr c, p7Dloc_4BC9 + jr nz, p7Dloc_4BE4 + ld a, (ioFlag) + cp 0 + jr nz, p7Dloc_4BC9 call Page0Call_2C7F - ld a, 0FFh - ld (ioFlag), a - pop de + ld a, 0FFh + ld (ioFlag), a + pop de push de call Page0Call_2C85 call Page0Call_3CD5 p7Dloc_4BC9: - pop de - ex de, hl + pop de + ex de, hl push hl call p7Dsub_4574 - ld de, 8484h - ld (OP2), bc + ld de, 8484h + ld (OP2), bc call p7Dsub_7700 - rst 28h -; --------------------------------------------------------------------------- - .dw 8054h -; --------------------------------------------------------------------------- - rst 28h -; --------------------------------------------------------------------------- - .dw 8066h -; --------------------------------------------------------------------------- - jr nz, p7Dloc_4BE4 - rst 28h -; --------------------------------------------------------------------------- - .dw 802Ah + rst 28h +; --------------------------------------------------------------------------- + .dw 8054h +; --------------------------------------------------------------------------- + rst 28h +; --------------------------------------------------------------------------- + .dw 8066h +; --------------------------------------------------------------------------- + jr nz, p7Dloc_4BE4 + rst 28h +; --------------------------------------------------------------------------- + .dw 802Ah ; --------------------------------------------------------------------------- p7Dloc_4BE4: - pop de - ex de, hl + pop de + ex de, hl push hl call p7Dsub_4574 - ld de, 8484h - ld (OP2), bc + ld de, 8484h + ld (OP2), bc call p7Dsub_7700 - rst 28h -; --------------------------------------------------------------------------- - .dw 8054h -; --------------------------------------------------------------------------- - rst 28h -; --------------------------------------------------------------------------- - .dw 8066h -; --------------------------------------------------------------------------- - jr nz, p7Dloc_4C01 - inc ix + rst 28h +; --------------------------------------------------------------------------- + .dw 8054h +; --------------------------------------------------------------------------- + rst 28h +; --------------------------------------------------------------------------- + .dw 8066h +; --------------------------------------------------------------------------- + jr nz, p7Dloc_4C01 + inc ix call p7Dsub_4C0C p7Dloc_4C01: - pop hl + pop hl call p7Dsub_4574 - add hl, bc - inc ix - jp p7Dloc_4B8E + add hl, bc + inc ix + jp p7Dloc_4B8E ; --------------------------------------------------------------------------- locret_4C0B: @@ -2572,70 +2572,70 @@ p7Dsub_4C0C: - ld de, 700h + ld de, 700h call p7Dsub_777E call p7Dsub_4574 p7Dloc_4C15: - ld de, 710h + ld de, 710h call p7Dsub_705E - jr nz, p7Dloc_4C70 - push hl - ld de, 740h + jr nz, p7Dloc_4C70 + push hl + ld de, 740h call p7Dsub_705E - jr nz, p7Dloc_4C38 + jr nz, p7Dloc_4C38 call p7Dsub_7700 call p7Dsub_50C5 - jr z, p7Dloc_4C38 + jr z, p7Dloc_4C38 call p7Dsub_536F call p7Dsub_48DE - jr c, p7Dloc_4C38 - jr z, p7Dloc_4C3B + jr c, p7Dloc_4C38 + jr z, p7Dloc_4C3B p7Dloc_4C38: - pop hl - jr p7Dloc_4C68 + pop hl + jr p7Dloc_4C68 ; --------------------------------------------------------------------------- p7Dloc_4C3B: - ld a, (ioFlag) - cp 0 - jr nz, p7Dloc_4C55 - pop de + ld a, (ioFlag) + cp 0 + jr nz, p7Dloc_4C55 + pop de push de push hl call p7Dsub_6021 - jr c, p7Dloc_4C66 - pop hl - pop de + jr c, p7Dloc_4C66 + pop hl + pop de push de call Page0Call_2C7F - ld a, 0FFh - ld (ioFlag), a + ld a, 0FFh + ld (ioFlag), a p7Dloc_4C55: - pop de + pop de push de push hl call p7Dsub_6021 - jr c, p7Dloc_4C66 + jr c, p7Dloc_4C66 call Page0Call_2C8B call Page0Call_3CD5 call Page7D_2BE6 p7Dloc_4C66: - pop hl - pop de + pop hl + pop de p7Dloc_4C68: call p7Dsub_4574 - add hl, bc - inc ix - jr p7Dloc_4C15 + add hl, bc + inc ix + jr p7Dloc_4C15 ; --------------------------------------------------------------------------- p7Dloc_4C70: - dec ix + dec ix ret ; End of function p7Dsub_4C0C @@ -2648,22 +2648,22 @@ push de push hl push af - rst 28h -; --------------------------------------------------------------------------- - .dw 8051h -; --------------------------------------------------------------------------- - ld (OP2), a - ex de, hl - pop af - rst 28h -; --------------------------------------------------------------------------- - .dw 8051h -; --------------------------------------------------------------------------- - ld bc, (OP2) - cp c - pop hl - pop de - pop bc + rst 28h +; --------------------------------------------------------------------------- + .dw 8051h +; --------------------------------------------------------------------------- + ld (OP2), a + ex de, hl + pop af + rst 28h +; --------------------------------------------------------------------------- + .dw 8051h +; --------------------------------------------------------------------------- + ld bc, (OP2) + cp c + pop hl + pop de + pop bc ret ; End of function p7Dsub_4C73 @@ -2680,18 +2680,18 @@ call p7Dloc_4D38 call p7Dsub_4CAE call p7Dsub_521D - ld bc, 0Dh + ld bc, 0Dh sla c call p7Dsub_7700 - ld de, tempSwapArea - rst 28h -; --------------------------------------------------------------------------- - .dw 8054h -; --------------------------------------------------------------------------- - pop af - pop bc - pop de - pop hl + ld de, tempSwapArea + rst 28h +; --------------------------------------------------------------------------- + .dw 8054h +; --------------------------------------------------------------------------- + pop af + pop bc + pop de + pop hl ret ; End of function p7Dsub_4C8B @@ -2701,90 +2701,90 @@ p7Dsub_4CAE: call p7Dsub_70D1 - jr nz, p7Dloc_4CF7 - ld de, 800h + jr nz, p7Dloc_4CF7 + ld de, 800h call p7Dsub_777E - jr nz, p7Dloc_4CF7 + jr nz, p7Dloc_4CF7 call p7Dsub_4574 push hl call p7Dsub_4894 - ld de, 800h + ld de, 800h call p7Dsub_777E - jp nz, p7Dloc_4D36 + jp nz, p7Dloc_4D36 call p7Dsub_4574 - pop de - ex de, hl - inc ix + pop de + ex de, hl + inc ix p7Dloc_4CD2: push hl p7Dloc_4CD3: call p7Dsub_4F95 - jr nz, p7Dloc_4CDD + jr nz, p7Dloc_4CDD call p7Dsub_4F10 - jr p7Dloc_4D1D + jr p7Dloc_4D1D ; --------------------------------------------------------------------------- p7Dloc_4CDD: push de push ix - ld de, 810h + ld de, 810h call p7Dsub_7700 - rst 28h -; --------------------------------------------------------------------------- - .dw 8030h -; --------------------------------------------------------------------------- - add hl, bc + rst 28h +; --------------------------------------------------------------------------- + .dw 8030h +; --------------------------------------------------------------------------- + add hl, bc call p7Dsub_705E - pop ix - pop de + pop ix + pop de p7Dloc_4CF0: call nz, p7Dsub_4E44 - jr nz, p7Dloc_4D1D - jr p7Dloc_4CD3 + jr nz, p7Dloc_4D1D + jr p7Dloc_4CD3 ; --------------------------------------------------------------------------- p7Dloc_4CF7: call p7Dsub_4894 - ld de, 800h + ld de, 800h call p7Dsub_777E - jr nz, locret_4D35 - inc ix + jr nz, locret_4D35 + inc ix call p7Dsub_4574 p7Dloc_4D07: - ld de, 810h + ld de, 810h call p7Dsub_705E - jr nz, locret_4D35 - push hl - ex de, hl + jr nz, locret_4D35 + push hl + ex de, hl call p7Dsub_4E44 - pop hl + pop hl call p7Dsub_4574 - add hl, bc - inc ix - jr p7Dloc_4D07 + add hl, bc + inc ix + jr p7Dloc_4D07 ; --------------------------------------------------------------------------- p7Dloc_4D1D: - pop hl - ex de, hl + pop hl + ex de, hl push de call p7Dsub_7700 - ld de, 810h - rst 28h -; --------------------------------------------------------------------------- - .dw 8030h -; --------------------------------------------------------------------------- - add hl, bc + ld de, 810h + rst 28h +; --------------------------------------------------------------------------- + .dw 8030h +; --------------------------------------------------------------------------- + add hl, bc call p7Dsub_705E - pop de - inc ix - jr nz, locret_4D35 - ex de, hl - jr p7Dloc_4CD2 + pop de + inc ix + jr nz, locret_4D35 + ex de, hl + jr p7Dloc_4CD2 ; --------------------------------------------------------------------------- locret_4D35: @@ -2792,7 +2792,7 @@ ; --------------------------------------------------------------------------- p7Dloc_4D36: - pop hl + pop hl ret ; End of function p7Dsub_4CAE @@ -2800,20 +2800,20 @@ p7Dloc_4D38: call p7Dsub_70D1 - jr nz, p7Dloc_4D82 - ld de, 700h + jr nz, p7Dloc_4D82 + ld de, 700h call p7Dsub_777E - jr nz, p7Dloc_4D82 + jr nz, p7Dloc_4D82 call p7Dsub_4574 push hl call p7Dsub_4894 - ld de, 700h + ld de, 700h call p7Dsub_777E - jp nz, p7Dloc_4DCB + jp nz, p7Dloc_4DCB call p7Dsub_4574 - pop de - ex de, hl - ld ix, 0Dh + pop de + ex de, hl + ld ix, 0Dh ; =============== S U B R O U T I N E ======================================= @@ -2825,78 +2825,78 @@ p7Dloc_4D5F: call p7Dsub_4F6E call z, p7Dsub_4EBD - jr z, p7Dloc_4DAF + jr z, p7Dloc_4DAF push de push ix - ld de, 710h - ld a, 7Eh ; '~' - rst 28h -; --------------------------------------------------------------------------- - .dw 8030h -; --------------------------------------------------------------------------- - add hl, bc + ld de, 710h + ld a, 7Eh ; '~' + rst 28h +; --------------------------------------------------------------------------- + .dw 8030h +; --------------------------------------------------------------------------- + add hl, bc call p7Dsub_705E - pop ix - pop de + pop ix + pop de call nz, p7Dsub_4DCD - jr nz, p7Dloc_4DAF - jr p7Dloc_4D5F + jr nz, p7Dloc_4DAF + jr p7Dloc_4D5F ; End of function p7Dsub_4D5E ; --------------------------------------------------------------------------- p7Dloc_4D80: - jr p7Dsub_4D5E + jr p7Dsub_4D5E ; --------------------------------------------------------------------------- p7Dloc_4D82: - ld ix, 0Ch + ld ix, 0Ch call p7Dsub_4894 - ld de, 700h + ld de, 700h call p7Dsub_777E - jp nz, locret_4DCA - inc ix + jp nz, locret_4DCA + inc ix call p7Dsub_4574 p7Dloc_4D97: - ld de, 710h + ld de, 710h call p7Dsub_705E - jr nz, p7Dloc_4DC8 - push hl - ex de, hl + jr nz, p7Dloc_4DC8 + push hl + ex de, hl call p7Dsub_4DCD - pop hl + pop hl call p7Dsub_4574 - or a + or a adc hl, bc - inc ix - jr p7Dloc_4D97 + inc ix + jr p7Dloc_4D97 ; --------------------------------------------------------------------------- ; START OF FUNCTION CHUNK FOR p7Dsub_4DCD p7Dloc_4DAF: - pop hl - ex de, hl - push de - ld a, 7Eh ; '~' - ld de, 710h - rst 28h -; --------------------------------------------------------------------------- - .dw 8030h -; --------------------------------------------------------------------------- - or a + pop hl + ex de, hl + push de + ld a, 7Eh ; '~' + ld de, 710h + rst 28h +; --------------------------------------------------------------------------- + .dw 8030h +; --------------------------------------------------------------------------- + or a adc hl, bc call p7Dsub_705E - pop de - jr nz, locret_4DCA - ex de, hl - inc ix - jr p7Dloc_4D80 + pop de + jr nz, locret_4DCA + ex de, hl + inc ix + jr p7Dloc_4D80 ; END OF FUNCTION CHUNK FOR p7Dsub_4DCD ; --------------------------------------------------------------------------- p7Dloc_4DC8: - dec ix + dec ix ; START OF FUNCTION CHUNK FOR p7Dsub_4DCD locret_4DCA: @@ -2905,7 +2905,7 @@ ; --------------------------------------------------------------------------- p7Dloc_4DCB: - pop hl + pop hl ret ; =============== S U B R O U T I N E ======================================= @@ -2922,85 +2922,85 @@ push ix p7Dloc_4DD2: - res 7, (iy+25h) - ex de, hl - push hl - ld a, 7Eh ; '~' - ld de, 740h - rst 28h -; --------------------------------------------------------------------------- - .dw 8030h -; --------------------------------------------------------------------------- - jr nz, p7Dloc_4DE6 - set 7, (iy+25h) + res 7, (iy+25h) + ex de, hl + push hl + ld a, 7Eh ; '~' + ld de, 740h + rst 28h +; --------------------------------------------------------------------------- + .dw 8030h +; --------------------------------------------------------------------------- + jr nz, p7Dloc_4DE6 + set 7, (iy+25h) p7Dloc_4DE6: - pop hl - ld a, 7Eh ; '~' - ld de, 760h - rst 28h -; --------------------------------------------------------------------------- - .dw 8030h -; --------------------------------------------------------------------------- - jr z, p7Dloc_4E01 - bit 7, (iy+25h) - jr z, p7Dloc_4DFC - ld de, 0 - jr p7Dloc_4E27 + pop hl + ld a, 7Eh ; '~' + ld de, 760h + rst 28h +; --------------------------------------------------------------------------- + .dw 8030h +; --------------------------------------------------------------------------- + jr z, p7Dloc_4E01 + bit 7, (iy+25h) + jr z, p7Dloc_4DFC + ld de, 0 + jr p7Dloc_4E27 ; --------------------------------------------------------------------------- p7Dloc_4DFC: - ld de, 80h ; '�' - jr p7Dloc_4E27 + ld de, 80h ; '�' + jr p7Dloc_4E27 ; --------------------------------------------------------------------------- p7Dloc_4E01: - ld a, c - or b - ld a, 0 - jr z, p7Dloc_4E0A + ld a, c + or b + ld a, 0 + jr z, p7Dloc_4E0A call p7Dsub_4566 p7Dloc_4E0A: push af - ld b, 9 - sub b - jr c, p7Dloc_4E20 - pop af - ld b, 8 - sub b + ld b, 9 + sub b + jr c, p7Dloc_4E20 + pop af + ld b, 8 + sub b call p7Dsub_4E9B - ld d, a - ld a, 8 + ld d, a + ld a, 8 call p7Dsub_4E9B - ld e, a - jr p7Dloc_4E27 + ld e, a + jr p7Dloc_4E27 ; --------------------------------------------------------------------------- p7Dloc_4E20: - ld d, 0 - pop af + ld d, 0 + pop af call p7Dsub_4E9B - ld e, a + ld e, a p7Dloc_4E27: - ld hl, tempSwapArea + ld hl, tempSwapArea push ix - pop bc + pop bc sla c - ld b, 0 - or a + ld b, 0 + or a adc hl, bc - ld (hl), e - inc hl - ld (hl), d - ld a, 0FFh - or a - res 7, (iy+25h) - pop ix - pop de - pop hl - pop bc + ld (hl), e + inc hl + ld (hl), d + ld a, 0FFh + or a + res 7, (iy+25h) + pop ix + pop de + pop hl + pop bc ret ; End of function p7Dsub_4DCD @@ -3015,65 +3015,65 @@ push hl push de push ix - ex de, hl - ld a, 7Eh ; '~' - ld de, 860h - rst 28h -; --------------------------------------------------------------------------- - .dw 8030h -; --------------------------------------------------------------------------- - jr z, p7Dloc_4E5A - ld de, 80h ; '�' - jr p7Dloc_4E80 + ex de, hl + ld a, 7Eh ; '~' + ld de, 860h + rst 28h +; --------------------------------------------------------------------------- + .dw 8030h +; --------------------------------------------------------------------------- + jr z, p7Dloc_4E5A + ld de, 80h ; '�' + jr p7Dloc_4E80 ; --------------------------------------------------------------------------- p7Dloc_4E5A: - ld a, c - or b - ld a, 0 - jr z, p7Dloc_4E63 + ld a, c + or b + ld a, 0 + jr z, p7Dloc_4E63 call p7Dsub_4566 p7Dloc_4E63: push af - ld b, 9 - sub b - jr c, p7Dloc_4E79 - pop af - ld b, 8 - sub b + ld b, 9 + sub b + jr c, p7Dloc_4E79 + pop af + ld b, 8 + sub b call p7Dsub_4E9B - ld d, a - ld a, 8 + ld d, a + ld a, 8 call p7Dsub_4E9B - ld e, a - jr p7Dloc_4E80 + ld e, a + jr p7Dloc_4E80 ; --------------------------------------------------------------------------- p7Dloc_4E79: - ld d, 0 - pop af + ld d, 0 + pop af call p7Dsub_4E9B - ld e, a + ld e, a p7Dloc_4E80: - ld hl, tempSwapArea + ld hl, tempSwapArea push ix - pop bc + pop bc sla c - ld b, 0 - or a + ld b, 0 + or a adc hl, bc - ld (hl), e - inc hl - ld (hl), d - ld a, 0FFh - bit 7, a - pop ix - pop de - pop hl - pop bc - pop af + ld (hl), e + inc hl + ld (hl), d + ld a, 0FFh + bit 7, a + pop ix + pop de + pop hl + pop bc + pop af ret ; End of function p7Dsub_4E44 @@ -3083,32 +3083,32 @@ p7Dsub_4E9B: push bc - ld c, 11h - sub c - jp nc, p7Dloc_4EB9 - or a + ld c, 11h + sub c + jp nc, p7Dloc_4EB9 + or a adc a, c - cp 0 - jr z, p7Dloc_4EB9 - cp 1 - jr z, p7Dloc_4EBB - ld b, a - dec b - ld a, 2 + cp 0 + jr z, p7Dloc_4EB9 + cp 1 + jr z, p7Dloc_4EBB + ld b, a + dec b + ld a, 2 p7Dloc_4EB0: sla a djnz p7Dloc_4EB0 - ld b, 1 - sub b - jr p7Dloc_4EBB + ld b, 1 + sub b + jr p7Dloc_4EBB ; --------------------------------------------------------------------------- p7Dloc_4EB9: - ld a, 0 + ld a, 0 p7Dloc_4EBB: - pop bc + pop bc ret ; End of function p7Dsub_4E9B @@ -3122,12 +3122,12 @@ push hl push de push ix - ld de, 710h + ld de, 710h call p7Dsub_4ECE - pop ix - pop de - pop hl - pop af + pop ix + pop de + pop hl + pop af ret ; End of function p7Dsub_4EBD @@ -3138,42 +3138,42 @@ p7Dsub_4ECE: call p7Dsub_705E call p7Dsub_4574 - ld de, 838Fh + ld de, 838Fh call p7Dsub_424C push hl - ld hl, OP6 - ld (hl), 1 - pop hl - rst 28h -; --------------------------------------------------------------------------- - .dw 8069h -; --------------------------------------------------------------------------- - jr z, p7Dloc_4EE8 - dec ix + ld hl, OP6 + ld (hl), 1 + pop hl + rst 28h +; --------------------------------------------------------------------------- + .dw 8069h +; --------------------------------------------------------------------------- + jr z, p7Dloc_4EE8 + dec ix p7Dloc_4EE8: call p7Dsub_764E push hl - pop ix + pop ix push ix - pop bc + pop bc sla c call p7Dsub_521D - or a + or a adc hl, bc - ld a, 7Eh ; '~' + ld a, 7Eh ; '~' p7Dloc_4EFB: - ld de, tempSwapArea - ex de, hl - pop bc + ld de, tempSwapArea + ex de, hl + pop bc push bc sla c - ld b, 0 - or a + ld b, 0 + or a adc hl, bc - ex de, hl - ld bc, 2 + ex de, hl + ld bc, 2 call FlashToRam ret ; End of function p7Dsub_4ECE @@ -3187,53 +3187,53 @@ push hl push de push ix - ld de, 810h + ld de, 810h call p7Dsub_4ECE - ld bc, (appID+1) - ld b, 0 - ld a, c - push af - and 0F0h ; '�' - ld c, a - pop af - xor c - ld c, a - ld (OP2), bc + ld bc, (appID+1) + ld b, 0 + ld a, c + push af + and 0F0h ; '�' + ld c, a + pop af + xor c + ld c, a + ld (OP2), bc p7Dloc_4F2D: - ld hl, 838Fh - ld de, 8484h + ld hl, 838Fh + ld de, 8484h ldir - rst 28h -; --------------------------------------------------------------------------- - .dw 8066h -; --------------------------------------------------------------------------- - pop ix - jr nz, p7Dloc_4F5E - inc ix - ld de, 700h + rst 28h +; --------------------------------------------------------------------------- + .dw 8066h +; --------------------------------------------------------------------------- + pop ix + jr nz, p7Dloc_4F5E + inc ix + ld de, 700h call p7Dsub_777E call p7Dsub_4574 p7Dloc_4F47: call p7Dsub_4EBD - inc ix - ld a, 7Eh ; '~' - ld de, 710h - rst 28h -; --------------------------------------------------------------------------- - .dw 8030h -; --------------------------------------------------------------------------- - or a + inc ix + ld a, 7Eh ; '~' + ld de, 710h + rst 28h +; --------------------------------------------------------------------------- + .dw 8030h +; --------------------------------------------------------------------------- + or a adc hl, bc call p7Dsub_705E - jr z, p7Dloc_4F47 - dec ix + jr z, p7Dloc_4F47 + dec ix p7Dloc_4F5E: - pop de - pop hl - pop af + pop de + pop hl + pop af ret ; End of function p7Dsub_4F10 @@ -3242,13 +3242,13 @@ p7Dsub_4F62: - ld hl, tempSwapArea - ld a, 0FFh - ld b, 0E8h ; '�' + ld hl, tempSwapArea + ld a, 0FFh + ld b, 0E8h ; '�' p7Dloc_4F69: - ld (hl), a - inc hl + ld (hl), a + inc hl djnz p7Dloc_4F69 ret ; End of function p7Dsub_4F62 @@ -3263,31 +3263,31 @@ push bc push ix push de - ld a, 7Eh ; '~' - ld de, 710h - rst 28h -; --------------------------------------------------------------------------- - .dw 8030h -; --------------------------------------------------------------------------- - pop de - push hl - push bc - ex de, hl - ld a, 7Eh ; '~' - ld de, 710h - rst 28h -; --------------------------------------------------------------------------- - .dw 8030h -; --------------------------------------------------------------------------- - pop de - ld a, e - pop de - cp c - jr nz, p7Dloc_4FE9 - ld a, c - or b - jr z, p7Dloc_4FEF - jp p7Dloc_4FB9 + ld a, 7Eh ; '~' + ld de, 710h + rst 28h +; --------------------------------------------------------------------------- + .dw 8030h +; --------------------------------------------------------------------------- + pop de + push hl + push bc + ex de, hl + ld a, 7Eh ; '~' + ld de, 710h + rst 28h +; --------------------------------------------------------------------------- + .dw 8030h +; --------------------------------------------------------------------------- + pop de + ld a, e + pop de + cp c + jr nz, p7Dloc_4FE9 + ld a, c + or b + jr z, p7Dloc_4FEF + jp p7Dloc_4FB9 ; End of function p7Dsub_4F6E @@ -3300,81 +3300,81 @@ push bc push ix push de - ld a, 7Eh ; '~' - ld de, 810h - rst 28h -; --------------------------------------------------------------------------- - .dw 8030h -; --------------------------------------------------------------------------- - pop de - push hl - push bc - ex de, hl - ld a, 7Eh ; '~' - ld de, 810h - rst 28h -; --------------------------------------------------------------------------- - .dw 8030h -; --------------------------------------------------------------------------- - pop de - ld a, e - pop de - cp c - jr nz, p7Dloc_4FE9 - ld a, c - or b - jr z, p7Dloc_4FEF + ld a, 7Eh ; '~' + ld de, 810h + rst 28h +; --------------------------------------------------------------------------- + .dw 8030h +; --------------------------------------------------------------------------- + pop de + push hl + push bc + ex de, hl + ld a, 7Eh ; '~' + ld de, 810h + rst 28h +; --------------------------------------------------------------------------- + .dw 8030h +; --------------------------------------------------------------------------- + pop de + ld a, e + pop de + cp c + jr nz, p7Dloc_4FE9 + ld a, c + or b + jr z, p7Dloc_4FEF p7Dloc_4FB9: - ld b, c + ld b, c p7Dloc_4FBA: - ld a, 7Eh ; '~' + ld a, 7Eh ; '~' call p7Dsub_4C73 - jr nz, p7Dloc_4FE9 - inc hl - inc de + jr nz, p7Dloc_4FE9 + inc hl + inc de djnz p7Dloc_4FBA call p7Dsub_4565 - and 0F0h ; '�' - cp 10h - jr z, p7Dloc_4FEF - cp 0 - jr z, p7Dloc_4FEF - dec hl - inc de + and 0F0h ; '�' + cp 10h + jr z, p7Dloc_4FEF + cp 0 + jr z, p7Dloc_4FEF + dec hl + inc de push de call p7Dsub_4574 - pop de - ex de, hl + pop de + ex de, hl push bc push de call p7Dloc_4575 - pop de - ex de, hl - ld a, c - pop bc - cp c - jr nz, p7Dloc_4FE9 - ld b, c - jr p7Dloc_4FBA + pop de + ex de, hl + ld a, c + pop bc + cp c + jr nz, p7Dloc_4FE9 + ld b, c + jr p7Dloc_4FBA ; --------------------------------------------------------------------------- p7Dloc_4FE9: - ld a, 0FFh - bit 7, a - jr p7Dloc_4FF3 + ld a, 0FFh + bit 7, a + jr p7Dloc_4FF3 ; --------------------------------------------------------------------------- p7Dloc_4FEF: - ld a, 0 - bit 7, a + ld a, 0 + bit 7, a p7Dloc_4FF3: - pop ix - pop bc - pop de - pop hl + pop ix + pop bc + pop de + pop hl ret ; End of function p7Dsub_4F95 @@ -3388,121 +3388,121 @@ push af push hl push af - inc hl - rst 28h -; --------------------------------------------------------------------------- - .dw 805Ah -; --------------------------------------------------------------------------- - or a + inc hl + rst 28h +; --------------------------------------------------------------------------- + .dw 805Ah +; --------------------------------------------------------------------------- + or a adc hl, bc - pop af - inc hl - rst 28h -; --------------------------------------------------------------------------- - .dw 805Ah -; --------------------------------------------------------------------------- - or a + pop af + inc hl + rst 28h +; --------------------------------------------------------------------------- + .dw 805Ah +; --------------------------------------------------------------------------- + or a adc hl, bc - pop de - or a - sbc hl, de - push hl - pop bc - ex de, hl - pop af - ld de, tempSwapArea - push bc - rst 28h -; --------------------------------------------------------------------------- - .dw 8054h -; --------------------------------------------------------------------------- - pop bc - ld a, 7Eh ; '~' + pop de + or a + sbc hl, de + push hl + pop bc + ex de, hl + pop af + ld de, tempSwapArea + push bc + rst 28h +; --------------------------------------------------------------------------- + .dw 8054h +; --------------------------------------------------------------------------- + pop bc + ld a, 7Eh ; '~' call p7Dsub_4894 push hl push hl - rst 28h -; --------------------------------------------------------------------------- - .dw 8060h -; --------------------------------------------------------------------------- - pop hl - ex de, hl - ld hl, tempSwapArea - ld a, 7Eh ; '~' - rst 28h -; --------------------------------------------------------------------------- - .dw 8087h -; --------------------------------------------------------------------------- - ld de, 320h - rst 28h -; --------------------------------------------------------------------------- - .dw 8027h -; --------------------------------------------------------------------------- - jr nz, p7Dloc_503E - rst 28h -; --------------------------------------------------------------------------- - .dw 802Ah + rst 28h +; --------------------------------------------------------------------------- + .dw 8060h +; --------------------------------------------------------------------------- + pop hl + ex de, hl + ld hl, tempSwapArea + ld a, 7Eh ; '~' + rst 28h +; --------------------------------------------------------------------------- + .dw 8087h +; --------------------------------------------------------------------------- + ld de, 320h + rst 28h +; --------------------------------------------------------------------------- + .dw 8027h +; --------------------------------------------------------------------------- + jr nz, p7Dloc_503E + rst 28h +; --------------------------------------------------------------------------- + .dw 802Ah ; --------------------------------------------------------------------------- p7Dloc_503E: - pop hl + pop hl ; START OF FUNCTION CHUNK FOR p7Dsub_5083 p7Dloc_503F: scf p7Dloc_5040: - ld a, 7Eh ; '~' - push af - push af - push hl - push hl - push af - inc hl - rst 28h -; --------------------------------------------------------------------------- - .dw 805Ah -; --------------------------------------------------------------------------- - or a + ld a, 7Eh ; '~' + push af + push af + push hl + push hl + push af + inc hl + rst 28h +; --------------------------------------------------------------------------- + .dw 805Ah +; --------------------------------------------------------------------------- + or a adc hl, bc - pop af - inc hl - rst 28h -; --------------------------------------------------------------------------- - .dw 805Ah -; --------------------------------------------------------------------------- - or a + pop af + inc hl + rst 28h +; --------------------------------------------------------------------------- + .dw 805Ah +; --------------------------------------------------------------------------- + or a adc hl, bc - pop de - or a - sbc hl, de - push hl - pop bc - pop hl - pop af + pop de + or a + sbc hl, de + push hl + pop bc + pop hl + pop af push bc push hl call p7Dsub_521D - ld bc, 0E8h ; '�' - ld a, 7Eh ; '~' - ld de, tempSwapArea - rst 28h -; --------------------------------------------------------------------------- - .dw 8054h -; --------------------------------------------------------------------------- - pop de - pop bc - ld a, d - xor 20h ; ' ' - ld d, a + ld bc, 0E8h ; '�' + ld a, 7Eh ; '~' + ld de, tempSwapArea + rst 28h +; --------------------------------------------------------------------------- + .dw 8054h +; --------------------------------------------------------------------------- + pop de + pop bc + ld a, d + xor 20h ; ' ' + ld d, a call p7Dsub_430E - jp nz, p7Dloc_46C1 - pop af + jp nz, p7Dloc_46C1 + pop af call c, p7Dsub_4926 - pop bc - pop hl - pop de - pop af + pop bc + pop hl + pop de + pop af ret ; END OF FUNCTION CHUNK FOR p7Dsub_5083 @@ -3518,7 +3518,7 @@ push de push hl push bc - jp p7Dloc_503F + jp p7Dloc_503F ; End of function p7Dsub_5083 @@ -3531,25 +3531,25 @@ push hl push bc call p7Dsub_4894 - ld de, 320h + ld de, 320h call p7Dsub_777E push hl - ld de, 320h - rst 28h -; --------------------------------------------------------------------------- - .dw 8027h -; --------------------------------------------------------------------------- - jr nz, p7Dloc_50A3 - rst 28h -; --------------------------------------------------------------------------- - .dw 802Ah + ld de, 320h + rst 28h +; --------------------------------------------------------------------------- + .dw 8027h +; --------------------------------------------------------------------------- + jr nz, p7Dloc_50A3 + rst 28h +; --------------------------------------------------------------------------- + .dw 802Ah ; --------------------------------------------------------------------------- p7Dloc_50A3: - pop hl + pop hl scf ccf - jr p7Dloc_5040 + jr p7Dloc_5040 ; End of function p7Dsub_508A @@ -3562,16 +3562,16 @@ push hl push de call p7Dsub_4894 - ld de, 320h + ld de, 320h call p7Dsub_777E call p7Dsub_4574 - ld a, 7Eh ; '~' + ld a, 7Eh ; '~' call p7Dsub_50C5 call z, p7Dsub_508A - pop de - pop hl - pop bc - pop af + pop de + pop hl + pop bc + pop af ret ; End of function p7Dsub_50A8 @@ -3585,93 +3585,93 @@ push de push af push hl - ld de, 320h - rst 28h -; --------------------------------------------------------------------------- - .dw 8027h -; --------------------------------------------------------------------------- - jr nz, p7Dloc_5119 + ld de, 320h + rst 28h +; --------------------------------------------------------------------------- + .dw 8027h +; --------------------------------------------------------------------------- + jr nz, p7Dloc_5119 call p7Dsub_4574 - ex de, hl - pop hl - inc hl - inc de - pop af - ld b, a - rst 28h -; --------------------------------------------------------------------------- - .dw 8051h -; --------------------------------------------------------------------------- - push af - and 0F0h ; '�' - ld c, a - pop af - xor c - push af - ex de, hl + ex de, hl + pop hl + inc hl + inc de + pop af + ld b, a + rst 28h +; --------------------------------------------------------------------------- + .dw 8051h +; --------------------------------------------------------------------------- + push af + and 0F0h ; '�' + ld c, a + pop af + xor c + push af + ex de, hl call p7Dsub_4566 - ld c, a - pop af - sub c - jr z, p7Dloc_50F3 - jr nc, p7Dloc_511B - jr c, p7Dloc_5113 + ld c, a + pop af + sub c + jr z, p7Dloc_50F3 + jr nc, p7Dloc_511B + jr c, p7Dloc_5113 p7Dloc_50F3: - ld a, b - inc de - inc hl - ld b, c - ex de, hl + ld a, b + inc de + inc hl + ld b, c + ex de, hl p7Dloc_50F8: push af - rst 28h -; --------------------------------------------------------------------------- - .dw 8051h -; --------------------------------------------------------------------------- - push af - ex de, hl + rst 28h +; --------------------------------------------------------------------------- + .dw 8051h +; --------------------------------------------------------------------------- + push af + ex de, hl call p7Dsub_4566 - ld c, a - pop af - sub c - jr z, p7Dloc_510A - jr nc, p7Dloc_511A - jr c, p7Dloc_5112 + ld c, a + pop af + sub c + jr z, p7Dloc_510A + jr nc, p7Dloc_511A + jr c, p7Dloc_5112 p7Dloc_510A: - pop af - inc de - inc hl - ex de, hl + pop af + inc de + inc hl + ex de, hl djnz p7Dloc_50F8 - jr p7Dloc_5113 + jr p7Dloc_5113 ; --------------------------------------------------------------------------- p7Dloc_5112: - pop af + pop af p7Dloc_5113: - ld a, 0FFh - bit 7, a - jr p7Dloc_511F + ld a, 0FFh + bit 7, a + jr p7Dloc_511F ; --------------------------------------------------------------------------- p7Dloc_5119: - pop af + pop af p7Dloc_511A: - pop af + pop af p7Dloc_511B: - ld a, 0 - bit 7, a + ld a, 0 + bit 7, a p7Dloc_511F: - pop de - pop hl - pop ix + pop de + pop hl + pop ix ret ; End of function p7Dsub_50C5 @@ -3687,63 +3687,63 @@ call p7Dsub_47B5 call p7Dsub_762A call p7Dsub_484E - inc ix + inc ix push ix call p7Dsub_4894 - ld de, 700h + ld de, 700h call p7Dsub_777E call p7Dsub_4574 p7Dloc_5141: - ld de, 710h + ld de, 710h call p7Dsub_705E - jr nz, p7Dloc_5156 - ex de, hl + jr nz, p7Dloc_5156 + ex de, hl call p7Dsub_4DCD - ex de, hl - inc ix + ex de, hl + inc ix call p7Dsub_4574 - add hl, bc - jr p7Dloc_5141 + add hl, bc + jr p7Dloc_5141 ; --------------------------------------------------------------------------- p7Dloc_5156: - ld hl, tempSwapArea + ld hl, tempSwapArea push ix - pop bc + pop bc sla c - add hl, bc - pop de + add hl, bc + pop de push hl sla e call p7Dsub_521D - add hl, de - push hl - ld a, c - sub e - jr nc, p7Dloc_516F - ld a, e - ld e, c - sub e + add hl, de + push hl + ld a, c + sub e + jr nc, p7Dloc_516F + ld a, e + ld e, c + sub e p7Dloc_516F: - ld c, a - ld hl, 0C8h ; '�' - sbc hl, de - sbc hl, bc - push hl - pop bc - pop hl - pop de - ld a, 7Eh ; '~' - rst 28h -; --------------------------------------------------------------------------- - .dw 8054h -; --------------------------------------------------------------------------- - pop af - pop de - pop bc - pop hl + ld c, a + ld hl, 0C8h ; '�' + sbc hl, de + sbc hl, bc + push hl + pop bc + pop hl + pop de + ld a, 7Eh ; '~' + rst 28h +; --------------------------------------------------------------------------- + .dw 8054h +; --------------------------------------------------------------------------- + pop af + pop de + pop bc + pop hl ret ; End of function p7Dsub_5124 @@ -3755,17 +3755,17 @@ push bc push hl call p7Dsub_521D - pop de - ex de, hl - or a - sbc hl, de - ex de, hl - ld hl, tempSwapArea - add hl, de - ld a, (unk_9C20) + pop de + ex de, hl + or a + sbc hl, de + ex de, hl + ld hl, tempSwapArea + add hl, de + ld a, (unk_9C20) call Page7D_2B86 - pop bc - ld (hl), b + pop bc + ld (hl), b ret ; End of function p7Dsub_5185 @@ -3779,28 +3779,28 @@ push hl call p7Dsub_51DB call p7Dsub_7BCC - ld c, a + ld c, a call p7Dsub_4566 push af - or c - ld b, a - pop af - and c - jr nz, p7Dloc_51BB + or c + ld b, a + pop af + and c + jr nz, p7Dloc_51BB call p7Dsub_5185 - ld a, 5 + ld a, 5 call Page7D_2B62 - jr p7Dloc_51BF + jr p7Dloc_51BF ; --------------------------------------------------------------------------- p7Dloc_51BB: - ex de, hl + ex de, hl call p7Dsub_456D p7Dloc_51BF: - pop hl - pop bc - pop af + pop hl + pop bc + pop af ret ; End of function p7Dsub_519D @@ -3815,15 +3815,15 @@ call p7Dsub_51DB call p7Dsub_7BCC cpl - ld c, a + ld c, a call p7Dsub_4566 - and c - ld b, a - ex de, hl + and c + ld b, a + ex de, hl call p7Dsub_456D - pop hl - pop bc - pop af + pop hl + pop bc + pop af ret ; End of function p7Dsub_51C3 @@ -3834,36 +3834,36 @@ p7Dsub_51DB: push de push af - ld b, a - rst 28h -; --------------------------------------------------------------------------- - .dw 80A8h -; --------------------------------------------------------------------------- - jr nz, p7Dloc_51ED + ld b, a + rst 28h +; --------------------------------------------------------------------------- + .dw 80A8h +; --------------------------------------------------------------------------- + jr nz, p7Dloc_51ED call p7Dsub_75EC - sub b - inc a - ld c, a - ld b, 0 - jr p7Dloc_5202 + sub b + inc a + ld c, a + ld b, 0 + jr p7Dloc_5202 ; --------------------------------------------------------------------------- p7Dloc_51ED: push hl - ld hl, OP6 - ld (hl), 0 - pop hl - rst 28h -; --------------------------------------------------------------------------- - .dw 8069h -; --------------------------------------------------------------------------- - inc ix + ld hl, OP6 + ld (hl), 0 + pop hl + rst 28h +; --------------------------------------------------------------------------- + .dw 8069h +; --------------------------------------------------------------------------- + inc ix push ix - pop hl + pop hl call p7Dsub_7643 - add hl, bc - push hl - pop bc + add hl, bc + push hl + pop bc p7Dloc_5202: push bc @@ -3871,14 +3871,14 @@ sra c sra c sra c - or a + or a adc hl, bc - pop bc - ld a, c - and 7 - ld c, a - pop af - pop de + pop bc + ld a, c + and 7 + ld c, a + pop af + pop de ret ; End of function p7Dsub_51DB @@ -3888,8 +3888,8 @@ Page7D_2B80: push bc - ld bc, 1FE0h - jr p7Dloc_5221 + ld bc, 1FE0h + jr p7Dloc_5221 ; End of function Page7D_2B80 @@ -3898,18 +3898,18 @@ p7Dsub_521D: push bc - ld bc, 1F18h + ld bc, 1F18h p7Dloc_5221: ; p7Dsub_522B+4j ... push ix - rst 28h -; --------------------------------------------------------------------------- - .dw 8057h -; --------------------------------------------------------------------------- - add hl, bc - pop ix - pop bc + rst 28h +; --------------------------------------------------------------------------- + .dw 8057h +; --------------------------------------------------------------------------- + add hl, bc + pop ix + pop bc ret ; End of function p7Dsub_521D @@ -3919,8 +3919,8 @@ p7Dsub_522B: push bc - ld bc, 1DEAh - jr p7Dloc_5221 + ld bc, 1DEAh + jr p7Dloc_5221 ; End of function p7Dsub_522B @@ -3929,7 +3929,7 @@ Page7D_2B68: call NZIf83Plus - jr nz, p7Dsub_521D + jr nz, p7Dsub_521D ; End of function Page7D_2B68 @@ -3938,8 +3938,8 @@ p7Dsub_5236: push bc - ld bc, 1E50h - jr p7Dloc_5221 + ld bc, 1E50h + jr p7Dloc_5221 ; End of function p7Dsub_5236 @@ -3948,8 +3948,8 @@ p7Dsub_523C: push bc - ld bc, 1FE0h - jr p7Dloc_5221 + ld bc, 1FE0h + jr p7Dloc_5221 ; End of function p7Dsub_523C @@ -3960,60 +3960,60 @@ push hl push bc push ix - ld a, (OP1) - push af - ld a, 8 + ld a, (OP1) + push af + ld a, 8 p7Dloc_524C: push af - ld hl, 4000h - rst 28h -; --------------------------------------------------------------------------- - .dw 8051h -; --------------------------------------------------------------------------- - cp 0FEh ; '�' - jr z, p7Dloc_527B - pop af - add a, 4 + ld hl, 4000h + rst 28h +; --------------------------------------------------------------------------- + .dw 8051h +; --------------------------------------------------------------------------- + cp 0FEh ; '�' + jr z, p7Dloc_527B + pop af + add a, 4 call p7Dsub_75E1 - jr c, p7Dloc_524C - ld a, 8 + jr c, p7Dloc_524C + ld a, 8 p7Dloc_5261: push af - ld hl, 4000h - rst 28h -; --------------------------------------------------------------------------- - .dw 8051h -; --------------------------------------------------------------------------- - cp 0FFh - jr z, p7Dloc_5278 - pop af - add a, 4 + ld hl, 4000h + rst 28h +; --------------------------------------------------------------------------- + .dw 8051h +; --------------------------------------------------------------------------- + cp 0FFh + jr z, p7Dloc_5278 + pop af + add a, 4 call p7Dsub_75E1 - jr c, p7Dloc_5261 - ld a, 8 - jr p7Dloc_5279 + jr c, p7Dloc_5261 + ld a, 8 + jr p7Dloc_5279 ; --------------------------------------------------------------------------- p7Dloc_5278: - pop af + pop af p7Dloc_5279: - jr p7Dloc_527C + jr p7Dloc_527C ; --------------------------------------------------------------------------- p7Dloc_527B: - pop af + pop af p7Dloc_527C: - ld b, a - pop af - ld (OP1), a - ld a, b - pop ix - pop bc - pop hl + ld b, a + pop af + ld (OP1), a + ld a, b + pop ix + pop bc + pop hl ret ; End of function FindSwapSector @@ -4026,75 +4026,75 @@ push hl push bc push de - ld b, 0FEh ; '�' - ld de, 4000h - rst 28h -; --------------------------------------------------------------------------- - .dw 8021h -; --------------------------------------------------------------------------- - pop de - pop bc - pop hl - pop af + ld b, 0FEh ; '�' + ld de, 4000h + rst 28h +; --------------------------------------------------------------------------- + .dw 8021h +; --------------------------------------------------------------------------- + pop de + pop bc + pop hl + pop af ret ; End of function Page7D_2C40 ; --------------------------------------------------------------------------- Page7D_2C22: - rst 28h -; --------------------------------------------------------------------------- - .dw 8066h -; --------------------------------------------------------------------------- - jr nz, locret_52D8 - ld a, 7Eh ; '~' + rst 28h +; --------------------------------------------------------------------------- + .dw 8066h +; --------------------------------------------------------------------------- + jr nz, locret_52D8 + ld a, 7Eh ; '~' p7Dloc_529F: - ld (appSearchPage), a - push hl - push hl - ld a, (appSearchPage) - inc hl - rst 28h -; --------------------------------------------------------------------------- - .dw 805Ah -; --------------------------------------------------------------------------- - or a + ld (appSearchPage), a + push hl + push hl + ld a, (appSearchPage) + inc hl + rst 28h +; --------------------------------------------------------------------------- + .dw 805Ah +; --------------------------------------------------------------------------- + or a adc hl, bc - inc hl - ld a, (appSearchPage) - rst 28h -; --------------------------------------------------------------------------- - .dw 805Ah -; --------------------------------------------------------------------------- - or a + inc hl + ld a, (appSearchPage) + rst 28h +; --------------------------------------------------------------------------- + .dw 805Ah +; --------------------------------------------------------------------------- + or a adc hl, bc - pop de - sbc hl, de - push hl - pop bc + pop de + sbc hl, de + push hl + pop bc call p7Dsub_4894 - ex de, hl - pop hl + ex de, hl + pop hl p7Dloc_52C2: push bc - ld a, (appSearchPage) - rst 28h -; --------------------------------------------------------------------------- - .dw 8051h -; --------------------------------------------------------------------------- - ld b, a + ld a, (appSearchPage) + rst 28h +; --------------------------------------------------------------------------- + .dw 8051h +; --------------------------------------------------------------------------- + ld b, a push hl call p7Dsub_456D - pop hl - pop bc - dec bc - ld a, b - or c - jr z, locret_52D8 - inc hl - jr p7Dloc_52C2 + pop hl + pop bc + dec bc + ld a, b + or c + jr z, locret_52D8 + inc hl + jr p7Dloc_52C2 ; --------------------------------------------------------------------------- locret_52D8: @@ -4104,16 +4104,16 @@ p7Dsub_52D9: - ld de, 8050h - ld hl, 4000h - push af - or a - rst 28h -; --------------------------------------------------------------------------- - .dw 8075h -; --------------------------------------------------------------------------- - jr nz, p7Dloc_52ED - pop af + ld de, 8050h + ld hl, 4000h + push af + or a + rst 28h +; --------------------------------------------------------------------------- + .dw 8075h +; --------------------------------------------------------------------------- + jr nz, p7Dloc_52ED + pop af call p7Dsub_50C5 scf ccf @@ -4121,7 +4121,7 @@ ; --------------------------------------------------------------------------- p7Dloc_52ED: - pop af + pop af scf ret ; End of function p7Dsub_52D9 @@ -4129,48 +4129,48 @@ ; --------------------------------------------------------------------------- Page7D_2CA0: - ld de, 8050h - push de - jp p7Dloc_52F7 + ld de, 8050h + push de + jp p7Dloc_52F7 p7Dloc_52F7: - ld hl, 4000h - pop de - push af - or a - rst 28h -; --------------------------------------------------------------------------- - .dw 8075h -; --------------------------------------------------------------------------- - jr nz, p7Dloc_5338 - pop af - ld (Abackup), a - ld a, i - di - push af - ld a, (Abackup) - push af - ld a, 1 + ld hl, 4000h + pop de + push af + or a + rst 28h +; --------------------------------------------------------------------------- + .dw 8075h +; --------------------------------------------------------------------------- + jr nz, p7Dloc_5338 + pop af + ld (Abackup), a + ld a, i + di + push af + ld a, (Abackup) + push af + ld a, 1 nop di nop nop im 1 di - out (14h), a + out (14h), a di call checkForFlashTrickery - pop af + pop af call p7Dsub_50C5 call p7Dsub_6006 call relockFlashBack - ld (Abackup), a - pop af - jp po, p7Dloc_532F + ld (Abackup), a + pop af + jp po, p7Dloc_532F ei p7Dloc_532F: - ld a, (Abackup) + ld a, (Abackup) call p7Dsub_6011 scf ccf @@ -4179,7 +4179,7 @@ ; START OF FUNCTION CHUNK FOR p7Dsub_533B p7Dloc_5338: - pop af + pop af scf ret ; END OF FUNCTION CHUNK FOR p7Dsub_533B @@ -4193,36 +4193,36 @@ push af call p7Dsub_6021 - jr c, p7Dloc_5338 - ld hl, 4000h - ld de, 320h - pop af - push af - or a - rst 28h -; --------------------------------------------------------------------------- - .dw 8075h -; --------------------------------------------------------------------------- - jr nz, p7Dloc_5338 - pop af - push af - push hl - inc hl - rst 28h -; --------------------------------------------------------------------------- - .dw 805Ah + jr c, p7Dloc_5338 + ld hl, 4000h + ld de, 320h + pop af + push af + or a + rst 28h +; --------------------------------------------------------------------------- + .dw 8075h +; --------------------------------------------------------------------------- + jr nz, p7Dloc_5338 + pop af + push af + push hl + inc hl + rst 28h +; --------------------------------------------------------------------------- + .dw 805Ah ; --------------------------------------------------------------------------- call p7Dsub_50C5 - jr nz, p7Dloc_5362 - pop hl - pop af + jr nz, p7Dloc_5362 + pop hl + pop af push af push hl call p7Dloc_4FF9 p7Dloc_5362: - pop hl - pop af + pop hl + pop af ret ; End of function p7Dsub_533B @@ -4236,7 +4236,7 @@ push de push bc call Page7D_2B68 - jr p7Dloc_537C + jr p7Dloc_537C ; End of function p7Dsub_5365 @@ -4249,52 +4249,52 @@ push de push bc call p7Dsub_521D - ld bc, 0Dh - add ix, bc + ld bc, 0Dh + add ix, bc p7Dloc_537C: push ix - pop bc + pop bc sla c - or a + or a adc hl, bc push hl call p7Dsub_4566 - cp 80h ; '�' - jr z, p7Dloc_53AC + cp 80h ; '�' + jr z, p7Dloc_53AC push af call p7Dsub_4565 - cp 0 - pop bc - jr z, p7Dloc_5399 + cp 0 + pop bc + jr z, p7Dloc_5399 srl a - jr p7Dloc_539B + jr p7Dloc_539B ; --------------------------------------------------------------------------- p7Dloc_5399: srl b p7Dloc_539B: - pop de - ld c, a + pop de + ld c, a push bc call p7Dsub_456D - pop bc - ld b, c + pop bc + ld b, c call p7Dsub_456D - pop bc - pop de - pop hl - pop ix + pop bc + pop de + pop hl + pop ix ret ; --------------------------------------------------------------------------- p7Dloc_53AC: - pop de - pop bc - pop de - pop hl - pop ix + pop de + pop bc + pop de + pop hl + pop ix ret ; End of function p7Dsub_536F @@ -4303,36 +4303,36 @@ p7Dsub_53B3: - ld (Abackup), a - ld a, i - di - push af - ld a, (Abackup) - push af - ld a, 1 + ld (Abackup), a + ld a, i + di + push af + ld a, (Abackup) + push af + ld a, 1 nop di nop nop im 1 di - out (14h), a + out (14h), a di call checkForFlashTrickery - pop af + pop af call Page7D_2B5C p7Dloc_53D1: call p7Dsub_6006 call relockFlashBack - ld (Abackup), a - pop af - jp po, p7Dloc_53DF + ld (Abackup), a + pop af + jp po, p7Dloc_53DF ei p7Dloc_53DF: - ld a, (Abackup) - jp p7Dsub_6011 + ld a, (Abackup) + jp p7Dsub_6011 ; End of function p7Dsub_53B3 @@ -4344,32 +4344,32 @@ push hl push bc push ix - ld b, a - rst 28h -; --------------------------------------------------------------------------- - .dw 80A8h -; --------------------------------------------------------------------------- - jr nz, p7Dloc_53FA + ld b, a + rst 28h +; --------------------------------------------------------------------------- + .dw 80A8h +; --------------------------------------------------------------------------- + jr nz, p7Dloc_53FA call p7Dsub_75EC - sub b - inc a - ld c, a - ld b, 0 - jr p7Dloc_541E + sub b + inc a + ld c, a + ld b, 0 + jr p7Dloc_541E ; --------------------------------------------------------------------------- p7Dloc_53FA: - ld hl, OP6 - ld (hl), 0 - ld a, (appSearchPage) - push af - rst 28h -; --------------------------------------------------------------------------- - .dw 8069h -; --------------------------------------------------------------------------- - pop af - ld (appSearchPage), a - jr p7Dloc_5411 + ld hl, OP6 + ld (hl), 0 + ld a, (appSearchPage) + push af + rst 28h +; --------------------------------------------------------------------------- + .dw 8069h +; --------------------------------------------------------------------------- + pop af + ld (appSearchPage), a + jr p7Dloc_5411 ; End of function Page7D_2B5C @@ -4383,14 +4383,14 @@ push ix p7Dloc_5411: - inc ix + inc ix push ix - pop hl + pop hl call p7Dsub_7643 - or a + or a adc hl, bc push hl - pop bc + pop bc p7Dloc_541E: push bc @@ -4398,19 +4398,19 @@ sra c sra c sra c - or a + or a adc hl, bc - pop bc - ld a, c - and 7 + pop bc + ld a, c + and 7 call p7Dsub_7BCC - ld c, a + ld c, a call p7Dsub_4566 - and c - pop ix - pop bc - pop hl - pop de + and c + pop ix + pop bc + pop hl + pop de ret ; End of function p7Dsub_540C @@ -4418,328 +4418,328 @@ p7Dloc_543D: push af - ld a, 1 + ld a, 1 nop di nop nop im 1 di - out (14h), a + out (14h), a di call checkForFlashTrickery - pop af - ld b, a - ld de, 8060h - ld hl, 4000h - or a - rst 28h -; --------------------------------------------------------------------------- - .dw 8075h -; --------------------------------------------------------------------------- - jr nz, p7Dloc_549D + pop af + ld b, a + ld de, 8060h + ld hl, 4000h + or a + rst 28h +; --------------------------------------------------------------------------- + .dw 8075h +; --------------------------------------------------------------------------- + jr nz, p7Dloc_549D call p7Dsub_75EC - ld c, b - sub c - ld bc, 0 - ld c, a + ld c, b + sub c + ld bc, 0 + ld c, a sla c call Page7D_2B68 - or a + or a adc hl, bc - ld a, 7Eh ; '~' - ld de, OP1 - ld bc, 2 - rst 28h -; --------------------------------------------------------------------------- - .dw 8054h -; --------------------------------------------------------------------------- - ld a, (OP1) - ld bc, 0 + ld a, 7Eh ; '~' + ld de, OP1 + ld bc, 2 + rst 28h +; --------------------------------------------------------------------------- + .dw 8054h +; --------------------------------------------------------------------------- + ld a, (OP1) + ld bc, 0 p7Dloc_547D: - cp 0 - jr z, p7Dloc_5486 + cp 0 + jr z, p7Dloc_5486 srl a - inc c - jr p7Dloc_547D + inc c + jr p7Dloc_547D ; --------------------------------------------------------------------------- p7Dloc_5486: - ld a, (OP1+1) + ld a, (OP1+1) p7Dloc_5489: - cp 0 - jr z, p7Dloc_5492 + cp 0 + jr z, p7Dloc_5492 srl a - inc c - jr p7Dloc_5489 + inc c + jr p7Dloc_5489 ; --------------------------------------------------------------------------- p7Dloc_5492: - ld a, c - ld (OP1), a - ld a, 0 - ld (OP1+1), a - bit 7, a + ld a, c + ld (OP1), a + ld a, 0 + ld (OP1+1), a + bit 7, a p7Dloc_549D: - jp relockFlashBack + jp relockFlashBack ; --------------------------------------------------------------------------- p7Dloc_54A0: - ld b, a - ld de, 8050h - ld hl, 4000h - or a - rst 28h -; --------------------------------------------------------------------------- - .dw 8075h -; --------------------------------------------------------------------------- - jr nz, locret_54BE - ld a, b - push af - inc hl - rst 28h -; --------------------------------------------------------------------------- - .dw 805Ah -; --------------------------------------------------------------------------- - pop af - ld de, OP1 - rst 28h -; --------------------------------------------------------------------------- - .dw 8054h -; --------------------------------------------------------------------------- - ld a, 0 - bit 7, a + ld b, a + ld de, 8050h + ld hl, 4000h + or a + rst 28h +; --------------------------------------------------------------------------- + .dw 8075h +; --------------------------------------------------------------------------- + jr nz, locret_54BE + ld a, b + push af + inc hl + rst 28h +; --------------------------------------------------------------------------- + .dw 805Ah +; --------------------------------------------------------------------------- + pop af + ld de, OP1 + rst 28h +; --------------------------------------------------------------------------- + .dw 8054h +; --------------------------------------------------------------------------- + ld a, 0 + bit 7, a locret_54BE: ret ; --------------------------------------------------------------------------- push hl - ld de, 8020h - ld hl, 4000h - ld a, 7Ah ; 'z' - or a - rst 28h -; --------------------------------------------------------------------------- - .dw 8075h -; --------------------------------------------------------------------------- - ld a, 7Ah ; 'z' - rst 28h -; --------------------------------------------------------------------------- - .dw 8051h -; --------------------------------------------------------------------------- - ld d, a - ld a, 7Ah ; 'z' - rst 28h -; --------------------------------------------------------------------------- - .dw 8051h -; --------------------------------------------------------------------------- - ld e, a - pop hl + ld de, 8020h + ld hl, 4000h + ld a, 7Ah ; 'z' + or a + rst 28h +; --------------------------------------------------------------------------- + .dw 8075h +; --------------------------------------------------------------------------- + ld a, 7Ah ; 'z' + rst 28h +; --------------------------------------------------------------------------- + .dw 8051h +; --------------------------------------------------------------------------- + ld d, a + ld a, 7Ah ; 'z' + rst 28h +; --------------------------------------------------------------------------- + .dw 8051h +; --------------------------------------------------------------------------- + ld e, a + pop hl ret ; --------------------------------------------------------------------------- Page7D_3C66: - ld (Abackup), a - ld a, i - di - push af - ld a, (Abackup) - push hl - push de - push af - ld a, 1 + ld (Abackup), a + ld a, i + di + push af + ld a, (Abackup) + push hl + push de + push af + ld a, 1 nop di nop nop im 1 di - out (14h), a + out (14h), a di call checkForFlashTrickery - pop af - ld de, 510h - push de - jr p7Dloc_54FD + pop af + ld de, 510h + push de + jr p7Dloc_54FD p7Dloc_54FD: call p7Dsub_70D1 - jr nz, p7Dloc_551F - ld de, 500h + jr nz, p7Dloc_551F + ld de, 500h call p7Dsub_777E - jr nz, p7Dloc_551F + jr nz, p7Dloc_551F call p7Dsub_4574 - ld a, 7Eh ; '~' - pop de - rst 28h -; --------------------------------------------------------------------------- - .dw 8030h -; --------------------------------------------------------------------------- - jr nz, p7Dloc_5520 - ld de, tempSwapArea - ld b, c - push bc - ld a, 7Eh ; '~' + ld a, 7Eh ; '~' + pop de + rst 28h +; --------------------------------------------------------------------------- + .dw 8030h +; --------------------------------------------------------------------------- + jr nz, p7Dloc_5520 + ld de, tempSwapArea + ld b, c + push bc + ld a, 7Eh ; '~' call p7Dsub_761F p7Dloc_551F: - pop bc + pop bc p7Dloc_5520: - pop de - pop hl - jp p7Dloc_53D1 + pop de + pop hl + jp p7Dloc_53D1 ; =============== S U B R O U T I N E ======================================= p7Dsub_5525: push af - ld hl, 4000h - inc hl - rst 28h -; --------------------------------------------------------------------------- - .dw _LoadAIndPaged + ld hl, 4000h + inc hl + rst 28h +; --------------------------------------------------------------------------- + .dw _LoadAIndPaged ; --------------------------------------------------------------------------- call p7Dsub_75FD - jp nz, p7Dloc_55C8 - inc hl - pop af + jp nz, p7Dloc_55C8 + inc hl + pop af call p7Dsub_761F - ld bc, 4000h - or a - sbc hl, bc - push hl - push af - ld hl, 4000h - ld de, 8080h - or a - rst 28h -; --------------------------------------------------------------------------- - .dw 8075h -; --------------------------------------------------------------------------- - inc hl - pop af - push af - rst 28h -; --------------------------------------------------------------------------- - .dw 805Ah -; --------------------------------------------------------------------------- - pop af - push af - rst 28h -; --------------------------------------------------------------------------- - .dw 8051h + ld bc, 4000h + or a + sbc hl, bc + push hl + push af + ld hl, 4000h + ld de, 8080h + or a + rst 28h +; --------------------------------------------------------------------------- + .dw 8075h +; --------------------------------------------------------------------------- + inc hl + pop af + push af + rst 28h +; --------------------------------------------------------------------------- + .dw 805Ah +; --------------------------------------------------------------------------- + pop af + push af + rst 28h +; --------------------------------------------------------------------------- + .dw 8051h ; --------------------------------------------------------------------------- p7Dloc_5555: ; DATA XREF: seg001:76C0w - dec a - or a - jr z, p7Dloc_5574 - ld c, a - pop af - sub c - push af - ld hl, (unk_83A1) + dec a + or a + jr z, p7Dloc_5574 + ld c, a + pop af + sub c + push af + ld hl, (unk_83A1) call p7Dsub_57C5 - ld b, c + ld b, c p7Dloc_5564: push bc - ld bc, 4000h - or a - sbc hl, bc - pop bc + ld bc, 4000h + or a + sbc hl, bc + pop bc djnz p7Dloc_5564 call p7Dsub_57C5 - ld (unk_83A1), hl + ld (unk_83A1), hl p7Dloc_5574: - ld hl, (unk_83A1) + ld hl, (unk_83A1) call p7Dsub_57C5 push hl - pop bc - ld hl, 4000h - or a + pop bc + ld hl, 4000h + or a adc hl, bc - pop af - pop bc - or a + pop af + pop bc + or a adc hl, bc push af p7Dloc_5588: - rst 28h -; --------------------------------------------------------------------------- - .dw 8051h -; --------------------------------------------------------------------------- - cp 2 - jr nz, p7Dloc_55C8 - pop af - push hl - push af - inc hl - rst 28h -; --------------------------------------------------------------------------- - .dw 8051h -; --------------------------------------------------------------------------- - and 0F0h ; '�' - cp 20h ; ' ' - jr z, p7Dloc_55A8 - pop af - pop hl - push af - inc hl - rst 28h -; --------------------------------------------------------------------------- - .dw 805Ah -; --------------------------------------------------------------------------- - or a + rst 28h +; --------------------------------------------------------------------------- + .dw 8051h +; --------------------------------------------------------------------------- + cp 2 + jr nz, p7Dloc_55C8 + pop af + push hl + push af + inc hl + rst 28h +; --------------------------------------------------------------------------- + .dw 8051h +; --------------------------------------------------------------------------- + and 0F0h ; '�' + cp 20h ; ' ' + jr z, p7Dloc_55A8 + pop af + pop hl + push af + inc hl + rst 28h +; --------------------------------------------------------------------------- + .dw 805Ah +; --------------------------------------------------------------------------- + or a adc hl, bc - jr p7Dloc_5588 + jr p7Dloc_5588 ; --------------------------------------------------------------------------- p7Dloc_55A8: - pop af - push af - rst 28h -; --------------------------------------------------------------------------- - .dw 805Ah -; --------------------------------------------------------------------------- - dec hl - inc bc - ld de, tempSwapArea + pop af + push af + rst 28h +; --------------------------------------------------------------------------- + .dw 805Ah +; --------------------------------------------------------------------------- + dec hl + inc bc + ld de, tempSwapArea p7Dloc_55B2: - pop af - push af - rst 28h -; --------------------------------------------------------------------------- - .dw 8051h -; --------------------------------------------------------------------------- - ld (de), a - inc hl - inc de - dec bc - ld a, c - or b - jr nz, p7Dloc_55B2 - pop af - pop hl - ld b, a - ld a, 0 - bit 7, a - ld a, b + pop af + push af + rst 28h +; --------------------------------------------------------------------------- + .dw 8051h +; --------------------------------------------------------------------------- + ld (de), a + inc hl + inc de + dec bc + ld a, c + or b + jr nz, p7Dloc_55B2 + pop af + pop hl + ld b, a + ld a, 0 + bit 7, a + ld a, b ret ; --------------------------------------------------------------------------- p7Dloc_55C8: - pop af - ld a, 0FFh - bit 7, a + pop af + ld a, 0FFh + bit 7, a ret ; End of function p7Dsub_5525 @@ -4748,67 +4748,67 @@ p7Dsub_55CE: - inc hl - push af - rst 28h -; --------------------------------------------------------------------------- - .dw 805Ah -; --------------------------------------------------------------------------- - or a + inc hl + push af + rst 28h +; --------------------------------------------------------------------------- + .dw 805Ah +; --------------------------------------------------------------------------- + or a adc hl, bc p7Dloc_55D6: - pop af - push af - rst 28h -; --------------------------------------------------------------------------- - .dw 8051h -; --------------------------------------------------------------------------- - cp 2 - jr nz, p7Dloc_5609 - inc hl - pop af - push af - rst 28h -; --------------------------------------------------------------------------- - .dw 8051h -; --------------------------------------------------------------------------- - and 0F0h ; '�' - cp 0 - jr z, p7Dloc_55F5 - pop af - push af - rst 28h -; --------------------------------------------------------------------------- - .dw 805Ah -; --------------------------------------------------------------------------- - or a + pop af + push af + rst 28h +; --------------------------------------------------------------------------- + .dw 8051h +; --------------------------------------------------------------------------- + cp 2 + jr nz, p7Dloc_5609 + inc hl + pop af + push af + rst 28h +; --------------------------------------------------------------------------- + .dw 8051h +; --------------------------------------------------------------------------- + and 0F0h ; '�' + cp 0 + jr z, p7Dloc_55F5 + pop af + push af + rst 28h +; --------------------------------------------------------------------------- + .dw 805Ah +; --------------------------------------------------------------------------- + or a adc hl, bc - jr p7Dloc_55D6 + jr p7Dloc_55D6 ; --------------------------------------------------------------------------- p7Dloc_55F5: - pop af - rst 28h -; --------------------------------------------------------------------------- - .dw 805Ah -; --------------------------------------------------------------------------- - dec hl - inc bc - ld de, tempSwapArea - rst 28h -; --------------------------------------------------------------------------- - .dw 8054h -; --------------------------------------------------------------------------- - ld b, c - ld c, 0 - ld a, 0 - bit 7, a + pop af + rst 28h +; --------------------------------------------------------------------------- + .dw 805Ah +; --------------------------------------------------------------------------- + dec hl + inc bc + ld de, tempSwapArea + rst 28h +; --------------------------------------------------------------------------- + .dw 8054h +; --------------------------------------------------------------------------- + ld b, c + ld c, 0 + ld a, 0 + bit 7, a ret ; --------------------------------------------------------------------------- p7Dloc_5609: - pop af + pop af ret ; End of function p7Dsub_55CE @@ -4819,104 +4819,104 @@ push de push hl push bc - rst 28h -; --------------------------------------------------------------------------- - .dw 807Eh -; --------------------------------------------------------------------------- - jr nz, p7Dloc_5640 - push af - ld a, 1 + rst 28h +; --------------------------------------------------------------------------- + .dw 807Eh +; --------------------------------------------------------------------------- + jr nz, p7Dloc_5640 + push af + ld a, 1 nop di nop nop im 1 di - out (14h), a + out (14h), a di call checkForFlashTrickery - pop af - rst 28h -; --------------------------------------------------------------------------- - .dw 8057h -; --------------------------------------------------------------------------- - ld a, 7Eh ; '~' - ld de, 410h - rst 28h -; --------------------------------------------------------------------------- - .dw 8027h -; --------------------------------------------------------------------------- - jr nz, p7Dloc_5640 + pop af + rst 28h +; --------------------------------------------------------------------------- + .dw 8057h +; --------------------------------------------------------------------------- + ld a, 7Eh ; '~' + ld de, 410h + rst 28h +; --------------------------------------------------------------------------- + .dw 8027h +; --------------------------------------------------------------------------- + jr nz, p7Dloc_5640 call p7Dsub_4574 - ld a, 7Eh ; '~' - ld de, 849Eh - rst 28h -; --------------------------------------------------------------------------- - .dw 8054h -; --------------------------------------------------------------------------- - ld a, 0 - bit 7, a + ld a, 7Eh ; '~' + ld de, 849Eh + rst 28h +; --------------------------------------------------------------------------- + .dw 8054h +; --------------------------------------------------------------------------- + ld a, 0 + bit 7, a p7Dloc_5640: - pop bc - pop hl - pop de - jp relockFlashBack + pop bc + pop hl + pop de + jp relockFlashBack ; --------------------------------------------------------------------------- Page7D_2B98: call Page0Call_23DE - jr nc, p7Dloc_5650 + jr nc, p7Dloc_5650 call Page0Call_23E3 - jr p7Dloc_565A + jr p7Dloc_565A ; --------------------------------------------------------------------------- p7Dloc_5650: call p7Dloc_560B - jr nz, p7Dloc_5695 + jr nz, p7Dloc_5695 call Page7D_2C34 - jr nz, p7Dloc_5695 + jr nz, p7Dloc_5695 p7Dloc_565A: - ld a, 1 + ld a, 1 call Page0Call_38EB push de push hl call p7Dloc_560B - jr nz, p7Dloc_5689 + jr nz, p7Dloc_5689 call OP1Set0 - ld de, OP1M - ld hl, OP4 - ld c, 7 - ld b, 0 + ld de, OP1M + ld hl, OP4 + ld c, 7 + ld b, 0 ldir - pop hl - pop de + pop hl + pop de push de call Page0Call_3AE9 - ex de, hl - ld hl, OP1 - ld a, (hl) + ex de, hl + ld hl, OP1 + ld a, (hl) call mov9B2 - pop hl - ld a, 0 - bit 7, a + pop hl + ld a, 0 + bit 7, a ret ; --------------------------------------------------------------------------- p7Dloc_5689: - pop hl - pop hl - push bc - push de - push hl - rst 28h -; --------------------------------------------------------------------------- - .dw 807Eh -; --------------------------------------------------------------------------- - pop hl - pop de - pop bc + pop hl + pop hl + push bc + push de + push hl + rst 28h +; --------------------------------------------------------------------------- + .dw 807Eh +; --------------------------------------------------------------------------- + pop hl + pop de + pop bc ret ; --------------------------------------------------------------------------- @@ -4924,14 +4924,14 @@ push bc push de push hl - rst 28h -; --------------------------------------------------------------------------- - .dw 807Eh -; --------------------------------------------------------------------------- - pop hl - pop de - pop bc - ex de, hl + rst 28h +; --------------------------------------------------------------------------- + .dw 807Eh +; --------------------------------------------------------------------------- + pop hl + pop de + pop bc + ex de, hl ret ; =============== S U B R O U T I N E ======================================= @@ -4942,65 +4942,65 @@ push hl push de call Page0Call_23DE - ex de, hl - ld c, (hl) - inc hl - ld b, (hl) - dec hl - ex de, hl - ld a, b - or c - jr z, p7Dloc_56D6 - ld hl, 1 + ex de, hl + ld c, (hl) + inc hl + ld b, (hl) + dec hl + ex de, hl + ld a, b + or c + jr z, p7Dloc_56D6 + ld hl, 1 p7Dloc_56B3: push de push hl push bc call Page0Call_3B07 - ld de, OP4 - ld hl, OP2M - ld b, 7 + ld de, OP4 + ld hl, OP2M + ld b, 7 p7Dloc_56C1: - ld a, (de) - cp (hl) - jr nz, p7Dloc_56CB - inc de - inc hl + ld a, (de) + cp (hl) + jr nz, p7Dloc_56CB + inc de + inc hl djnz p7Dloc_56C1 - jr p7Dloc_56DA + jr p7Dloc_56DA ; --------------------------------------------------------------------------- p7Dloc_56CB: - pop bc - pop hl - pop de - inc hl - dec bc - ld a, c - or b - jr z, p7Dloc_56D6 - jr p7Dloc_56B3 + pop bc + pop hl + pop de + inc hl + dec bc + ld a, c + or b + jr z, p7Dloc_56D6 + jr p7Dloc_56B3 ; --------------------------------------------------------------------------- p7Dloc_56D6: ; Page7D_2C34+32j - pop de - pop hl - pop bc + pop de + pop hl + pop bc ret ; --------------------------------------------------------------------------- p7Dloc_56DA: - ld a, 0FFh - bit 7, a - pop bc - pop hl - pop hl - pop de - pop hl - pop bc + ld a, 0FFh + bit 7, a + pop bc + pop hl + pop hl + pop de + pop hl + pop bc ret ; End of function Page7D_2C34 @@ -5011,83 +5011,83 @@ push de push bc push af - ld hl, 4000h - inc hl - rst 28h -; --------------------------------------------------------------------------- - .dw 8051h + ld hl, 4000h + inc hl + rst 28h +; --------------------------------------------------------------------------- + .dw 8051h ; --------------------------------------------------------------------------- call p7Dsub_75FD - jr nz, p7Dloc_5737 - inc hl - pop af + jr nz, p7Dloc_5737 + inc hl + pop af call p7Dsub_761F - ld hl, (unk_839F) - push hl - ld hl, (unk_83A1) + ld hl, (unk_839F) + push hl + ld hl, (unk_83A1) push hl push af call p7Dsub_5525 push hl - inc hl - rst 28h -; --------------------------------------------------------------------------- - .dw 805Ah -; --------------------------------------------------------------------------- - or a + inc hl + rst 28h +; --------------------------------------------------------------------------- + .dw 805Ah +; --------------------------------------------------------------------------- + or a adc hl, bc - pop bc - or a - sbc hl, bc - pop af - pop bc - ld (unk_83A1), bc - pop bc - ld (unk_839F), bc - push af - push hl - ld hl, 4000h - inc hl - rst 28h -; --------------------------------------------------------------------------- - .dw 805Ah -; --------------------------------------------------------------------------- - ld bc, 4000h - or a - sbc hl, bc - push hl - pop bc + pop bc + or a + sbc hl, bc + pop af + pop bc + ld (unk_83A1), bc + pop bc + ld (unk_839F), bc + push af + push hl + ld hl, 4000h + inc hl + rst 28h +; --------------------------------------------------------------------------- + .dw 805Ah +; --------------------------------------------------------------------------- + ld bc, 4000h + or a + sbc hl, bc + push hl + pop bc call p7Dsub_573C - pop bc - inc bc - inc bc + pop bc + inc bc + inc bc call p7Dsub_573C p7Dloc_5737: - pop af - pop bc - pop de - pop hl + pop af + pop bc + pop de + pop hl ret ; =============== S U B R O U T I N E ======================================= p7Dsub_573C: - ld hl, (unk_83A1) + ld hl, (unk_83A1) call p7Dsub_57C5 - or a + or a adc hl, bc call p7Dsub_57C5 - ld (unk_83A1), hl - ret nc - ld hl, (unk_839F) - inc h - jr nz, p7Dloc_5753 - inc l + ld (unk_83A1), hl + ret nc + ld hl, (unk_839F) + inc h + jr nz, p7Dloc_5753 + inc l p7Dloc_5753: - ld (unk_839F), hl + ld (unk_839F), hl ret ; End of function p7Dsub_573C @@ -5100,23 +5100,23 @@ push de push bc push af - inc hl - ld a, (hl) + inc hl + ld a, (hl) call p7Dsub_75FD - jr nz, p7Dloc_5768 + jr nz, p7Dloc_5768 p7Dloc_5762: - inc hl - ld a, (hl) - ld (de), a - inc de + inc hl + ld a, (hl) + ld (de), a + inc de djnz p7Dloc_5762 p7Dloc_5768: - pop af - pop bc - pop de - pop hl + pop af + pop bc + pop de + pop hl ret ; End of function p7Dsub_5757 @@ -5126,23 +5126,23 @@ p7Dsub_576D: push af - ld a, 1 + ld a, 1 call Page7D_2B86 - ld b, a + ld b, a call p7Dsub_75EC - sub b - ld b, 0 - ld c, a - ld hl, tempSwapArea + sub b + ld b, 0 + ld c, a + ld hl, tempSwapArea sla c - add hl, bc - ld a, 0FFh - ld (hl), a - inc hl - ld (hl), a - ld a, 1 + add hl, bc + ld a, 0FFh + ld (hl), a + inc hl + ld (hl), a + ld a, 1 call Page7D_2B62 - pop af + pop af ret ; End of function p7Dsub_576D @@ -5152,36 +5152,36 @@ p7Dsub_578D: push af - ld a, (unk_83A4) - or a - jr z, p7Dloc_57C3 - ld hl, (unk_83A1) + ld a, (unk_83A4) + or a + jr z, p7Dloc_57C3 + ld hl, (unk_83A1) call p7Dsub_57C5 - ld a, h - or l - jr nz, p7Dloc_57B2 - ld hl, (unk_839F) - ld a, h - or l - jr z, p7Dloc_57C3 + ld a, h + or l + jr nz, p7Dloc_57B2 + ld hl, (unk_839F) + ld a, h + or l + jr z, p7Dloc_57C3 call p7Dsub_57C5 - dec hl + dec hl call p7Dsub_57C5 - ld (unk_839F), hl - ld hl, 0 + ld (unk_839F), hl + ld hl, 0 p7Dloc_57B2: - dec hl + dec hl call p7Dsub_57C5 - ld (unk_83A1), hl - ld hl, (unk_839F) - ld a, l - or h - jr nz, p7Dloc_57C3 - ld hl, (unk_83A1) + ld (unk_83A1), hl + ld hl, (unk_839F) + ld a, l + or h + jr nz, p7Dloc_57C3 + ld hl, (unk_83A1) p7Dloc_57C3: - pop af + pop af ret ; End of function p7Dsub_578D @@ -5191,10 +5191,10 @@ p7Dsub_57C5: push af - ld a, l - ld l, h - ld h, a - pop af + ld a, l + ld l, h + ld h, a + pop af ret ; End of function p7Dsub_57C5 @@ -5204,280 +5204,280 @@ push bc push de call p7Dsub_5980 - jp z, p7Dloc_5973 - rst 28h -; --------------------------------------------------------------------------- - .dw 8057h -; --------------------------------------------------------------------------- - push hl - push hl - pop bc - rst 28h -; --------------------------------------------------------------------------- - .dw 802Dh -; --------------------------------------------------------------------------- - or a - sbc hl, bc - dec hl - ld (appInfo), hl - push hl - pop bc - pop hl + jp z, p7Dloc_5973 + rst 28h +; --------------------------------------------------------------------------- + .dw 8057h +; --------------------------------------------------------------------------- + push hl + push hl + pop bc + rst 28h +; --------------------------------------------------------------------------- + .dw 802Dh +; --------------------------------------------------------------------------- + or a + sbc hl, bc + dec hl + ld (appInfo), hl + push hl + pop bc + pop hl push hl call p7Dsub_4565 - dec hl - cp 0FFh - jp z, p7Dloc_5972 - cp 0 - jp z, JErrorNo + dec hl + cp 0FFh + jp z, p7Dloc_5972 + cp 0 + jp z, JErrorNo call p7Dsub_42D3 call p7Dsub_5980 - jp z, p7Dloc_5972 - pop de - inc de - ex de, hl + jp z, p7Dloc_5972 + pop de + inc de + ex de, hl call p7Dsub_597A - ld (OP2), a + ld (OP2), a call p7Dsub_40A6 - or a - ex de, hl + or a + ex de, hl adc hl, bc push hl - ld de, 0A20h - rst 28h -; --------------------------------------------------------------------------- - .dw 8027h -; --------------------------------------------------------------------------- - jr nz, p7Dloc_5832 - ld a, h - and 0Fh - or 40h ; '@' - ld h, a + ld de, 0A20h + rst 28h +; --------------------------------------------------------------------------- + .dw 8027h +; --------------------------------------------------------------------------- + jr nz, p7Dloc_5832 + ld a, h + and 0Fh + or 40h ; '@' + ld h, a call p7Dsub_597A - rst 28h -; --------------------------------------------------------------------------- - .dw 805Ah + rst 28h +; --------------------------------------------------------------------------- + .dw 805Ah ; --------------------------------------------------------------------------- p7Dloc_5823: - ld b, 0 + ld b, 0 push bc call p7Dsub_597A - ex de, hl - rst 28h -; --------------------------------------------------------------------------- - .dw 8021h -; --------------------------------------------------------------------------- - ex de, hl - pop bc - dec c - jr nz, p7Dloc_5823 + ex de, hl + rst 28h +; --------------------------------------------------------------------------- + .dw 8021h +; --------------------------------------------------------------------------- + ex de, hl + pop bc + dec c + jr nz, p7Dloc_5823 p7Dloc_5832: call p7Dsub_5980 - jp z, p7Dloc_5972 - ld hl, 4000h - ld a, 7Ah ; 'z' - ld de, 8070h - rst 28h -; --------------------------------------------------------------------------- - .dw 8075h -; --------------------------------------------------------------------------- - inc hl - ld a, 7Ah ; 'z' - rst 28h -; --------------------------------------------------------------------------- - .dw 805Ah -; --------------------------------------------------------------------------- - ld bc, 4000h - or a - sbc hl, bc - push hl - pop bc - ld de, ramStart - ld hl, 4000h - ld a, 7Ah ; 'z' - push bc - rst 28h -; --------------------------------------------------------------------------- - .dw 8054h -; --------------------------------------------------------------------------- - pop bc - pop de - ld hl, ramStart + jp z, p7Dloc_5972 + ld hl, 4000h + ld a, 7Ah ; 'z' + ld de, 8070h + rst 28h +; --------------------------------------------------------------------------- + .dw 8075h +; --------------------------------------------------------------------------- + inc hl + ld a, 7Ah ; 'z' + rst 28h +; --------------------------------------------------------------------------- + .dw 805Ah +; --------------------------------------------------------------------------- + ld bc, 4000h + or a + sbc hl, bc + push hl + pop bc + ld de, ramStart + ld hl, 4000h + ld a, 7Ah ; 'z' + push bc + rst 28h +; --------------------------------------------------------------------------- + .dw 8054h +; --------------------------------------------------------------------------- + pop bc + pop de + ld hl, ramStart call p7Dsub_597A push bc - rst 28h -; --------------------------------------------------------------------------- - .dw 8087h -; --------------------------------------------------------------------------- - pop bc - push de - ld hl, (appInfo) - or a + rst 28h +; --------------------------------------------------------------------------- + .dw 8087h +; --------------------------------------------------------------------------- + pop bc + push de + ld hl, (appInfo) + or a adc hl, bc - ld (appInfo), hl + ld (appInfo), hl call p7Dsub_75F5 p7Dloc_5877: call ZeroOP1 call p7Dsub_638B call OP2ToOP1 - jr c, p7Dloc_58AD + jr c, p7Dloc_58AD call p7Dloc_61A4 - pop de - ld bc, 4000h - or a - sbc hl, bc - push hl - pop bc - or a - ld hl, (appInfo) + pop de + ld bc, 4000h + or a + sbc hl, bc + push hl + pop bc + or a + ld hl, (appInfo) adc hl, bc - ld (appInfo), hl - ld hl, 4000h + ld (appInfo), hl + ld hl, 4000h push af call p7Dsub_597A - ld (OP2), a - pop af + ld (OP2), a + pop af call p7Dloc_40A9 - or a - ex de, hl + or a + ex de, hl adc hl, bc - ex de, hl - push de - jr p7Dloc_5877 + ex de, hl + push de + jr p7Dloc_5877 ; --------------------------------------------------------------------------- p7Dloc_58AD: - pop de - rst 28h -; --------------------------------------------------------------------------- - .dw 808Dh -; --------------------------------------------------------------------------- - ld hl, 4000h - push hl - ld hl, 0 - ld (unk_839F), hl - ld hl, (appInfo) + pop de + rst 28h +; --------------------------------------------------------------------------- + .dw 808Dh +; --------------------------------------------------------------------------- + ld hl, 4000h + push hl + ld hl, 0 + ld (unk_839F), hl + ld hl, (appInfo) call p7Dsub_57C5 - ld (unk_83A1), hl - pop hl - ld a, 1 - ld (unk_83A4), a + ld (unk_83A1), hl + pop hl + ld a, 1 + ld (unk_83A4), a p7Dloc_58CA: - ld a, 1 - ld (unk_83A3), a + ld a, 1 + ld (unk_83A3), a call p7Dsub_597A - ld de, ramStart - ld bc, 1 + ld de, ramStart + ld bc, 1 push hl call FlashToRam call p7Dsub_5E0A call p7Dsub_578D - ld a, h - or l - pop hl - inc hl - jr nz, p7Dloc_58CA - inc hl - inc hl - push hl - rst 28h -; --------------------------------------------------------------------------- - .dw 8018h -; --------------------------------------------------------------------------- - ld hl, 0D02h - ld (OP1), hl - ld hl, OP1 - pop de - push de - dec de - dec de - ld bc, 2 + ld a, h + or l + pop hl + inc hl + jr nz, p7Dloc_58CA + inc hl + inc hl + push hl + rst 28h +; --------------------------------------------------------------------------- + .dw 8018h +; --------------------------------------------------------------------------- + ld hl, 0D02h + ld (OP1), hl + ld hl, OP1 + pop de + push de + dec de + dec de + ld bc, 2 call p7Dsub_597A - rst 28h -; --------------------------------------------------------------------------- - .dw 8087h + rst 28h +; --------------------------------------------------------------------------- + .dw 8087h ; --------------------------------------------------------------------------- call p7Dsub_5980 - jp z, p7Dloc_5972 - ld de, 0A20h - rst 28h -; --------------------------------------------------------------------------- - .dw 8027h + jp z, p7Dloc_5972 + ld de, 0A20h + rst 28h +; --------------------------------------------------------------------------- + .dw 8027h ; --------------------------------------------------------------------------- call p7Dsub_4574 - inc bc - dec hl - ld de, ramStart - rst 28h -; --------------------------------------------------------------------------- - .dw 8054h -; --------------------------------------------------------------------------- - ld de, bigInteger1 - ld b, 0 - ld a, (unk_8291) - ld c, a - ld hl, 8291h - inc bc + inc bc + dec hl + ld de, ramStart + rst 28h +; --------------------------------------------------------------------------- + .dw 8054h +; --------------------------------------------------------------------------- + ld de, bigInteger1 + ld b, 0 + ld a, (unk_8291) + ld c, a + ld hl, 8291h + inc bc ldir - rst 28h -; --------------------------------------------------------------------------- - .dw 80C0h -; --------------------------------------------------------------------------- - pop de - ld hl, OP1 - ld b, 0 - ld a, (hl) - ld c, a - inc bc + rst 28h +; --------------------------------------------------------------------------- + .dw 80C0h +; --------------------------------------------------------------------------- + pop de + ld hl, OP1 + ld b, 0 + ld a, (hl) + ld c, a + inc bc call p7Dsub_597A push bc - rst 28h -; --------------------------------------------------------------------------- - .dw 8087h -; --------------------------------------------------------------------------- - ld hl, (appInfo) - pop bc - inc bc - inc bc - or a + rst 28h +; --------------------------------------------------------------------------- + .dw 8087h +; --------------------------------------------------------------------------- + ld hl, (appInfo) + pop bc + inc bc + inc bc + or a adc hl, bc - ld (unk_839F), hl + ld (unk_839F), hl call p7Dsub_597A - ld (OP2), a + ld (OP2), a call p7Dsub_7700 push de - rst 28h -; --------------------------------------------------------------------------- - .dw 8057h -; --------------------------------------------------------------------------- - ld bc, 1D00h - add hl, bc - pop de - ld bc, 300h + rst 28h +; --------------------------------------------------------------------------- + .dw 8057h +; --------------------------------------------------------------------------- + ld bc, 1D00h + add hl, bc + pop de + ld bc, 300h call p7Dsub_40A6 - ld hl, (unk_839F) - ld bc, 300h - add hl, bc - ld (unk_839F), hl - ld hl, 4000h - xor a - pop de - pop bc + ld hl, (unk_839F) + ld bc, 300h + add hl, bc + ld (unk_839F), hl + ld hl, 4000h + xor a + pop de + pop bc ret ; --------------------------------------------------------------------------- p7Dloc_5972: - pop hl + pop hl p7Dloc_5973: - pop de - pop bc - ld a, 0FFh - bit 7, a + pop de + pop bc + ld a, 0FFh + bit 7, a ret ; =============== S U B R O U T I N E ======================================= @@ -5485,8 +5485,8 @@ p7Dsub_597A: call FindSwapSector - inc a - inc a + inc a + inc a ret ; End of function p7Dsub_597A @@ -5495,11 +5495,11 @@ p7Dsub_5980: - set 2, (iy+16h) - in a, (2) - bit 0, a - ret nz - res 2, (iy+16h) + set 2, (iy+16h) + in a, (2) + bit 0, a + ret nz + res 2, (iy+16h) ret ; End of function p7Dsub_5980 @@ -5509,30 +5509,30 @@ p7Dsub_598E: push bc - ld de, 847Ch - ld b, 5 + ld de, 847Ch + ld b, 5 p7Dloc_5994: call DivHLBy10 - add a, 30h ; '0' - ld (de), a - dec de + add a, 30h ; '0' + ld (de), a + dec de djnz p7Dloc_5994 - sub a - ld (unk_847C+1), a - ex de, hl - ld a, 30h ; '0' - ld b, 4 + sub a + ld (unk_847C+1), a + ex de, hl + ld a, 30h ; '0' + ld b, 4 p7Dloc_59A6: - inc hl - cp (hl) - jr nz, p7Dloc_59AE - ld (hl), 20h ; ' ' + inc hl + cp (hl) + jr nz, p7Dloc_59AE + ld (hl), 20h ; ' ' djnz p7Dloc_59A6 p7Dloc_59AE: - pop bc + pop bc call Page0Call_3D4D ret ; End of function p7Dsub_598E @@ -5541,131 +5541,131 @@ p7Dloc_59B3: push af - ld de, 0E10h - rst 28h -; --------------------------------------------------------------------------- - .dw 80B1h -; --------------------------------------------------------------------------- - ld de, 18h - rst 28h -; --------------------------------------------------------------------------- - .dw 80B1h -; --------------------------------------------------------------------------- - ld hl, (OP1M) + ld de, 0E10h + rst 28h +; --------------------------------------------------------------------------- + .dw 80B1h +; --------------------------------------------------------------------------- + ld de, 18h + rst 28h +; --------------------------------------------------------------------------- + .dw 80B1h +; --------------------------------------------------------------------------- + ld hl, (OP1M) call p7Dsub_57C5 - ld de, 16Dh - rst 28h -; --------------------------------------------------------------------------- - .dw 804Bh -; --------------------------------------------------------------------------- - push de - pop hl - ld bc, 7CDh - or a + ld de, 16Dh + rst 28h +; --------------------------------------------------------------------------- + .dw 804Bh +; --------------------------------------------------------------------------- + push de + pop hl + ld bc, 7CDh + or a adc hl, bc call p7Dsub_5A68 - or a - ld hl, (OP1M) + or a + ld hl, (OP1M) call p7Dsub_57C5 - sbc hl, bc + sbc hl, bc call p7Dsub_57C5 - ld (OP1M), hl + ld (OP1M), hl call p7Dsub_57C5 - ld de, 16Dh - rst 28h -; --------------------------------------------------------------------------- - .dw 804Bh -; --------------------------------------------------------------------------- - push de - pop hl - ld bc, 7CDh - or a + ld de, 16Dh + rst 28h +; --------------------------------------------------------------------------- + .dw 804Bh +; --------------------------------------------------------------------------- + push de + pop hl + ld bc, 7CDh + or a adc hl, bc push hl - ld (tempSwapArea), hl - ld a, e - ld de, 16Dh - rst 28h -; --------------------------------------------------------------------------- - .dw 8045h -; --------------------------------------------------------------------------- - push hl - pop bc - ld hl, (OP1M) + ld (tempSwapArea), hl + ld a, e + ld de, 16Dh + rst 28h +; --------------------------------------------------------------------------- + .dw 8045h +; --------------------------------------------------------------------------- + push hl + pop bc + ld hl, (OP1M) call p7Dsub_57C5 - or a - sbc hl, bc - ld bc, 0 + or a + sbc hl, bc + ld bc, 0 p7Dloc_5A10: push hl - ld a, 2 - cp c - jr nz, p7Dloc_5A26 - ld hl, (tempSwapArea) + ld a, 2 + cp c + jr nz, p7Dloc_5A26 + ld hl, (tempSwapArea) call p7Dsub_5AA5 - jr nz, p7Dloc_5A26 - ld hl, end_of_7D_table - ld e, (hl) - inc hl - ld d, (hl) - jr p7Dloc_5A31 + jr nz, p7Dloc_5A26 + ld hl, end_of_7D_table + ld e, (hl) + inc hl + ld d, (hl) + jr p7Dloc_5A31 ; --------------------------------------------------------------------------- p7Dloc_5A26: - or a - ld hl, start_of_7D_table + or a + ld hl, start_of_7D_table adc hl, bc adc hl, bc - ld e, (hl) - inc hl - ld d, (hl) + ld e, (hl) + inc hl + ld d, (hl) p7Dloc_5A31: - or a - pop hl - push hl - sbc hl, de - jr c, p7Dloc_5A3C - pop hl - inc bc - jr p7Dloc_5A10 + or a + pop hl + push hl + sbc hl, de + jr c, p7Dloc_5A3C + pop hl + inc bc + jr p7Dloc_5A10 ; --------------------------------------------------------------------------- p7Dloc_5A3C: - pop hl - push hl - dec bc - ld a, 2 - cp c - jr nz, p7Dloc_5A54 - ld hl, (tempSwapArea) + pop hl + push hl + dec bc + ld a, 2 + cp c + jr nz, p7Dloc_5A54 + ld hl, (tempSwapArea) call p7Dsub_5AA5 - jr nz, p7Dloc_5A54 - ld hl, end_of_7D_table - ld e, (hl) - inc hl - ld d, (hl) - jr p7Dloc_5A5F + jr nz, p7Dloc_5A54 + ld hl, end_of_7D_table + ld e, (hl) + inc hl + ld d, (hl) + jr p7Dloc_5A5F ; --------------------------------------------------------------------------- p7Dloc_5A54: - ld hl, start_of_7D_table - or a + ld hl, start_of_7D_table + or a adc hl, bc adc hl, bc - ld e, (hl) - inc hl - ld d, (hl) + ld e, (hl) + inc hl + ld d, (hl) p7Dloc_5A5F: - pop hl - or a - sbc hl, de - pop de - inc hl - inc bc - pop af + pop hl + or a + sbc hl, de + pop de + inc hl + inc bc + pop af ret ; =============== S U B R O U T I N E ======================================= @@ -5676,52 +5676,52 @@ push hl push de push hl - ld bc, 7CDh - or a - sbc hl, bc - pop hl - ret c - jr z, p7Dloc_5A77 - dec hl + ld bc, 7CDh + or a + sbc hl, bc + pop hl + ret c + jr z, p7Dloc_5A77 + dec hl p7Dloc_5A77: push hl - ld de, 4 - rst 28h -; --------------------------------------------------------------------------- - .dw 804Bh -; --------------------------------------------------------------------------- - pop hl - push de - push hl - ld de, 64h ; 'd' - rst 28h -; --------------------------------------------------------------------------- - .dw 804Bh -; --------------------------------------------------------------------------- - pop hl - push de - ld de, 190h - rst 28h -; --------------------------------------------------------------------------- - .dw 804Bh -; --------------------------------------------------------------------------- - pop bc - pop hl - push de - or a - sbc hl, bc - pop bc - or a + ld de, 4 + rst 28h +; --------------------------------------------------------------------------- + .dw 804Bh +; --------------------------------------------------------------------------- + pop hl + push de + push hl + ld de, 64h ; 'd' + rst 28h +; --------------------------------------------------------------------------- + .dw 804Bh +; --------------------------------------------------------------------------- + pop hl + push de + ld de, 190h + rst 28h +; --------------------------------------------------------------------------- + .dw 804Bh +; --------------------------------------------------------------------------- + pop bc + pop hl + push de + or a + sbc hl, bc + pop bc + or a adc hl, bc - ld bc, 1E4h - or a - sbc hl, bc - push hl - pop bc - pop de - pop hl - pop af + ld bc, 1E4h + or a + sbc hl, bc + push hl + pop bc + pop de + pop hl + pop af ret ; End of function p7Dsub_5A68 @@ -5731,39 +5731,39 @@ p7Dsub_5AA5: push hl - ld de, 4 - rst 28h -; --------------------------------------------------------------------------- - .dw 804Bh -; --------------------------------------------------------------------------- - ld a, l - or h - jr nz, p7Dloc_5ACA - pop hl - push hl - ld de, 64h ; 'd' - rst 28h -; --------------------------------------------------------------------------- - .dw 804Bh -; --------------------------------------------------------------------------- - ld a, l - or h - jr nz, p7Dloc_5AC6 - pop hl - push hl - ld de, 190h - rst 28h -; --------------------------------------------------------------------------- - .dw 804Bh -; --------------------------------------------------------------------------- - jr nz, p7Dloc_5ACA + ld de, 4 + rst 28h +; --------------------------------------------------------------------------- + .dw 804Bh +; --------------------------------------------------------------------------- + ld a, l + or h + jr nz, p7Dloc_5ACA + pop hl + push hl + ld de, 64h ; 'd' + rst 28h +; --------------------------------------------------------------------------- + .dw 804Bh +; --------------------------------------------------------------------------- + ld a, l + or h + jr nz, p7Dloc_5AC6 + pop hl + push hl + ld de, 190h + rst 28h +; --------------------------------------------------------------------------- + .dw 804Bh +; --------------------------------------------------------------------------- + jr nz, p7Dloc_5ACA p7Dloc_5AC6: - ld a, 0 - bit 7, a + ld a, 0 + bit 7, a p7Dloc_5ACA: - pop hl + pop hl ret ; End of function p7Dsub_5AA5 @@ -5774,16 +5774,16 @@ push bc push de push af - ld de, ramStart - ld bc, 100h - rst 28h -; --------------------------------------------------------------------------- - .dw 8054h -; --------------------------------------------------------------------------- - pop af - pop de - pop bc - pop hl + ld de, ramStart + ld bc, 100h + rst 28h +; --------------------------------------------------------------------------- + .dw 8054h +; --------------------------------------------------------------------------- + pop af + pop de + pop bc + pop hl ret ; --------------------------------------------------------------------------- @@ -5793,50 +5793,50 @@ push af call Page0Call_3D0B call Page0Call_3D2F - ld hl, aIdlist - ld a, 3Dh ; '=' - bit 1, (iy+35h) + ld hl, aIdlist + ld a, 3Dh ; '=' + bit 1, (iy+35h) call nz, Page0Call_3C45 call p7Dsub_7045 call Page0Call_23DE - jr c, p7Dloc_5B0D - ld a, (de) - ld hl, (curRow+1) - ld bc, 5 + jr c, p7Dloc_5B0D + ld a, (de) + ld hl, (curRow+1) + ld bc, 5 adc hl, bc - ld (curRow+1), hl - ld l, a - ld h, 0 + ld (curRow+1), hl + ld l, a + ld h, 0 call Page0Call_3C7B p7Dloc_5B0D: - pop af - pop bc - pop hl + pop af + pop bc + pop hl ret ; --------------------------------------------------------------------------- Page7D_2E56: call Page0Call_23DE - jr c, locret_5B2E - push af - ld a, (de) - ld l, a - inc de - ld a, (de) - ld h, a - dec de - ld a, l - or h - jr z, p7Dloc_5B2A - pop af - ld bc, 1 + jr c, locret_5B2E + push af + ld a, (de) + ld l, a + inc de + ld a, (de) + ld h, a + dec de + ld a, l + or h + jr z, p7Dloc_5B2A + pop af + ld bc, 1 call Page0Call_31D7 - jr Page7D_2E56 + jr Page7D_2E56 ; --------------------------------------------------------------------------- p7Dloc_5B2A: - pop af + pop af call Page0Call_23D4 locret_5B2E: @@ -5845,24 +5845,24 @@ Page7D_2BC2: push af - ld de, 0A10h - rst 28h -; --------------------------------------------------------------------------- - .dw 8027h -; --------------------------------------------------------------------------- - jr nz, p7Dloc_5B49 + ld de, 0A10h + rst 28h +; --------------------------------------------------------------------------- + .dw 8027h +; --------------------------------------------------------------------------- + jr nz, p7Dloc_5B49 call p7Dsub_4574 - ld de, OP2 - ld b, c - ld a, 7Eh ; '~' + ld de, OP2 + ld b, c + ld a, 7Eh ; '~' call p7Dsub_761F - pop af + pop af call p7Dsub_5B4D ret ; --------------------------------------------------------------------------- p7Dloc_5B49: - pop af + pop af scf ccf ret @@ -5874,110 +5874,110 @@ push bc push de call p7Dsub_7656 - ld hl, 4003h - ld (appSearchPage), a + ld hl, 4003h + ld (appSearchPage), a p7Dloc_5B58: push hl - rst 28h -; --------------------------------------------------------------------------- - .dw 8051h -; --------------------------------------------------------------------------- - cp 3 - jr z, p7Dloc_5B67 - cp 0FFh - jr z, p7Dloc_5BA8 - pop hl - jr p7Dloc_5BC2 + rst 28h +; --------------------------------------------------------------------------- + .dw 8051h +; --------------------------------------------------------------------------- + cp 3 + jr z, p7Dloc_5B67 + cp 0FFh + jr z, p7Dloc_5BA8 + pop hl + jr p7Dloc_5BC2 ; --------------------------------------------------------------------------- p7Dloc_5B67: - ld a, (appSearchPage) + ld a, (appSearchPage) call p7Dloc_442C push bc push de - ld hl, OP2 - pop de - pop bc - jr nz, p7Dloc_5BC2 - ld b, c + ld hl, OP2 + pop de + pop bc + jr nz, p7Dloc_5BC2 + ld b, c p7Dloc_5B77: - ld a, (hl) - ld c, a - ex de, hl - ld a, (appSearchPage) - rst 28h -; --------------------------------------------------------------------------- - .dw 8051h -; --------------------------------------------------------------------------- - ex de, hl - cp c - jr nz, p7Dloc_5B8E - inc de - inc hl + ld a, (hl) + ld c, a + ex de, hl + ld a, (appSearchPage) + rst 28h +; --------------------------------------------------------------------------- + .dw 8051h +; --------------------------------------------------------------------------- + ex de, hl + cp c + jr nz, p7Dloc_5B8E + inc de + inc hl djnz p7Dloc_5B77 - pop hl - ld a, (appSearchPage) - jr p7Dloc_5BC6 + pop hl + ld a, (appSearchPage) + jr p7Dloc_5BC6 ; --------------------------------------------------------------------------- p7Dloc_5B8E: - pop hl - inc hl - ld a, (appSearchPage) - push de - rst 28h -; --------------------------------------------------------------------------- - .dw 805Ah -; --------------------------------------------------------------------------- - pop de - or a + pop hl + inc hl + ld a, (appSearchPage) + push de + rst 28h +; --------------------------------------------------------------------------- + .dw 805Ah +; --------------------------------------------------------------------------- + pop de + or a adc hl, bc - inc hl - ld a, (appSearchPage) - push de - rst 28h -; --------------------------------------------------------------------------- - .dw 805Ah -; --------------------------------------------------------------------------- - pop de + inc hl + ld a, (appSearchPage) + push de + rst 28h +; --------------------------------------------------------------------------- + .dw 805Ah +; --------------------------------------------------------------------------- + pop de adc hl, bc - jr p7Dloc_5B58 + jr p7Dloc_5B58 ; --------------------------------------------------------------------------- p7Dloc_5BA8: - pop hl - ld a, (appSearchPage) - inc a - ld (appSearchPage), a + pop hl + ld a, (appSearchPage) + inc a + ld (appSearchPage), a call NZIf83Plus - jr nz, p7Dloc_5BB9 - cp 6Ch ; 'l' - jr p7Dloc_5BBB + jr nz, p7Dloc_5BB9 + cp 6Ch ; 'l' + jr p7Dloc_5BBB ; --------------------------------------------------------------------------- p7Dloc_5BB9: - cp 18h + cp 18h p7Dloc_5BBB: - jr z, p7Dloc_5BC2 - ld hl, 4000h - jr p7Dloc_5B58 + jr z, p7Dloc_5BC2 + ld hl, 4000h + jr p7Dloc_5B58 ; --------------------------------------------------------------------------- p7Dloc_5BC2: scf ccf - jr p7Dloc_5BC7 + jr p7Dloc_5BC7 ; --------------------------------------------------------------------------- p7Dloc_5BC6: scf p7Dloc_5BC7: - pop de - pop bc + pop de + pop bc ret ; End of function p7Dsub_5B4D @@ -5987,83 +5987,83 @@ push de push bc push hl - ld (appSearchPage), a + ld (appSearchPage), a call p7Dsub_4894 call p7Dsub_457C - ld a, (appSearchPage) - pop hl + ld a, (appSearchPage) + pop hl call p7Dloc_529F - pop bc - pop de + pop bc + pop de ret ; --------------------------------------------------------------------------- Page7D_3C54: - ld (Abackup), a - ld a, i - di - push af - ld a, (Abackup) - push af - ld a, 1 + ld (Abackup), a + ld a, i + di + push af + ld a, (Abackup) + push af + ld a, 1 nop di nop nop im 1 di - out (14h), a + out (14h), a di call checkForFlashTrickery - pop af + pop af push de push bc p7Dloc_5BFD: - ld de, 410h - rst 28h -; --------------------------------------------------------------------------- - .dw 8027h -; --------------------------------------------------------------------------- - jr z, p7Dloc_5C0A - rst 28h -; --------------------------------------------------------------------------- - .dw 80AEh -; --------------------------------------------------------------------------- - jr p7Dloc_5BFD + ld de, 410h + rst 28h +; --------------------------------------------------------------------------- + .dw 8027h +; --------------------------------------------------------------------------- + jr z, p7Dloc_5C0A + rst 28h +; --------------------------------------------------------------------------- + .dw 80AEh +; --------------------------------------------------------------------------- + jr p7Dloc_5BFD ; --------------------------------------------------------------------------- p7Dloc_5C0A: call p7Dsub_4574 - ld de, OP2 - rst 28h -; --------------------------------------------------------------------------- - .dw 8051h -; --------------------------------------------------------------------------- - ld (de), a - inc de + ld de, OP2 + rst 28h +; --------------------------------------------------------------------------- + .dw 8051h +; --------------------------------------------------------------------------- + ld (de), a + inc de call p7Dsub_4565 - ld (de), a - ld hl, OP2 - pop bc - pop de + ld (de), a + ld hl, OP2 + pop bc + pop de call relockFlashBack - ld (Abackup), a - pop af - jp po, p7Dloc_5C29 + ld (Abackup), a + pop af + jp po, p7Dloc_5C29 ei p7Dloc_5C29: - ld a, (Abackup) + ld a, (Abackup) ret ; --------------------------------------------------------------------------- p7Dloc_5C2D: - ld hl, 4000h - ld de, 8090h - rst 28h -; --------------------------------------------------------------------------- - .dw 8075h + ld hl, 4000h + ld de, 8090h + rst 28h +; --------------------------------------------------------------------------- + .dw 8075h ; --------------------------------------------------------------------------- ret ; --------------------------------------------------------------------------- @@ -6071,13 +6071,13 @@ Page7D_2C1C: push hl call p7Dsub_7656 - ld hl, 4000h - rst 28h -; --------------------------------------------------------------------------- - .dw 8051h -; --------------------------------------------------------------------------- - cp 0 - pop hl + ld hl, 4000h + rst 28h +; --------------------------------------------------------------------------- + .dw 8051h +; --------------------------------------------------------------------------- + cp 0 + pop hl ret ; --------------------------------------------------------------------------- @@ -6087,106 +6087,106 @@ push af push hl push af - ld a, 1 + ld a, 1 nop di nop nop im 1 di - out (14h), a + out (14h), a di call checkForFlashTrickery - pop af - ld de, 4000h - ld b, 0 + pop af + ld de, 4000h + ld b, 0 call p7Dsub_7656 - rst 28h -; --------------------------------------------------------------------------- - .dw 80C6h -; --------------------------------------------------------------------------- - pop hl - push hl - ld b, l + rst 28h +; --------------------------------------------------------------------------- + .dw 80C6h +; --------------------------------------------------------------------------- + pop hl + push hl + ld b, l call p7Dsub_7656 - rst 28h -; --------------------------------------------------------------------------- - .dw 80C6h -; --------------------------------------------------------------------------- - pop hl - ld b, h + rst 28h +; --------------------------------------------------------------------------- + .dw 80C6h +; --------------------------------------------------------------------------- + pop hl + ld b, h call p7Dsub_7656 - rst 28h -; --------------------------------------------------------------------------- - .dw 80C6h -; --------------------------------------------------------------------------- - pop af - pop bc - pop de - jp relockFlashBack + rst 28h +; --------------------------------------------------------------------------- + .dw 80C6h +; --------------------------------------------------------------------------- + pop af + pop bc + pop de + jp relockFlashBack ; --------------------------------------------------------------------------- Page7D_3C4E: push hl p7Dloc_5C7D: - ld a, (ix+0) + ld a, (ix+0) push bc call p7Dsub_5C8E - pop bc - inc ix + pop bc + inc ix djnz p7Dloc_5C7D call p7Dsub_6503 - pop hl + pop hl ret ; =============== S U B R O U T I N E ======================================= p7Dsub_5C8E: - ld a, (ix+0) - push af - and 0F0h ; '�' + ld a, (ix+0) + push af + and 0F0h ; '�' srl a srl a srl a srl a - ld b, 2 + ld b, 2 p7Dloc_5C9E: push af - sub 0Ah - jr c, p7Dloc_5CB2 - pop af - add a, 37h ; '7' - ld (hl), a - inc hl - dec b - ld a, b - or b - jr z, p7Dloc_5CC1 - pop af - and 0Fh - jr p7Dloc_5C9E + sub 0Ah + jr c, p7Dloc_5CB2 + pop af + add a, 37h ; '7' + ld (hl), a + inc hl + dec b + ld a, b + or b + jr z, p7Dloc_5CC1 + pop af + and 0Fh + jr p7Dloc_5C9E ; --------------------------------------------------------------------------- p7Dloc_5CB2: - pop af - add a, 30h ; '0' - ld (hl), a - inc hl - dec b - ld a, b - or b - jr z, p7Dloc_5CC1 - pop af - and 0Fh - jr p7Dloc_5C9E + pop af + add a, 30h ; '0' + ld (hl), a + inc hl + dec b + ld a, b + or b + jr z, p7Dloc_5CC1 + pop af + and 0Fh + jr p7Dloc_5C9E ; --------------------------------------------------------------------------- p7Dloc_5CC1: - ld a, 0 - ld (hl), a + ld a, 0 + ld (hl), a ret ; End of function p7Dsub_5C8E @@ -6196,48 +6196,48 @@ push hl push bc push de - ld a, (hl) - push af - and 0F0h ; '�' + ld a, (hl) + push af + and 0F0h ; '�' srl a srl a srl a srl a - ld b, 2 + ld b, 2 p7Dloc_5CD6: push af - sub 0Ah - jr c, p7Dloc_5CEB - pop af - add a, 37h ; '7' + sub 0Ah + jr c, p7Dloc_5CEB + pop af + add a, 37h ; '7' call Page0Call_3D47 - dec b - ld a, b - or b - jr z, p7Dloc_5CFB - pop af - and 0Fh - jr p7Dloc_5CD6 + dec b + ld a, b + or b + jr z, p7Dloc_5CFB + pop af + and 0Fh + jr p7Dloc_5CD6 ; --------------------------------------------------------------------------- p7Dloc_5CEB: - pop af - add a, 30h ; '0' + pop af + add a, 30h ; '0' call Page0Call_3D47 - dec b - ld a, b - or b - jr z, p7Dloc_5CFB - pop af - and 0Fh - jr p7Dloc_5CD6 + dec b + ld a, b + or b + jr z, p7Dloc_5CFB + pop af + and 0Fh + jr p7Dloc_5CD6 ; --------------------------------------------------------------------------- p7Dloc_5CFB: - pop de - pop bc - pop hl + pop de + pop bc + pop hl ret ; =============== S U B R O U T I N E ======================================= @@ -6249,32 +6249,32 @@ push hl push de push af - ld a, c - or b - jr z, p7Dloc_5D18 - ld de, MD5Buffer + ld a, c + or b + jr z, p7Dloc_5D18 + ld de, MD5Buffer p7Dloc_5D0B: - pop af - push af - rst 28h -; --------------------------------------------------------------------------- - .dw 8051h -; --------------------------------------------------------------------------- - ld (de), a - inc de - inc hl - dec bc - ld a, c - or b - jr nz, p7Dloc_5D0B + pop af + push af + rst 28h +; --------------------------------------------------------------------------- + .dw 8051h +; --------------------------------------------------------------------------- + ld (de), a + inc de + inc hl + dec bc + ld a, c + or b + jr nz, p7Dloc_5D0B p7Dloc_5D18: - pop af - pop de - pop hl - pop bc - pop af + pop af + pop de + pop hl + pop bc + pop af ret ; End of function p7Dsub_5CFF @@ -6286,36 +6286,36 @@ push bc push de push af - ld b, a - ld a, 0 - or c - jr z, p7Dloc_5D3D - ld a, b - ld de, MD5Buffer - ld b, c - ld hl, 0 - ld a, (de) - ld l, a - dec b - ld a, b - or b - jr z, p7Dloc_5D3F - inc de - ld a, l - ld h, a - ld a, (de) - ld h, a - jr p7Dloc_5D3F + ld b, a + ld a, 0 + or c + jr z, p7Dloc_5D3D + ld a, b + ld de, MD5Buffer + ld b, c + ld hl, 0 + ld a, (de) + ld l, a + dec b + ld a, b + or b + jr z, p7Dloc_5D3F + inc de + ld a, l + ld h, a + ld a, (de) + ld h, a + jr p7Dloc_5D3F ; --------------------------------------------------------------------------- p7Dloc_5D3D: - ld h, a - ld l, a + ld h, a + ld l, a p7Dloc_5D3F: - pop af - pop de - pop bc + pop af + pop de + pop bc ret ; End of function p7Dsub_5D1E @@ -6327,36 +6327,36 @@ push hl push de push af - ld b, a - ld a, 0 - or c - jr z, p7Dloc_5D62 - ld a, b - ld hl, MD5Buffer - ld e, c - ld bc, 0 - ld a, (hl) - ld c, a - dec e - ld a, e - or e - jr z, p7Dloc_5D64 - inc hl - ld a, c - ld b, a - ld a, (hl) - ld c, a - jr p7Dloc_5D64 + ld b, a + ld a, 0 + or c + jr z, p7Dloc_5D62 + ld a, b + ld hl, MD5Buffer + ld e, c + ld bc, 0 + ld a, (hl) + ld c, a + dec e + ld a, e + or e + jr z, p7Dloc_5D64 + inc hl + ld a, c + ld b, a + ld a, (hl) + ld c, a + jr p7Dloc_5D64 ; --------------------------------------------------------------------------- p7Dloc_5D62: - ld b, a - ld c, a + ld b, a + ld c, a p7Dloc_5D64: - pop af - pop de - pop hl + pop af + pop de + pop hl ret ; End of function p7Dsub_5D43 @@ -6368,85 +6368,85 @@ push af push hl call Page7D_2B56 - ld e, b - ld d, 0 - push de - inc b - ld c, 0 - ld a, 8 + ld e, b + ld d, 0 + push de + inc b + ld c, 0 + ld a, 8 p7Dloc_5D76: - cp b - jr z, p7Dloc_5DC2 - jr nc, p7Dloc_5DC0 - push bc - ld hl, 4000h + cp b + jr z, p7Dloc_5DC2 + jr nc, p7Dloc_5DC0 + push bc + ld hl, 4000h push af call Page7D_2CD0 - cp 0FEh ; '�' - jr nz, p7Dloc_5D8D - pop af - add a, 4 + cp 0FEh ; '�' + jr nz, p7Dloc_5D8D + pop af + add a, 4 p7Dloc_5D8A: - pop bc - jr p7Dloc_5D76 + pop bc + jr p7Dloc_5D76 ; --------------------------------------------------------------------------- p7Dloc_5D8D: - cp 0FFh - jr z, p7Dloc_5D9F - pop af - pop bc - pop de - push af - ld a, c - add a, d - ld d, a - pop af - push de - ld c, 0 - push bc - push af - inc hl + cp 0FFh + jr z, p7Dloc_5D9F + pop af + pop bc + pop de + push af + ld a, c + add a, d + ld d, a + pop af + push de + ld c, 0 + push bc + push af + inc hl p7Dloc_5D9F: - pop af - ld c, 0FFh + pop af + ld c, 0FFh call Page7D_2B6E - ld bc, 4000h - or a - sbc hl, bc - jr nz, p7Dloc_5DB0 - pop bc - inc c + ld bc, 4000h + or a + sbc hl, bc + jr nz, p7Dloc_5DB0 + pop bc + inc c push bc p7Dloc_5DB0: ; Page7D_2E44+56j - inc a - pop bc - cp b - jr z, p7Dloc_5DC2 + inc a + pop bc + cp b + jr z, p7Dloc_5DC2 push bc call p7Dsub_67EC - jr z, p7Dloc_5D8A - pop bc - inc c - push bc - jr p7Dloc_5DB0 + jr z, p7Dloc_5D8A + pop bc + inc c + push bc + jr p7Dloc_5DB0 ; --------------------------------------------------------------------------- p7Dloc_5DC0: - xor a - ld c, a + xor a + ld c, a p7Dloc_5DC2: ; Page7D_2E44+4Bj - ld b, c - pop de - pop hl - pop af + ld b, c + pop de + pop hl + pop af ret ; End of function Page7D_2E44 @@ -6456,28 +6456,28 @@ p7Dsub_5DC7: call Page7D_2E44 - ld c, e - push bc - push de - ld a, 1 - ld hl, ramStart - ld de, 8080h - rst 28h -; --------------------------------------------------------------------------- - .dw 8075h -; --------------------------------------------------------------------------- - inc hl - ld a, 1 - rst 28h -; --------------------------------------------------------------------------- - .dw 805Ah -; --------------------------------------------------------------------------- - ld a, (hl) - pop de - ld e, d - ld d, a - pop bc - sub b + ld c, e + push bc + push de + ld a, 1 + ld hl, ramStart + ld de, 8080h + rst 28h +; --------------------------------------------------------------------------- + .dw 8075h +; --------------------------------------------------------------------------- + inc hl + ld a, 1 + rst 28h +; --------------------------------------------------------------------------- + .dw 805Ah +; --------------------------------------------------------------------------- + ld a, (hl) + pop de + ld e, d + ld d, a + pop bc + sub b ret ; End of function p7Dsub_5DC7 @@ -6488,32 +6488,32 @@ push bc push de push hl - rst 28h -; --------------------------------------------------------------------------- - .dw 802Dh -; --------------------------------------------------------------------------- - ex de, hl - rst 28h -; --------------------------------------------------------------------------- - .dw 8057h -; --------------------------------------------------------------------------- - ex de, hl - or a - sbc hl, de - ex de, hl - ld hl, 1F18h + rst 28h +; --------------------------------------------------------------------------- + .dw 802Dh +; --------------------------------------------------------------------------- + ex de, hl + rst 28h +; --------------------------------------------------------------------------- + .dw 8057h +; --------------------------------------------------------------------------- + ex de, hl + or a + sbc hl, de + ex de, hl + ld hl, 1F18h call NZIf83Plus - jr nz, p7Dloc_5E00 - ld hl, 1DEAh + jr nz, p7Dloc_5E00 + ld hl, 1DEAh p7Dloc_5E00: - or a - sbc hl, de - pop bc - sbc hl, bc - pop de - pop bc - pop hl + or a + sbc hl, de + pop bc + sbc hl, bc + pop de + pop bc + pop hl ret ; =============== S U B R O U T I N E ======================================= @@ -6521,29 +6521,29 @@ p7Dsub_5E0A: ; p7Dsub_7240:p7Dloc_739Bp - ld a, (unk_83A3) - ld b, a - ld c, 0 - or c - jr z, p7Dloc_5E23 - ld hl, ramStart + ld a, (unk_83A3) + ld b, a + ld c, 0 + or c + jr z, p7Dloc_5E23 + ld hl, ramStart p7Dloc_5E16: push bc push hl - ld bc, 1 - rst 28h -; --------------------------------------------------------------------------- - .dw 8090h -; --------------------------------------------------------------------------- - pop hl - inc hl - pop bc + ld bc, 1 + rst 28h +; --------------------------------------------------------------------------- + .dw 8090h +; --------------------------------------------------------------------------- + pop hl + inc hl + pop bc djnz p7Dloc_5E16 p7Dloc_5E23: - ld a, 0 - ld (unk_83A3), a + ld a, 0 + ld (unk_83A3), a ret ; End of function p7Dsub_5E0A @@ -6552,16 +6552,16 @@ p7Dloc_5E29: ; p7Dsub_5E59+9j - ld a, 0Ch + ld a, 0Ch call Page0Call_2C49 - jp JErrorNo + jp JErrorNo ; END OF FUNCTION CHUNK FOR Page7D_2C9A ; =============== S U B R O U T I N E ======================================= p7Dsub_5E31: - ld hl, 4000h + ld hl, 4000h ; End of function p7Dsub_5E31 @@ -6574,32 +6574,32 @@ push af - ld de, 8010h - push af - or a - rst 28h -; --------------------------------------------------------------------------- - .dw 8075h -; --------------------------------------------------------------------------- - jp nz, p7Dloc_5E29 - inc hl - pop af - push af - rst 28h -; --------------------------------------------------------------------------- - .dw 805Ah -; --------------------------------------------------------------------------- - ld de, appID - ld a, 7 - ld (de), a - ld de, 838Fh - ld (appID+1), bc - pop af - rst 28h -; --------------------------------------------------------------------------- - .dw 8054h -; --------------------------------------------------------------------------- - pop af + ld de, 8010h + push af + or a + rst 28h +; --------------------------------------------------------------------------- + .dw 8075h +; --------------------------------------------------------------------------- + jp nz, p7Dloc_5E29 + inc hl + pop af + push af + rst 28h +; --------------------------------------------------------------------------- + .dw 805Ah +; --------------------------------------------------------------------------- + ld de, appID + ld a, 7 + ld (de), a + ld de, 838Fh + ld (appID+1), bc + pop af + rst 28h +; --------------------------------------------------------------------------- + .dw 8054h +; --------------------------------------------------------------------------- + pop af ret ; End of function Page7D_2C9A @@ -6609,29 +6609,29 @@ p7Dsub_5E59: push af - ld de, 8010h - push af - or a - rst 28h -; --------------------------------------------------------------------------- - .dw 8075h -; --------------------------------------------------------------------------- - jp nz, p7Dloc_5E29 - inc hl - pop af - push af - rst 28h -; --------------------------------------------------------------------------- - .dw 805Ah -; --------------------------------------------------------------------------- - ld de, 838Eh - ld (appID), bc - pop af - rst 28h -; --------------------------------------------------------------------------- - .dw 8054h -; --------------------------------------------------------------------------- - pop af + ld de, 8010h + push af + or a + rst 28h +; --------------------------------------------------------------------------- + .dw 8075h +; --------------------------------------------------------------------------- + jp nz, p7Dloc_5E29 + inc hl + pop af + push af + rst 28h +; --------------------------------------------------------------------------- + .dw 805Ah +; --------------------------------------------------------------------------- + ld de, 838Eh + ld (appID), bc + pop af + rst 28h +; --------------------------------------------------------------------------- + .dw 8054h +; --------------------------------------------------------------------------- + pop af ret ; End of function p7Dsub_5E59 @@ -6640,19 +6640,19 @@ p7Dsub_5E78: - ld b, a + ld b, a call p7Dsub_75EC - sub b - ld b, 0 - ld c, a - push bc - pop ix + sub b + ld b, 0 + ld c, a + push bc + pop ix call p7Dsub_48B5 - jr c, locret_5E8F - jr z, locret_5E8F + jr c, locret_5E8F + jr z, locret_5E8F push af call p7Dsub_5365 - pop af + pop af locret_5E8F: ret @@ -6665,84 +6665,84 @@ p7Dsub_5E90: push af push af - ld a, 1 - or a - ld hl, ramStart - ld de, 8060h - rst 28h -; --------------------------------------------------------------------------- - .dw 8075h -; --------------------------------------------------------------------------- - jr z, p7Dloc_5EB5 - ld hl, ramStart - ld de, 8050h - rst 28h -; --------------------------------------------------------------------------- - .dw 8075h -; --------------------------------------------------------------------------- - jr z, p7Dloc_5EB0 - ld de, 80h ; '�' - jr p7Dloc_5EDD + ld a, 1 + or a + ld hl, ramStart + ld de, 8060h + rst 28h +; --------------------------------------------------------------------------- + .dw 8075h +; --------------------------------------------------------------------------- + jr z, p7Dloc_5EB5 + ld hl, ramStart + ld de, 8050h + rst 28h +; --------------------------------------------------------------------------- + .dw 8075h +; --------------------------------------------------------------------------- + jr z, p7Dloc_5EB0 + ld de, 80h ; '�' + jr p7Dloc_5EDD ; --------------------------------------------------------------------------- p7Dloc_5EB0: - ld de, 0 - jr p7Dloc_5EDD + ld de, 0 + jr p7Dloc_5EDD ; --------------------------------------------------------------------------- p7Dloc_5EB5: - inc hl - ld a, 1 - rst 28h -; --------------------------------------------------------------------------- - .dw 805Ah -; --------------------------------------------------------------------------- - ld a, 1 - rst 28h -; --------------------------------------------------------------------------- - .dw 8051h -; --------------------------------------------------------------------------- - push af - ld b, 9 - sub b - jr c, p7Dloc_5ED6 - pop af - ld b, 8 - sub b + inc hl + ld a, 1 + rst 28h +; --------------------------------------------------------------------------- + .dw 805Ah +; --------------------------------------------------------------------------- + ld a, 1 + rst 28h +; --------------------------------------------------------------------------- + .dw 8051h +; --------------------------------------------------------------------------- + push af + ld b, 9 + sub b + jr c, p7Dloc_5ED6 + pop af + ld b, 8 + sub b call p7Dsub_4E9B - ld d, a - ld a, 8 + ld d, a + ld a, 8 call p7Dsub_4E9B - ld e, a - jr p7Dloc_5EDD + ld e, a + jr p7Dloc_5EDD ; --------------------------------------------------------------------------- p7Dloc_5ED6: - ld d, 0 - pop af + ld d, 0 + pop af call p7Dsub_4E9B - ld e, a + ld e, a p7Dloc_5EDD: - pop af - ld b, a + pop af + ld b, a call p7Dsub_75EC - sub b - ld bc, 0 - ld c, a + sub b + ld bc, 0 + ld c, a call Page7D_2B68 sla c - add hl, bc - ld b, e - ex de, hl + add hl, bc + ld b, e + ex de, hl push hl call p7Dsub_456D - pop hl - ex de, hl - ld b, d - ex de, hl + pop hl + ex de, hl + ld b, d + ex de, hl call p7Dsub_456D - pop af + pop af ret ; End of function p7Dsub_5E90 @@ -6755,38 +6755,38 @@ push bc push de push hl - pop de - ld b, a - ld c, 8 - sub c - jr c, p7Dloc_5F25 + pop de + ld b, a + ld c, 8 + sub c + jr c, p7Dloc_5F25 call p7Dsub_75EC - inc a - ld c, a - ld a, b - sub c - jr nc, p7Dloc_5F25 - ld bc, 4000h - or a - sbc hl, bc - jr c, p7Dloc_5F25 - push de - pop hl - or a - ld bc, ramStart - sbc hl, bc - jr nc, p7Dloc_5F25 - or a - jr p7Dloc_5F26 + inc a + ld c, a + ld a, b + sub c + jr nc, p7Dloc_5F25 + ld bc, 4000h + or a + sbc hl, bc + jr c, p7Dloc_5F25 + push de + pop hl + or a + ld bc, ramStart + sbc hl, bc + jr nc, p7Dloc_5F25 + or a + jr p7Dloc_5F26 ; --------------------------------------------------------------------------- p7Dloc_5F25: scf p7Dloc_5F26: - pop de - pop bc - pop hl + pop de + pop bc + pop hl ret ; End of function p7Dsub_5EFC @@ -6794,91 +6794,91 @@ Page7D_2BF8: push hl - rst 28h -; --------------------------------------------------------------------------- - .dw 8057h -; --------------------------------------------------------------------------- - ld de, 0A10h + rst 28h +; --------------------------------------------------------------------------- + .dw 8057h +; --------------------------------------------------------------------------- + ld de, 0A10h call p7Dsub_777E - jp z, JError - pop hl - ld de, 0A10h + jp z, JError + pop hl + ld de, 0A10h call p7Dsub_777E - jp nz, JError - ex de, hl - push de - rst 28h -; --------------------------------------------------------------------------- - .dw 802Dh -; --------------------------------------------------------------------------- - pop de - ld bc, 2 - ex de, hl + jp nz, JError + ex de, hl + push de + rst 28h +; --------------------------------------------------------------------------- + .dw 802Dh +; --------------------------------------------------------------------------- + pop de + ld bc, 2 + ex de, hl p7Dloc_5F4B: push bc call p7Dsub_4566 - ld b, a + ld b, a push hl call p7Dsub_456D - pop hl + pop hl call p7Dsub_4565 - ld b, a + ld b, a push hl call p7Dsub_456D - pop hl + pop hl push de push hl call p7Dloc_4575 - pop de - push bc - push hl - sbc hl, de - ld b, l - dec b - pop hl - ld a, 0 - cp b - jr z, p7Dloc_5F74 + pop de + push bc + push hl + sbc hl, de + ld b, l + dec b + pop hl + ld a, 0 + cp b + jr z, p7Dloc_5F74 p7Dloc_5F70: - inc a - dec hl + inc a + dec hl djnz p7Dloc_5F70 p7Dloc_5F74: - pop bc - pop de - or a + pop bc + pop de + or a adc a, c - ld c, a - ld a, 7Eh ; '~' - push de - push bc - ld de, MD5Buffer - rst 28h -; --------------------------------------------------------------------------- - .dw 8054h -; --------------------------------------------------------------------------- - push hl - ld hl, MD5Buffer + ld c, a + ld a, 7Eh ; '~' + push de + push bc + ld de, MD5Buffer + rst 28h +; --------------------------------------------------------------------------- + .dw 8054h +; --------------------------------------------------------------------------- + push hl + ld hl, MD5Buffer call p7Dsub_5F9F - pop hl - pop bc - pop de - push hl - ld hl, MD5Buffer - ld a, 7Eh ; '~' - rst 28h -; --------------------------------------------------------------------------- - .dw 8087h -; --------------------------------------------------------------------------- - pop hl - pop bc - dec c - ld a, c - cp 0 - jr nz, p7Dloc_5F4B + pop hl + pop bc + pop de + push hl + ld hl, MD5Buffer + ld a, 7Eh ; '~' + rst 28h +; --------------------------------------------------------------------------- + .dw 8087h +; --------------------------------------------------------------------------- + pop hl + pop bc + dec c + ld a, c + cp 0 + jr nz, p7Dloc_5F4B ret ; =============== S U B R O U T I N E ======================================= @@ -6886,88 +6886,88 @@ p7Dsub_5F9F: push hl - ld a, (hl) - cp 0 - jr nz, p7Dloc_5FBD - push hl - ld d, (hl) - inc hl - ld e, (hl) - push de - rst 28h -; --------------------------------------------------------------------------- - .dw 80C3h -; --------------------------------------------------------------------------- - push de - pop bc - pop de - ex de, hl - ld h, b - ld a, l - and 0Fh - or a + ld a, (hl) + cp 0 + jr nz, p7Dloc_5FBD + push hl + ld d, (hl) + inc hl + ld e, (hl) + push de + rst 28h +; --------------------------------------------------------------------------- + .dw 80C3h +; --------------------------------------------------------------------------- + push de + pop bc + pop de + ex de, hl + ld h, b + ld a, l + and 0Fh + or a adc a, c - ld l, a - ex de, hl - pop hl - ld (hl), e - inc hl - ld (hl), d + ld l, a + ex de, hl + pop hl + ld (hl), e + inc hl + ld (hl), d p7Dloc_5FBD: - pop hl + pop hl ret ; End of function p7Dsub_5F9F ; --------------------------------------------------------------------------- start_of_7D_table: - .db 0 - .db 0 - .db 1Fh - .db 0 - .db 3Bh ; ; - .db 0 - .db 5Ah ; Z - .db 0 - .db 78h ; x - .db 0 - .db 97h ; � - .db 0 - .db 0B5h ; � - .db 0 - .db 0D4h ; � - .db 0 - .db 0F3h ; � - .db 0 - .db 11h - .db 1 - .db 30h ; 0 - .db 1 - .db 4Eh ; N - .db 1 - .db 0FFh - .db 0FFh + .db 0 + .db 0 + .db 1Fh + .db 0 + .db 3Bh ; ; + .db 0 + .db 5Ah ; Z + .db 0 + .db 78h ; x + .db 0 + .db 97h ; � + .db 0 + .db 0B5h ; � + .db 0 + .db 0D4h ; � + .db 0 + .db 0F3h ; � + .db 0 + .db 11h + .db 1 + .db 30h ; 0 + .db 1 + .db 4Eh ; N + .db 1 + .db 0FFh + .db 0FFh end_of_7D_table: - .db 3Ch ; < - .db 0 + .db 3Ch ; < + .db 0 ; =============== S U B R O U T I N E ======================================= relockFlashBack: push af - xor a + xor a nop di nop nop im 1 di - out (14h), a - di - or a - jp nz, 0 - pop af + out (14h), a + di + or a + jp nz, 0 + pop af ret ; End of function relockFlashBack @@ -6976,19 +6976,19 @@ Page7D_3E10: - ld (Abackup), a - ld a, i - di - push af - ld a, (Abackup) + ld (Abackup), a + ld a, i + di + push af + ld a, (Abackup) call relockFlashBack - ld (Abackup), a - pop af - jp po, p7Dloc_6002 + ld (Abackup), a + pop af + jp po, p7Dloc_6002 ei p7Dloc_6002: - ld a, (Abackup) + ld a, (Abackup) ret ; End of function Page7D_3E10 @@ -7001,11 +7001,11 @@ push af push bc push af - pop bc - ld a, c - ld (unk_83EA), a - pop bc - pop af + pop bc + ld a, c + ld (unk_83EA), a + pop bc + pop af ret ; End of function p7Dsub_6006 @@ -7014,15 +7014,15 @@ p7Dsub_6011: - ld (unk_83EC), a - push bc - ld b, a - ld a, (unk_83EA) - ld c, a - push bc - pop af - pop bc - ld a, (unk_83EC) + ld (unk_83EC), a + push bc + ld b, a + ld a, (unk_83EA) + ld c, a + push bc + pop af + pop bc + ld a, (unk_83EC) ret ; End of function p7Dsub_6011 @@ -7034,44 +7034,44 @@ call p7Dsub_75F5 p7Dloc_6024: - ld a, (appID) - ld c, a - ld b, 0 - ld hl, 838Eh - ld de, ramStart - ld (de), a - inc de + ld a, (appID) + ld c, a + ld b, 0 + ld hl, 838Eh + ld de, ramStart + ld (de), a + inc de ldir call p7Dsub_607A push af - ld a, (ramStart) - ld c, a - ld b, 0 - ld hl, 8001h - ld de, appID - ld (de), a - inc de + ld a, (ramStart) + ld c, a + ld b, 0 + ld hl, 8001h + ld de, appID + ld (de), a + inc de ldir - pop af - ret c + pop af + ret c call p7Dsub_6067 - jr nz, p7Dloc_6053 - or a - jp p7Dloc_61A4 + jr nz, p7Dloc_6053 + or a + jp p7Dloc_61A4 ; --------------------------------------------------------------------------- p7Dloc_6053: push af - ld a, (ramStart) - ld c, a - ld b, 0 - ld hl, 8001h - ld de, appID - ld (de), a - inc de + ld a, (ramStart) + ld c, a + ld b, 0 + ld hl, 8001h + ld de, appID + ld (de), a + inc de ldir - pop af - jr p7Dloc_6024 + pop af + jr p7Dloc_6024 ; End of function p7Dsub_6021 @@ -7079,20 +7079,20 @@ p7Dsub_6067: - ld de, OP2 - ld hl, appID - ld a, (de) - ld c, (hl) - cp c - ret nz - ld b, c + ld de, OP2 + ld hl, appID + ld a, (de) + ld c, (hl) + cp c + ret nz + ld b, c p7Dloc_6072: - inc hl - inc de - ld a, (de) - cp (hl) - ret nz + inc hl + inc de + ld a, (de) + cp (hl) + ret nz djnz p7Dloc_6072 ret ; End of function p7Dsub_6067 @@ -7102,80 +7102,80 @@ p7Dsub_607A: - ld de, appSearchPage - ld a, (de) - or a - jr z, locret_60E4 - dec a - ld (de), a - cp 7 - jr nz, p7Dloc_608A + ld de, appSearchPage + ld a, (de) + or a + jr z, locret_60E4 + dec a + ld (de), a + cp 7 + jr nz, p7Dloc_608A scf - jr locret_60E4 + jr locret_60E4 ; --------------------------------------------------------------------------- p7Dloc_608A: - ld a, (appSearchPage) - ld hl, 4000h + ld a, (appSearchPage) + ld hl, 4000h call Page0Call_3E31 - jr nz, p7Dsub_607A - ld de, 8010h - or a - rst 28h -; --------------------------------------------------------------------------- - .dw 8075h -; --------------------------------------------------------------------------- - jr nz, p7Dsub_607A - ld a, (appSearchPage) - inc hl - rst 28h -; --------------------------------------------------------------------------- - .dw 805Ah -; --------------------------------------------------------------------------- - ld a, (appSearchPage) - rst 28h -; --------------------------------------------------------------------------- - .dw 8051h -; --------------------------------------------------------------------------- - or a - jr z, p7Dsub_607A - inc a - jr z, p7Dsub_607A - ld a, (appSearchPage) + jr nz, p7Dsub_607A + ld de, 8010h + or a + rst 28h +; --------------------------------------------------------------------------- + .dw 8075h +; --------------------------------------------------------------------------- + jr nz, p7Dsub_607A + ld a, (appSearchPage) + inc hl + rst 28h +; --------------------------------------------------------------------------- + .dw 805Ah +; --------------------------------------------------------------------------- + ld a, (appSearchPage) + rst 28h +; --------------------------------------------------------------------------- + .dw 8051h +; --------------------------------------------------------------------------- + or a + jr z, p7Dsub_607A + inc a + jr z, p7Dsub_607A + ld a, (appSearchPage) push hl push bc call p7Dsub_5E31 call Page7D_2B5C - jr z, p7Dloc_60C2 - pop bc - pop hl - jr p7Dsub_607A + jr z, p7Dloc_60C2 + pop bc + pop hl + jr p7Dsub_607A ; --------------------------------------------------------------------------- p7Dloc_60C2: call ZeroOP2 - pop bc - pop hl - ld a, b - or a - jr nz, p7Dloc_60D2 - xor a - ld a, c - ld e, 9 - sub e - jr c, p7Dloc_60D5 + pop bc + pop hl + ld a, b + or a + jr nz, p7Dloc_60D2 + xor a + ld a, c + ld e, 9 + sub e + jr c, p7Dloc_60D5 p7Dloc_60D2: - ld bc, 8 + ld bc, 8 p7Dloc_60D5: - ld a, c - ld (OP2), a - ld a, (appSearchPage) - ld de, 8484h - rst 28h -; --------------------------------------------------------------------------- - .dw 8054h + ld a, c + ld (OP2), a + ld a, (appSearchPage) + ld de, 8484h + rst 28h +; --------------------------------------------------------------------------- + .dw 8054h ; --------------------------------------------------------------------------- scf ccf @@ -7187,117 +7187,117 @@ ; --------------------------------------------------------------------------- FindAppUp: - ld a, 1 - jr p7Dloc_60EA + ld a, 1 + jr p7Dloc_60EA ; --------------------------------------------------------------------------- FindAppDn: - xor a + xor a p7Dloc_60EA: - ld bc, 0 + ld bc, 0 push bc call OP1ToOP3 push af - ld a, (unk_9C87) - cp 69h ; 'i' + ld a, (unk_9C87) + cp 69h ; 'i' call nz, p7Dsub_7BA4 call p7Dsub_75F5 - pop af + pop af p7Dloc_60FE: push af call p7Dsub_6388 - pop hl - ld a, h - jr c, p7Dloc_6140 - push af - ld a, (unk_9C87) - cp 69h ; 'i' - ld a, (appSearchPage) + pop hl + ld a, h + jr c, p7Dloc_6140 + push af + ld a, (unk_9C87) + cp 69h ; 'i' + ld a, (appSearchPage) call nz, p7Dsub_7BAF - pop af + pop af call p7Dsub_6172 - jr c, p7Dloc_612E - bit 3, c - jr nz, p7Dloc_60FE - pop bc - inc b - push bc - bit 0, a - jr nz, p7Dloc_60FE - bit 1, a - jr z, p7Dloc_6163 + jr c, p7Dloc_612E + bit 3, c + jr nz, p7Dloc_60FE + pop bc + inc b + push bc + bit 0, a + jr nz, p7Dloc_60FE + bit 1, a + jr z, p7Dloc_6163 call p7Dloc_6177 - jr c, p7Dloc_6165 - jr p7Dloc_60FE + jr c, p7Dloc_6165 + jr p7Dloc_60FE ; --------------------------------------------------------------------------- p7Dloc_612E: - pop bc - inc c - push bc - bit 0, a - jr z, p7Dloc_60FE - bit 1, a - jr z, p7Dloc_6163 + pop bc + inc c + push bc + bit 0, a + jr z, p7Dloc_60FE + bit 1, a + jr z, p7Dloc_6163 call p7Dloc_6177 - jr c, p7Dloc_60FE - jr p7Dloc_6165 + jr c, p7Dloc_60FE + jr p7Dloc_6165 ; --------------------------------------------------------------------------- p7Dloc_6140: call OP3ToOP1 - res 0, a - sub 2 - pop bc - push af - ld a, (unk_8497) - ld d, a - xor a - ld (unk_8497), a - ld (unk_8481), a - ld a, (unk_9C87) - cp 1 - ld a, 69h ; 'i' - jr nz, p7Dloc_615E - xor a + res 0, a + sub 2 + pop bc + push af + ld a, (unk_8497) + ld d, a + xor a + ld (unk_8497), a + ld (unk_8481), a + ld a, (unk_9C87) + cp 1 + ld a, 69h ; 'i' + jr nz, p7Dloc_615E + xor a p7Dloc_615E: - ld (unk_9C87), a - pop af + ld (unk_9C87), a + pop af ret ; --------------------------------------------------------------------------- p7Dloc_6163: - set 1, a + set 1, a p7Dloc_6165: call OP2ToOP3 push af - ld a, (appSearchPage) - ld (unk_8497), a - pop af - jr p7Dloc_60FE + ld a, (appSearchPage) + ld (unk_8497), a + pop af + jr p7Dloc_60FE ; =============== S U B R O U T I N E ======================================= p7Dsub_6172: - ld de, 8480h - jr p7Dloc_617A + ld de, 8480h + jr p7Dloc_617A ; --------------------------------------------------------------------------- p7Dloc_6177: - ld de, 8496h + ld de, 8496h p7Dloc_617A: push af - ld hl, 848Bh - ld b, 8 + ld hl, 848Bh + ld b, 8 call Page0Call_3E3D - pop hl - ld a, h + pop hl + ld a, h ret ; End of function p7Dsub_6172 @@ -7310,11 +7310,11 @@ p7Dloc_6189: call p7Dsub_638B - ret c + ret c call p7Dsub_6172 - bit 3, c - jr z, p7Dloc_6189 - jr p7Dloc_61A4 + bit 3, c + jr z, p7Dloc_6189 + jr p7Dloc_61A4 ; --------------------------------------------------------------------------- FindApp: @@ -7322,31 +7322,31 @@ p7Dloc_6199: call p7Dsub_6388 - ret c + ret c call p7Dsub_6172 - bit 3, c - jr z, p7Dloc_6199 + bit 3, c + jr z, p7Dloc_6199 p7Dloc_61A4: - ld a, (appSearchPage) - or a - push bc - ld de, 8070h - ld hl, 4000h - push af - rst 28h -; --------------------------------------------------------------------------- - .dw 8075h -; --------------------------------------------------------------------------- - pop af - inc hl - push af - rst 28h -; --------------------------------------------------------------------------- - .dw 805Ah -; --------------------------------------------------------------------------- - pop af - pop bc + ld a, (appSearchPage) + or a + push bc + ld de, 8070h + ld hl, 4000h + push af + rst 28h +; --------------------------------------------------------------------------- + .dw 8075h +; --------------------------------------------------------------------------- + pop af + inc hl + push af + rst 28h +; --------------------------------------------------------------------------- + .dw 805Ah +; --------------------------------------------------------------------------- + pop af + pop bc ret ; End of function p7Dsub_6186 @@ -7354,124 +7354,124 @@ p7Dloc_61BC: call Page0Call_2D2D - res 1, (iy+5) + res 1, (iy+5) push af call Page0Call_3CFF - pop af - push af - ld hl, 4000h - ld de, 8040h - rst 28h -; --------------------------------------------------------------------------- - .dw 8075h -; --------------------------------------------------------------------------- - inc hl - pop af - push af - rst 28h -; --------------------------------------------------------------------------- - .dw 805Ah -; --------------------------------------------------------------------------- - pop af + pop af + push af + ld hl, 4000h + ld de, 8040h + rst 28h +; --------------------------------------------------------------------------- + .dw 8075h +; --------------------------------------------------------------------------- + inc hl + pop af + push af + rst 28h +; --------------------------------------------------------------------------- + .dw 805Ah +; --------------------------------------------------------------------------- + pop af push af call p7Dsub_5CFF - ld hl, MD5Buffer - or a + ld hl, MD5Buffer + or a adc hl, bc - ld (hl), 0 - ld a, 24h ; '$' - sub c - ld l, a - ld h, 5 - ld (penCol), hl - ld hl, MD5Buffer + ld (hl), 0 + ld a, 24h ; '$' + sub c + ld l, a + ld h, 5 + ld (penCol), hl + ld hl, MD5Buffer call Page0Call_3D4D - bit 1, (iy+35h) - jr z, p7Dloc_6201 - ld a, 50h ; 'P' + bit 1, (iy+35h) + jr z, p7Dloc_6201 + ld a, 50h ; 'P' call Page0Call_3C45 - jr z, p7Dloc_620C + jr z, p7Dloc_620C p7Dloc_6201: - ld hl, aCCopyright1998-2 - ld de, tempSwapArea - ld bc, 19h + ld hl, aCCopyright1998-2 + ld de, tempSwapArea + ld bc, 19h ldir p7Dloc_620C: - ld hl, tempSwapArea + ld hl, tempSwapArea call p7Dsub_62B3 - ld hl, aTexasInstrumentsInc-2 + ld hl, aTexasInstrumentsInc-2 call p7Dsub_62B3 - pop af + pop af push af call p7Dloc_54A0 - jr nz, p7Dloc_6270 - pop af + jr nz, p7Dloc_6270 + pop af push af call Page7D_2CA0 - jr z, p7Dloc_6237 - ld hl, aExpiredOn-2 - ld a, 51h ; 'Q' - bit 1, (iy+35h) + jr z, p7Dloc_6237 + ld hl, aExpiredOn-2 + ld a, 51h ; 'Q' + bit 1, (iy+35h) call nz, Page0Call_3C45 call p7Dsub_62B3 - jr p7Dloc_6246 + jr p7Dloc_6246 ; --------------------------------------------------------------------------- p7Dloc_6237: - ld hl, aExpirationDate-2 - ld a, 52h ; 'R' - bit 1, (iy+35h) + ld hl, aExpirationDate-2 + ld a, 52h ; 'R' + bit 1, (iy+35h) call nz, Page0Call_3C45 call p7Dsub_62B3 p7Dloc_6246: - pop af + pop af push af call p7Dloc_54A0 call p7Dloc_59B3 push de push hl push bc - pop hl + pop hl call p7Dsub_598E - ld a, (p7Dloc_6385) + ld a, (p7Dloc_6385) call Page0Call_3D47 - pop hl + pop hl call p7Dsub_598E - ld a, (p7Dloc_6385) + ld a, (p7Dloc_6385) call Page0Call_3D47 - pop hl + pop hl call p7Dsub_598E - pop af + pop af push af call Page7D_2CA0 - jr z, p7Dloc_629B + jr z, p7Dloc_629B p7Dloc_6270: - pop af + pop af push af call p7Dloc_543D - jr nz, p7Dloc_629B - ld hl, aTrialsRemaining-2 - ld a, 53h ; 'S' - bit 1, (iy+35h) + jr nz, p7Dloc_629B + ld hl, aTrialsRemaining-2 + ld a, 53h ; 'S' + bit 1, (iy+35h) call nz, Page0Call_3C45 call p7Dsub_62B3 - ld a, (OP1) - ld hl, OP1 + ld a, (OP1) + ld hl, OP1 call p7Dsub_650D - ld a, (OP1) + ld a, (OP1) call Page0Call_3D47 - ld a, (OP1+1) + ld a, (OP1+1) call Page0Call_3D47 p7Dloc_629B: - pop af - ld hl, aPressAnyKey___-2 - ld a, 54h ; 'T' - bit 1, (iy+35h) + pop af + ld hl, aPressAnyKey___-2 + ld a, 54h ; 'T' + bit 1, (iy+35h) call nz, Page0Call_3C45 call p7Dsub_62B3 ei @@ -7485,10 +7485,10 @@ p7Dsub_62B3: push hl call ldHLind - ld (penCol), hl - pop hl - inc hl - inc hl + ld (penCol), hl + pop hl + inc hl + inc hl call Page0Call_3D4D ret ; End of function p7Dsub_62B3 @@ -7497,119 +7497,119 @@ Page7D_2CB2: call Page0Call_2E65 - ld hl, progToEdit - ld de, 8479h + ld hl, progToEdit + ld de, 8479h call Mov8B - xor a + xor a call FindApp - jr c, p7Dloc_6345 + jr c, p7Dloc_6345 push hl push af call FillBasePageTable call Page0Call_3F09 di push af - ld a, 1 + ld a, 1 nop di nop nop im 1 di - out (14h), a + out (14h), a di call checkForFlashTrickery - pop af - pop af + pop af + pop af push af call p7Dsub_5E31 call Page7D_2B5C - jr nz, p7Dloc_631D - pop af - push af - rst 28h -; --------------------------------------------------------------------------- - .dw 80A8h -; --------------------------------------------------------------------------- - jr z, p7Dloc_6305 - pop af - push af - rst 28h -; --------------------------------------------------------------------------- - .dw 8096h -; --------------------------------------------------------------------------- - jr z, p7Dloc_6348 + jr nz, p7Dloc_631D + pop af + push af + rst 28h +; --------------------------------------------------------------------------- + .dw 80A8h +; --------------------------------------------------------------------------- + jr z, p7Dloc_6305 + pop af + push af + rst 28h +; --------------------------------------------------------------------------- + .dw 8096h +; --------------------------------------------------------------------------- + jr z, p7Dloc_6348 p7Dloc_6305: - pop af - push af - ld hl, 4000h + pop af + push af + ld hl, 4000h call p7Dsub_5E59 call p7Dsub_52D9 - jr c, p7Dloc_6314 - jr z, p7Dloc_6348 + jr c, p7Dloc_6314 + jr z, p7Dloc_6348 p7Dloc_6314: - pop af + pop af push af call p7Dsub_5E78 - jr c, p7Dloc_6348 - jr nz, p7Dloc_6348 + jr c, p7Dloc_6348 + jr nz, p7Dloc_6348 p7Dloc_631D: - pop af - pop hl + pop af + pop hl push af call p7Dsub_5E31 call Chk_Batt_Low - jr z, p7Dloc_6344 - rst 28h -; --------------------------------------------------------------------------- - .dw 80A8h -; --------------------------------------------------------------------------- - jr nz, p7Dloc_6332 - pop af + jr z, p7Dloc_6344 + rst 28h +; --------------------------------------------------------------------------- + .dw 80A8h +; --------------------------------------------------------------------------- + jr nz, p7Dloc_6332 + pop af push af call p7Dsub_576D p7Dloc_6332: - pop af + pop af call Page7D_2BE6 call Page0Call_2E65 call Page0Call_3E8B - ld hl, 0 - ld (curRow), hl - jr p7Dloc_6345 + ld hl, 0 + ld (curRow), hl + jr p7Dloc_6345 ; --------------------------------------------------------------------------- p7Dloc_6344: - pop af + pop af p7Dloc_6345: - jp Page0Call_2539 + jp Page0Call_2539 ; --------------------------------------------------------------------------- p7Dloc_6348: - pop af - ld (appPage), a + pop af + ld (appPage), a call p7Dsub_6FC0 - jp nz, Page0Call_2555 + jp nz, Page0Call_2555 call NZIf83Plus call z, p7Dsub_6FF9 - ld a, (appPage) + ld a, (appPage) call p7Dloc_5C2D - jr z, p7Dloc_6366 - ld a, (appPage) + jr z, p7Dloc_6366 + ld a, (appPage) call p7Dloc_61BC p7Dloc_6366: call relockFlashBack - ld a, (appPage) - pop hl + ld a, (appPage) + pop hl ei ret ; --------------------------------------------------------------------------- - .dw 0D14h + .dw 0D14h aCCopyright1998:.asc '(c) Copyright 1998',0 ; --------------------------------------------------------------------------- @@ -7627,7 +7627,7 @@ p7Dsub_6388: ; p7Dsub_6186:p7Dloc_6199p scf - jr p7Dloc_638D + jr p7Dloc_638D ; End of function p7Dsub_6388 @@ -7643,123 +7643,123 @@ push af p7Dloc_638E: - ld de, appSearchPage - ld a, (de) - dec a - ld (de), a - cp 7 - jr nz, p7Dloc_639B - pop af + ld de, appSearchPage + ld a, (de) + dec a + ld (de), a + cp 7 + jr nz, p7Dloc_639B + pop af scf ret ; --------------------------------------------------------------------------- p7Dloc_639B: - ld a, (unk_9C87) - cp 69h ; 'i' - jr nz, p7Dloc_63C8 - ld a, (appSearchPage) + ld a, (unk_9C87) + cp 69h ; 'i' + jr nz, p7Dloc_63C8 + ld a, (appSearchPage) call p7Dsub_7BB5 - jr z, p7Dloc_638E - ld a, (appSearchPage) - ld hl, 4000h + jr z, p7Dloc_638E + ld a, (appSearchPage) + ld hl, 4000h p7Dloc_63B0: - ld de, 8040h - rst 28h -; --------------------------------------------------------------------------- - .dw 8075h -; --------------------------------------------------------------------------- - jr z, p7Dloc_63BF + ld de, 8040h + rst 28h +; --------------------------------------------------------------------------- + .dw 8075h +; --------------------------------------------------------------------------- + jr z, p7Dloc_63BF p7Dloc_63B8: - ld a, 1 - ld (unk_9C87), a - jr p7Dloc_638E + ld a, 1 + ld (unk_9C87), a + jr p7Dloc_638E ; --------------------------------------------------------------------------- p7Dloc_63BF: - inc hl - ld a, (appSearchPage) - rst 28h -; --------------------------------------------------------------------------- - .dw 805Ah -; --------------------------------------------------------------------------- - jr p7Dloc_6407 + inc hl + ld a, (appSearchPage) + rst 28h +; --------------------------------------------------------------------------- + .dw 805Ah +; --------------------------------------------------------------------------- + jr p7Dloc_6407 ; --------------------------------------------------------------------------- p7Dloc_63C8: - ld a, (de) - ld hl, 4000h + ld a, (de) + ld hl, 4000h call Page0Call_3E31 - jr nz, p7Dloc_638E - ld de, 8040h - or a - rst 28h -; --------------------------------------------------------------------------- - .dw 8075h -; --------------------------------------------------------------------------- - jr nz, p7Dloc_638E - inc hl - ld a, (appSearchPage) - push af - rst 28h -; --------------------------------------------------------------------------- - .dw 805Ah -; --------------------------------------------------------------------------- - pop af - rst 28h -; --------------------------------------------------------------------------- - .dw 8051h -; --------------------------------------------------------------------------- - or a - jr z, p7Dloc_638E - inc a - jr z, p7Dloc_638E - ld a, (appSearchPage) + jr nz, p7Dloc_638E + ld de, 8040h + or a + rst 28h +; --------------------------------------------------------------------------- + .dw 8075h +; --------------------------------------------------------------------------- + jr nz, p7Dloc_638E + inc hl + ld a, (appSearchPage) + push af + rst 28h +; --------------------------------------------------------------------------- + .dw 805Ah +; --------------------------------------------------------------------------- + pop af + rst 28h +; --------------------------------------------------------------------------- + .dw 8051h +; --------------------------------------------------------------------------- + or a + jr z, p7Dloc_638E + inc a + jr z, p7Dloc_638E + ld a, (appSearchPage) push hl push bc call p7Dsub_5E31 - pop bc - pop hl - pop af - push af - ld a, (appSearchPage) - jr nc, p7Dloc_6402 + pop bc + pop hl + pop af + push af + ld a, (appSearchPage) + jr nc, p7Dloc_6402 call p7Dsub_53B3 - jr p7Dloc_6405 + jr p7Dloc_6405 ; --------------------------------------------------------------------------- p7Dloc_6402: call Page7D_2B5C p7Dloc_6405: - jr nz, p7Dloc_638E + jr nz, p7Dloc_638E p7Dloc_6407: - pop af + pop af push hl push bc call ZeroOP2 - pop bc - pop hl - ld a, b - or a - jr nz, p7Dloc_6419 - ld a, c - ld e, 9 - sub e - jr c, p7Dloc_641C + pop bc + pop hl + ld a, b + or a + jr nz, p7Dloc_6419 + ld a, c + ld e, 9 + sub e + jr c, p7Dloc_641C p7Dloc_6419: - ld bc, 8 + ld bc, 8 p7Dloc_641C: - ld de, 8484h - ld a, (appSearchPage) - rst 28h -; --------------------------------------------------------------------------- - .dw 8054h + ld de, 8484h + ld a, (appSearchPage) + rst 28h +; --------------------------------------------------------------------------- + .dw 8054h ; --------------------------------------------------------------------------- scf ccf @@ -7775,42 +7775,42 @@ push bc push de call p7Dsub_6186 - jr c, p7Dloc_6468 - ld (appInfo+1), a + jr c, p7Dloc_6468 + ld (appInfo+1), a call p7Dsub_7CB2 - jr z, p7Dloc_6462 + jr z, p7Dloc_6462 call p7Dsub_7124 - jr z, p7Dloc_644E + jr z, p7Dloc_644E call OP1ToOP4 - ld a, 14h - ld (OP4), a - rst 18h + ld a, 14h + ld (OP4), a + rst 18h call relockFlashBack call Page0Call_2C67 - jr p7Dloc_646B + jr p7Dloc_646B ; --------------------------------------------------------------------------- p7Dloc_644E: - ld de, 5 - ld a, 2 - ld (unk_867E), a + ld de, 5 + ld a, 2 + ld (unk_867E), a call Page0Call_2C4F call Page0Call_2C6D - ld a, (appInfo) - or a - jr nz, p7Dloc_6468 + ld a, (appInfo) + or a + jr nz, p7Dloc_6468 p7Dloc_6462: - ld a, (appInfo+1) + ld a, (appInfo+1) call Page7D_2BE6 p7Dloc_6468: call relockFlashBack p7Dloc_646B: - pop de - pop bc - pop hl + pop de + pop bc + pop hl ret ; End of function p7Dsub_6428 @@ -7822,118 +7822,118 @@ push bc push af push af - ld a, 1 + ld a, 1 nop di nop nop im 1 di - out (14h), a + out (14h), a di call checkForFlashTrickery - pop af - ld hl, 4000h + pop af + ld hl, 4000h call p7Dsub_4566 - cp 0 - jr z, p7Dloc_64AE - ld hl, 6000h + cp 0 + jr z, p7Dloc_64AE + ld hl, 6000h call p7Dsub_4566 - cp 0 - jr z, p7Dloc_64AE - cp 8Fh ; '�' - jr z, p7Dloc_64A6 - ld hl, 4000h + cp 0 + jr z, p7Dloc_64AE + cp 8Fh ; '�' + jr z, p7Dloc_64A6 + ld hl, 4000h call p7Dsub_4566 - cp 8Fh ; '�' - jr z, p7Dloc_64A6 + cp 8Fh ; '�' + jr z, p7Dloc_64A6 p7Dloc_64A6: - ld b, 0 - ex de, hl + ld b, 0 + ex de, hl call p7Dsub_456D - jr p7Dloc_64CE + jr p7Dloc_64CE ; --------------------------------------------------------------------------- p7Dloc_64AE: - ld a, h - xor 20h ; ' ' - ld h, a + ld a, h + xor 20h ; ' ' + ld h, a call p7Dsub_4566 - cp 8Fh ; '�' - jr z, p7Dloc_64C0 - cp 0 - jp z, p7Dloc_64E1 - jr p7Dloc_64CE + cp 8Fh ; '�' + jr z, p7Dloc_64C0 + cp 0 + jp z, p7Dloc_64E1 + jr p7Dloc_64CE ; --------------------------------------------------------------------------- p7Dloc_64C0: push hl - ld a, h - xor 20h ; ' ' - ld h, a + ld a, h + xor 20h ; ' ' + ld h, a call p7Dsub_457C - pop de - ld b, 0 + pop de + ld b, 0 call p7Dsub_456D p7Dloc_64CE: - pop af - cp 0Fh - jr nz, p7Dloc_64D8 + pop af + cp 0Fh + jr nz, p7Dloc_64D8 call Page0Call_2B8F - jr p7Dloc_64DB + jr p7Dloc_64DB ; --------------------------------------------------------------------------- p7Dloc_64D8: call Page0Call_2B89 p7Dloc_64DB: - pop bc - pop de - pop hl - jp relockFlashBack + pop bc + pop de + pop hl + jp relockFlashBack ; --------------------------------------------------------------------------- p7Dloc_64E1: - ld hl, 4001h - ld de, 6001h + ld hl, 4001h + ld de, 6001h p7Dloc_64E7: call p7Dsub_4566 - cp 0 - jr z, p7Dloc_64F2 - cp 0FFh - jr nz, p7Dloc_64F6 + cp 0 + jr z, p7Dloc_64F2 + cp 0FFh + jr nz, p7Dloc_64F6 p7Dloc_64F2: - inc hl - ex de, hl - jr p7Dloc_64E7 + inc hl + ex de, hl + jr p7Dloc_64E7 ; --------------------------------------------------------------------------- p7Dloc_64F6: - ld a, h - xor 20h ; ' ' - and 0F0h ; '�' - ld h, a - xor a - ld l, a + ld a, h + xor 20h ; ' ' + and 0F0h ; '�' + ld h, a + xor a + ld l, a call p7Dsub_457C - jr p7Dloc_64CE + jr p7Dloc_64CE ; =============== S U B R O U T I N E ======================================= p7Dsub_6503: - ld a, d - or a - jr nz, p7Dloc_650A + ld a, d + or a + jr nz, p7Dloc_650A call p7Dsub_651E p7Dloc_650A: - xor a - ld (hl), a + xor a + ld (hl), a ret ; End of function p7Dsub_6503 @@ -7944,15 +7944,15 @@ p7Dsub_650D: call Page0Call_32E5 call p7Dsub_6523 - jr z, p7Dloc_6519 - add a, 30h ; '0' - ld (hl), a - inc hl + jr z, p7Dloc_6519 + add a, 30h ; '0' + ld (hl), a + inc hl p7Dloc_6519: - ld a, b + ld a, b call p7Dsub_6523 - ret z + ret z ; End of function p7Dsub_650D @@ -7960,9 +7960,9 @@ p7Dsub_651E: - add a, 30h ; '0' - ld (hl), a - inc hl + add a, 30h ; '0' + ld (hl), a + inc hl ret ; End of function p7Dsub_651E @@ -7971,17 +7971,17 @@ p7Dsub_6523: - or a - jr z, p7Dloc_6529 - ld d, 1 + or a + jr z, p7Dloc_6529 + ld d, 1 ret ; --------------------------------------------------------------------------- p7Dloc_6529: - ld e, a - ld a, d - or a - ld a, e + ld e, a + ld a, d + or a + ld a, e ret ; End of function p7Dsub_6523 @@ -7993,25 +7993,25 @@ push af push bc push de - ld hl, (unk_83A1) + ld hl, (unk_83A1) call p7Dsub_57C5 - or a + or a adc hl, de call p7Dsub_57C5 - ld (unk_83A1), hl - jr nc, p7Dloc_654C - ld hl, (unk_839F) - inc h - jr nz, p7Dloc_6549 - inc l + ld (unk_83A1), hl + jr nc, p7Dloc_654C + ld hl, (unk_839F) + inc h + jr nz, p7Dloc_6549 + inc l p7Dloc_6549: - ld (unk_839F), hl + ld (unk_839F), hl p7Dloc_654C: - pop de - pop bc - pop af + pop de + pop bc + pop af ret ; End of function p7Dsub_652E @@ -8022,9 +8022,9 @@ Page7D_2CE2: ; Page7D_2B6E+32p ... push de - ld de, 1 + ld de, 1 call Page7D_2CCA - pop de + pop de ret ; End of function Page7D_2CE2 @@ -8038,45 +8038,45 @@ push bc push de push de - ex de, hl - ld de, 4000h - rst 28h -; --------------------------------------------------------------------------- - .dw 804Bh -; --------------------------------------------------------------------------- - ld a, (arcPage) - add a, e - ld (arcPage), a - ld a, e - ld de, 4000h - rst 28h -; --------------------------------------------------------------------------- - .dw 8045h -; --------------------------------------------------------------------------- - push hl - pop bc - pop hl - or a - sbc hl, bc - push hl - pop bc - ld hl, (arcPtr) - or a + ex de, hl + ld de, 4000h + rst 28h +; --------------------------------------------------------------------------- + .dw 804Bh +; --------------------------------------------------------------------------- + ld a, (arcPage) + add a, e + ld (arcPage), a + ld a, e + ld de, 4000h + rst 28h +; --------------------------------------------------------------------------- + .dw 8045h +; --------------------------------------------------------------------------- + push hl + pop bc + pop hl + or a + sbc hl, bc + push hl + pop bc + ld hl, (arcPtr) + or a adc hl, bc - bit 7, h - jr z, p7Dloc_6591 - ld a, (arcPage) - inc a - ld (arcPage), a - ld bc, 4000h - or a - sbc hl, bc + bit 7, h + jr z, p7Dloc_6591 + ld a, (arcPage) + inc a + ld (arcPage), a + ld bc, 4000h + or a + sbc hl, bc p7Dloc_6591: - ld (arcPtr), hl - pop de - pop bc - pop af + ld (arcPtr), hl + pop de + pop bc + pop af ret ; End of function Page7D_2CCA @@ -8088,27 +8088,27 @@ push af push bc push hl - ld hl, arcPage - jr p7Dloc_65A6 + ld hl, arcPage + jr p7Dloc_65A6 ; --------------------------------------------------------------------------- p7Dloc_65A0: push af push bc push hl - ld hl, 839Fh + ld hl, 839Fh p7Dloc_65A6: - xor a - ld b, 4 + xor a + ld b, 4 p7Dloc_65A9: - ld (hl), a - inc hl + ld (hl), a + inc hl djnz p7Dloc_65A9 - pop hl - pop bc - pop af + pop hl + pop bc + pop af ret ; End of function p7Dsub_6598 @@ -8117,73 +8117,73 @@ ArcChk: push af push hl - bit 6, (iy+24h) - jr nz, p7Dloc_65F2 + bit 6, (iy+24h) + jr nz, p7Dloc_65F2 call p7Dloc_65A0 - ld (Abackup), a - ld a, i - di - push af - ld a, (Abackup) - push af - ld a, 1 + ld (Abackup), a + ld a, i + di + push af + ld a, (Abackup) + push af + ld a, 1 nop di nop nop im 1 di - out (14h), a + out (14h), a di call checkForFlashTrickery - pop af + pop af call Page7D_2C10 call relockFlashBack - ld (Abackup), a - pop af - jp po, p7Dloc_65E5 + ld (Abackup), a + pop af + jp po, p7Dloc_65E5 ei p7Dloc_65E5: - ld a, (Abackup) - ld de, 9C96h + ld a, (Abackup) + ld de, 9C96h call p7Dsub_6621 - set 6, (iy+24h) + set 6, (iy+24h) p7Dloc_65F2: - bit 7, (iy+24h) - jr nz, p7Dloc_6608 + bit 7, (iy+24h) + jr nz, p7Dloc_6608 call p7Dloc_65A0 call p7Dsub_662F - ld de, 9C9Ah + ld de, 9C9Ah call p7Dsub_6621 - set 7, (iy+24h) + set 7, (iy+24h) p7Dloc_6608: - ld hl, 9C9Ah + ld hl, 9C9Ah call p7Dsub_6626 - ld de, 83A2h - ld hl, 9C99h - ld b, 4 - or a + ld de, 83A2h + ld hl, 9C99h + ld b, 4 + or a p7Dloc_6617: - ld a, (de) + ld a, (de) adc a, (hl) - ld (de), a - dec hl - dec de + ld (de), a + dec hl + dec de djnz p7Dloc_6617 - pop hl - pop af + pop hl + pop af ret ; =============== S U B R O U T I N E ======================================= p7Dsub_6621: - ld hl, 839Fh - jr p7Dloc_6629 + ld hl, 839Fh + jr p7Dloc_6629 ; End of function p7Dsub_6621 @@ -8191,10 +8191,10 @@ p7Dsub_6626: - ld de, 839Fh + ld de, 839Fh p7Dloc_6629: - ld bc, 4 + ld bc, 4 ldir ret ; End of function p7Dsub_6626 @@ -8205,90 +8205,90 @@ p7Dsub_662F: call Page7D_2B56 - inc b - ld a, 8 - ld de, 0 + inc b + ld a, 8 + ld de, 0 p7Dloc_6638: call p7Dsub_7BD4 - cp b - ret nc - ld hl, 4000h + cp b + ret nc + ld hl, 4000h push af call Page7D_2CD0 - cp 0FEh ; '�' - jr z, p7Dloc_6664 - cp 0FFh - jr nz, p7Dloc_665C - pop af + cp 0FEh ; '�' + jr z, p7Dloc_6664 + cp 0FFh + jr nz, p7Dloc_665C + pop af push af call Page7D_2B74 call p7Dsub_652E - ld de, 1 + ld de, 1 call p7Dsub_652E - jr p7Dloc_6664 + jr p7Dloc_6664 ; --------------------------------------------------------------------------- p7Dloc_665C: - cp 0F0h ; '�' - jr z, p7Dloc_6669 - pop af - inc a - jr p7Dloc_6638 + cp 0F0h ; '�' + jr z, p7Dloc_6669 + pop af + inc a + jr p7Dloc_6638 ; --------------------------------------------------------------------------- p7Dloc_6664: - pop af - add a, 4 - jr p7Dloc_6638 + pop af + add a, 4 + jr p7Dloc_6638 ; --------------------------------------------------------------------------- p7Dloc_6669: - inc hl - pop af + inc hl + pop af push af p7Dloc_666C: push af push hl - ld c, 0F0h ; '�' + ld c, 0F0h ; '�' push bc call Page7D_2B6E push bc - pop de - pop bc - jr z, p7Dloc_6696 - inc sp - inc sp - inc sp - inc sp - ld (arcPage), a - ld (arcPtr), hl - inc de - inc de - inc de + pop de + pop bc + jr z, p7Dloc_6696 + inc sp + inc sp + inc sp + inc sp + ld (arcPage), a + ld (arcPtr), hl + inc de + inc de + inc de push de call Page7D_2CCA - pop de + pop de call p7Dsub_652E - ld a, (arcPage) - ld hl, (arcPtr) - jr p7Dloc_666C + ld a, (arcPage) + ld hl, (arcPtr) + jr p7Dloc_666C ; --------------------------------------------------------------------------- p7Dloc_6696: - pop hl - pop af - ld c, 0FFh + pop hl + pop af + ld c, 0FFh push bc call Page7D_2B6E - pop bc - jr z, p7Dloc_66A7 + pop bc + jr z, p7Dloc_66A7 call Page7D_2B74 call p7Dsub_652E p7Dloc_66A7: - jr p7Dloc_6664 + jr p7Dloc_6664 ; End of function p7Dsub_662F @@ -8299,18 +8299,18 @@ push af push bc push hl - ld bc, (freeArcBlock) - or a - sbc hl, bc - jr c, p7Dloc_66BB - or a + ld bc, (freeArcBlock) + or a + sbc hl, bc + jr c, p7Dloc_66BB + or a adc hl, bc - ld (freeArcBlock), hl + ld (freeArcBlock), hl p7Dloc_66BB: - pop hl - pop bc - pop af + pop hl + pop bc + pop af ret ; End of function p7Dsub_66A9 @@ -8319,93 +8319,93 @@ Page7D_2EB6: push bc push de - ld a, (OP1) - push af - push bc - ld bc, 0 - ld (freeArcBlock), bc + ld a, (OP1) + push af + push bc + ld bc, 0 + ld (freeArcBlock), bc call Page7D_2B56 - ld a, b - ld (unk_83FF), a - pop bc - ld a, 8 + ld a, b + ld (unk_83FF), a + pop bc + ld a, 8 p7Dloc_66D7: push af - ld hl, 4000h + ld hl, 4000h call Page7D_2CD0 - cp 0FEh ; '�' - jr nz, p7Dloc_66E7 + cp 0FEh ; '�' + jr nz, p7Dloc_66E7 p7Dloc_66E2: - pop af - add a, 3 - jr p7Dloc_66F0 + pop af + add a, 3 + jr p7Dloc_66F0 ; --------------------------------------------------------------------------- p7Dloc_66E7: - cp 0F0h ; '�' - jr z, p7Dloc_66FB - cp 0FFh - jr z, p7Dloc_6711 - pop af + cp 0F0h ; '�' + jr z, p7Dloc_66FB + cp 0FFh + jr z, p7Dloc_6711 + pop af p7Dloc_66F0: push hl - ld hl, 83FFh - cp (hl) - pop hl - jr nc, p7Dloc_672F - inc a - jr p7Dloc_66D7 + ld hl, 83FFh + cp (hl) + pop hl + jr nc, p7Dloc_672F + inc a + jr p7Dloc_66D7 ; --------------------------------------------------------------------------- p7Dloc_66FB: - pop af - push af - push bc - ld c, 0FFh - ld (arcPage), a - ld (arcPtr), hl + pop af + push af + push bc + ld c, 0FFh + ld (arcPage), a + ld (arcPtr), hl call Page7D_2CE2 call Page7D_2B6E - pop bc - jr z, p7Dloc_66E2 - pop de + pop bc + jr z, p7Dloc_66E2 + pop de push af p7Dloc_6711: - pop af - ld (tempSwapArea), hl - push bc - push af - ld a, (unk_83FF) - ld b, a - inc b - pop af + pop af + ld (tempSwapArea), hl + push bc + push af + ld a, (unk_83FF) + ld b, a + inc b + pop af call Page7D_2B74 - ex de, hl - pop bc - or a + ex de, hl + pop bc + or a call p7Dsub_66A9 - sbc hl, bc - ld hl, (tempSwapArea) - jr nc, p7Dloc_6733 - jr p7Dloc_66F0 + sbc hl, bc + ld hl, (tempSwapArea) + jr nc, p7Dloc_6733 + jr p7Dloc_66F0 ; --------------------------------------------------------------------------- p7Dloc_672F: - ld a, 0FFh - add a, 10h + ld a, 0FFh + add a, 10h p7Dloc_6733: - pop bc - ld c, a - ld a, b - ld (OP1), a - ld a, c - pop de - pop bc + pop bc + ld c, a + ld a, b + ld (OP1), a + ld a, c + pop de + pop bc ret ; =============== S U B R O U T I N E ======================================= @@ -8416,37 +8416,37 @@ push bc push af push hl - pop de - ld hl, 7FFFh - or a - sbc hl, de + pop de + ld hl, 7FFFh + or a + sbc hl, de p7Dloc_6748: - ex de, hl - inc a + ex de, hl + inc a call p7Dsub_67EC - jr z, p7Dloc_6765 - cp b - jr nc, p7Dloc_6765 - ld hl, 4000h + jr z, p7Dloc_6765 + cp b + jr nc, p7Dloc_6765 + ld hl, 4000h push af call Page7D_2CD0 - cp 0FFh - jr nz, p7Dloc_6764 - ld hl, 4000h - add hl, de - pop af - jr p7Dloc_6748 + cp 0FFh + jr nz, p7Dloc_6764 + ld hl, 4000h + add hl, de + pop af + jr p7Dloc_6748 ; --------------------------------------------------------------------------- p7Dloc_6764: - pop af + pop af p7Dloc_6765: ; Page7D_2B74+13j - pop af - pop bc - pop hl + pop af + pop bc + pop hl ret ; End of function Page7D_2B74 @@ -8457,85 +8457,85 @@ Page7D_2B6E: ; p7Dsub_662F+42p ... call p7Dsub_6598 - ld (arcPage), a - ld (arcPtr), hl - push bc - push hl - push af - or 3 - ld b, 15h + ld (arcPage), a + ld (arcPtr), hl + push bc + push hl + push af + or 3 + ld b, 15h call NZIf83Plus - jr nz, p7Dloc_6780 - ld b, 69h ; 'i' + jr nz, p7Dloc_6780 + ld b, 69h ; 'i' p7Dloc_6780: - cp b - jr c, p7Dloc_6784 - ld a, b + cp b + jr c, p7Dloc_6784 + ld a, b p7Dloc_6784: - ld (unk_8390), a - pop af - pop hl - pop bc + ld (unk_8390), a + pop af + pop hl + pop bc p7Dloc_678A: push bc - ld a, (arcPage) + ld a, (arcPage) call Page7D_2CD0 - cp c - jr z, p7Dloc_67C8 - cp 0FFh - jr z, p7Dloc_67C2 - ld (arcPtr), hl + cp c + jr z, p7Dloc_67C8 + cp 0FFh + jr z, p7Dloc_67C2 + ld (arcPtr), hl call Page7D_2CE2 - ld a, (arcPage) + ld a, (arcPage) call Page7D_2CD0 - ld e, a + ld e, a call Page7D_2CE2 - ld a, (arcPage) + ld a, (arcPage) call Page7D_2CD0 - ld d, a - inc de + ld d, a + inc de call Page7D_2CCA - ld a, (unk_8390) - ld b, a - ld a, (arcPage) - cp b - jr c, p7Dloc_67BF - jr nz, p7Dloc_67C2 + ld a, (unk_8390) + ld b, a + ld a, (arcPage) + cp b + jr c, p7Dloc_67BF + jr nz, p7Dloc_67C2 p7Dloc_67BF: - pop bc - jr p7Dloc_678A + pop bc + jr p7Dloc_678A ; --------------------------------------------------------------------------- p7Dloc_67C2: ; Page7D_2B6E+54j - xor a - ld a, (arcPage) - pop bc + xor a + ld a, (arcPage) + pop bc ret ; --------------------------------------------------------------------------- p7Dloc_67C8: - pop bc - ld a, (arcPage) - push af - push hl - ld (arcPtr), hl + pop bc + ld a, (arcPage) + push af + push hl + ld (arcPtr), hl call Page7D_2CE2 - ld a, (arcPage) + ld a, (arcPage) call Page7D_2CD0 - ld c, a - ld a, (arcPage) + ld c, a + ld a, (arcPage) call Page7D_2CE2 - ld a, (arcPage) + ld a, (arcPage) call Page7D_2CD0 - ld b, a - pop hl - pop af - or a + ld b, a + pop hl + pop af + or a ret ; End of function Page7D_2B6E @@ -8546,21 +8546,21 @@ p7Dsub_67EC: ; Page7D_2B74+Dp push bc - ld b, a - and 3 - ld a, b - jr z, p7Dloc_67FE + ld b, a + and 3 + ld a, b + jr z, p7Dloc_67FE call NZIf83Plus - jr nz, p7Dloc_67FC - cp 6Ah ; 'j' - jr p7Dloc_67FE + jr nz, p7Dloc_67FC + cp 6Ah ; 'j' + jr p7Dloc_67FE ; --------------------------------------------------------------------------- p7Dloc_67FC: - cp 16h + cp 16h p7Dloc_67FE: - pop bc + pop bc ret ; End of function p7Dsub_67EC @@ -8574,248 +8574,248 @@ push hl push de call p7Dsub_75EC - ld hl, 4000h + ld hl, 4000h p7Dloc_6809: push af call Page7D_2CD0 - cp 80h ; '�' - jr z, p7Dloc_6815 - cp 0 - jr nz, p7Dloc_6827 + cp 80h ; '�' + jr z, p7Dloc_6815 + cp 0 + jr nz, p7Dloc_6827 p7Dloc_6815: - pop af + pop af push af call Page0Call_3E31 - jr nz, p7Dloc_6827 + jr nz, p7Dloc_6827 call FindAppNumPages - ld a, c - or c - jr z, p7Dloc_6827 - pop af - sub c - jr p7Dloc_6809 + ld a, c + or c + jr z, p7Dloc_6827 + pop af + sub c + jr p7Dloc_6809 ; --------------------------------------------------------------------------- p7Dloc_6827: ; Page7D_2B56+1Aj ... - pop af - ld b, a - pop de - pop hl - pop af + pop af + ld b, a + pop de + pop hl + pop af ret ; End of function Page7D_2B56 ; --------------------------------------------------------------------------- Page7D_2EC2: - res 7, (iy+24h) - push af - ld a, 1 + res 7, (iy+24h) + push af + ld a, 1 nop di nop nop im 1 di - out (14h), a + out (14h), a di call checkForFlashTrickery - pop af - ld a, (arcInfo) - ld hl, (arcInfo+1) + pop af + ld a, (arcInfo) + ld hl, (arcInfo+1) call p7Dsub_69E8 - ld de, (unk_83F3) - ld bc, (unk_83F9) + ld de, (unk_83F3) + ld bc, (unk_83F9) call Page7D_2C46 - jp c, Page0Call_2541 - rst 28h -; --------------------------------------------------------------------------- - .dw 8054h -; --------------------------------------------------------------------------- - ld de, (arcInfo+1) - ld a, (arcInfo) - ld b, 0F0h ; '�' - rst 28h -; --------------------------------------------------------------------------- - .dw 8021h -; --------------------------------------------------------------------------- - ld de, (unk_83F3) - ld (arcInfo+1), de - ld a, 0 - ld (arcInfo), a - ld hl, (unk_83F1) + jp c, Page0Call_2541 + rst 28h +; --------------------------------------------------------------------------- + .dw 8054h +; --------------------------------------------------------------------------- + ld de, (arcInfo+1) + ld a, (arcInfo) + ld b, 0F0h ; '�' + rst 28h +; --------------------------------------------------------------------------- + .dw 8021h +; --------------------------------------------------------------------------- + ld de, (unk_83F3) + ld (arcInfo+1), de + ld a, 0 + ld (arcInfo), a + ld hl, (unk_83F1) call Page0Call_2EDD - jp relockFlashBack + jp relockFlashBack ; --------------------------------------------------------------------------- Page7D_2D06: - res 7, (iy+24h) - push af - ld a, 1 + res 7, (iy+24h) + push af + ld a, 1 nop di nop nop im 1 di - out (14h), a + out (14h), a di call checkForFlashTrickery - pop af - ex de, hl - jp p7Dloc_692E + pop af + ex de, hl + jp p7Dloc_692E ; =============== S U B R O U T I N E ======================================= Page7D_2EB0: - res 7, (iy+24h) - push af - ld a, 1 + res 7, (iy+24h) + push af + ld a, 1 nop di nop nop im 1 di - out (14h), a + out (14h), a di call checkForFlashTrickery - pop af - ld a, (arcInfo) - ld hl, (arcInfo+1) + pop af + ld a, (arcInfo) + ld hl, (arcInfo+1) call p7Dsub_69D4 - jr nz, p7Dloc_68D2 - ld b, 0F0h ; '�' - ld a, (arcInfo) - ld de, (arcInfo+1) + jr nz, p7Dloc_68D2 + ld b, 0F0h ; '�' + ld a, (arcInfo) + ld de, (arcInfo+1) call p7Dsub_6F82 - jp c, Page0Call_2541 - rst 28h -; --------------------------------------------------------------------------- - .dw 8021h -; --------------------------------------------------------------------------- - ld hl, (arcInfo+1) - inc hl - ld (arcInfo+1), hl - jr p7Dloc_68D6 + jp c, Page0Call_2541 + rst 28h +; --------------------------------------------------------------------------- + .dw 8021h +; --------------------------------------------------------------------------- + ld hl, (arcInfo+1) + inc hl + ld (arcInfo+1), hl + jr p7Dloc_68D6 ; --------------------------------------------------------------------------- p7Dloc_68D2: - ld de, (arcInfo+1) + ld de, (arcInfo+1) p7Dloc_68D6: - ld b, 0FEh ; '�' - ld a, (arcInfo) - ld (unk_8404), a - ld (unk_8402), de + ld b, 0FEh ; '�' + ld a, (arcInfo) + ld (unk_8404), a + ld (unk_8402), de call p7Dsub_6F82 - jp c, Page0Call_2541 - rst 28h -; --------------------------------------------------------------------------- - .dw 8021h -; --------------------------------------------------------------------------- - ld a, (arcInfo) - ld de, (unk_8402) - ld (arcPage), a - ld (arcPtr), de + jp c, Page0Call_2541 + rst 28h +; --------------------------------------------------------------------------- + .dw 8021h +; --------------------------------------------------------------------------- + ld a, (arcInfo) + ld de, (unk_8402) + ld (arcPage), a + ld (arcPtr), de call Page7D_2CE2 - ld a, (arcPage) - ld de, (arcPtr) - ld hl, 83F9h - ld bc, 2 + ld a, (arcPage) + ld de, (arcPtr) + ld hl, 83F9h + ld bc, 2 call Page7D_2C46 - jp c, Page0Call_2541 - rst 28h -; --------------------------------------------------------------------------- - .dw 8087h -; --------------------------------------------------------------------------- - ld de, 2 + jp c, Page0Call_2541 + rst 28h +; --------------------------------------------------------------------------- + .dw 8087h +; --------------------------------------------------------------------------- + ld de, 2 call Page7D_2CCA - ld a, (unk_8404) - ld (arcInfo), a - ld de, (arcPtr) - ld hl, (unk_83F1) + ld a, (unk_8404) + ld (arcInfo), a + ld de, (arcPtr) + ld hl, (unk_83F1) call Page0Call_2EDD - ld a, (arcPage) - ld (arcInfo), a + ld a, (arcPage) + ld (arcInfo), a p7Dloc_692E: - ld hl, (unk_83F1) - ld bc, (unk_83F5) - push de - ld de, OP1 - ld b, c + ld hl, (unk_83F1) + ld bc, (unk_83F5) + push de + ld de, OP1 + ld b, c p7Dloc_693A: - ld a, (hl) - ld (de), a - inc de - dec hl + ld a, (hl) + ld (de), a + inc de + dec hl djnz p7Dloc_693A - pop de - ld a, (arcInfo) - ld bc, (unk_83F5) - ld hl, OP1 - res 7, (hl) - ld (arcPtr), de - ld (arcPage), a + pop de + ld a, (arcInfo) + ld bc, (unk_83F5) + ld hl, OP1 + res 7, (hl) + ld (arcPtr), de + ld (arcPage), a call Page7D_2C46 - jp c, Page0Call_2541 - rst 28h -; --------------------------------------------------------------------------- - .dw 8087h -; --------------------------------------------------------------------------- - ld de, (unk_83F5) + jp c, Page0Call_2541 + rst 28h +; --------------------------------------------------------------------------- + .dw 8087h +; --------------------------------------------------------------------------- + ld de, (unk_83F5) call Page7D_2CCA - ld a, (arcPage) - ld (arcInfo), a - ld de, (arcPtr) - ld (unk_83FB), de - bit 3, (iy+26h) - res 3, (iy+26h) - jr nz, p7Dloc_69D1 - ld a, (arcInfo) - ld hl, (unk_83F3) - bit 5, (iy+26h) - ld bc, 2 - jr nz, p7Dloc_698F - ld bc, (unk_83F7) + ld a, (arcPage) + ld (arcInfo), a + ld de, (arcPtr) + ld (unk_83FB), de + bit 3, (iy+26h) + res 3, (iy+26h) + jr nz, p7Dloc_69D1 + ld a, (arcInfo) + ld hl, (unk_83F3) + bit 5, (iy+26h) + ld bc, 2 + jr nz, p7Dloc_698F + ld bc, (unk_83F7) p7Dloc_698F: - ld (arcPtr), de - ld (arcPage), a + ld (arcPtr), de + ld (arcPage), a call Page7D_2C46 - jp c, Page0Call_2541 + jp c, Page0Call_2541 call p7Dsub_7666 - bit 5, (iy+26h) - ld de, 2 - jr nz, p7Dloc_69AC - ld de, (unk_83F7) + bit 5, (iy+26h) + ld de, 2 + jr nz, p7Dloc_69AC + ld de, (unk_83F7) p7Dloc_69AC: call Page7D_2CCA - ld a, (arcPage) - ld (arcInfo), a - ld de, (arcPtr) - bit 2, (iy+26h) - jr nz, p7Dloc_69D1 - ld de, (unk_8402) - ld b, 0FCh ; '�' - ld a, (unk_8404) + ld a, (arcPage) + ld (arcInfo), a + ld de, (arcPtr) + bit 2, (iy+26h) + jr nz, p7Dloc_69D1 + ld de, (unk_8402) + ld b, 0FCh ; '�' + ld a, (unk_8404) call p7Dsub_6F82 - jp c, Page0Call_2541 - rst 28h -; --------------------------------------------------------------------------- - .dw 8021h + jp c, Page0Call_2541 + rst 28h +; --------------------------------------------------------------------------- + .dw 8021h ; --------------------------------------------------------------------------- p7Dloc_69D1: ; Page7D_2EB0+126j - jp relockFlashBack + jp relockFlashBack ; End of function Page7D_2EB0 @@ -8825,17 +8825,17 @@ p7Dsub_69D4: ; p7Dsub_7CDA+39p push hl - ld bc, 4000h - or a - sbc hl, bc - pop hl - jr z, p7Dloc_69DF - ret nc + ld bc, 4000h + or a + sbc hl, bc + pop hl + jr z, p7Dloc_69DF + ret nc p7Dloc_69DF: - ld b, a - and 3 - ld a, b + ld b, a + and 3 + ld a, b ret ; End of function p7Dsub_69D4 @@ -8855,20 +8855,20 @@ push hl push af call Page7D_2CD0 - ld e, a - pop af - inc hl + ld e, a + pop af + inc hl call Page0Call_23FC - jr nc, p7Dloc_69FA - inc a + jr nc, p7Dloc_69FA + inc a p7Dloc_69FA: call Page7D_2CD0 - ld d, a - push de - pop bc - pop hl - pop af + ld d, a + push de + pop bc + pop hl + pop af ret ; End of function p7Dsub_69E8 @@ -8883,54 +8883,54 @@ p7Dsub_6A07: - inc hl - inc hl - inc hl + inc hl + inc hl + inc hl call Page0Call_23FC - jr nc, Page7D_2CD6 - inc a + jr nc, Page7D_2CD6 + inc a Page7D_2CD6: push af call Page7D_2CD0 - and 1Fh - or a + and 1Fh + or a call Page0Call_23F6 - jr nc, p7Dloc_6A21 - ld d, a - pop af - inc a - push af - ld a, d + jr nc, p7Dloc_6A21 + ld d, a + pop af + inc a + push af + ld a, d p7Dloc_6A21: - ld de, 3 + ld de, 3 call page0_17B3 - jr z, p7Dloc_6A3D + jr z, p7Dloc_6A3D call IS_A_LSTorCLST - jr z, p7Dloc_6A3D - pop af - ld (arcPage), a + jr z, p7Dloc_6A3D + pop af + ld (arcPage), a call Page7D_2CD0 - cp 5Dh ; ']' - ld a, (arcPage) - jr nz, p7Dloc_6A45 + cp 5Dh ; ']' + ld a, (arcPage) + jr nz, p7Dloc_6A45 push af p7Dloc_6A3D: - pop af + pop af push af call Page7D_2CD0 - ld e, a - pop af - inc e + ld e, a + pop af + inc e p7Dloc_6A45: - ld (arcPage), a - ld (arcPtr), hl + ld (arcPage), a + ld (arcPtr), hl call Page7D_2CCA - ld a, (arcPage) - ld hl, (arcPtr) + ld a, (arcPage) + ld hl, (arcPtr) ret ; End of function p7Dsub_6A07 @@ -8939,22 +8939,22 @@ Page7D_2D42: call Page7D_2B56 call p7Dsub_75EC - cp b - jr c, p7Dloc_6A6D - jr z, p7Dloc_6A6D + cp b + jr c, p7Dloc_6A6D + jr z, p7Dloc_6A6D p7Dloc_6A60: push bc call DeleteApp - pop bc - ld a, (appSearchPage+1) - cp b - jr c, p7Dloc_6A6D - jr nz, p7Dloc_6A60 + pop bc + ld a, (appSearchPage+1) + cp b + jr c, p7Dloc_6A6D + jr nz, p7Dloc_6A60 p7Dloc_6A6D: - res 2, (iy+25h) - ld a, 4 + res 2, (iy+25h) + ld a, 4 call Page0Call_2EB9 ret ; --------------------------------------------------------------------------- @@ -8962,133 +8962,133 @@ Page7D_2D36: call Page0Call_3F2D push af - ld a, 1 + ld a, 1 nop di nop nop im 1 di - out (14h), a + out (14h), a di call checkForFlashTrickery - pop af - ld a, 8 - rst 28h -; --------------------------------------------------------------------------- - .dw 8084h -; --------------------------------------------------------------------------- - ld a, 8 - ld de, 4000h - ld b, 0FEh ; '�' - rst 28h -; --------------------------------------------------------------------------- - .dw 8021h -; --------------------------------------------------------------------------- - ld a, 0Ch + pop af + ld a, 8 + rst 28h +; --------------------------------------------------------------------------- + .dw 8084h +; --------------------------------------------------------------------------- + ld a, 8 + ld de, 4000h + ld b, 0FEh ; '�' + rst 28h +; --------------------------------------------------------------------------- + .dw 8021h +; --------------------------------------------------------------------------- + ld a, 0Ch p7Dloc_6A9C: push af call p7Dsub_7BD4 - pop af - push af - rst 28h -; --------------------------------------------------------------------------- - .dw 8084h -; --------------------------------------------------------------------------- - pop af - add a, 4 + pop af + push af + rst 28h +; --------------------------------------------------------------------------- + .dw 8084h +; --------------------------------------------------------------------------- + pop af + add a, 4 p7Dloc_6AA8: ; DATA XREF: seg001:76B7w seg001:76C9w call p7Dsub_75E1 - jr c, p7Dloc_6A9C - ld hl, tempSwapArea - ld b, 0E8h ; '�' + jr c, p7Dloc_6A9C + ld hl, tempSwapArea + ld b, 0E8h ; '�' p7Dloc_6AB2: - ld a, 0FFh - ld (hl), a - inc hl + ld a, 0FFh + ld (hl), a + inc hl djnz p7Dloc_6AB2 - ld a, 0FEh ; '�' - ld hl, 836Dh - ld (hl), a + ld a, 0FEh ; '�' + ld hl, 836Dh + ld (hl), a call NZIf83Plus - jr z, p7Dloc_6AC9 - ld a, 7Fh ; '' - ld hl, 836Eh - ld (hl), a + jr z, p7Dloc_6AC9 + ld a, 7Fh ; '' + ld hl, 836Eh + ld (hl), a p7Dloc_6AC9: - ld a, 0 + ld a, 0 call Page7D_2B62 - jp relockFlashBack + jp relockFlashBack ; --------------------------------------------------------------------------- Page7D_2D48: - res 6, (iy+24h) - res 7, (iy+24h) - res 4, (iy+26h) - ld a, 8 + res 6, (iy+24h) + res 7, (iy+24h) + res 4, (iy+26h) + ld a, 8 p7Dloc_6ADF: push af - ld hl, 4000h + ld hl, 4000h call Page7D_2CD0 - cp 0FEh ; '�' - jr nz, p7Dloc_6AF3 + cp 0FEh ; '�' + jr nz, p7Dloc_6AF3 p7Dloc_6AEA: - pop af - push bc - ld c, 3 - add a, c - pop bc - push af - jr p7Dloc_6AFB + pop af + push bc + ld c, 3 + add a, c + pop bc + push af + jr p7Dloc_6AFB ; --------------------------------------------------------------------------- p7Dloc_6AF3: - cp 0F0h ; '�' - jr z, p7Dloc_6B07 - cp 0FFh - jr z, p7Dloc_6AEA + cp 0F0h ; '�' + jr z, p7Dloc_6B07 + cp 0FFh + jr z, p7Dloc_6AEA p7Dloc_6AFB: - pop af + pop af push hl call Page7D_2B56 - cp b - pop hl - jr nc, locret_6B35 - inc a - jr p7Dloc_6ADF + cp b + pop hl + jr nc, locret_6B35 + inc a + jr p7Dloc_6ADF ; --------------------------------------------------------------------------- p7Dloc_6B07: - pop af - push af - ld (arcPage), a - ld (arcPtr), hl + pop af + push af + ld (arcPage), a + ld (arcPtr), hl call Page7D_2CE2 p7Dloc_6B12: - ld c, 0FCh ; '�' + ld c, 0FCh ; '�' call Page7D_2B6E - jr z, p7Dloc_6AEA - ld (arcPage), a - ld (arcPtr), hl + jr z, p7Dloc_6AEA + ld (arcPage), a + ld (arcPtr), hl push bc call Page0Call_2FC7 - pop de - inc de - inc de - ld (arcPage), a - ld (arcPtr), hl - inc de + pop de + inc de + inc de + ld (arcPage), a + ld (arcPtr), hl + inc de call Page7D_2CCA - ld a, (arcPage) - jr p7Dloc_6B12 + ld a, (arcPage) + jr p7Dloc_6B12 ; --------------------------------------------------------------------------- locret_6B35: @@ -9101,13 +9101,13 @@ push hl push bc push de - ld bc, 1 - ld de, flashByte1 + ld bc, 1 + ld de, flashByte1 call FlashToRam - ld a, (flashByte1) - pop de - pop bc - pop hl + ld a, (flashByte1) + pop de + pop bc + pop hl ret ; End of function Page7D_2CD0 @@ -9117,48 +9117,48 @@ FlashToRam: call NZIf83Plus - jr z, p7Dloc_6B50 - and 1Fh + jr z, p7Dloc_6B50 + and 1Fh p7Dloc_6B50: push ix - ld ix, FlashToRamPrivilegedCopy + ld ix, FlashToRamPrivilegedCopy call p7Dsub_6B87 - pop ix + pop ix ret ; End of function FlashToRam FlashToRamPrivilegedCopy: - .dw 29h - ld (flashByte2), a - in a, (6) - push af - ld a, (flashByte2) - out (6), a - bit 7, h - jr nz, p7Dloc_6B83 + .dw 29h + ld (flashByte2), a + in a, (6) + push af + ld a, (flashByte2) + out (6), a + bit 7, h + jr nz, p7Dloc_6B83 p7Dloc_6B6D: - bit 7, h - jr z, p7Dloc_6B79 - in a, (6) - inc a - out (6), a - ld hl, 4000h + bit 7, h + jr z, p7Dloc_6B79 + in a, (6) + inc a + out (6), a + ld hl, 4000h p7Dloc_6B79: ldi - ld a, b - or c - jr nz, p7Dloc_6B6D + ld a, b + or c + jr nz, p7Dloc_6B6D p7Dloc_6B7F: - pop af - out (6), a + pop af + out (6), a ret p7Dloc_6B83: ldir - jr p7Dloc_6B7F + jr p7Dloc_6B7F ; =============== S U B R O U T I N E ======================================= @@ -9170,27 +9170,27 @@ push de push hl push ix - pop hl - ld c, (hl) - inc hl - ld b, (hl) - inc hl - ld de, ramCode + pop hl + ld c, (hl) + inc hl + ld b, (hl) + inc hl + ld de, ramCode push de ldir - pop ix - pop hl - pop de - pop bc + pop ix + pop hl + pop de + pop bc call p7Dsub_6BAD push af - ld a, (unk_82A2) - bit 2, a - jr z, p7Dloc_6BAB + ld a, (unk_82A2) + bit 2, a + jr z, p7Dloc_6BAB ei p7Dloc_6BAB: - pop af + pop af ret ; End of function p7Dsub_6B87 @@ -9199,7 +9199,7 @@ p7Dsub_6BAD: - jp ramCode + jp ramCode ; End of function p7Dsub_6BAD @@ -9209,170 +9209,170 @@ p7Dsub_6BB0: push af push bc - ld a, i - push af - di - pop bc - ld a, c - ld (unk_82A2), a - pop bc - pop af + ld a, i + push af + di + pop bc + ld a, c + ld (unk_82A2), a + pop bc + pop af ret ; End of function p7Dsub_6BB0 ; --------------------------------------------------------------------------- Page7D_3E28: - res 7, (iy+24h) - push af - ld a, 1 + res 7, (iy+24h) + push af + ld a, 1 nop di nop nop im 1 di - out (14h), a + out (14h), a di call checkForFlashTrickery - pop af - ld a, b - ld b, 0F0h ; '�' + pop af + ld a, b + ld b, 0F0h ; '�' call p7Dsub_6F82 - jp c, Page0Call_2541 - rst 28h -; --------------------------------------------------------------------------- - .dw 8021h -; --------------------------------------------------------------------------- - jp relockFlashBack + jp c, Page0Call_2541 + rst 28h +; --------------------------------------------------------------------------- + .dw 8021h +; --------------------------------------------------------------------------- + jp relockFlashBack ; --------------------------------------------------------------------------- Page7D_2D3C: - res 7, (iy+24h) - ld a, 8 + res 7, (iy+24h) + ld a, 8 p7Dloc_6BE8: push af - ld hl, 4000h + ld hl, 4000h call Page7D_2CD0 - cp 0FEh ; '�' - jr nz, p7Dloc_6BF9 + cp 0FEh ; '�' + jr nz, p7Dloc_6BF9 p7Dloc_6BF3: - pop af - add a, 3 - push af - jr p7Dloc_6C01 + pop af + add a, 3 + push af + jr p7Dloc_6C01 ; --------------------------------------------------------------------------- p7Dloc_6BF9: - cp 0F0h ; '�' - jr z, p7Dloc_6C0E - cp 0FFh - jr z, p7Dloc_6BF3 + cp 0F0h ; '�' + jr z, p7Dloc_6C0E + cp 0FFh + jr z, p7Dloc_6BF3 p7Dloc_6C01: - pop af + pop af push hl call Page7D_2B56 - cp b - pop hl - jp nc, p7Dloc_6CAB - inc a - jr p7Dloc_6BE8 + cp b + pop hl + jp nc, p7Dloc_6CAB + inc a + jr p7Dloc_6BE8 ; --------------------------------------------------------------------------- p7Dloc_6C0E: - pop af - push af - ld (arcPage), a - ld (arcPtr), hl + pop af + push af + ld (arcPage), a + ld (arcPtr), hl call Page7D_2CE2 p7Dloc_6C19: - ld c, 0FCh ; '�' + ld c, 0FCh ; '�' call Page7D_2B6E - jr z, p7Dloc_6BF3 - ld (arcPage), a - ld (arcPtr), hl - ld (unk_8404), a - ld (unk_8402), hl - ld de, 3 + jr z, p7Dloc_6BF3 + ld (arcPage), a + ld (arcPtr), hl + ld (unk_8404), a + ld (unk_8402), hl + ld de, 3 call Page7D_2CCA - ld a, (arcPage) + ld a, (arcPage) push bc push af call Page7D_2CD0 - and 1Fh - ld (OP1), a + and 1Fh + ld (OP1), a call page0_17B3 - jr z, p7Dloc_6C49 + jr z, p7Dloc_6C49 call IS_A_LSTorCLST - jr nz, p7Dloc_6C6A + jr nz, p7Dloc_6C6A p7Dloc_6C49: - or a + or a call Page0Call_23F6 - jr nc, p7Dloc_6C52 - pop af - inc a + jr nc, p7Dloc_6C52 + pop af + inc a push af p7Dloc_6C52: - pop af + pop af push af call Page7D_2CD0 - ld c, a - ld b, 0 - pop af - ld (arcPage), a - ld (arcPtr), hl + ld c, a + ld b, 0 + pop af + ld (arcPage), a + ld (arcPtr), hl call Page7D_2CE2 - ld a, (arcPage) - push af - jr p7Dloc_6C76 + ld a, (arcPage) + push af + jr p7Dloc_6C76 ; --------------------------------------------------------------------------- p7Dloc_6C6A: - or a + or a call Page0Call_23F6 - jr nc, p7Dloc_6C73 - pop af - inc a + jr nc, p7Dloc_6C73 + pop af + inc a push af p7Dloc_6C73: - ld bc, 3 + ld bc, 3 p7Dloc_6C76: - ld de, 8479h - push hl - ld a, (OP1) + ld de, 8479h + push hl + ld a, (OP1) push af call ZeroOP1 - pop af - ld (OP1), a - pop hl - pop af + pop af + ld (OP1), a + pop hl + pop af call FlashToRam call ChkFindSym call page0_1F31 - pop de - inc de - inc de - ld a, (unk_8404) - ld hl, (unk_8402) - ld (arcPage), a - ld (arcPtr), hl + pop de + inc de + inc de + ld a, (unk_8404) + ld hl, (unk_8402) + ld (arcPage), a + ld (arcPtr), hl call Page7D_2CCA call Page7D_2CE2 - ld a, (arcPage) - jp p7Dloc_6C19 + ld a, (arcPage) + jp p7Dloc_6C19 ; --------------------------------------------------------------------------- p7Dloc_6CAB: - res 2, (iy+25h) - ld a, 3 + res 2, (iy+25h) + ld a, 3 call Page0Call_2EB9 ret @@ -9381,21 +9381,21 @@ Page7D_2C16: - ld hl, 8697h + ld hl, 8697h call NZIf83Plus - jr z, p7Dloc_6CC4 - ld c, a - ld b, 0 - add hl, bc - set 7, (hl) + jr z, p7Dloc_6CC4 + ld c, a + ld b, 0 + add hl, bc + set 7, (hl) ret ; --------------------------------------------------------------------------- p7Dloc_6CC4: - ld b, a + ld b, a call Page0Call_2DB1 - or (hl) - ld (hl), a + or (hl) + ld (hl), a ret ; End of function Page7D_2C16 @@ -9404,54 +9404,54 @@ p7Dsub_6CCB: - ld (arcPage), a - ld (arcPtr), hl - ld de, 3 + ld (arcPage), a + ld (arcPtr), hl + ld de, 3 call Page7D_2CCA call ZeroOP1 - ld a, (arcPage) - ld hl, (arcPtr) + ld a, (arcPage) + ld hl, (arcPtr) call Page7D_2CD0 - ld (OP1), a + ld (OP1), a call Page0Call_23F6 - jr nc, p7Dloc_6CF2 - ld a, (arcPage) - inc a - ld (arcPage), a + jr nc, p7Dloc_6CF2 + ld a, (arcPage) + inc a + ld (arcPage), a p7Dloc_6CF2: - ld (arcPtr), hl - ld a, (OP1) - ld b, 3 + ld (arcPtr), hl + ld a, (OP1) + ld b, 3 call page0_17B3 - jr z, p7Dloc_6D11 + jr z, p7Dloc_6D11 call IS_A_LSTorCLST - jr z, p7Dloc_6D11 - ld a, (arcPage) + jr z, p7Dloc_6D11 + ld a, (arcPage) call Page7D_2CD0 - cp 5Dh ; ']' - ld a, (arcPage) - jr nz, p7Dloc_6D21 + cp 5Dh ; ']' + ld a, (arcPage) + jr nz, p7Dloc_6D21 p7Dloc_6D11: - ld a, (arcPage) - ld hl, (arcPtr) + ld a, (arcPage) + ld hl, (arcPtr) call Page7D_2CD0 - ld b, a - ld a, (arcPage) + ld b, a + ld a, (arcPage) call Page7D_2CE2 p7Dloc_6D21: - ld de, 8479h + ld de, 8479h p7Dloc_6D24: - ld a, (arcPage) - ld hl, (arcPtr) + ld a, (arcPage) + ld hl, (arcPtr) push bc call Page7D_2CD0 - pop bc - ld (de), a - inc de + pop bc + ld (de), a + inc de call Page7D_2CE2 djnz p7Dloc_6D24 ret @@ -9464,194 +9464,194 @@ push hl push de push af - ld (arcInfo), a - ld (arcInfo+1), hl - ld a, b - ld (unk_83F1), a - ld (unk_83F1+1), de - ld (unk_8404), a - ld (unk_8402), de - ld a, (arcInfo) - ld hl, (arcInfo+1) + ld (arcInfo), a + ld (arcInfo+1), hl + ld a, b + ld (unk_83F1), a + ld (unk_83F1+1), de + ld (unk_8404), a + ld (unk_8402), de + ld a, (arcInfo) + ld hl, (arcInfo+1) call p7Dsub_6CCB - ld a, (OP1) - and 1Fh - push af - ld a, (arcInfo) - ld hl, (arcInfo+1) - ld (arcPage), a - ld (arcPtr), hl + ld a, (OP1) + and 1Fh + push af + ld a, (arcInfo) + ld hl, (arcInfo+1) + ld (arcPage), a + ld (arcPtr), hl call Page7D_2CE2 - ld a, (arcPage) + ld a, (arcPage) call Page7D_2CD0 - ld c, a + ld c, a call Page7D_2CE2 - ld a, (arcPage) + ld a, (arcPage) call Page7D_2CD0 - ld b, a + ld b, a call Page7D_2CE2 push bc - ld a, (arcPage) - ld (arcInfo), a - ld (arcInfo+1), hl - ld a, (unk_83F1) - ld de, (unk_83F1+1) - ld (arcPage), a - ld (arcPtr), de - ld b, 0FEh ; '�' - rst 28h -; --------------------------------------------------------------------------- - .dw 8021h + ld a, (arcPage) + ld (arcInfo), a + ld (arcInfo+1), hl + ld a, (unk_83F1) + ld de, (unk_83F1+1) + ld (arcPage), a + ld (arcPtr), de + ld b, 0FEh ; '�' + rst 28h +; --------------------------------------------------------------------------- + .dw 8021h ; --------------------------------------------------------------------------- call Page7D_2CE2 - ld a, (arcPage) - ld de, (arcPtr) - pop bc - push bc - ld b, c - rst 28h -; --------------------------------------------------------------------------- - .dw 8021h + ld a, (arcPage) + ld de, (arcPtr) + pop bc + push bc + ld b, c + rst 28h +; --------------------------------------------------------------------------- + .dw 8021h ; --------------------------------------------------------------------------- call Page7D_2CE2 - ld a, (arcPage) - ld de, (arcPtr) - pop bc - push bc - rst 28h -; --------------------------------------------------------------------------- - .dw 8021h + ld a, (arcPage) + ld de, (arcPtr) + pop bc + push bc + rst 28h +; --------------------------------------------------------------------------- + .dw 8021h ; --------------------------------------------------------------------------- call Page7D_2CE2 - ld a, (arcPage) - ld de, (arcPtr) - ld (unk_83F1), a - ld (unk_83F1+1), de - ld a, (arcInfo) - ld hl, (arcInfo+1) - ld (arcPage), a - ld (arcPtr), hl - ld de, 83FDh - ld bc, 3 + ld a, (arcPage) + ld de, (arcPtr) + ld (unk_83F1), a + ld (unk_83F1+1), de + ld a, (arcInfo) + ld hl, (arcInfo+1) + ld (arcPage), a + ld (arcPtr), hl + ld de, 83FDh + ld bc, 3 call FlashToRam - ld de, 6 + ld de, 6 call Page7D_2CCA - ld a, (arcPage) - ld hl, (arcPtr) - ld (arcInfo), a - ld (arcInfo+1), hl - ld a, (unk_83F1) - ld de, (unk_83F1+1) - ld (arcPage), a - ld (arcPtr), de - ld hl, 83FDh - ld bc, 3 - rst 28h -; --------------------------------------------------------------------------- - .dw 8087h -; --------------------------------------------------------------------------- - ld de, 3 + ld a, (arcPage) + ld hl, (arcPtr) + ld (arcInfo), a + ld (arcInfo+1), hl + ld a, (unk_83F1) + ld de, (unk_83F1+1) + ld (arcPage), a + ld (arcPtr), de + ld hl, 83FDh + ld bc, 3 + rst 28h +; --------------------------------------------------------------------------- + .dw 8087h +; --------------------------------------------------------------------------- + ld de, 3 call Page7D_2CCA - ld a, (arcPage) - ld de, (arcPtr) - ld hl, 8402h - ld bc, 3 - rst 28h -; --------------------------------------------------------------------------- - .dw 8087h -; --------------------------------------------------------------------------- - ld de, 3 + ld a, (arcPage) + ld de, (arcPtr) + ld hl, 8402h + ld bc, 3 + rst 28h +; --------------------------------------------------------------------------- + .dw 8087h +; --------------------------------------------------------------------------- + ld de, 3 call Page7D_2CCA - ld a, (arcPage) - ld de, (arcPtr) - ld (unk_83F1), a - ld (unk_83F1+1), de - pop hl - ld bc, 6 - or a - sbc hl, bc - push hl - pop bc + ld a, (arcPage) + ld de, (arcPtr) + ld (unk_83F1), a + ld (unk_83F1+1), de + pop hl + ld bc, 6 + or a + sbc hl, bc + push hl + pop bc p7Dloc_6E40: - ld hl, 0 - ld (unk_83F3+1), hl - ld de, ramStart + ld hl, 0 + ld (unk_83F3+1), hl + ld de, ramStart p7Dloc_6E49: push bc - ld a, (arcInfo) - ld b, a - ld hl, (arcInfo+1) + ld a, (arcInfo) + ld b, a + ld hl, (arcInfo+1) call LoadCIndPaged - ld a, c - ld (de), a - inc de - inc hl - bit 7, h - jr z, p7Dloc_6E60 - inc b - ld hl, 4000h + ld a, c + ld (de), a + inc de + inc hl + bit 7, h + jr z, p7Dloc_6E60 + inc b + ld hl, 4000h p7Dloc_6E60: call p7Dsub_6ECE - ld a, b - ld (arcInfo), a - ld (arcInfo+1), hl - pop bc - dec bc - ld a, b - or c - jr z, p7Dloc_6EA7 + ld a, b + ld (arcInfo), a + ld (arcInfo+1), hl + pop bc + dec bc + ld a, b + or c + jr z, p7Dloc_6EA7 call p7Dsub_6ED5 - jr z, p7Dloc_6E77 - jr p7Dloc_6E49 + jr z, p7Dloc_6E77 + jr p7Dloc_6E49 ; --------------------------------------------------------------------------- p7Dloc_6E77: push bc - ld hl, ramStart - ld de, (unk_83F1+1) - ld a, (unk_83F1) - ld (arcPtr), de - ld (arcPage), a - ld bc, (unk_83F3+1) - rst 28h -; --------------------------------------------------------------------------- - .dw 8087h -; --------------------------------------------------------------------------- - ld de, (unk_83F3+1) + ld hl, ramStart + ld de, (unk_83F1+1) + ld a, (unk_83F1) + ld (arcPtr), de + ld (arcPage), a + ld bc, (unk_83F3+1) + rst 28h +; --------------------------------------------------------------------------- + .dw 8087h +; --------------------------------------------------------------------------- + ld de, (unk_83F3+1) call Page7D_2CCA - ld a, (arcPage) - ld hl, (arcPtr) - ld (unk_83F1), a - ld (unk_83F1+1), hl - pop bc - jp p7Dloc_6E40 + ld a, (arcPage) + ld hl, (arcPtr) + ld (unk_83F1), a + ld (unk_83F1+1), hl + pop bc + jp p7Dloc_6E40 ; --------------------------------------------------------------------------- p7Dloc_6EA7: - ld hl, ramStart - ld de, (unk_83F1+1) - ld a, (unk_83F1) - ld bc, (unk_83F3+1) - rst 28h -; --------------------------------------------------------------------------- - .dw 8087h -; --------------------------------------------------------------------------- - ld a, (unk_8404) - ld de, (unk_8402) - ld b, 0FCh ; '�' - rst 28h -; --------------------------------------------------------------------------- - .dw 8021h -; --------------------------------------------------------------------------- - pop af - ld (OP1), a - pop af - pop de - pop hl - pop bc + ld hl, ramStart + ld de, (unk_83F1+1) + ld a, (unk_83F1) + ld bc, (unk_83F3+1) + rst 28h +; --------------------------------------------------------------------------- + .dw 8087h +; --------------------------------------------------------------------------- + ld a, (unk_8404) + ld de, (unk_8402) + ld b, 0FCh ; '�' + rst 28h +; --------------------------------------------------------------------------- + .dw 8021h +; --------------------------------------------------------------------------- + pop af + ld (OP1), a + pop af + pop de + pop hl + pop bc ret ; --------------------------------------------------------------------------- ret @@ -9661,9 +9661,9 @@ p7Dsub_6ECE: push hl - ld hl, 83F4h - inc (hl) - pop hl + ld hl, 83F4h + inc (hl) + pop hl ret ; End of function p7Dsub_6ECE @@ -9672,8 +9672,8 @@ p7Dsub_6ED5: - ld a, (unk_83F3+1) - cp 0FFh + ld a, (unk_83F3+1) + cp 0FFh ret ; End of function p7Dsub_6ED5 @@ -9688,93 +9688,93 @@ ; Page7D_2C10+75j call p7Dsub_7BD4 call Page7D_2B56 - cp b - jr c, locret_6F53 - jr z, locret_6F53 - ld hl, 4000h + cp b + jr c, locret_6F53 + jr z, locret_6F53 + ld hl, 4000h push af call Page7D_2CD0 - cp 0 - jr nz, p7Dloc_6F0A - pop af + cp 0 + jr nz, p7Dloc_6F0A + pop af push af call FindAppNumPages - ld a, c - or c - jr z, p7Dloc_6F52 - ld b, c - ld de, 4000h + ld a, c + or c + jr z, p7Dloc_6F52 + ld b, c + ld de, 4000h p7Dloc_6F01: call p7Dsub_652E djnz p7Dloc_6F01 p7Dloc_6F06: - pop af - sub c - jr p7Dloc_6EDE + pop af + sub c + jr p7Dloc_6EDE ; --------------------------------------------------------------------------- p7Dloc_6F0A: - cp 80h ; '�' - jr nz, p7Dloc_6F52 - pop af + cp 80h ; '�' + jr nz, p7Dloc_6F52 + pop af push af call Page0Call_3E31 - jr nz, p7Dloc_6F52 - pop af + jr nz, p7Dloc_6F52 + pop af push af call Page7D_2C9A call Page7D_2B5C - jr z, p7Dloc_6F43 - pop af + jr z, p7Dloc_6F43 + pop af push af call FindAppNumPages - ld a, c - or c - jr z, p7Dloc_6F52 - ld b, c + ld a, c + or c + jr z, p7Dloc_6F52 + ld b, c p7Dloc_6F29: - pop af - push af - push bc - ld de, 4000h - ld b, 0 - rst 28h -; --------------------------------------------------------------------------- - .dw 8021h -; --------------------------------------------------------------------------- - ld de, 4000h + pop af + push af + push bc + ld de, 4000h + ld b, 0 + rst 28h +; --------------------------------------------------------------------------- + .dw 8021h +; --------------------------------------------------------------------------- + ld de, 4000h call p7Dsub_652E - pop bc - dec b - jr z, p7Dloc_6F4E - pop af - dec a - push af - jr p7Dloc_6F29 + pop bc + dec b + jr z, p7Dloc_6F4E + pop af + dec a + push af + jr p7Dloc_6F29 ; --------------------------------------------------------------------------- p7Dloc_6F43: - pop af + pop af push af call FindAppNumPages - ld a, c - or a - jr z, p7Dloc_6F52 - jr p7Dloc_6F06 + ld a, c + or a + jr z, p7Dloc_6F52 + jr p7Dloc_6F06 ; --------------------------------------------------------------------------- p7Dloc_6F4E: - pop af - dec a - jr p7Dloc_6EDE + pop af + dec a + jr p7Dloc_6EDE ; --------------------------------------------------------------------------- p7Dloc_6F52: ; Page7D_2C10+31j ... - pop af + pop af locret_6F53: ; Page7D_2C10+Cj @@ -9790,28 +9790,28 @@ push hl push de push bc - cp 8 - jp c, p7Dloc_6F7D - push af - ld a, (OP1) + cp 8 + jp c, p7Dloc_6F7D + push af + ld a, (OP1) push af call Page7D_2B56 - pop af - ld (OP1), a - pop af - cp b - jr z, p7Dloc_6F6E - jr nc, p7Dloc_6F7D + pop af + ld (OP1), a + pop af + cp b + jr z, p7Dloc_6F6E + jr nc, p7Dloc_6F7D p7Dloc_6F6E: - ld bc, 4000h - sbc hl, bc - jr c, p7Dloc_6F7D - ex de, hl - or a - sbc hl, bc - jr c, p7Dloc_6F7D - jr p7Dloc_6F7E + ld bc, 4000h + sbc hl, bc + jr c, p7Dloc_6F7D + ex de, hl + or a + sbc hl, bc + jr c, p7Dloc_6F7D + jr p7Dloc_6F7E ; --------------------------------------------------------------------------- p7Dloc_6F7D: @@ -9819,9 +9819,9 @@ scf p7Dloc_6F7E: - pop bc - pop de - pop hl + pop bc + pop de + pop hl ret ; End of function Page7D_2C46 @@ -9834,35 +9834,35 @@ push hl push de push bc - cp 8 - jp c, p7Dloc_6FA7 - push af - ld a, (OP1) + cp 8 + jp c, p7Dloc_6FA7 + push af + ld a, (OP1) push af call Page7D_2B56 - pop af - ld (OP1), a - pop af - cp b - jr z, p7Dloc_6F9C - jr nc, p7Dloc_6FA7 + pop af + ld (OP1), a + pop af + cp b + jr z, p7Dloc_6F9C + jr nc, p7Dloc_6FA7 p7Dloc_6F9C: - ld bc, 4000h - ex de, hl - or a - sbc hl, bc - jr c, p7Dloc_6FA7 - jr p7Dloc_6FA8 + ld bc, 4000h + ex de, hl + or a + sbc hl, bc + jr c, p7Dloc_6FA7 + jr p7Dloc_6FA8 ; --------------------------------------------------------------------------- p7Dloc_6FA7: scf p7Dloc_6FA8: - pop bc - pop de - pop hl + pop bc + pop de + pop hl ret ; End of function p7Dsub_6F82 @@ -9875,21 +9875,21 @@ push hl push bc call p7Dsub_75E1 - jr nc, p7Dloc_6FBD + jr nc, p7Dloc_6FBD call Page7D_2B56 - cp b - jr c, p7Dloc_6FBA - or a + cp b + jr c, p7Dloc_6FBA + or a p7Dloc_6FBA: - pop bc - pop hl + pop bc + pop hl ret ; --------------------------------------------------------------------------- p7Dloc_6FBD: scf - jr p7Dloc_6FBA + jr p7Dloc_6FBA ; End of function p7Dsub_6FAC @@ -9900,44 +9900,44 @@ push hl push bc push de - ld hl, 4000h - ld de, 80C0h - rst 28h -; --------------------------------------------------------------------------- - .dw 8075h -; --------------------------------------------------------------------------- - jr nz, p7Dloc_6FF4 - inc hl - ld a, (appPage) - rst 28h -; --------------------------------------------------------------------------- - .dw 805Ah -; --------------------------------------------------------------------------- - ld a, (appPage) + ld hl, 4000h + ld de, 80C0h + rst 28h +; --------------------------------------------------------------------------- + .dw 8075h +; --------------------------------------------------------------------------- + jr nz, p7Dloc_6FF4 + inc hl + ld a, (appPage) + rst 28h +; --------------------------------------------------------------------------- + .dw 805Ah +; --------------------------------------------------------------------------- + ld a, (appPage) call p7Dsub_5CFF call GetBaseVer - ld b, a - ld a, (MD5Buffer) - cp b - jr z, p7Dloc_6FE9 - jr c, p7Dloc_6FF4 - jr p7Dloc_6FF5 + ld b, a + ld a, (MD5Buffer) + cp b + jr z, p7Dloc_6FE9 + jr c, p7Dloc_6FF4 + jr p7Dloc_6FF5 ; --------------------------------------------------------------------------- p7Dloc_6FE9: call GetBaseVer - ld a, (unk_83A6) - cp b - jr z, p7Dloc_6FF4 - jr nc, p7Dloc_6FF5 + ld a, (unk_83A6) + cp b + jr z, p7Dloc_6FF4 + jr nc, p7Dloc_6FF5 p7Dloc_6FF4: - xor a + xor a p7Dloc_6FF5: - pop de - pop bc - pop hl + pop de + pop bc + pop hl ret ; End of function p7Dsub_6FC0 @@ -9949,41 +9949,41 @@ push hl push bc push de - bit 5, (iy+24h) - jr nz, p7Dloc_701F - ld a, (appPage) - ld hl, 4000h - ld de, 80A0h - rst 28h -; --------------------------------------------------------------------------- - .dw 8075h -; --------------------------------------------------------------------------- - jr nz, p7Dloc_7024 - inc hl - ld a, (appPage) - rst 28h -; --------------------------------------------------------------------------- - .dw 805Ah -; --------------------------------------------------------------------------- - ld a, b - or c - jr z, p7Dloc_7024 - ld a, (hl) - or a - jr z, p7Dloc_7024 + bit 5, (iy+24h) + jr nz, p7Dloc_701F + ld a, (appPage) + ld hl, 4000h + ld de, 80A0h + rst 28h +; --------------------------------------------------------------------------- + .dw 8075h +; --------------------------------------------------------------------------- + jr nz, p7Dloc_7024 + inc hl + ld a, (appPage) + rst 28h +; --------------------------------------------------------------------------- + .dw 805Ah +; --------------------------------------------------------------------------- + ld a, b + or c + jr z, p7Dloc_7024 + ld a, (hl) + or a + jr z, p7Dloc_7024 p7Dloc_701F: call page0_BB1 - jr p7Dloc_7027 + jr p7Dloc_7027 ; --------------------------------------------------------------------------- p7Dloc_7024: call page0_B8D p7Dloc_7027: - pop de - pop bc - pop hl + pop de + pop bc + pop hl ret ; End of function p7Dsub_6FF9 @@ -9997,24 +9997,24 @@ p7Dsub_7045: push bc push af - ld a, (winBtm) - ld b, a + ld a, (winBtm) + ld b, a p7Dloc_704B: - ld a, (hl) - inc hl - or a + ld a, (hl) + inc hl + or a scf - jr z, p7Dloc_705A + jr z, p7Dloc_705A call Page0Call_3F9F - ld a, (curRow) - cp b - jr c, p7Dloc_704B + ld a, (curRow) + cp b + jr c, p7Dloc_704B p7Dloc_705A: - pop bc - ld a, b - pop bc + pop bc + ld a, b + pop bc ret ; End of function p7Dsub_7045 @@ -10023,7 +10023,7 @@ p7Dsub_705E: - ld a, 7Eh ; '~' + ld a, 7Eh ; '~' ; End of function p7Dsub_705E @@ -10036,74 +10036,74 @@ p7Dloc_7062: push af - rst 28h -; --------------------------------------------------------------------------- - .dw 8051h -; --------------------------------------------------------------------------- - cp d - jr nz, p7Dloc_709E - inc hl - pop af - push af - rst 28h -; --------------------------------------------------------------------------- - .dw 8051h -; --------------------------------------------------------------------------- - and 0F0h ; '�' - cp e - jr nz, p7Dloc_7078 - pop af - dec hl - jr p7Dloc_70A2 + rst 28h +; --------------------------------------------------------------------------- + .dw 8051h +; --------------------------------------------------------------------------- + cp d + jr nz, p7Dloc_709E + inc hl + pop af + push af + rst 28h +; --------------------------------------------------------------------------- + .dw 8051h +; --------------------------------------------------------------------------- + and 0F0h ; '�' + cp e + jr nz, p7Dloc_7078 + pop af + dec hl + jr p7Dloc_70A2 ; --------------------------------------------------------------------------- p7Dloc_7078: - pop af - push af - push de - rst 28h -; --------------------------------------------------------------------------- - .dw 805Ah -; --------------------------------------------------------------------------- - pop de - add hl, bc - ld (arcInfo), hl - pop af - push af - push hl - inc hl - rst 28h -; --------------------------------------------------------------------------- - .dw 8051h -; --------------------------------------------------------------------------- - and 0F0h ; '�' - cp e - jr z, p7Dloc_7093 - cp 10h - jr z, p7Dloc_7097 + pop af + push af + push de + rst 28h +; --------------------------------------------------------------------------- + .dw 805Ah +; --------------------------------------------------------------------------- + pop de + add hl, bc + ld (arcInfo), hl + pop af + push af + push hl + inc hl + rst 28h +; --------------------------------------------------------------------------- + .dw 8051h +; --------------------------------------------------------------------------- + and 0F0h ; '�' + cp e + jr z, p7Dloc_7093 + cp 10h + jr z, p7Dloc_7097 p7Dloc_7093: - pop hl - pop af - jr p7Dloc_7062 + pop hl + pop af + jr p7Dloc_7062 ; --------------------------------------------------------------------------- p7Dloc_7097: - pop hl - ld hl, (arcInfo) - ld a, 1 - or a + pop hl + ld hl, (arcInfo) + ld a, 1 + or a p7Dloc_709E: - pop bc - pop ix + pop bc + pop ix ret ; --------------------------------------------------------------------------- p7Dloc_70A2: - ld a, 0 - bit 7, a - pop ix + ld a, 0 + bit 7, a + pop ix ret ; End of function p7Dsub_7060 @@ -10111,29 +10111,29 @@ Page7D_2CFA: push af - ld a, 1 + ld a, 1 nop di nop nop im 1 di - out (14h), a + out (14h), a di call checkForFlashTrickery - pop af + pop af call Page0Call_240A - ld e, (hl) - dec hl - ld d, (hl) - dec hl - ld a, (hl) - ld b, 0FCh ; '�' + ld e, (hl) + dec hl + ld d, (hl) + dec hl + ld a, (hl) + ld b, 0FCh ; '�' call Page7D_2C46 - jp c, Page0Call_2541 - rst 28h -; --------------------------------------------------------------------------- - .dw 8021h + jp c, Page0Call_2541 + rst 28h +; --------------------------------------------------------------------------- + .dw 8021h ; --------------------------------------------------------------------------- call Page7D_3E10 ret @@ -10142,10 +10142,10 @@ p7Dsub_70D1: - ld de, 300h - rst 28h -; --------------------------------------------------------------------------- - .dw 8027h + ld de, 300h + rst 28h +; --------------------------------------------------------------------------- + .dw 8027h ; --------------------------------------------------------------------------- ret ; End of function p7Dsub_70D1 @@ -10156,70 +10156,70 @@ Page7D_3C60: push af - ld a, 1 + ld a, 1 nop di nop nop im 1 di - out (14h), a + out (14h), a di call checkForFlashTrickery - pop af + pop af call p7Dsub_70D1 - jp nz, relockFlashBack - push hl - ld hl, aCert_Revision - ld de, OP1 - ld bc, 12h + jp nz, relockFlashBack + push hl + ld hl, aCert_Revision + ld de, OP1 + ld bc, 12h p7Dloc_710A: - ld a, (hl) - ld (de), a - inc hl - inc de + ld a, (hl) + ld (de), a + inc hl + inc de djnz p7Dloc_710A - ld hl, OP1 + ld hl, OP1 call Page0Call_3D4D - ld a, 7Eh ; '~' - pop hl + ld a, 7Eh ; '~' + pop hl call p7Dsub_4873 push bc - pop hl + pop hl call p7Dsub_598E - jp relockFlashBack + jp relockFlashBack ; =============== S U B R O U T I N E ======================================= p7Dsub_7124: - ld a, (header) - cp 23h ; '#' + ld a, (header) + cp 23h ; '#' ret ; End of function p7Dsub_7124 ; --------------------------------------------------------------------------- Page7D_2BB6: - ld bc, (unk_8685) - sub c - ld hl, (unk_8683) - push af - ld a, (unk_8434) - sub c + ld bc, (unk_8685) + sub c + ld hl, (unk_8683) + push af + ld a, (unk_8434) + sub c call p7Dsub_5EFC - jr c, p7Dloc_7150 - pop af - ld bc, (ioData) - push hl - push bc - push af - ld h, 9 + jr c, p7Dloc_7150 + pop af + ld bc, (ioData) + push hl + push bc + push af + ld h, 9 call Page0Call_2C5B - pop af - pop bc - pop hl + pop af + pop bc + pop hl call p7Dsub_7240 ret ; --------------------------------------------------------------------------- @@ -10230,27 +10230,27 @@ call relockFlashBack call p7Dsub_7124 push af - jr z, p7Dloc_715C + jr z, p7Dloc_715C call popErrorHandleR p7Dloc_715C: - pop af - push af - jr z, p7Dloc_7166 - ld hl, Page0Call_2C79 + pop af + push af + jr z, p7Dloc_7166 + ld hl, Page0Call_2C79 call pushErrorHandleR p7Dloc_7166: call Page0Call_3D2F - ld a, 0Bh + ld a, 0Bh call Page0Call_2C49 - pop af - jr z, p7Dloc_7174 + pop af + jr z, p7Dloc_7174 call popErrorHandleR p7Dloc_7174: call Page0Call_3D05 - jp Page0Call_2541 + jp Page0Call_2541 ; END OF FUNCTION CHUNK FOR p7Dsub_7240 ; =============== S U B R O U T I N E ======================================= @@ -10258,9 +10258,9 @@ p7Dsub_717A: - ld hl, ramStart - ld de, 81AFh - jr p7Dloc_7188 + ld hl, ramStart + ld de, 81AFh + jr p7Dloc_7188 ; End of function p7Dsub_717A @@ -10269,11 +10269,11 @@ p7Dsub_7182: ; p7Dsub_7240+1EDp ... - ld hl, 81AFh - ld de, ramStart + ld hl, 81AFh + ld de, ramStart p7Dloc_7188: - ld bc, 80h ; '�' + ld bc, 80h ; '�' ldir ret ; End of function p7Dsub_7182 @@ -10281,103 +10281,103 @@ ; --------------------------------------------------------------------------- WriteToFlash: - cp 0 - jr z, p7Dloc_71B3 - cp 1 - jp z, Page7D_2BE0 - cp 2 - jp z, p7Dloc_7E57 - cp 3 - jp z, p7Dloc_7E31 - cp 4 - jp z, p7Dsub_7D67 - cp 5 - jp z, p7Dloc_7E8D - cp 6 - jp z, p7Dloc_7E91 - jp ErrInvalid + cp 0 + jr z, p7Dloc_71B3 + cp 1 + jp z, Page7D_2BE0 + cp 2 + jp z, p7Dloc_7E57 + cp 3 + jp z, p7Dloc_7E31 + cp 4 + jp z, p7Dsub_7D67 + cp 5 + jp z, p7Dloc_7E8D + cp 6 + jp z, p7Dloc_7E91 + jp ErrInvalid ; --------------------------------------------------------------------------- p7Dloc_71B3: push ix - ld a, (ramCodeEnd) - or a - ld a, e - jr nz, p7Dloc_71D9 + ld a, (ramCodeEnd) + or a + ld a, e + jr nz, p7Dloc_71D9 push hl push bc call p7Dsub_7B72 - pop bc - pop hl - or a - jp z, Page7D_2BBC - push hl - ld de, 4000h - sbc hl, de - jp nz, Page0Call_2541 - ld hl, 7Fh ; '' - sbc hl, bc - jp nc, Page0Call_2541 - pop hl + pop bc + pop hl + or a + jp z, Page7D_2BBC + push hl + ld de, 4000h + sbc hl, de + jp nz, Page0Call_2541 + ld hl, 7Fh ; '' + sbc hl, bc + jp nc, Page0Call_2541 + pop hl p7Dloc_71D9: push af - ld (appSearchPage+1), a + ld (appSearchPage+1), a call p7Dsub_5EFC - jp c, Page0Call_2541 - push hl - ld de, 4080h - sbc hl, de - pop hl - jr nc, p7Dloc_71FD - ld a, (ramCodeEnd) - or a - jr z, p7Dloc_71FD - ld a, (unk_8434) - ld e, a - ld a, (appSearchPage+1) - cp e - jp z, Page0Call_2541 + jp c, Page0Call_2541 + push hl + ld de, 4080h + sbc hl, de + pop hl + jr nc, p7Dloc_71FD + ld a, (ramCodeEnd) + or a + jr z, p7Dloc_71FD + ld a, (unk_8434) + ld e, a + ld a, (appSearchPage+1) + cp e + jp z, Page0Call_2541 p7Dloc_71FD: - xor a - ld (appInfo), a - ld (unk_843B), hl - ld (unk_8439), bc - push af - ld a, 1 + xor a + ld (appInfo), a + ld (unk_843B), hl + ld (unk_8439), bc + push af + ld a, 1 nop di nop nop im 1 di - out (14h), a + out (14h), a di call checkForFlashTrickery - pop af - res 6, (iy+24h) - res 7, (iy+24h) - xor a - ld (unk_9C87), a + pop af + res 6, (iy+24h) + res 7, (iy+24h) + xor a + ld (unk_9C87), a p7Dloc_7225: push bc - ld a, (unk_83A4) - cp 0 - jr z, p7Dloc_7234 - ld a, (unk_83A3) - inc a - ld (unk_83A3), a + ld a, (unk_83A4) + cp 0 + jr z, p7Dloc_7234 + ld a, (unk_83A3) + inc a + ld (unk_83A3), a p7Dloc_7234: call p7Dsub_7CBB - pop bc - dec bc - ld a, b - or c - jr nz, p7Dloc_7225 - jp p7Dloc_739B + pop bc + dec bc + ld a, b + or c + jr nz, p7Dloc_7225 + jp p7Dloc_739B ; =============== S U B R O U T I N E ======================================= @@ -10393,51 +10393,51 @@ push ix push af - ld (appSearchPage+1), a - xor a - ld (sndRecState), a - ex de, hl - ld (unk_843B), de + ld (appSearchPage+1), a + xor a + ld (sndRecState), a + ex de, hl + ld (unk_843B), de push bc call Page0Call_2C61 - pop bc - ld hl, ioFlag - ld a, (unk_8675) - cp 15h - jp nz, p7Dloc_733F - push af - ld a, 1 + pop bc + ld hl, ioFlag + ld a, (unk_8675) + cp 15h + jp nz, p7Dloc_733F + push af + ld a, 1 nop di nop nop im 1 di - out (14h), a + out (14h), a di call checkForFlashTrickery - pop af - ld hl, (unk_8676) - or a - sbc hl, bc - jp nz, p7Dloc_733F - res 6, (iy+24h) - res 7, (iy+24h) - xor a - ld (unk_9C87), a - ld bc, (unk_8676) - ld de, 0 - ld (unk_8678), de - ld a, c - or b - jp z, p7Dloc_7363 - ld hl, ramStart - ld (unk_8439), bc + pop af + ld hl, (unk_8676) + or a + sbc hl, bc + jp nz, p7Dloc_733F + res 6, (iy+24h) + res 7, (iy+24h) + xor a + ld (unk_9C87), a + ld bc, (unk_8676) + ld de, 0 + ld (unk_8678), de + ld a, c + or b + jp z, p7Dloc_7363 + ld hl, ramStart + ld (unk_8439), bc p7Dloc_729C: call CHKERRBREAK - jp z, p7Dloc_7345 - jp JErrorNo + jp z, p7Dloc_7345 + jp JErrorNo ; End of function p7Dsub_7240 ; --------------------------------------------------------------------------- @@ -10449,27 +10449,27 @@ call relockFlashBack call p7Dsub_7124 push af - jr z, p7Dloc_72B4 + jr z, p7Dloc_72B4 call popErrorHandleR p7Dloc_72B4: - pop af - push af - jr z, p7Dloc_72BE - ld hl, Page0Call_2C79 + pop af + push af + jr z, p7Dloc_72BE + ld hl, Page0Call_2C79 call pushErrorHandleR p7Dloc_72BE: call Page0Call_3D2F - ld a, 1 + ld a, 1 call Page0Call_2C49 - pop af - jr z, p7Dloc_72CC + pop af + jr z, p7Dloc_72CC call popErrorHandleR p7Dloc_72CC: call Page0Call_3D05 - jp ErrMemory + jp ErrMemory ; END OF FUNCTION CHUNK FOR p7Dsub_7BEA ; --------------------------------------------------------------------------- ; START OF FUNCTION CHUNK FOR p7Dsub_7240 @@ -10479,28 +10479,28 @@ call relockFlashBack call p7Dsub_7124 push af - jr z, p7Dloc_72E1 + jr z, p7Dloc_72E1 call popErrorHandleR p7Dloc_72E1: - pop af - push af - jr z, p7Dloc_72EB - ld hl, Page0Call_2C79 + pop af + push af + jr z, p7Dloc_72EB + ld hl, Page0Call_2C79 call pushErrorHandleR p7Dloc_72EB: call Page0Call_3D2F - ld a, 7 + ld a, 7 call Page0Call_2C49 - pop af - jr z, p7Dloc_72F9 + pop af + jr z, p7Dloc_72F9 call popErrorHandleR p7Dloc_72F9: call Page0Call_2C55 call Page0Call_3D05 - jp Page0Call_2539 + jp Page0Call_2539 ; --------------------------------------------------------------------------- p7Dloc_7302: @@ -10508,27 +10508,27 @@ call relockFlashBack call p7Dsub_7124 push af - jr z, p7Dloc_7311 + jr z, p7Dloc_7311 call popErrorHandleR p7Dloc_7311: - pop af - push af - jr z, p7Dloc_731B - ld hl, Page0Call_2C79 + pop af + push af + jr z, p7Dloc_731B + ld hl, Page0Call_2C79 call pushErrorHandleR p7Dloc_731B: call Page0Call_3D2F - ld a, 9 + ld a, 9 call Page0Call_2C49 - pop af - jr z, p7Dloc_7329 + pop af + jr z, p7Dloc_7329 call popErrorHandleR p7Dloc_7329: call Page0Call_3D05 - jp Page0Call_253D + jp Page0Call_253D ; END OF FUNCTION CHUNK FOR p7Dsub_7240 ; --------------------------------------------------------------------------- ; START OF FUNCTION CHUNK FOR p7Dsub_75B8 @@ -10542,8 +10542,8 @@ ; START OF FUNCTION CHUNK FOR p7Dsub_7240 p7Dloc_7336: - ld h, 36h ; '6' - jp Page0Call_2C73 + ld h, 36h ; '6' + jp Page0Call_2C73 ; END OF FUNCTION CHUNK FOR p7Dsub_7240 ; =============== S U B R O U T I N E ======================================= @@ -10552,11 +10552,11 @@ p7Dsub_733B: ; p7Dsub_7240:p7Dloc_72D2p ... call p7Dsub_7CB2 - ret nz + ret nz p7Dloc_733F: call relockFlashBack - jp JErrorNo + jp JErrorNo ; End of function p7Dsub_733B ; --------------------------------------------------------------------------- @@ -10565,375 +10565,375 @@ p7Dloc_7345: push bc call j_RecAByteIO - ld (hl), a + ld (hl), a call p7Dsub_7CA5 - inc hl - ex de, hl - ld b, 0 - ld hl, (unk_8678) - add hl, bc - ld (unk_8678), hl - ex de, hl + inc hl + ex de, hl + ld b, 0 + ld hl, (unk_8678) + add hl, bc + ld (unk_8678), hl + ex de, hl call p7Dsub_7CBB - pop bc - dec bc - ld a, b - or c - jp nz, p7Dloc_729C + pop bc + dec bc + ld a, b + or c + jp nz, p7Dloc_729C p7Dloc_7363: call j_RecAByteIO push af call j_RecAByteIO - ld b, a - pop af - ld c, a - in a, (2) - and 80h ; '�' - jr z, p7Dloc_738A - in a, (20h) - and 1 - jr z, p7Dloc_738A - xor a - out (20h), a - ld de, 0FEh ; '�' + ld b, a + pop af + ld c, a + in a, (2) + and 80h ; '�' + jr z, p7Dloc_738A + in a, (20h) + and 1 + jr z, p7Dloc_738A + xor a + out (20h), a + ld de, 0FEh ; '�' p7Dloc_737F: - dec de - ld a, d - or e - jr nz, p7Dloc_737F - ld a, 1 - out (20h), a - jr p7Dloc_7392 + dec de + ld a, d + or e + jr nz, p7Dloc_737F + ld a, 1 + out (20h), a + jr p7Dloc_7392 ; --------------------------------------------------------------------------- p7Dloc_738A: ; p7Dsub_7240+137j - ld de, 100h + ld de, 100h p7Dloc_738D: - dec de - ld a, d - or e - jr nz, p7Dloc_738D + dec de + ld a, d + or e + jr nz, p7Dloc_738D p7Dloc_7392: - ld hl, (unk_8678) - or a - sbc hl, bc - jp nz, p7Dloc_75A5 + ld hl, (unk_8678) + or a + sbc hl, bc + jp nz, p7Dloc_75A5 p7Dloc_739B: call p7Dsub_5E0A - ld a, (ramCodeEnd) - cp 0 - jp nz, p7Dloc_74BC - ld de, (unk_843B) - push de - rst 28h -; --------------------------------------------------------------------------- - .dw 8063h -; --------------------------------------------------------------------------- - pop de - ld (unk_843B), de - jp nz, p7Dloc_72D2 - ld a, 1 - ld de, 8050h + ld a, (ramCodeEnd) + cp 0 + jp nz, p7Dloc_74BC + ld de, (unk_843B) + push de + rst 28h +; --------------------------------------------------------------------------- + .dw 8063h +; --------------------------------------------------------------------------- + pop de + ld (unk_843B), de + jp nz, p7Dloc_72D2 + ld a, 1 + ld de, 8050h call p7Dsub_7060 - jr nz, p7Dloc_73C6 + jr nz, p7Dloc_73C6 call p7Dsub_50C5 - jp nz, p7Dloc_7302 + jp nz, p7Dloc_7302 p7Dloc_73C6: call p7Dsub_75B8 - ld a, (appInfo) - cp 0 - jp nz, p7Dloc_75B4 - di - ld hl, (curRow) + ld a, (appInfo) + cp 0 + jp nz, p7Dloc_75B4 + di + ld hl, (curRow) push hl call Page0Call_3CD5 - ld a, (ioFlag) + ld a, (ioFlag) push af call p7Dsub_717A - res 2, (iy+25h) + res 2, (iy+25h) call Chk_Batt_Low - jp z, ErrInvalid - ld a, 0 - ld b, 0 + jp z, ErrInvalid + ld a, 0 + ld b, 0 call Page0Call_2EB9 call p7Dsub_7182 - pop af - pop hl - ld (curRow), hl - ld (ioFlag), a + pop af + pop hl + ld (curRow), hl + ld (ioFlag), a call p7Dsub_7B72 - or a - jp z, Page7D_2BBC + or a + jp z, Page7D_2BBC push af call p7Dsub_7BEA - jr c, p7Dloc_740C + jr c, p7Dloc_740C p7Dloc_7409: - jp nz, Page7D_2BBC + jp nz, Page7D_2BBC p7Dloc_740C: - xor a - cp d - jp z, ErrInvalid + xor a + cp d + jp z, ErrInvalid push de call FindSwapSector - cp 8 - jr z, p7Dloc_7430 - add a, 4 - ld b, a - ld a, c - sub d - cp b - jr nc, p7Dloc_7430 - ld a, 5 + cp 8 + jr z, p7Dloc_7430 + add a, 4 + ld b, a + ld a, c + sub d + cp b + jr nc, p7Dloc_7430 + ld a, 5 call Page0Call_2EB9 call FindSwapSector - cp 8 - jr nz, p7Dloc_7409 + cp 8 + jr nz, p7Dloc_7409 call p7Dsub_7182 p7Dloc_7430: ; p7Dsub_7240+1DFj - ld a, (appSearchPage) + ld a, (appSearchPage) call Page7D_2C16 - ld a, 1 - ld hl, ramStart + ld a, 1 + ld hl, ramStart call Page7D_2C9A call p7Dsub_7CB2 - jr z, p7Dloc_7453 - ld a, 19h - ld (sndRecState), a + jr z, p7Dloc_7453 + ld a, 19h + ld (sndRecState), a call Page0Call_2E23 call Page0Call_2DE7 di - xor a - ld (sndRecState), a + xor a + ld (sndRecState), a p7Dloc_7453: - pop de - pop af - push de - push af - ld a, 1 + pop de + pop af + push de + push af + ld a, 1 nop di nop nop im 1 di - out (14h), a + out (14h), a di call checkForFlashTrickery - pop af + pop af call p7Dsub_519D call p7Dsub_5E90 - ld hl, ramStart + ld hl, ramStart call p7Dsub_5757 - ld hl, (unk_83A1) + ld hl, (unk_83A1) call p7Dsub_57C5 push hl - ld a, 1 - ld hl, ramStart - push hl - inc hl - rst 28h -; --------------------------------------------------------------------------- - .dw 805Ah -; --------------------------------------------------------------------------- - pop bc - sbc hl, bc - push hl - pop bc - ld hl, (unk_8439) - sbc hl, bc - push hl - pop bc - pop hl - sbc hl, bc + ld a, 1 + ld hl, ramStart + push hl + inc hl + rst 28h +; --------------------------------------------------------------------------- + .dw 805Ah +; --------------------------------------------------------------------------- + pop bc + sbc hl, bc + push hl + pop bc + ld hl, (unk_8439) + sbc hl, bc + push hl + pop bc + pop hl + sbc hl, bc call p7Dsub_57C5 - ld (unk_83A1), hl - jr c, p7Dloc_749D - jr nz, p7Dloc_74F0 + ld (unk_83A1), hl + jr c, p7Dloc_749D + jr nz, p7Dloc_74F0 p7Dloc_749D: - ld hl, (unk_839F) + ld hl, (unk_839F) call p7Dsub_57C5 - dec hl + dec hl call p7Dsub_57C5 - ld (unk_839F), hl - ld a, l - or h - jr nz, p7Dloc_74BA - ld hl, (unk_83A1) - ld a, l - or h - jr nz, p7Dloc_74BA - ld a, 0 - ld (unk_83A4), a + ld (unk_839F), hl + ld a, l + or h + jr nz, p7Dloc_74BA + ld hl, (unk_83A1) + ld a, l + or h + jr nz, p7Dloc_74BA + ld a, 0 + ld (unk_83A4), a p7Dloc_74BA: ; p7Dsub_7240+273j - jr p7Dloc_74F0 + jr p7Dloc_74F0 ; --------------------------------------------------------------------------- p7Dloc_74BC: push de call p7Dsub_7CB2 - jr nz, p7Dloc_74F0 - ld a, (appSearchPage+1) + jr nz, p7Dloc_74F0 + ld a, (appSearchPage+1) call p7Dsub_7CCF call p7Dsub_4566 - cp 0FEh ; '�' - jr nz, p7Dloc_74ED + cp 0FEh ; '�' + jr nz, p7Dloc_74ED call p7Dsub_4565 - cp 0BFh ; '�' - jr nz, p7Dloc_74ED + cp 0BFh ; '�' + jr nz, p7Dloc_74ED call p7Dsub_4565 - ld b, a - ld a, (appSearchPage+1) - cp b - jr z, p7Dloc_74F0 - jr nc, p7Dloc_74ED + ld b, a + ld a, (appSearchPage+1) + cp b + jr z, p7Dloc_74F0 + jr nc, p7Dloc_74ED call p7Dsub_4565 - ld b, a - ld a, (appSearchPage+1) - inc b - cp b - jr nc, p7Dloc_74F0 + ld b, a + ld a, (appSearchPage+1) + inc b + cp b + jr nc, p7Dloc_74F0 p7Dloc_74ED: ; p7Dsub_7240+294j ... - jp p7Dloc_7150 + jp p7Dloc_7150 ; --------------------------------------------------------------------------- p7Dloc_74F0: ; p7Dsub_7240:p7Dloc_74BAj ... - ld bc, (unk_8439) - ld hl, ramStart - ld de, (unk_843B) - ld a, (appSearchPage+1) - bit 7, d - jp nz, p7Dloc_7150 - bit 6, d - jp z, p7Dloc_7150 - cp 8 - jp c, p7Dloc_7150 + ld bc, (unk_8439) + ld hl, ramStart + ld de, (unk_843B) + ld a, (appSearchPage+1) + bit 7, d + jp nz, p7Dloc_7150 + bit 6, d + jp z, p7Dloc_7150 + cp 8 + jp c, p7Dloc_7150 call p7Dsub_75E1 - jp nc, p7Dloc_7150 + jp nc, p7Dloc_7150 call p7Dsub_756F - rst 28h -; --------------------------------------------------------------------------- - .dw 8087h + rst 28h +; --------------------------------------------------------------------------- + .dw 8087h ; --------------------------------------------------------------------------- call p7Dsub_7CB2 - jr z, p7Dloc_752A + jr z, p7Dloc_752A call relockFlashBack call Page0Call_3F1B p7Dloc_7524: - pop de + pop de p7Dloc_7525: - pop af - pop ix - xor a + pop af + pop ix + xor a ret ; --------------------------------------------------------------------------- p7Dloc_752A: - ld a, (ramCodeEnd) - or a - jr z, p7Dloc_7535 + ld a, (ramCodeEnd) + or a + jr z, p7Dloc_7535 call relockFlashBack - jr p7Dloc_7524 + jr p7Dloc_7524 ; --------------------------------------------------------------------------- p7Dloc_7535: call p7Dsub_7CCF - pop de - push hl - push de - ld b, 4 + pop de + push hl + push de + ld b, 4 p7Dloc_753D: call p7Dsub_4566 - cp 0FFh - jr nz, p7Dloc_7549 - inc hl + cp 0FFh + jr nz, p7Dloc_7549 + inc hl djnz p7Dloc_753D - jr p7Dloc_754C + jr p7Dloc_754C ; --------------------------------------------------------------------------- p7Dloc_7549: call Page7D_2BB0 p7Dloc_754C: - ld hl, 0BFFEh - ld (OP1+1), hl - ld a, (appSearchPage) - ld (unk_847B), a - pop de - sub d - ld (unk_847C), a - ld bc, 4 - ld hl, 8479h + ld hl, 0BFFEh + ld (OP1+1), hl + ld a, (appSearchPage) + ld (unk_847B), a + pop de + sub d + ld (unk_847C), a + ld bc, 4 + ld hl, 8479h call p7Dsub_7700 - pop de - rst 28h -; --------------------------------------------------------------------------- - .dw 8087h + pop de + rst 28h +; --------------------------------------------------------------------------- + .dw 8087h ; --------------------------------------------------------------------------- call relockFlashBack - jr p7Dloc_7525 + jr p7Dloc_7525 ; END OF FUNCTION CHUNK FOR p7Dsub_7240 ; =============== S U B R O U T I N E ======================================= p7Dsub_756F: - ld h, d - ld l, e - dec hl - add hl, bc - bit 7, h - jr z, p7Dloc_75A1 - ld hl, ramStart - ld de, (unk_843B) - or a - sbc hl, de - ld b, h - ld c, l - ld hl, ramStart - push bc - rst 28h -; --------------------------------------------------------------------------- - .dw 8087h -; --------------------------------------------------------------------------- - pop bc - ld a, (appSearchPage+1) - dec a - ld hl, (unk_8439) - or a - sbc hl, bc - push bc - ld b, h - ld c, l - pop de - ld hl, ramStart - add hl, de - ld de, 4000h + ld h, d + ld l, e + dec hl + add hl, bc + bit 7, h + jr z, p7Dloc_75A1 + ld hl, ramStart + ld de, (unk_843B) + or a + sbc hl, de + ld b, h + ld c, l + ld hl, ramStart + push bc + rst 28h +; --------------------------------------------------------------------------- + .dw 8087h +; --------------------------------------------------------------------------- + pop bc + ld a, (appSearchPage+1) + dec a + ld hl, (unk_8439) + or a + sbc hl, bc + push bc + ld b, h + ld c, l + pop de + ld hl, ramStart + add hl, de + ld de, 4000h ret ; --------------------------------------------------------------------------- p7Dloc_75A1: - ld hl, ramStart + ld hl, ramStart ret ; End of function p7Dsub_756F @@ -10941,25 +10941,25 @@ ; START OF FUNCTION CHUNK FOR p7Dsub_7240 p7Dloc_75A5: - ld hl, (unk_8439) - push hl - ld h, 5Ah ; 'Z' + ld hl, (unk_8439) + push hl + ld h, 5Ah ; 'Z' call Page0Call_2C5B - jp p7Dloc_7336 + jp p7Dloc_7336 ; END OF FUNCTION CHUNK FOR p7Dsub_7240 ; --------------------------------------------------------------------------- ; START OF FUNCTION CHUNK FOR p7Dsub_75B8 p7Dloc_75B1: - jp p7Dloc_732F + jp p7Dloc_732F ; END OF FUNCTION CHUNK FOR p7Dsub_75B8 ; --------------------------------------------------------------------------- ; START OF FUNCTION CHUNK FOR p7Dsub_7240 p7Dloc_75B4: - pop af - pop ix + pop af + pop ix ret ; END OF FUNCTION CHUNK FOR p7Dsub_7240 @@ -10972,28 +10972,28 @@ call ZeroOP1 - ld a, 1 - or a - ld hl, ramStart - ld de, 8040h - rst 28h -; --------------------------------------------------------------------------- - .dw 8075h -; --------------------------------------------------------------------------- - jp nz, p7Dloc_75B1 - inc hl - ld a, 1 - rst 28h -; --------------------------------------------------------------------------- - .dw 805Ah -; --------------------------------------------------------------------------- - ld de, 8479h + ld a, 1 + or a + ld hl, ramStart + ld de, 8040h + rst 28h +; --------------------------------------------------------------------------- + .dw 8075h +; --------------------------------------------------------------------------- + jp nz, p7Dloc_75B1 + inc hl + ld a, 1 + rst 28h +; --------------------------------------------------------------------------- + .dw 805Ah +; --------------------------------------------------------------------------- + ld de, 8479h ldir - ld a, (appSearchPage+1) + ld a, (appSearchPage+1) push af call p7Dsub_6428 - pop af - ld (appSearchPage+1), a + pop af + ld (appSearchPage+1), a ret ; End of function p7Dsub_75B8 @@ -11004,13 +11004,13 @@ p7Dsub_75E1: ; FindSwapSector+18p ... call NZIf83Plus - jr nz, p7Dloc_75E9 - cp 6Ah ; 'j' + jr nz, p7Dloc_75E9 + cp 6Ah ; 'j' ret ; --------------------------------------------------------------------------- p7Dloc_75E9: - cp 16h + cp 16h ret ; End of function p7Dsub_75E1 @@ -11019,10 +11019,10 @@ p7Dsub_75EC: - ld a, 15h + ld a, 15h call NZIf83Plus - ret nz - ld a, 69h ; 'i' + ret nz + ld a, 69h ; 'i' ret ; End of function p7Dsub_75EC @@ -11032,8 +11032,8 @@ p7Dsub_75F5: call p7Dsub_75EC - inc a - ld (appSearchPage), a + inc a + ld (appSearchPage), a ret ; End of function p7Dsub_75F5 @@ -11042,35 +11042,35 @@ p7Dsub_75FD: - ld de, 839Fh - and 0Fh - cp 0Fh - jr nz, p7Dloc_7609 - ld b, 4 + ld de, 839Fh + and 0Fh + cp 0Fh + jr nz, p7Dloc_7609 + ld b, 4 ret ; --------------------------------------------------------------------------- p7Dloc_7609: - cp 0Eh - jr nz, p7Dloc_7612 - ld b, 2 - xor a - jr p7Dloc_761A + cp 0Eh + jr nz, p7Dloc_7612 + ld b, 2 + xor a + jr p7Dloc_761A ; --------------------------------------------------------------------------- p7Dloc_7612: - cp 0Dh - ret nz - ld b, 1 - xor a - ld (de), a - inc de + cp 0Dh + ret nz + ld b, 1 + xor a + ld (de), a + inc de p7Dloc_761A: - ld (de), a - inc de - ld (de), a - inc de + ld (de), a + inc de + ld (de), a + inc de ret ; End of function p7Dsub_75FD @@ -11081,10 +11081,10 @@ p7Dsub_761F: push af call Page7D_2CD0 - ld (de), a - inc de - inc hl - pop af + ld (de), a + inc de + inc hl + pop af djnz p7Dsub_761F ret ; End of function p7Dsub_761F @@ -11095,10 +11095,10 @@ p7Dsub_762A: call p7Dsub_7634 - ld de, 610h - rst 28h -; --------------------------------------------------------------------------- - .dw 8030h + ld de, 610h + rst 28h +; --------------------------------------------------------------------------- + .dw 8030h ; --------------------------------------------------------------------------- ret ; End of function p7Dsub_762A @@ -11109,10 +11109,10 @@ p7Dsub_7634: call p7Dsub_4894 - ld de, 600h + ld de, 600h call p7Dsub_777E call p7Dsub_4574 - ld a, 7Eh ; '~' + ld a, 7Eh ; '~' ret ; End of function p7Dsub_7634 @@ -11121,10 +11121,10 @@ p7Dsub_7643: - ld bc, 0Dh + ld bc, 0Dh call NZIf83Plus - ret nz - ld bc, 61h ; 'a' + ret nz + ld bc, 61h ; 'a' ret ; End of function p7Dsub_7643 @@ -11135,9 +11135,9 @@ p7Dsub_764E: ; p7Dsub_484E:p7Dloc_486Cp ... push ix - pop hl - ld bc, 0Dh - add hl, bc + pop hl + ld bc, 0Dh + add hl, bc ret ; End of function p7Dsub_764E @@ -11146,22 +11146,22 @@ p7Dsub_7656: - ld a, 16h + ld a, 16h call NZIf83Plus - ret nz - ld a, 6Ah ; 'j' + ret nz + ld a, 6Ah ; 'j' ret ; End of function p7Dsub_7656 ; --------------------------------------------------------------------------- - ld hl, OP1 - ld (hl), b + ld hl, OP1 + ld (hl), b ; =============== S U B R O U T I N E ======================================= p7Dsub_7663: - ld bc, 1 + ld bc, 1 ; End of function p7Dsub_7663 @@ -11170,122 +11170,122 @@ p7Dsub_7666: ; CopyFlashPage+38p ... - res 1, (iy+25h) + res 1, (iy+25h) call NZIf83Plus - jr z, p7Dloc_7671 - and 1Fh + jr z, p7Dloc_7671 + and 1Fh p7Dloc_7671: push ix - ld ix, WriteFlashPrivilegedCopy + ld ix, WriteFlashPrivilegedCopy call p7Dsub_6B87 - pop ix + pop ix ret ; End of function p7Dsub_7666 WriteFlashPrivilegedCopy: - .dw 81h - ld (flashByte2), a - in a, (6) - push af - ld a, (flashByte2) - out (6), a - bit 7, h - jr nz, p7Dloc_7692 - set 1, (iy+25h) + .dw 81h + ld (flashByte2), a + in a, (6) + push af + ld a, (flashByte2) + out (6), a + bit 7, h + jr nz, p7Dloc_7692 + set 1, (iy+25h) p7Dloc_7692: - bit 1, (iy+25h) - push hl - jr nz, p7Dloc_76AD - ld hl, 7FFFh - or a - sbc hl, de - jr nc, p7Dloc_76AD - in a, (6) - inc a - cp 7Eh ; '~' - jr z, p7Dloc_76AA - out (6), a + bit 1, (iy+25h) + push hl + jr nz, p7Dloc_76AD + ld hl, 7FFFh + or a + sbc hl, de + jr nc, p7Dloc_76AD + in a, (6) + inc a + cp 7Eh ; '~' + jr z, p7Dloc_76AA + out (6), a p7Dloc_76AA: - ld de, 4000h + ld de, 4000h p7Dloc_76AD: - pop hl - in a, (6) - push af - ld a, 2 - out (6), a - ld a, 0AAh ; '�' - ld (p7Dloc_6AA8+2), a - ld a, 1 - out (6), a - ld a, 55h ; 'U' - ld (p7Dloc_5555), a - ld a, 2 - out (6), a - ld a, 0A0h ; '�' - ld (p7Dloc_6AA8+2), a - pop af - out (6), a - ld a, (hl) - ld a, (hl) - ld (de), a + pop hl + in a, (6) + push af + ld a, 2 + out (6), a + ld a, 0AAh ; '�' + ld (p7Dloc_6AA8+2), a + ld a, 1 + out (6), a + ld a, 55h ; 'U' + ld (p7Dloc_5555), a + ld a, 2 + out (6), a + ld a, 0A0h ; '�' + ld (p7Dloc_6AA8+2), a + pop af + out (6), a + ld a, (hl) + ld a, (hl) + ld (de), a p7Dloc_76D2: - ld a, (de) - push af - xor (hl) - and 80h ; '�' - jr z, p7Dloc_76E6 - pop af - bit 5, a - jr z, p7Dloc_76D2 - ld a, (de) - xor (hl) - and 80h ; '�' - jr nz, p7Dloc_76F8 - jr p7Dloc_76E7 + ld a, (de) + push af + xor (hl) + and 80h ; '�' + jr z, p7Dloc_76E6 + pop af + bit 5, a + jr z, p7Dloc_76D2 + ld a, (de) + xor (hl) + and 80h ; '�' + jr nz, p7Dloc_76F8 + jr p7Dloc_76E7 ; --------------------------------------------------------------------------- p7Dloc_76E6: - pop af + pop af p7Dloc_76E7: - inc de - inc hl - dec bc - ld a, b - or c - jr nz, p7Dloc_7692 - dec de - ld a, 0F0h ; '�' - ld (de), a - inc de - pop af - out (6), a - xor a + inc de + inc hl + dec bc + ld a, b + or c + jr nz, p7Dloc_7692 + dec de + ld a, 0F0h ; '�' + ld (de), a + inc de + pop af + out (6), a + xor a ret ; --------------------------------------------------------------------------- p7Dloc_76F8: - ld a, 0F0h ; '�' - ld (de), a - pop af - out (6), a - or a + ld a, 0F0h ; '�' + ld (de), a + pop af + out (6), a + or a ret ; =============== S U B R O U T I N E ======================================= p7Dsub_7700: - in a, (2) - and 80h ; '�' - ld a, 1Eh - ret z - ld a, 7Eh ; '~' + in a, (2) + and 80h ; '�' + ld a, 1Eh + ret z + ld a, 7Eh ; '~' ret ; End of function p7Dsub_7700 @@ -11293,72 +11293,72 @@ Page7D_2C28: push af - inc a - ld (appSearchPage), a + inc a + ld (appSearchPage), a call p7Dsub_638B - ld a, 14h - ld (OP1), a - ld bc, 8 - ld hl, 8484h - ld de, 8479h + ld a, 14h + ld (OP1), a + ld bc, 8 + ld hl, 8484h + ld de, 8479h ldir - pop af + pop af ret ; --------------------------------------------------------------------------- Page7D_2BE0: push af - ld a, 1 + ld a, 1 nop di nop nop im 1 di - out (14h), a + out (14h), a di call checkForFlashTrickery - pop af - ld a, (unk_8434) + pop af + ld a, (unk_8434) nop call p7Dsub_43F6 - jr nz, ret8 - ld a, (unk_8434) - ld hl, 4000h + jr nz, ret8 + ld a, (unk_8434) + ld hl, 4000h call p7Dsub_5E59 call p7Dsub_52D9 - jp c, p7Dloc_774F - jr nz, ret9 + jp c, p7Dloc_774F + jr nz, ret9 p7Dloc_774F: - ld a, (unk_8434) - ld hl, 4000h + ld a, (unk_8434) + ld hl, 4000h call Page7D_2C9A call p7Dsub_51C3 - ld a, (unk_8434) - ld hl, 4000h + ld a, (unk_8434) + ld hl, 4000h call p7Dsub_5E59 call p7Dsub_533B call Page7D_2B56 - ld a, b - rst 28h -; --------------------------------------------------------------------------- - .dw 80CFh -; --------------------------------------------------------------------------- - ld a, 0FFh - ld (ioFlag), a + ld a, b + rst 28h +; --------------------------------------------------------------------------- + .dw 80CFh +; --------------------------------------------------------------------------- + ld a, 0FFh + ld (ioFlag), a call relockFlashBack - xor a + xor a ret ; --------------------------------------------------------------------------- ret9: - ld a, 9 + ld a, 9 ret ; --------------------------------------------------------------------------- ret8: - ld a, 8 + ld a, 8 ret ; =============== S U B R O U T I N E ======================================= @@ -11366,85 +11366,85 @@ p7Dsub_777E: call p7Dsub_7700 - rst 28h -; --------------------------------------------------------------------------- - .dw 805Dh + rst 28h +; --------------------------------------------------------------------------- + .dw 805Dh ; --------------------------------------------------------------------------- ret ; End of function p7Dsub_777E ; --------------------------------------------------------------------------- - rst 28h -; --------------------------------------------------------------------------- - .dw 8063h -; --------------------------------------------------------------------------- - jp nz, p7Dloc_7813 - ld a, 1 - ld de, 8050h + rst 28h +; --------------------------------------------------------------------------- + .dw 8063h +; --------------------------------------------------------------------------- + jp nz, p7Dloc_7813 + ld a, 1 + ld de, 8050h call p7Dsub_7060 - jr nz, p7Dloc_779B + jr nz, p7Dloc_779B call p7Dsub_50C5 - jp nz, p7Dloc_7810 + jp nz, p7Dloc_7810 p7Dloc_779B: call p7Dsub_7B41 - ld a, (appInfo) - cp 0 - jp nz, p7Dloc_75B4 - di - ld a, (ioFlag) + ld a, (appInfo) + cp 0 + jp nz, p7Dloc_75B4 + di + ld a, (ioFlag) push af call p7Dsub_717A - ld a, 0 - ld b, 0 - res 2, (iy+25h) + ld a, 0 + ld b, 0 + res 2, (iy+25h) call Page0Call_2EB9 call p7Dsub_7182 - pop af - ld (ioFlag), a + pop af + ld (ioFlag), a call p7Dsub_7B72 - or a - jp z, p7Dloc_780D + or a + jp z, p7Dloc_780D push af call p7Dsub_7BEA - jr c, p7Dloc_77D2 - jr z, p7Dloc_77D2 + jr c, p7Dloc_77D2 + jr z, p7Dloc_77D2 p7Dloc_77CF: - jp p7Dloc_780D + jp p7Dloc_780D ; --------------------------------------------------------------------------- p7Dloc_77D2: call FindSwapSector - cp 8 - jr z, p7Dloc_77F0 - add a, 4 - ld b, a - ld a, c - sub d - cp b - jr nc, p7Dloc_77F0 - ld a, 5 + cp 8 + jr z, p7Dloc_77F0 + add a, 4 + ld b, a + ld a, c + sub d + cp b + jr nc, p7Dloc_77F0 + ld a, 5 call Page0Call_2EB9 call FindSwapSector - cp 8 - jr nz, p7Dloc_77CF + cp 8 + jr nz, p7Dloc_77CF call p7Dsub_7182 p7Dloc_77F0: - ld a, (appSearchPage) + ld a, (appSearchPage) call Page7D_2C16 - ld a, 1 - ld hl, ramStart + ld a, 1 + ld hl, ramStart call Page7D_2C9A - ld a, 19h - ld (sndRecState), a - pop af - push af - di - xor a - ld (sndRecState), a - pop af + ld a, 19h + ld (sndRecState), a + pop af + push af + di + xor a + ld (sndRecState), a + pop af ret ; --------------------------------------------------------------------------- ret @@ -11452,63 +11452,63 @@ p7Dloc_780D: - jp ErrMemory + jp ErrMemory ; --------------------------------------------------------------------------- p7Dloc_7810: - jp Page0Call_253D + jp Page0Call_253D ; --------------------------------------------------------------------------- p7Dloc_7813: - jp Page0Call_2539 + jp Page0Call_2539 ; --------------------------------------------------------------------------- call popErrorHandleR - ld a, 23h ; '#' - ld (errNo), a - or 1 - ret -; --------------------------------------------------------------------------- - push af - ld (unk_8439), a + ld a, 23h ; '#' + ld (errNo), a + or 1 + ret +; --------------------------------------------------------------------------- + push af + ld (unk_8439), a call p7Dsub_5525 - ld b, a - pop af - sub b - ld de, 4000h - push hl - or a - jr z, p7Dloc_7855 + ld b, a + pop af + sub b + ld de, 4000h + push hl + or a + jr z, p7Dloc_7855 push af p7Dloc_7833: - ld hl, 4000h - ld bc, 4000h + ld hl, 4000h + ld bc, 4000h call p7Dsub_7865 - pop af - dec a - or a - jr z, p7Dloc_784B - push af - ld a, (unk_8439) - dec a - ld (unk_8439), a - jr p7Dloc_7833 + pop af + dec a + or a + jr z, p7Dloc_784B + push af + ld a, (unk_8439) + dec a + ld (unk_8439), a + jr p7Dloc_7833 ; --------------------------------------------------------------------------- p7Dloc_784B: - ld hl, 4000h - ld a, (unk_8439) - dec a - ld (unk_8439), a + ld hl, 4000h + ld a, (unk_8439) + dec a + ld (unk_8439), a p7Dloc_7855: - pop hl - ld de, 4000h - or a - sbc hl, de - push hl - pop bc - ld hl, 4000h + pop hl + ld de, 4000h + or a + sbc hl, de + push hl + pop bc + ld hl, 4000h call p7Dsub_7865 ret @@ -11518,52 +11518,52 @@ p7Dsub_7865: push hl push bc - ld a, (unk_8439) - ld de, ramStart - ld bc, 100h - rst 28h -; --------------------------------------------------------------------------- - .dw 8054h -; --------------------------------------------------------------------------- - pop bc - ld hl, 100h - or a - sbc hl, bc - jr nc, p7Dloc_7882 - push bc - ld bc, 100h - jr p7Dloc_7883 + ld a, (unk_8439) + ld de, ramStart + ld bc, 100h + rst 28h +; --------------------------------------------------------------------------- + .dw 8054h +; --------------------------------------------------------------------------- + pop bc + ld hl, 100h + or a + sbc hl, bc + jr nc, p7Dloc_7882 + push bc + ld bc, 100h + jr p7Dloc_7883 ; --------------------------------------------------------------------------- p7Dloc_7882: push bc p7Dloc_7883: - ld hl, ramStart - rst 28h -; --------------------------------------------------------------------------- - .dw 8090h -; --------------------------------------------------------------------------- - ex de, hl - pop hl - ld bc, 100h - or a - sbc hl, bc - push hl - pop bc - ex de, hl - jr z, p7Dloc_78A1 - jr c, p7Dloc_78A1 - pop hl - push bc - ld de, 100h - add hl, de - pop bc - jr p7Dsub_7865 + ld hl, ramStart + rst 28h +; --------------------------------------------------------------------------- + .dw 8090h +; --------------------------------------------------------------------------- + ex de, hl + pop hl + ld bc, 100h + or a + sbc hl, bc + push hl + pop bc + ex de, hl + jr z, p7Dloc_78A1 + jr c, p7Dloc_78A1 + pop hl + push bc + ld de, 100h + add hl, de + pop bc + jr p7Dsub_7865 ; --------------------------------------------------------------------------- p7Dloc_78A1: - pop hl + pop hl ret ; End of function p7Dsub_7865 @@ -11575,29 +11575,29 @@ push af push hl push bc - ld b, 8 + ld b, 8 p7Dloc_78A8: - ld c, a - xor e + ld c, a + xor e rr d rr e - and 1 - jr z, p7Dloc_78BA - ld a, 8 - xor e - ld e, a - ld a, 84h ; '�' - xor d - ld d, a + and 1 + jr z, p7Dloc_78BA + ld a, 8 + xor e + ld e, a + ld a, 84h ; '�' + xor d + ld d, a p7Dloc_78BA: - ld a, c + ld a, c rra djnz p7Dloc_78A8 - pop bc - pop hl - pop af + pop bc + pop hl + pop af ret ; End of function p7Dsub_78A3 @@ -11609,49 +11609,49 @@ push hl push bc push af - ld de, 0FFFFh - ld a, b - or c - jr z, p7Dloc_78F1 + ld de, 0FFFFh + ld a, b + or c + jr z, p7Dloc_78F1 p7Dloc_78CC: - ld a, (hl) - inc hl - push af - push hl - push bc - ld b, 8 + ld a, (hl) + inc hl + push af + push hl + push bc + ld b, 8 p7Dloc_78D3: - ld c, a - xor e + ld c, a + xor e rr d rr e - and 1 - jr z, p7Dloc_78E5 - ld a, 8 - xor e - ld e, a - ld a, 84h ; '�' - xor d - ld d, a + and 1 + jr z, p7Dloc_78E5 + ld a, 8 + xor e + ld e, a + ld a, 84h ; '�' + xor d + ld d, a p7Dloc_78E5: - ld a, c + ld a, c rra djnz p7Dloc_78D3 - pop bc - pop hl - pop af - dec bc - ld a, b - or c - jr nz, p7Dloc_78CC + pop bc + pop hl + pop af + dec bc + ld a, b + or c + jr nz, p7Dloc_78CC p7Dloc_78F1: - pop af - pop bc - pop hl + pop af + pop bc + pop hl ret ; End of function p7Dsub_78C2 @@ -11664,25 +11664,25 @@ push hl push de push bc - ld hl, p7Dloc_790F + ld hl, p7Dloc_790F call APP_PUSH_ERRORH call j_RecAByteIO - ld l, a + ld l, a call APP_POP_ERRORH - bit 4, (iy+9) - jr nz, p7Dloc_790F - xor a - ld a, l - jr p7Dloc_7911 + bit 4, (iy+9) + jr nz, p7Dloc_790F + xor a + ld a, l + jr p7Dloc_7911 ; --------------------------------------------------------------------------- p7Dloc_790F: - or 0FFh + or 0FFh p7Dloc_7911: - pop bc - pop de - pop hl + pop bc + pop de + pop hl ret ; End of function p7Dsub_78F5 @@ -11694,28 +11694,28 @@ push hl push bc push af - ld de, 0 - ld a, b - or c - jr z, p7Dloc_792D + ld de, 0 + ld a, b + or c + jr z, p7Dloc_792D p7Dloc_791F: call p7Dsub_78F5 - jr nz, p7Dloc_792D - ld (hl), a - inc hl - inc de - dec bc - ld a, b - or c - jr nz, p7Dloc_791F - xor a + jr nz, p7Dloc_792D + ld (hl), a + inc hl + inc de + dec bc + ld a, b + or c + jr nz, p7Dloc_791F + xor a p7Dloc_792D: - pop bc - ld a, b - pop bc - pop hl + pop bc + ld a, b + pop bc + pop hl ret ; End of function p7Dsub_7915 @@ -11727,24 +11727,24 @@ push bc push af call NZIf83Plus - jr z, p7Dloc_7945 - in a, (0) - and 3 - jr z, p7Dloc_7949 - cp 3 - jr z, p7Dloc_7949 - jr p7Dloc_7949 + jr z, p7Dloc_7945 + in a, (0) + and 3 + jr z, p7Dloc_7949 + cp 3 + jr z, p7Dloc_7949 + jr p7Dloc_7949 ; --------------------------------------------------------------------------- p7Dloc_7945: - in a, (9) - and 58h ; 'X' + in a, (9) + and 58h ; 'X' p7Dloc_7949: ; LinkStatus+Fj ... - pop bc - ld a, b - pop bc + pop bc + ld a, b + pop bc ret ; End of function LinkStatus @@ -11757,14 +11757,14 @@ p7Dloc_794E: call LinkStatus - jr z, p7Dloc_795A + jr z, p7Dloc_795A call p7Dsub_78F5 - jr nz, p7Dloc_795A - jr p7Dloc_794E + jr nz, p7Dloc_795A + jr p7Dloc_794E ; --------------------------------------------------------------------------- p7Dloc_795A: - pop af + pop af ret ; End of function p7Dsub_794D @@ -11774,154 +11774,154 @@ p7Dsub_795C: push ix - ld ix, 0 - add ix, sp - push hl - push de - push af - push af - push af - ld de, 0FFFFh + ld ix, 0 + add ix, sp + push hl + push de + push af + push af + push af + ld de, 0FFFFh call p7Dsub_78F5 - jp nz, p7Dloc_79F0 + jp nz, p7Dloc_79F0 call p7Dsub_78F5 - jr nz, p7Dloc_79F0 + jr nz, p7Dloc_79F0 call p7Dsub_78A3 - ld h, a + ld h, a call p7Dsub_78F5 - jr nz, p7Dloc_79F0 + jr nz, p7Dloc_79F0 call p7Dsub_78A3 - ld l, a - ld (ix+0F9h), h - ld (ix+0F8h), l + ld l, a + ld (ix+0F9h), h + ld (ix+0F8h), l call p7Dsub_78F5 - jr nz, p7Dloc_79F0 + jr nz, p7Dloc_79F0 call p7Dsub_78A3 - ld h, a + ld h, a call p7Dsub_78F5 - jr nz, p7Dloc_79F0 + jr nz, p7Dloc_79F0 call p7Dsub_78A3 - ld l, a - ld (ix+0FBh), h - ld (ix+0FAh), l + ld l, a + ld (ix+0FBh), h + ld (ix+0FAh), l call p7Dsub_78F5 - jr nz, p7Dloc_79F0 - ld h, a + jr nz, p7Dloc_79F0 + ld h, a call p7Dsub_78F5 - jr nz, p7Dloc_79F0 - ld l, a - and a - sbc hl, de - jr nz, p7Dloc_79F0 - ld d, (ix+0FBh) - ld e, (ix+0FAh) - ld a, d - or e - jr z, p7Dloc_79F5 - ld h, (ix+0FDh) - ld l, (ix+0FCh) - and a - sbc hl, de - jr c, p7Dloc_79F0 - ld h, (ix+0FFh) - ld l, (ix+0FEh) - ld b, (ix+0FBh) - ld c, (ix+0FAh) + jr nz, p7Dloc_79F0 + ld l, a + and a + sbc hl, de + jr nz, p7Dloc_79F0 + ld d, (ix+0FBh) + ld e, (ix+0FAh) + ld a, d + or e + jr z, p7Dloc_79F5 + ld h, (ix+0FDh) + ld l, (ix+0FCh) + and a + sbc hl, de + jr c, p7Dloc_79F0 + ld h, (ix+0FFh) + ld l, (ix+0FEh) + ld b, (ix+0FBh) + ld c, (ix+0FAh) call p7Dsub_7915 - jr nz, p7Dloc_79F0 + jr nz, p7Dloc_79F0 call p7Dsub_78C2 call p7Dsub_78F5 - jr nz, p7Dloc_79F0 - ld h, a + jr nz, p7Dloc_79F0 + ld h, a call p7Dsub_78F5 - jr nz, p7Dloc_79F0 - ld l, a - and a - sbc hl, de - jr nz, p7Dloc_79F0 - xor a - jr p7Dloc_79F5 + jr nz, p7Dloc_79F0 + ld l, a + and a + sbc hl, de + jr nz, p7Dloc_79F0 + xor a + jr p7Dloc_79F5 ; --------------------------------------------------------------------------- p7Dloc_79F0: call p7Dsub_794D - or 0FFh + or 0FFh p7Dloc_79F5: - pop bc - ld a, b - pop bc - pop de - pop hl - pop hl - pop ix + pop bc + ld a, b + pop bc + pop de + pop hl + pop hl + pop ix ret ; End of function p7Dsub_795C ; --------------------------------------------------------------------------- push ix - ld ix, 0 - add ix, sp - push hl - push de - push af - push af - push af - push af - ld b, 0 - ld a, c - or a - jr z, p7Dloc_7A17 - dec c - cp 33h ; '3' - jr c, p7Dloc_7A19 + ld ix, 0 + add ix, sp + push hl + push de + push af + push af + push af + push af + ld b, 0 + ld a, c + or a + jr z, p7Dloc_7A17 + dec c + cp 33h ; '3' + jr c, p7Dloc_7A19 p7Dloc_7A17: - ld c, 32h ; '2' + ld c, 32h ; '2' p7Dloc_7A19: - ld (ix+0F7h), b - ld (ix+0F6h), c + ld (ix+0F7h), b + ld (ix+0F6h), c call p7Dsub_7A8D - jr nz, p7Dloc_7A52 - ld h, (ix+0FFh) - ld l, (ix+0FEh) - ld d, (ix+0FDh) - ld e, (ix+0FCh) + jr nz, p7Dloc_7A52 + ld h, (ix+0FFh) + ld l, (ix+0FEh) + ld d, (ix+0FDh) + ld e, (ix+0FCh) call p7Dsub_795C - ld (ix+0FBh), d - ld (ix+0FAh), e - ld (ix+0F9h), b - ld (ix+0F8h), c - jr z, p7Dloc_7A59 - ld b, (ix+0F7h) - ld c, (ix+0F6h) - bit 4, (iy+9) - jr nz, p7Dloc_7A52 - dec bc - ld a, b - or c - jr nz, p7Dloc_7A19 + ld (ix+0FBh), d + ld (ix+0FAh), e + ld (ix+0F9h), b + ld (ix+0F8h), c + jr z, p7Dloc_7A59 + ld b, (ix+0F7h) + ld c, (ix+0F6h) + bit 4, (iy+9) + jr nz, p7Dloc_7A52 + dec bc + ld a, b + or c + jr nz, p7Dloc_7A19 p7Dloc_7A52: call p7Dsub_7A85 - or 0FFh - jr p7Dloc_7A5D + or 0FFh + jr p7Dloc_7A5D ; --------------------------------------------------------------------------- p7Dloc_7A59: call p7Dsub_7A75 - xor a + xor a p7Dloc_7A5D: - pop bc - ld a, b - pop bc - pop bc - pop de - pop hl - pop hl - pop ix + pop bc + ld a, b + pop bc + pop bc + pop de + pop hl + pop hl + pop ix ret ; =============== S U B R O U T I N E ======================================= @@ -11930,11 +11930,11 @@ p7Dsub_7A67: push hl push de - ld hl, 0 - ld de, 0 + ld hl, 0 + ld de, 0 call p7Dsub_7AD0 - pop de - pop hl + pop de + pop hl ret ; End of function p7Dsub_7A67 @@ -11944,17 +11944,17 @@ p7Dsub_7A75: push bc - ld b, 1 + ld b, 1 call p7Dsub_7A67 - pop bc + pop bc ret ; End of function p7Dsub_7A75 ; --------------------------------------------------------------------------- push bc - ld b, 2 + ld b, 2 call p7Dsub_7A67 - pop bc + pop bc ret ; =============== S U B R O U T I N E ======================================= @@ -11962,9 +11962,9 @@ p7Dsub_7A85: push bc - ld b, 4 + ld b, 4 call p7Dsub_7A67 - pop bc + pop bc ret ; End of function p7Dsub_7A85 @@ -11973,8 +11973,8 @@ p7Dsub_7A8D: - bit 4, (iy+9) - res 4, (iy+9) + bit 4, (iy+9) + res 4, (iy+9) ret ; End of function p7Dsub_7A8D @@ -11987,25 +11987,25 @@ push de push bc push af - ld hl, p7Dloc_7AAF + ld hl, p7Dloc_7AAF call APP_PUSH_ERRORH call j_SendAByte call APP_POP_ERRORH - bit 4, (iy+9) - jr nz, p7Dloc_7AAF - xor a - jr p7Dloc_7AB1 + bit 4, (iy+9) + jr nz, p7Dloc_7AAF + xor a + jr p7Dloc_7AB1 ; --------------------------------------------------------------------------- p7Dloc_7AAF: - or 0FFh + or 0FFh p7Dloc_7AB1: - pop bc - ld a, b - pop bc - pop de - pop hl + pop bc + ld a, b + pop bc + pop de + pop hl ret ; End of function p7Dsub_7A96 @@ -12017,26 +12017,26 @@ push hl push bc push af - ld a, b - or c - jr z, p7Dloc_7ACB + ld a, b + or c + jr z, p7Dloc_7ACB p7Dloc_7ABE: - ld a, (hl) + ld a, (hl) call p7Dsub_7A96 - jr nz, p7Dloc_7ACB - inc hl - dec bc - ld a, b - or c - jr nz, p7Dloc_7ABE - xor a + jr nz, p7Dloc_7ACB + inc hl + dec bc + ld a, b + or c + jr nz, p7Dloc_7ABE + xor a p7Dloc_7ACB: - pop bc - ld a, b - pop bc - pop hl + pop bc + ld a, b + pop bc + pop hl ret ; End of function p7Dsub_7AB7 @@ -12046,68 +12046,68 @@ p7Dsub_7AD0: push ix - ld ix, 0 - add ix, sp - push hl - push de - push bc - push af - ld de, 0FFFFh - ld a, 5Bh ; '[' + ld ix, 0 + add ix, sp + push hl + push de + push bc + push af + ld de, 0FFFFh + ld a, 5Bh ; '[' call p7Dsub_7A96 - jr nz, p7Dloc_7B37 - ld a, b + jr nz, p7Dloc_7B37 + ld a, b call p7Dsub_78A3 call p7Dsub_7A96 - jr nz, p7Dloc_7B37 - ld a, c + jr nz, p7Dloc_7B37 + ld a, c call p7Dsub_78A3 call p7Dsub_7A96 - jr nz, p7Dloc_7B37 - ld b, (ix+0FDh) - ld c, (ix+0FCh) - ld a, b + jr nz, p7Dloc_7B37 + ld b, (ix+0FDh) + ld c, (ix+0FCh) + ld a, b call p7Dsub_78A3 call p7Dsub_7A96 - jr nz, p7Dloc_7B37 - ld a, c + jr nz, p7Dloc_7B37 + ld a, c call p7Dsub_78A3 call p7Dsub_7A96 - jr nz, p7Dloc_7B37 - ld a, d + jr nz, p7Dloc_7B37 + ld a, d call p7Dsub_7A96 - jr nz, p7Dloc_7B37 - ld a, e + jr nz, p7Dloc_7B37 + ld a, e call p7Dsub_7A96 - jr nz, p7Dloc_7B37 - ld a, b - or c - jr z, p7Dloc_7B34 + jr nz, p7Dloc_7B37 + ld a, b + or c + jr z, p7Dloc_7B34 call p7Dsub_78C2 call p7Dsub_7AB7 - jr nz, p7Dloc_7B37 - ld a, d + jr nz, p7Dloc_7B37 + ld a, d call p7Dsub_7A96 - jr nz, p7Dloc_7B37 - ld a, e + jr nz, p7Dloc_7B37 + ld a, e call p7Dsub_7A96 - jr nz, p7Dloc_7B37 + jr nz, p7Dloc_7B37 p7Dloc_7B34: - xor a - jr p7Dloc_7B39 + xor a + jr p7Dloc_7B39 ; --------------------------------------------------------------------------- p7Dloc_7B37: - or 0FFh + or 0FFh p7Dloc_7B39: - pop bc - ld a, b - pop bc - pop de - pop hl - pop ix + pop bc + ld a, b + pop bc + pop de + pop hl + pop ix ret ; End of function p7Dsub_7AD0 @@ -12117,33 +12117,33 @@ p7Dsub_7B41: call ZeroOP1 - ld a, 1 - or a - ld hl, ramStart - ld de, 8040h - rst 28h -; --------------------------------------------------------------------------- - .dw 8075h -; --------------------------------------------------------------------------- - jp nz, p7Dloc_75B1 - inc hl - ld a, 1 - rst 28h -; --------------------------------------------------------------------------- - .dw 805Ah -; --------------------------------------------------------------------------- - ld de, 8479h + ld a, 1 + or a + ld hl, ramStart + ld de, 8040h + rst 28h +; --------------------------------------------------------------------------- + .dw 8075h +; --------------------------------------------------------------------------- + jp nz, p7Dloc_75B1 + inc hl + ld a, 1 + rst 28h +; --------------------------------------------------------------------------- + .dw 805Ah +; --------------------------------------------------------------------------- + ld de, 8479h ldir - ld hl, (appSearchPage) + ld hl, (appSearchPage) push hl call p7Dsub_6186 - jr c, p7Dloc_7B6D - ld (appInfo+1), a + jr c, p7Dloc_7B6D + ld (appInfo+1), a call Page7D_2BE6 p7Dloc_7B6D: - pop hl - ld (appSearchPage), hl + pop hl + ld (appSearchPage), hl ret ; End of function p7Dsub_7B41 @@ -12156,44 +12156,44 @@ call p7Dsub_75EC p7Dloc_7B75: - ld hl, 4000h + ld hl, 4000h push af call Page7D_2CD0 - cp 80h ; '�' - jr z, p7Dloc_7B84 - cp 0 - jr nz, p7Dloc_7B9C + cp 80h ; '�' + jr z, p7Dloc_7B84 + cp 0 + jr nz, p7Dloc_7B9C p7Dloc_7B84: - pop af + pop af call Page0Call_3E31 - jr nz, p7Dloc_7B9A + jr nz, p7Dloc_7B9A call FindAppNumPages - ld b, a - ld a, c - or a - jr z, p7Dloc_7B98 - ld a, b - sub c - cp 8 - jr nc, p7Dloc_7B75 + ld b, a + ld a, c + or a + jr z, p7Dloc_7B98 + ld a, b + sub c + cp 8 + jr nc, p7Dloc_7B75 p7Dloc_7B98: - xor a + xor a ret ; --------------------------------------------------------------------------- p7Dloc_7B9A: - cp a + cp a ret ; --------------------------------------------------------------------------- p7Dloc_7B9C: - cp 0FFh - pop bc - ld a, b - jr nz, p7Dloc_7B9A - or a + cp 0FFh + pop bc + ld a, b + jr nz, p7Dloc_7B9A + or a ret ; End of function p7Dsub_7B72 @@ -12202,13 +12202,13 @@ p7Dsub_7BA4: - xor a - ld b, 0Eh - ld hl, 9C88h + xor a + ld b, 0Eh + ld hl, 9C88h p7Dloc_7BAA: - ld (hl), a - inc hl + ld (hl), a + inc hl djnz p7Dloc_7BAA ret ; End of function p7Dsub_7BA4 @@ -12219,8 +12219,8 @@ p7Dsub_7BAF: call p7Dsub_7BBA - or (hl) - ld (hl), a + or (hl) + ld (hl), a ret ; End of function p7Dsub_7BAF @@ -12230,7 +12230,7 @@ p7Dsub_7BB5: call p7Dsub_7BBA - and (hl) + and (hl) ret ; End of function p7Dsub_7BB5 @@ -12239,16 +12239,16 @@ p7Dsub_7BBA: - sub 8 - ld hl, 9C88h - ld c, a - ld b, 0 + sub 8 + ld hl, 9C88h + ld c, a + ld b, 0 sra c sra c sra c - add hl, bc - and 7 - ld c, a + add hl, bc + and 7 + ld c, a ; End of function p7Dsub_7BBA @@ -12256,9 +12256,9 @@ p7Dsub_7BCC: - ld b, c - ld a, 80h ; '�' - inc b + ld b, c + ld a, 80h ; '�' + inc b p7Dloc_7BD0: rlca @@ -12272,19 +12272,19 @@ p7Dsub_7BD4: - bit 0, (iy+12h) - ret z - push af - push bc - push de - push hl - ld a, 1 - ld (indicCounter), a + bit 0, (iy+12h) + ret z + push af + push bc + push de + push hl + ld a, 1 + ld (indicCounter), a call page0_1BF - pop hl - pop de - pop bc - pop af + pop hl + pop de + pop bc + pop af ret ; End of function p7Dsub_7BD4 @@ -12297,20 +12297,20 @@ - ld (appSearchPage+1), a - ld (appSearchPage), a - ld (unk_8434), a + ld (appSearchPage+1), a + ld (appSearchPage), a + ld (unk_8434), a call p7Dsub_5DC7 - ret c - ret z - ld a, e - or a - jp z, Page7D_2BBC - ld a, 6 + ret c + ret z + ld a, e + or a + jp z, Page7D_2BBC + ld a, 6 call Page0Call_2EB9 - jp z, Page7D_2BBC + jp z, Page7D_2BBC call p7Dsub_7182 - ld a, (unk_8434) + ld a, (unk_8434) call p7Dsub_5DC7 ret ; End of function p7Dsub_7BEA @@ -12319,62 +12319,62 @@ Page7D_3EB8: push af - ld a, 1 + ld a, 1 nop di nop nop im 1 di - out (14h), a + out (14h), a di call checkForFlashTrickery - pop af + pop af call Page7D_2B56 - ld a, b - rst 28h -; --------------------------------------------------------------------------- - .dw 80CFh -; --------------------------------------------------------------------------- - jp relockFlashBack + ld a, b + rst 28h +; --------------------------------------------------------------------------- + .dw 80CFh +; --------------------------------------------------------------------------- + jp relockFlashBack ; --------------------------------------------------------------------------- DoNothing2: ret ; --------------------------------------------------------------------------- - jp nz, p7Dloc_7C2E + jp nz, p7Dloc_7C2E p7Dloc_7C2E: call popErrorHandleR - ld a, 23h ; '#' - ld (errNo), a - pop hl - ld (freeRAM), hl + ld a, 23h ; '#' + ld (errNo), a + pop hl + ld (freeRAM), hl call p7Dsub_7C64 - jr z, p7Dloc_7C4D + jr z, p7Dloc_7C4D call OP4ToOP1 call ChkFindSym call nc, DelVarArc call relockFlashBack - jr p7Dloc_7C61 + jr p7Dloc_7C61 ; --------------------------------------------------------------------------- p7Dloc_7C4D: call ChkFindSym - ex de, hl - ld bc, (freeRAM) - dec bc - dec bc - ld (hl), c - inc hl - ld (hl), b - dec hl - ex de, hl - ld a, 3 + ex de, hl + ld bc, (freeRAM) + dec bc + dec bc + ld (hl), c + inc hl + ld (hl), b + dec hl + ex de, hl + ld a, 3 call DELVARIO p7Dloc_7C61: - or 1 + or 1 ret ; =============== S U B R O U T I N E ======================================= @@ -12382,21 +12382,21 @@ p7Dsub_7C64: push hl - ld hl, ioNewData - bit 7, (hl) - pop hl + ld hl, ioNewData + bit 7, (hl) + pop hl ret ; End of function p7Dsub_7C64 ; --------------------------------------------------------------------------- call page0_17B0 - jr z, p7Dloc_7C7D + jr z, p7Dloc_7C7D call ISO1NONTEMPLST - jr nz, p7Dloc_7C84 + jr nz, p7Dloc_7C84 push bc call CMPPRGNAMLEN - inc a - jr p7Dloc_7C81 + inc a + jr p7Dloc_7C81 ; --------------------------------------------------------------------------- p7Dloc_7C7D: @@ -12404,23 +12404,23 @@ call CMPPRGNAMLEN p7Dloc_7C81: - pop bc - or a + pop bc + or a ret ; --------------------------------------------------------------------------- p7Dloc_7C84: - xor a + xor a scf ret ; --------------------------------------------------------------------------- push hl - ld hl, (unk_83F7) - or a - sbc hl, bc - jp c, ErrMemory - ld (unk_83F7), hl - pop hl + ld hl, (unk_83F7) + or a + sbc hl, bc + jp c, ErrMemory + ld (unk_83F7), hl + pop hl ret ; =============== S U B R O U T I N E ======================================= @@ -12428,15 +12428,15 @@ p7Dsub_7C96: call NZIf83Plus - jr nz, p7Dloc_7CA0 - and 7Fh ; '' - cp 6Ah ; 'j' + jr nz, p7Dloc_7CA0 + and 7Fh ; '' + cp 6Ah ; 'j' ret ; --------------------------------------------------------------------------- p7Dloc_7CA0: - and 1Fh - cp 16h + and 1Fh + cp 16h ret ; End of function p7Dsub_7C96 @@ -12445,12 +12445,12 @@ p7Dsub_7CA5: - ld a, (unk_83A4) - or a - ret z - ld a, (unk_83A3) - inc a - ld (unk_83A3), a + ld a, (unk_83A4) + or a + ret z + ld a, (unk_83A3) + inc a + ld (unk_83A3), a ret ; End of function p7Dsub_7CA5 @@ -12460,11 +12460,11 @@ p7Dsub_7CB2: push bc - ld b, a - ld a, (sndRecState) - inc a - ld a, b - pop bc + ld b, a + ld a, (sndRecState) + inc a + ld a, b + pop bc ret ; End of function p7Dsub_7CB2 @@ -12474,17 +12474,17 @@ p7Dsub_7CBB: ; p7Dsub_7240+119p - ld a, (ramCodeEnd) - cp 0 - ret z + ld a, (ramCodeEnd) + cp 0 + ret z push hl call p7Dsub_578D - ld a, l - or h - pop hl - ret nz - ld a, 0 - ld (unk_83A4), a + ld a, l + or h + pop hl + ret nz + ld a, 0 + ld (unk_83A4), a ret ; End of function p7Dsub_7CBB @@ -12494,15 +12494,15 @@ p7Dsub_7CCF: ; p7Dsub_7240:p7Dloc_7535p ... - rst 28h -; --------------------------------------------------------------------------- - .dw 8057h + rst 28h +; --------------------------------------------------------------------------- + .dw 8057h ; End of function p7Dsub_7CCF ; --------------------------------------------------------------------------- call Page7D_2BEC - ld de, 1DE2h - add hl, de + ld de, 1DE2h + add hl, de ret ; =============== S U B R O U T I N E ======================================= @@ -12511,90 +12511,90 @@ p7Dsub_7CDA: push af push af - ld a, 1 + ld a, 1 nop di nop nop im 1 di - out (14h), a + out (14h), a di call checkForFlashTrickery - pop af + pop af call Page0Call_2ECB call p7Dsub_7CCF push hl - ld b, 8 + ld b, 8 p7Dloc_7CF5: call p7Dsub_4566 - cp 0FFh - jr nz, p7Dloc_7D01 - inc hl + cp 0FFh + jr nz, p7Dloc_7D01 + inc hl djnz p7Dloc_7CF5 - jr p7Dloc_7D04 + jr p7Dloc_7D04 ; --------------------------------------------------------------------------- p7Dloc_7D01: call Page7D_2BB0 p7Dloc_7D04: - ld hl, 7FFEh - ld (OP1+1), hl - ld a, (arcInfo) - ld (unk_847B), a - ld hl, (arcInfo+1) + ld hl, 7FFEh + ld (OP1+1), hl + ld a, (arcInfo) + ld (unk_847B), a + ld hl, (arcInfo+1) call p7Dsub_69D4 - jr nz, p7Dloc_7D19 - inc hl + jr nz, p7Dloc_7D19 + inc hl p7Dloc_7D19: - inc hl - inc hl - inc hl - ld de, (unk_83F5) - add hl, de - ld (unk_847C), hl - ld (iMathPtr5), hl - ld de, (unk_83F7) - bit 7, d - jr z, p7Dloc_7D33 - inc a - inc a - res 7, d + inc hl + inc hl + inc hl + ld de, (unk_83F5) + add hl, de + ld (unk_847C), hl + ld (iMathPtr5), hl + ld de, (unk_83F7) + bit 7, d + jr z, p7Dloc_7D33 + inc a + inc a + res 7, d p7Dloc_7D33: - bit 6, d - jr z, p7Dloc_7D3A - inc a - res 6, d + bit 6, d + jr z, p7Dloc_7D3A + inc a + res 6, d p7Dloc_7D3A: - add hl, de - bit 7, h - jr z, p7Dloc_7D44 - inc a - res 7, h - set 6, h + add hl, de + bit 7, h + jr z, p7Dloc_7D44 + inc a + res 7, h + set 6, h p7Dloc_7D44: - ld (unk_847E), a - ld (unk_847F), hl - ld bc, 8 - ld hl, 8479h + ld (unk_847E), a + ld (unk_847F), hl + ld bc, 8 + ld hl, 8479h call p7Dsub_7700 - pop de - rst 28h -; --------------------------------------------------------------------------- - .dw 8087h + pop de + rst 28h +; --------------------------------------------------------------------------- + .dw 8087h ; --------------------------------------------------------------------------- call relockFlashBack - set 3, (iy+26h) + set 3, (iy+26h) call Page7D_2EB0 - pop af - ld hl, (unk_83F1) - ld (hl), a + pop af + ld hl, (unk_83F1) + ld (hl), a ret ; End of function p7Dsub_7CDA @@ -12603,103 +12603,103 @@ p7Dsub_7D67: - ld a, (pagedCount) - or a - ret z - push bc - push de - push hl - ld c, a - xor a - ld (pagedCount), a - ld hl, pagedBuf - ld (pagedGetPtr), hl - ld de, (iMathPtr5) - ld a, (arcInfo) - push de - ld (Abackup), a - ld a, i - di - push af - ld a, (Abackup) - push af - ld a, 1 + ld a, (pagedCount) + or a + ret z + push bc + push de + push hl + ld c, a + xor a + ld (pagedCount), a + ld hl, pagedBuf + ld (pagedGetPtr), hl + ld de, (iMathPtr5) + ld a, (arcInfo) + push de + ld (Abackup), a + ld a, i + di + push af + ld a, (Abackup) + push af + ld a, 1 nop di nop nop im 1 di - out (14h), a + out (14h), a di call checkForFlashTrickery - pop af + pop af call p7Dsub_7C96 - jr nc, p7Dloc_7E0D - cp 8 - jr c, p7Dloc_7E0D + jr nc, p7Dloc_7E0D + cp 8 + jr c, p7Dloc_7E0D call p7Dsub_7CCF call p7Dsub_4566 - cp 0FEh ; '�' - jr nz, p7Dloc_7E0D + cp 0FEh ; '�' + jr nz, p7Dloc_7E0D call p7Dsub_4565 - cp 7Fh ; '' - jr nz, p7Dloc_7E0D + cp 7Fh ; '' + jr nz, p7Dloc_7E0D call p7Dsub_4565 - ld b, a - ld a, (arcInfo) - cp b - jr c, p7Dloc_7E0D - jr nz, p7Dloc_7DD3 + ld b, a + ld a, (arcInfo) + cp b + jr c, p7Dloc_7E0D + jr nz, p7Dloc_7DD3 call p7Dsub_455C push hl - ld hl, (iMathPtr5) + ld hl, (iMathPtr5) call CpHLDE - ex de, hl - pop hl - jr c, p7Dloc_7E0D - jr p7Dloc_7DD9 + ex de, hl + pop hl + jr c, p7Dloc_7E0D + jr p7Dloc_7DD9 ; --------------------------------------------------------------------------- p7Dloc_7DD3: - ld de, (iMathPtr5) - inc hl - inc hl + ld de, (iMathPtr5) + inc hl + inc hl p7Dloc_7DD9: - ld a, (arcInfo) - ld b, 0 - ex de, hl - add hl, bc + ld a, (arcInfo) + ld b, 0 + ex de, hl + add hl, bc call Page0Call_23FC - jr nc, p7Dloc_7DE6 - inc a + jr nc, p7Dloc_7DE6 + inc a p7Dloc_7DE6: - ld b, a - ex de, hl + ld b, a + ex de, hl call p7Dsub_4565 - cp b - jr c, p7Dloc_7E0D - jr nz, p7Dloc_7DFC + cp b + jr c, p7Dloc_7E0D + jr nz, p7Dloc_7DFC push de call p7Dsub_455C - pop hl - dec hl + pop hl + dec hl call CpHLDE - ex de, hl - jr nc, p7Dloc_7E0D + ex de, hl + jr nc, p7Dloc_7E0D p7Dloc_7DFC: - ld de, (iMathPtr5) - ld hl, pagedBuf - ld b, 0 - ld a, (arcInfo) - rst 28h -; --------------------------------------------------------------------------- - .dw 80C9h -; --------------------------------------------------------------------------- - jr p7Dloc_7E0E + ld de, (iMathPtr5) + ld hl, pagedBuf + ld b, 0 + ld a, (arcInfo) + rst 28h +; --------------------------------------------------------------------------- + .dw 80C9h +; --------------------------------------------------------------------------- + jr p7Dloc_7E0E ; --------------------------------------------------------------------------- p7Dloc_7E0D: @@ -12707,43 +12707,43 @@ p7Dloc_7E0E: call relockFlashBack - ld (Abackup), a - pop af - jp po, p7Dloc_7E19 + ld (Abackup), a + pop af + jp po, p7Dloc_7E19 ei p7Dloc_7E19: - ld a, (Abackup) - ld (iMathPtr5), de - pop hl - or a - sbc hl, de - jr c, p7Dloc_7E2D - ld a, (arcInfo) - inc a - ld (arcInfo), a + ld a, (Abackup) + ld (iMathPtr5), de + pop hl + or a + sbc hl, de + jr c, p7Dloc_7E2D + ld a, (arcInfo) + inc a + ld (arcInfo), a p7Dloc_7E2D: - pop hl - pop de - pop bc + pop hl + pop de + pop bc ret ; End of function p7Dsub_7D67 ; --------------------------------------------------------------------------- p7Dloc_7E31: - ld a, (hl) - inc hl + ld a, (hl) + inc hl push hl push bc call p7Dsub_7E40 - pop bc - pop hl - dec bc - ld a, c - or b - jr nz, p7Dloc_7E31 + pop bc + pop hl + dec bc + ld a, c + or b + jr nz, p7Dloc_7E31 ret ; =============== S U B R O U T I N E ======================================= @@ -12751,15 +12751,15 @@ p7Dsub_7E40: push hl - ld hl, (pagedGetPtr) - ld (hl), a - inc hl - ld (pagedGetPtr), hl - pop hl - ld a, (pagedCount) - inc a - ld (pagedCount), a - cp 10h + ld hl, (pagedGetPtr) + ld (hl), a + inc hl + ld (pagedGetPtr), hl + pop hl + ld a, (pagedCount) + inc a + ld (pagedCount), a + cp 10h call z, p7Dsub_7D67 ret ; End of function p7Dsub_7E40 @@ -12767,45 +12767,43 @@ ; --------------------------------------------------------------------------- p7Dloc_7E57: - dec hl - dec hl - ld a, (hl) - inc hl - inc hl - cp 4 - jr c, p7Dloc_7E66 + dec hl + dec hl + ld a, (hl) + inc hl + inc hl + cp 4 + jr c, p7Dloc_7E66 call DelVarArc - jp Page0Call_2555 + jp Page0Call_2555 ; --------------------------------------------------------------------------- p7Dloc_7E66: - ld a, (OP1+1) - cp 24h ; '$' - jp z, Page0Call_24B5 + ld a, (OP1+1) + cp 24h ; '$' + jp z, Page0Call_24B5 call Page0Call_2EE9 - jp z, Page0Call_24B5 - ld a, (hl) - push af - and 1Fh - ld (hl), a + jp z, Page0Call_24B5 + ld a, (hl) + push af + and 1Fh + ld (hl), a call Page0Call_2ED1 - pop af + pop af call p7Dsub_7CDA - xor a - ld (pagedCount), a - push hl - ld hl, pagedBuf - ld (pagedGetPtr), hl - pop hl - ret - + xor a + ld (pagedCount), a + push hl + ld hl, pagedBuf + ld (pagedGetPtr), hl + pop hl + ret p7Dloc_7E8D: call Page0Call_2C91 ret - p7Dloc_7E91: call page0_1F38 ret .org $7FFF - .db 5Dh ; ] + .db 5Dh ; ]