This repository has been archived by the owner on Jul 24, 2024. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathprogram.S
45 lines (41 loc) · 1.89 KB
/
program.S
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
.thumb_func @ Necessary because sdk uses BLX
.global main @ Provide program starting address to linker
main:
BL stdio_init_all
MOV R5, #0
LDR R3, =size
LDR R4, =signals
loop:
LDR R6, [R4, R5]
ADD R5, #4
PUSH {R3}
@ TODO: Branch and Link (BL) to dispatch label
POP {R3}
CMP R5, R3
BNE loop
rest:
NOP
B rest
.data
signals: .word 966081, 475877, 219889, 275073, 753047
.word 507159, 284406, 537691, 38249, 53059
.word 181407, 336722, 345502, 166471, 686535
.word 452779, 465214, 843909, 286891, 979596
.word 370365, 527254, 355151, 273454, 981076
.word 904705, 416301, 786009, 760676, 877459
.word 91279, 346450, 579616, 740219, 102706
.word 728970, 459071, 893083, 70417, 131406
.word 188263, 833592, 393345, 96850, 969028
.word 583019, 188486, 93105, 830644, 990678
.word 820370, 175851, 438405, 727792, 30969
.word 718193, 172907, 15193, 475440, 732513
.word 938307, 816167, 103268, 336742, 367860
.word 437173, 765356, 941571, 353088, 743371
.word 302967, 423311, 318643, 923403, 320974
.word 355959, 166521, 771393, 382652, 163116
.word 689999, 828204, 61875, 115982, 49647
.word 891553, 491925, 94807, 177088, 973945
.word 8695, 987054, 656653, 359910, 235998
.word 427535, 516345, 426889, 983363, 544308
end:
.set size, end - signals