20 lines
380 B
ArmAsm
20 lines
380 B
ArmAsm
.arm
|
|
.global _start
|
|
_start:
|
|
push {r0-r12 , lr}
|
|
ldr r0, =0x08000c00
|
|
mov r1, #0xA00
|
|
mov r2, #0x0
|
|
thread_stack_loop:
|
|
str r2, [r0], #0x4
|
|
subs r1, r1, #4
|
|
bgt thread_stack_loop
|
|
mov r0, #0x3F @ thread priority
|
|
ldr r1, =thread @ thread_addr
|
|
mov r2, #0x0 @ arg
|
|
ldr r3, =0x08000c00 @ StackTop
|
|
ldr r4, =0x1
|
|
svc 0x8
|
|
pop {r0-r12 , lr}
|
|
ldr r0, =0x80CB0A8
|
|
ldr pc, =0x080860B4 |