debug tool for STM32F042F6P6
check_1_bit.s
- Committer:
- bieleluk
- Date:
- 2019-04-15
- Revision:
- 0:98789a3f7363
- Child:
- 24:bc7c4e8f3fe0
File content as of revision 0:98789a3f7363:
AREA asm_func, CODE, READONLY ; Export my_asm function location so that C compiler can find it and link EXPORT check_1_bit check_1_bit PUSH {LR} ;R0 = GPIOx ;R1 = offset ;r2 = pin_number LDR R3, [R0, R1] LDR R0, =31 SUBS R0,R2 LSLS R3,R3,R0 LSRS R3,#31 MOVS R0,R3 POP {PC} ALIGN END