debug tool for STM32F042F6P6
check_2_bit.s@27:e255eaf79cd2, 2019-05-28 (annotated)
- Committer:
- bieleluk
- Date:
- Tue May 28 09:45:17 2019 +0000
- Revision:
- 27:e255eaf79cd2
- Parent:
- 24:bc7c4e8f3fe0
Who changed what in which revision?
User | Revision | Line number | New contents of line |
---|---|---|---|
bieleluk | 0:98789a3f7363 | 1 | AREA asm_func, CODE, READONLY |
bieleluk | 0:98789a3f7363 | 2 | EXPORT check_2_bit |
bieleluk | 0:98789a3f7363 | 3 | check_2_bit |
bieleluk | 0:98789a3f7363 | 4 | |
bieleluk | 0:98789a3f7363 | 5 | PUSH {LR} |
bieleluk | 0:98789a3f7363 | 6 | ;R0 = GPIOx |
bieleluk | 0:98789a3f7363 | 7 | ;R1 = offset |
bieleluk | 0:98789a3f7363 | 8 | ;r2 = pin_number |
bieleluk | 0:98789a3f7363 | 9 | |
bieleluk | 0:98789a3f7363 | 10 | |
bieleluk | 0:98789a3f7363 | 11 | LDR R3, [R0, R1] |
bieleluk | 0:98789a3f7363 | 12 | |
bieleluk | 0:98789a3f7363 | 13 | LDR R0, =30 |
bieleluk | 0:98789a3f7363 | 14 | SUBS R0,R2 |
bieleluk | 0:98789a3f7363 | 15 | SUBS R0,R2 |
bieleluk | 0:98789a3f7363 | 16 | LSLS R3,R3,R0 |
bieleluk | 0:98789a3f7363 | 17 | LSRS R3,#30 |
bieleluk | 0:98789a3f7363 | 18 | |
bieleluk | 0:98789a3f7363 | 19 | MOVS R0,R3 |
bieleluk | 0:98789a3f7363 | 20 | |
bieleluk | 0:98789a3f7363 | 21 | POP {PC} |
bieleluk | 0:98789a3f7363 | 22 | |
bieleluk | 0:98789a3f7363 | 23 | |
bieleluk | 0:98789a3f7363 | 24 | ALIGN |
bieleluk | 0:98789a3f7363 | 25 | END |
bieleluk | 0:98789a3f7363 | 26 |