ak3-labs-asm/lab1_v2.S

23 lines
270 B
ArmAsm

.syntax unified
.cpu cortex-m4
.thumb
.macro BKPT_WRITE addr_src
mov r0, 0x4
mov r1, \addr_src
bkpt 0xAB
.endm
.section .data
test_string: .asciz "Hello"
.section .text
lab1_v2:
push {lr}
ldr r1, =test_string
BKPT_WRITE r1
pop {pc}