FreeCalypso > hg > freecalypso-reveng
diff pirelli/fw-disasm @ 248:73039e3416c7
pirelli/fw-disasm: abb_inth located
author | Mychaela Falconia <falcon@freecalypso.org> |
---|---|
date | Sun, 24 Dec 2017 04:43:48 +0000 |
parents | 1e1191fbdf90 |
children | b84fa089a560 |
line wrap: on
line diff
--- a/pirelli/fw-disasm Sun Dec 24 01:19:25 2017 +0000 +++ b/pirelli/fw-disasm Sun Dec 24 04:43:48 2017 +0000 @@ -1062,6 +1062,362 @@ 3495b0: b002 add sp, #8 3495b2: bd00 pop {pc} +$spi_abb_read_int_reg_callback: + 39efc4: b510 push {r4, lr} + 39efc6: b089 sub sp, #36 ; 0x24 + 39efc8: 9002 str r0, [sp, #8] + 39efca: 9802 ldr r0, [sp, #8] + 39efcc: 8800 ldrh r0, [r0, #0] + 39efce: 08c0 lsr r0, r0, #3 + 39efd0: d344 bcc 0x39f05c + 39efd2: 2014 mov r0, #20 ; 0x14 + 39efd4: f05a fbba bl 0x3f974c + 39efd8: f7aa f998 bl 0x34930c + 39efdc: 2110 mov r1, #16 ; 0x10 + 39efde: 4001 and r1, r0 + 39efe0: 4668 mov r0, sp + 39efe2: 81c1 strh r1, [r0, #14] ; 0xe + 39efe4: 89c0 ldrh r0, [r0, #14] ; 0xe + 39efe6: 2800 cmp r0, #0 + 39efe8: d000 beq 0x39efec + 39efea: e15d b 0x39f2a8 + 39efec: f04b fa6a bl 0x3ea4c4 + 39eff0: 4669 mov r1, sp + 39eff2: 2000 mov r0, #0 + 39eff4: 8188 strh r0, [r1, #12] ; 0xc + 39eff6: 4668 mov r0, sp + 39eff8: 8980 ldrh r0, [r0, #12] ; 0xc + 39effa: 2808 cmp r0, #8 + 39effc: da18 bge 0x39f030 + 39effe: 4668 mov r0, sp + 39f000: 89c0 ldrh r0, [r0, #14] ; 0xe + 39f002: 2800 cmp r0, #0 + 39f004: d114 bne 0x39f030 + 39f006: 2036 mov r0, #54 ; 0x36 + 39f008: f05a fba0 bl 0x3f974c + 39f00c: f7aa f97e bl 0x34930c + 39f010: 2110 mov r1, #16 ; 0x10 + 39f012: 4001 and r1, r0 + 39f014: 4668 mov r0, sp + 39f016: 81c1 strh r1, [r0, #14] ; 0xe + 39f018: 4669 mov r1, sp + 39f01a: 8980 ldrh r0, [r0, #12] ; 0xc + 39f01c: 3001 add r0, #1 + 39f01e: 8188 strh r0, [r1, #12] ; 0xc + 39f020: 4668 mov r0, sp + 39f022: 8980 ldrh r0, [r0, #12] ; 0xc + 39f024: 2808 cmp r0, #8 + 39f026: da03 bge 0x39f030 + 39f028: 4668 mov r0, sp + 39f02a: 89c0 ldrh r0, [r0, #14] ; 0xe + 39f02c: 2800 cmp r0, #0 + 39f02e: d0ea beq 0x39f006 + 39f030: 4668 mov r0, sp + 39f032: 89c0 ldrh r0, [r0, #14] ; 0xe + 39f034: 2800 cmp r0, #0 + 39f036: d000 beq 0x39f03a + 39f038: e136 b 0x39f2a8 + 39f03a: 48d9 ldr r0, =0x1774ccf ; via 0x39f3a0 + 39f03c: 7800 ldrb r0, [r0, #0] + 39f03e: 2800 cmp r0, #0 + 39f040: d100 bne 0x39f044 + 39f042: e131 b 0x39f2a8 + 39f044: 48d7 ldr r0, =0xa0010 ; via 0x39f3a4 + 39f046: 9000 str r0, [sp, #0] + 39f048: a09a add r0, pc, #616 ; 0x268 + 39f04a: 2119 mov r1, #25 ; 0x19 + 39f04c: 2200 mov r2, #0 + 39f04e: 43d2 mvn r2, r2 + 39f050: 2305 mov r3, #5 + 39f052: f03b fdef bl 0x3dac34 + 39f056: f002 f9f1 bl 0x3a143c + 39f05a: e125 b 0x39f2a8 +; end of PUSHOFF_IT_STS handling + 39f05c: 9802 ldr r0, [sp, #8] + 39f05e: 8800 ldrh r0, [r0, #0] + 39f060: 0880 lsr r0, r0, #2 + 39f062: d30b bcc 0x39f07c + 39f064: 48cf ldr r0, =0xa0010 ; via 0x39f3a4 + 39f066: 9000 str r0, [sp, #0] + 39f068: a099 add r0, pc, #612 ; 0x264 + 39f06a: 2120 mov r1, #32 ; 0x20 + 39f06c: 2200 mov r2, #0 + 39f06e: 43d2 mvn r2, r2 + 39f070: 2305 mov r3, #5 + 39f072: f03b fddf bl 0x3dac34 + 39f076: f002 fa9c bl 0x3a15b2 + 39f07a: e115 b 0x39f2a8 +; end of REMOT_IT_STS handling + 39f07c: 9802 ldr r0, [sp, #8] + 39f07e: 8800 ldrh r0, [r0, #0] + 39f080: 0980 lsr r0, r0, #6 + 39f082: d200 bcs 0x39f086 + 39f084: e0ed b 0x39f262 +; The following write of 0 into byte var at 0x1775041 +; is a Foxconn/Pirelli addition. + 39f086: 49c8 ldr r1, =0x1775041 ; via 0x39f3a8 + 39f088: 2000 mov r0, #0 + 39f08a: 7008 strb r0, [r1, #0] + 39f08c: 48c5 ldr r0, =0xa0010 ; via 0x39f3a4 + 39f08e: 9000 str r0, [sp, #0] + 39f090: a098 add r0, pc, #608 ; 0x260 + 39f092: 210f mov r1, #15 ; 0xf + 39f094: 2200 mov r2, #0 + 39f096: 43d2 mvn r2, r2 + 39f098: 2305 mov r3, #5 + 39f09a: f03b fdcb bl 0x3dac34 ; rvf_send_trace() + 39f09e: 48c3 ldr r0, =0x1774e38 ; via 0x39f3ac + 39f0a0: 6800 ldr r0, [r0, #0] + 39f0a2: 3004 add r0, #4 + 39f0a4: f7aa f9f8 bl 0x349498 ; $ABB_Read_ADC + 39f0a8: 48c0 ldr r0, =0x1774e38 ; via 0x39f3ac + 39f0aa: 6800 ldr r0, [r0, #0] + 39f0ac: 8dc0 ldrh r0, [r0, #46] ; 0x2e + 39f0ae: 2806 cmp r0, #6 + 39f0b0: db03 blt 0x39f0ba + 39f0b2: 48be ldr r0, =0x1774e38 ; via 0x39f3ac + 39f0b4: 6801 ldr r1, [r0, #0] + 39f0b6: 2000 mov r0, #0 + 39f0b8: 85c8 strh r0, [r1, #46] ; 0x2e + 39f0ba: 48bc ldr r0, =0x1774e38 ; via 0x39f3ac + 39f0bc: 6800 ldr r0, [r0, #0] + 39f0be: 8dc0 ldrh r0, [r0, #46] ; 0x2e + 39f0c0: 0040 lsl r0, r0, #1 + 39f0c2: 49ba ldr r1, =0x1774e38 ; via 0x39f3ac + 39f0c4: 6809 ldr r1, [r1, #0] + 39f0c6: 1840 add r0, r0, r1 + 39f0c8: 49b8 ldr r1, =0x1774e38 ; via 0x39f3ac + 39f0ca: 6809 ldr r1, [r1, #0] + 39f0cc: 8889 ldrh r1, [r1, #4] + 39f0ce: 8281 strh r1, [r0, #20] ; 0x14 + 39f0d0: 48b6 ldr r0, =0x1774e38 ; via 0x39f3ac + 39f0d2: 6800 ldr r0, [r0, #0] + 39f0d4: 302e add r0, #46 ; 0x2e + 39f0d6: 8801 ldrh r1, [r0, #0] + 39f0d8: 3101 add r1, #1 + 39f0da: 8001 strh r1, [r0, #0] + 39f0dc: 2133 mov r1, #51 ; 0x33 + 39f0de: 48b3 ldr r0, =0x1774e38 ; via 0x39f3ac + 39f0e0: 6800 ldr r0, [r0, #0] + 39f0e2: 5c08 ldrb r0, [r1, r0] + 39f0e4: 2801 cmp r0, #1 + 39f0e6: d000 beq 0x39f0ea + 39f0e8: e0de b 0x39f2a8 + 39f0ea: 2010 mov r0, #16 ; 0x10 + 39f0ec: f7f8 ff53 bl 0x397f96 ; $osx_alloc_prim + 39f0f0: 9004 str r0, [sp, #16] ; 0x10 + 39f0f2: 9804 ldr r0, [sp, #16] ; 0x10 + 39f0f4: 2800 cmp r0, #0 + 39f0f6: d022 beq 0x39f13e + 39f0f8: 9904 ldr r1, [sp, #16] ; 0x10 + 39f0fa: 2069 mov r0, #105 ; 0x69 + 39f0fc: 6008 str r0, [r1, #0] + 39f0fe: 4669 mov r1, sp + 39f100: 2000 mov r0, #0 + 39f102: 7508 strb r0, [r1, #20] ; 0x14 + 39f104: 4668 mov r0, sp + 39f106: 7d00 ldrb r0, [r0, #20] ; 0x14 + 39f108: 2808 cmp r0, #8 + 39f10a: da14 bge 0x39f136 + 39f10c: 4668 mov r0, sp + 39f10e: 7d00 ldrb r0, [r0, #20] ; 0x14 + 39f110: 0042 lsl r2, r0, #1 + 39f112: 9804 ldr r0, [sp, #16] ; 0x10 + 39f114: 6901 ldr r1, [r0, #16] ; 0x10 + 39f116: 4668 mov r0, sp + 39f118: 7d00 ldrb r0, [r0, #20] ; 0x14 + 39f11a: 0043 lsl r3, r0, #1 + 39f11c: 48a3 ldr r0, =0x1774e38 ; via 0x39f3ac + 39f11e: 6800 ldr r0, [r0, #0] + 39f120: 1818 add r0, r3, r0 + 39f122: 8880 ldrh r0, [r0, #4] + 39f124: 5250 strh r0, [r2, r1] + 39f126: 4668 mov r0, sp + 39f128: 4669 mov r1, sp + 39f12a: 7d09 ldrb r1, [r1, #20] ; 0x14 + 39f12c: 3101 add r1, #1 + 39f12e: 7501 strb r1, [r0, #20] ; 0x14 + 39f130: 7d00 ldrb r0, [r0, #20] ; 0x14 + 39f132: 2808 cmp r0, #8 + 39f134: dbea blt 0x39f10c + 39f136: 9804 ldr r0, [sp, #16] ; 0x10 + 39f138: 2102 mov r1, #2 + 39f13a: f7f8 fe9a bl 0x397e72 ; $osx_send_prim +; checking GPIO 6 input + 39f13e: 2400 mov r4, #0 + 39f140: 2005 mov r0, #5 + 39f142: f030 fed8 bl 0x3cfef6 + 39f146: 2800 cmp r0, #0 + 39f148: d100 bne 0x39f14c + 39f14a: 2401 mov r4, #1 + 39f14c: a808 add r0, sp, #32 ; 0x20 + 39f14e: 7004 strb r4, [r0, #0] + 39f150: 4897 ldr r0, =0x17750fc ; via 0x39f3b0 + 39f152: 7800 ldrb r0, [r0, #0] + 39f154: a908 add r1, sp, #32 ; 0x20 + 39f156: 7809 ldrb r1, [r1, #0] + 39f158: 4288 cmp r0, r1 + 39f15a: d017 beq 0x39f18c + 39f15c: f7b0 ffc4 bl 0x3500e8 + 39f160: 2801 cmp r0, #1 + 39f162: d10a bne 0x39f17a + 39f164: 4893 ldr r0, =0x17750fe ; via 0x39f3b4 + 39f166: 2101 mov r1, #1 + 39f168: 7001 strb r1, [r0, #0] + 39f16a: 4991 ldr r1, =0x17750fc ; via 0x39f3b0 + 39f16c: a808 add r0, sp, #32 ; 0x20 + 39f16e: 7800 ldrb r0, [r0, #0] + 39f170: 7008 strb r0, [r1, #0] + 39f172: 488c ldr r0, =0xa0010 ; via 0x39f3a4 + 39f174: 9000 str r0, [sp, #0] + 39f176: a063 add r0, pc, #396 ; 0x18c + 39f178: e002 b 0x39f180 + 39f17a: 488a ldr r0, =0xa0010 ; via 0x39f3a4 + 39f17c: 9000 str r0, [sp, #0] + 39f17e: a063 add r0, pc, #396 ; 0x18c + 39f180: 2107 mov r1, #7 + 39f182: 2200 mov r2, #0 + 39f184: 43d2 mvn r2, r2 + 39f186: 2305 mov r3, #5 + 39f188: f03b fd54 bl 0x3dac34 +; end of GPIO 6 check code + 39f18c: 488a ldr r0, =0x17751e8 ; via 0x39f3b8 + 39f18e: 7800 ldrb r0, [r0, #0] + 39f190: 2800 cmp r0, #0 + 39f192: d019 beq 0x39f1c8 + 39f194: f69e f9ce bl 0x23d534 + 39f198: 2802 cmp r0, #2 + 39f19a: dd15 ble 0x39f1c8 + 39f19c: 4883 ldr r0, =0x1774e38 ; via 0x39f3ac + 39f19e: 6800 ldr r0, [r0, #0] + 39f1a0: 8a41 ldrh r1, [r0, #18] ; 0x12 + 39f1a2: 2049 mov r0, #73 ; 0x49 + 39f1a4: 00c0 lsl r0, r0, #3 + 39f1a6: 4281 cmp r1, r0 + 39f1a8: dd0e ble 0x39f1c8 + 39f1aa: 4983 ldr r1, =0x17751e8 ; via 0x39f3b8 + 39f1ac: 2000 mov r0, #0 + 39f1ae: 7008 strb r0, [r1, #0] + 39f1b0: 4882 ldr r0, =0x17751e9 ; via 0x39f3bc + 39f1b2: 2101 mov r1, #1 + 39f1b4: 7001 strb r1, [r0, #0] + 39f1b6: 487b ldr r0, =0xa0010 ; via 0x39f3a4 + 39f1b8: 9000 str r0, [sp, #0] + 39f1ba: a060 add r0, pc, #384 ; 0x180 + 39f1bc: 2103 mov r1, #3 + 39f1be: 2200 mov r2, #0 + 39f1c0: 43d2 mvn r2, r2 + 39f1c2: 2305 mov r3, #5 + 39f1c4: f03b fd36 bl 0x3dac34 + 39f1c8: 4879 ldr r0, =0x17750fc ; via 0x39f3b0 + 39f1ca: 7800 ldrb r0, [r0, #0] + 39f1cc: 2800 cmp r0, #0 + 39f1ce: d110 bne 0x39f1f2 + 39f1d0: 487b ldr r0, =0x1774db8 ; via 0x39f3c0 + 39f1d2: 6800 ldr r0, [r0, #0] + 39f1d4: 2801 cmp r0, #1 + 39f1d6: d003 beq 0x39f1e0 + 39f1d8: 4879 ldr r0, =0x1774db8 ; via 0x39f3c0 + 39f1da: 6800 ldr r0, [r0, #0] + 39f1dc: 2802 cmp r0, #2 + 39f1de: d108 bne 0x39f1f2 + 39f1e0: 4872 ldr r0, =0x1774e38 ; via 0x39f3ac + 39f1e2: 6800 ldr r0, [r0, #0] + 39f1e4: 8a41 ldrh r1, [r0, #18] ; 0x12 + 39f1e6: 2049 mov r0, #73 ; 0x49 + 39f1e8: 00c0 lsl r0, r0, #3 + 39f1ea: 4281 cmp r1, r0 + 39f1ec: dc04 bgt 0x39f1f8 + 39f1ee: 2101 mov r1, #1 + 39f1f0: e000 b 0x39f1f4 + 39f1f2: 2100 mov r1, #0 + 39f1f4: 4870 ldr r0, =0x17751e8 ; via 0x39f3b8 + 39f1f6: 7001 strb r1, [r0, #0] + 39f1f8: 486e ldr r0, =0x17750fe ; via 0x39f3b4 + 39f1fa: 7800 ldrb r0, [r0, #0] + 39f1fc: 2800 cmp r0, #0 + 39f1fe: d103 bne 0x39f208 + 39f200: 486e ldr r0, =0x17751e9 ; via 0x39f3bc + 39f202: 7800 ldrb r0, [r0, #0] + 39f204: 2800 cmp r0, #0 + 39f206: d04f beq 0x39f2a8 + 39f208: 486e ldr r0, =0x1775098 ; via 0x39f3c4 + 39f20a: 6800 ldr r0, [r0, #0] + 39f20c: 8800 ldrh r0, [r0, #0] + 39f20e: 2110 mov r1, #16 ; 0x10 + 39f210: aa07 add r2, sp, #28 ; 0x1c + 39f212: f625 fbd9 bl 0x1c49c8 + 39f216: 9006 str r0, [sp, #24] ; 0x18 + 39f218: 9806 ldr r0, [sp, #24] ; 0x18 + 39f21a: 2802 cmp r0, #2 + 39f21c: d015 beq 0x39f24a + 39f21e: 9907 ldr r1, [sp, #28] ; 0x1c + 39f220: 4869 ldr r0, =0xd809 ; via 0x39f3c8 + 39f222: 6008 str r0, [r1, #0] + 39f224: 9907 ldr r1, [sp, #28] ; 0x1c + 39f226: 2000 mov r0, #0 + 39f228: 43c0 mvn r0, r0 + 39f22a: 7308 strb r0, [r1, #12] ; 0xc + 39f22c: 9806 ldr r0, [sp, #24] ; 0x18 + 39f22e: 2800 cmp r0, #0 + 39f230: d101 bne 0x39f236 + 39f232: 2101 mov r1, #1 + 39f234: e000 b 0x39f238 + 39f236: 2100 mov r1, #0 + 39f238: 9807 ldr r0, [sp, #28] ; 0x1c + 39f23a: 7341 strb r1, [r0, #13] ; 0xd + 39f23c: 4861 ldr r0, =0x1775098 ; via 0x39f3c4 + 39f23e: 6800 ldr r0, [r0, #0] + 39f240: 7880 ldrb r0, [r0, #2] + 39f242: 9907 ldr r1, [sp, #28] ; 0x1c + 39f244: f019 feac bl 0x3b8fa0 + 39f248: e02e b 0x39f2a8 + 39f24a: 4860 ldr r0, =0xa0008 ; via 0x39f3cc + 39f24c: 9000 str r0, [sp, #0] + 39f24e: a03c add r0, pc, #240 ; 0xf0 + 39f250: 212e mov r1, #46 ; 0x2e + 39f252: 2200 mov r2, #0 + 39f254: 43d2 mvn r2, r2 + 39f256: 2301 mov r3, #1 + 39f258: f03b fcec bl 0x3dac34 + 39f25c: f00f fe8b bl 0x3aef76 + 39f260: e022 b 0x39f2a8 + 39f262: 9802 ldr r0, [sp, #8] + 39f264: 8800 ldrh r0, [r0, #0] + 39f266: 0900 lsr r0, r0, #4 + 39f268: d31e bcc 0x39f2a8 + 39f26a: f7aa f84f bl 0x34930c + 39f26e: 4669 mov r1, sp + 39f270: 81c8 strh r0, [r1, #14] ; 0xe + 39f272: 4668 mov r0, sp + 39f274: 89c0 ldrh r0, [r0, #14] ; 0xe + 39f276: 09c0 lsr r0, r0, #7 + 39f278: d30b bcc 0x39f292 + 39f27a: 484a ldr r0, =0xa0010 ; via 0x39f3a4 + 39f27c: 9000 str r0, [sp, #0] + 39f27e: a03c add r0, pc, #240 ; 0xf0 + 39f280: 2114 mov r1, #20 ; 0x14 + 39f282: 2200 mov r2, #0 + 39f284: 43d2 mvn r2, r2 + 39f286: 2305 mov r3, #5 + 39f288: f03b fcd4 bl 0x3dac34 + 39f28c: f002 f993 bl 0x3a15b6 + 39f290: e00a b 0x39f2a8 + 39f292: 4844 ldr r0, =0xa0010 ; via 0x39f3a4 + 39f294: 9000 str r0, [sp, #0] + 39f296: a03c add r0, pc, #240 ; 0xf0 + 39f298: 2116 mov r1, #22 ; 0x16 + 39f29a: 2200 mov r2, #0 + 39f29c: 43d2 mvn r2, r2 + 39f29e: 2305 mov r3, #5 + 39f2a0: f03b fcc8 bl 0x3dac34 + 39f2a4: f002 f99a bl 0x3a15dc + 39f2a8: 200c mov r0, #12 ; 0xc + 39f2aa: f040 fd00 bl 0x3dfcae + 39f2ae: b009 add sp, #36 ; 0x24 + 39f2b0: bd10 pop {r4, pc} + 39f2b2: 46c0 nop (mov r8, r8) + $Init_Target: 3bb7d4: b570 push {r4, r5, r6, lr} 3bb7d6: b081 sub sp, #4 @@ -1426,7 +1782,8 @@ 0x00: prim_id like in TCS211 0x02: addr_id (ditto) 0x04: adc_result[8] array (ditto) -0x14: Foxconn/Pirelli's unknown insertions +0x14: array of 6 16-bit words storing consecutive VBAT ADC readings +0x2E: 16-bit var write pointer for the array at offset 0x14 0x32: assumed is_gsm_on 0x33: assumed is_adc_on 0x34: assumed SpiTaskReady @@ -1732,6 +2089,29 @@ 3cdaa0: 2000 mov r0, #0 3cdaa2: bd00 pop {pc} +; function called from the ADC end handler + 3cfef6: b510 push {r4, lr} + 3cfef8: 2400 mov r4, #0 + 3cfefa: 2105 mov r1, #5 + 3cfefc: 1a40 sub r0, r0, r1 + 3cfefe: 2800 cmp r0, #0 + 3cff00: d008 beq 0x3cff14 + 3cff02: 3803 sub r0, #3 + 3cff04: 2800 cmp r0, #0 + 3cff06: d10b bne 0x3cff20 + 3cff08: 200d mov r0, #13 ; 0xd + 3cff0a: f013 f8a9 bl 0x3e3060 ; $AI_ReadBit + 3cff0e: 2801 cmp r0, #1 + 3cff10: d005 beq 0x3cff1e + 3cff12: e005 b 0x3cff20 + 3cff14: 2006 mov r0, #6 + 3cff16: f013 f8a3 bl 0x3e3060 ; $AI_ReadBit + 3cff1a: 2801 cmp r0, #1 + 3cff1c: d100 bne 0x3cff20 + 3cff1e: 2401 mov r4, #1 + 3cff20: 1c20 add r0, r4, #0 + 3cff22: bd10 pop {r4, pc} + $Create_ABB_HISR: 3dc928: b500 push {lr} 3dc92a: b083 sub sp, #12 ; 0xc @@ -1826,6 +2206,172 @@ 3dc9e0: b003 add sp, #12 ; 0xc 3dc9e2: bd00 pop {pc} +$AI_EnableBit: + 3e300c: 4a44 ldr r2, =0xfffef00a ; via 0x3e3120 + 3e300e: 2101 mov r1, #1 + 3e3010: 4081 lsl r1, r0 + 3e3012: 8810 ldrh r0, [r2, #0] + 3e3014: 4301 orr r1, r0 + 3e3016: 8011 strh r1, [r2, #0] + 3e3018: 4770 bx lr + +$AI_DisableBit: + 3e301a: 4a41 ldr r2, =0xfffef00a ; via 0x3e3120 + 3e301c: 2101 mov r1, #1 + 3e301e: 4081 lsl r1, r0 + 3e3020: 8810 ldrh r0, [r2, #0] + 3e3022: 4388 bic r0, r1 + 3e3024: 8010 strh r0, [r2, #0] + 3e3026: 4770 bx lr + +$AI_SetBit: + 3e3028: 4a3e ldr r2, =0xfffe4802 ; via 0x3e3124 + 3e302a: 2101 mov r1, #1 + 3e302c: 4081 lsl r1, r0 + 3e302e: 8810 ldrh r0, [r2, #0] + 3e3030: 4301 orr r1, r0 + 3e3032: 8011 strh r1, [r2, #0] + 3e3034: 4770 bx lr + +$AI_ResetBit: + 3e3036: 4a3b ldr r2, =0xfffe4802 ; via 0x3e3124 + 3e3038: 2101 mov r1, #1 + 3e303a: 4081 lsl r1, r0 + 3e303c: 8810 ldrh r0, [r2, #0] + 3e303e: 4388 bic r0, r1 + 3e3040: 8010 strh r0, [r2, #0] + 3e3042: 4770 bx lr + +$AI_ConfigBitAsOutput: + 3e3044: 4a38 ldr r2, =0xfffe4804 ; via 0x3e3128 + 3e3046: 2101 mov r1, #1 + 3e3048: 4081 lsl r1, r0 + 3e304a: 8810 ldrh r0, [r2, #0] + 3e304c: 4388 bic r0, r1 + 3e304e: 8010 strh r0, [r2, #0] + 3e3050: 4770 bx lr + +$AI_ConfigBitAsInput: + 3e3052: 4a35 ldr r2, =0xfffe4804 ; via 0x3e3128 + 3e3054: 2101 mov r1, #1 + 3e3056: 4081 lsl r1, r0 + 3e3058: 8810 ldrh r0, [r2, #0] + 3e305a: 4301 orr r1, r0 + 3e305c: 8011 strh r1, [r2, #0] + 3e305e: 4770 bx lr + +$AI_ReadBit: + 3e3060: 4932 ldr r1, =0xfffe4800 ; via 0x3e312c + 3e3062: 8809 ldrh r1, [r1, #0] + 3e3064: 4101 asr r1, r0 + 3e3066: 07c8 lsl r0, r1, #31 + 3e3068: 0fc0 lsr r0, r0, #31 + 3e306a: 0600 lsl r0, r0, #24 + 3e306c: 0e00 lsr r0, r0, #24 + 3e306e: 4770 bx lr + +$AI_Power: + 3e3070: b500 push {lr} + 3e3072: 2800 cmp r0, #0 + 3e3074: d101 bne 0x3e307a + 3e3076: f766 fbff bl 0x349878 ; $ABB_Power_Off + 3e307a: bd00 pop {pc} + +$AI_ResetIoConfig: + 3e307c: 492a ldr r1, =0xfffe4804 ; via 0x3e3128 + 3e307e: 482c ldr r0, =0xffff ; via 0x3e3130 + 3e3080: 8008 strh r0, [r1, #0] + 3e3082: 4827 ldr r0, =0xfffef00a ; via 0x3e3120 + 3e3084: 2100 mov r1, #0 + 3e3086: 8001 strh r1, [r0, #0] + 3e3088: 4770 bx lr + +$AI_ClockEnable: + 3e308a: 492a ldr r1, =0xfffe4806 ; via 0x3e3134 + 3e308c: 2020 mov r0, #32 ; 0x20 + 3e308e: 880a ldrh r2, [r1, #0] + 3e3090: 4310 orr r0, r2 + 3e3092: 8008 strh r0, [r1, #0] + 3e3094: 4770 bx lr + +$AI_InitIOConfig: + 3e3096: b500 push {lr} + 3e3098: f7ec fe54 bl 0x3cfd44 + 3e309c: 2000 mov r0, #0 + 3e309e: 4926 ldr r1, =0x1773f8a ; via 0x3e3138 + 3e30a0: 7008 strb r0, [r1, #0] + 3e30a2: 4926 ldr r1, =0x17750fd ; via 0x3e313c + 3e30a4: 7008 strb r0, [r1, #0] + 3e30a6: 4926 ldr r1, =0x17750ff ; via 0x3e3140 + 3e30a8: 2201 mov r2, #1 + 3e30aa: 700a strb r2, [r1, #0] + 3e30ac: 4925 ldr r1, =0x17750fe ; via 0x3e3144 + 3e30ae: 7008 strb r0, [r1, #0] + 3e30b0: 4825 ldr r0, =0x17750fc ; via 0x3e3148 + 3e30b2: 21ff mov r1, #255 ; 0xff + 3e30b4: 7001 strb r1, [r0, #0] + 3e30b6: bd00 pop {pc} + +$AI_SelectIOForIT: + 3e30b8: 0109 lsl r1, r1, #4 + 3e30ba: 1840 add r0, r0, r1 + 3e30bc: 0040 lsl r0, r0, #1 + 3e30be: 3001 add r0, #1 + 3e30c0: 4922 ldr r1, =0xfffe4814 ; via 0x3e314c + 3e30c2: 8008 strh r0, [r1, #0] + 3e30c4: 4770 bx lr + +$AI_CheckITSource: + 3e30c6: 2100 mov r1, #0 + 3e30c8: 4a21 ldr r2, =0xfffe4816 ; via 0x3e3150 + 3e30ca: 8812 ldrh r2, [r2, #0] + 3e30cc: 4210 tst r0, r2 + 3e30ce: d000 beq 0x3e30d2 + 3e30d0: 2101 mov r1, #1 + 3e30d2: 1c08 add r0, r1, #0 + 3e30d4: 4770 bx lr + +$AI_UnmaskIT: + 3e30d6: 4a1f ldr r2, =0xfffe4818 ; via 0x3e3154 + 3e30d8: 8811 ldrh r1, [r2, #0] + 3e30da: 4381 bic r1, r0 + 3e30dc: 8011 strh r1, [r2, #0] + 3e30de: 4770 bx lr + +$AI_MaskIT: + 3e30e0: 4a1c ldr r2, =0xfffe4818 ; via 0x3e3154 + 3e30e2: 8811 ldrh r1, [r2, #0] + 3e30e4: 4301 orr r1, r0 + 3e30e6: 8011 strh r1, [r2, #0] + 3e30e8: 4770 bx lr + + 3e30ea: 2130 mov r1, #48 ; 0x30 + 3e30ec: 7001 strb r1, [r0, #0] + 3e30ee: 3001 add r0, #1 + 3e30f0: 2231 mov r2, #49 ; 0x31 + 3e30f2: 7002 strb r2, [r0, #0] + 3e30f4: 3001 add r0, #1 + 3e30f6: 222e mov r2, #46 ; 0x2e + 3e30f8: 7002 strb r2, [r0, #0] + 3e30fa: 3001 add r0, #1 + 3e30fc: 7001 strb r1, [r0, #0] + 3e30fe: 3001 add r0, #1 + 3e3100: 7001 strb r1, [r0, #0] + 3e3102: 3001 add r0, #1 + 3e3104: 2100 mov r1, #0 + 3e3106: 7001 strb r1, [r0, #0] + 3e3108: 4770 bx lr + + 3e310a: b500 push {lr} + 3e310c: 2801 cmp r0, #1 + 3e310e: d103 bne 0x3e3118 + 3e3110: 2001 mov r0, #1 + 3e3112: f7ff ff90 bl 0x3e3036 ; $AI_ResetBit + 3e3116: bd00 pop {pc} + 3e3118: 2001 mov r0, #1 + 3e311a: f7ff ff85 bl 0x3e3028 ; $AI_SetBit + 3e311e: bd00 pop {pc} + _f_checksum: 3e6990: e1a0c000 mov r12, r0 3e6994: e3a00000 mov r0, #0 @@ -2335,3 +2881,6 @@ 0x1774e70: pwr_env_ctrl_blk 0x1774e74: pwr_error_ft + +0x1775041: byte var set to 0 in spi_abb_read_int_reg_callback() + in ADC end processing