-
-
- .text
- .global _start
- _start:
- ldr r0,=0x50000a28
- ldr r1,[r0]
- orr r1,r1,#(0x3<<4)
- orr r1,r1,#(0x1<<1)
- str r1,[r0]
-
- ldr r0,=0x50006000
- ldr r1,[r0]
- bic r1,r1,#(0x3<<20)
- orr r1,r1,#(0x1<<20)
- bic r1,r1,#(0x3<<16)
- orr r1,r1,#(0x1<<16)
- str r1,[r0]
-
-
- ldr r0,=0x50007000
- ldr r1,[r0]
- bic r1,r1,#(0x3<<20)
- orr r1,r1,#(0x1<<20)
- str r1,[r0]
-
- ldr r0,=0x50003000
- ldr r1,[r0]
- bic r1,r1,#(0x3<<12)
- orr r1,r1,#(0x1<<12)
- str r1,[r0]
-
- ldr r0,=0x50006004
- ldr r1,[r0]
- bic r1,r1,#(0x1<<10)
- bic r1,r1,#(0x1<<8)
- str r1,[r0]
-
-
- ldr r0,=0x50007004
- ldr r1,[r0]
- bic r1,r1,#(0x1<<10)
- str r1,[r0]
-
- ldr r0,=0x50003004
- ldr r1,[r0]
- bic r1,r1,#(0x1<<6)
- str r1,[r0]
-
- ldr r0,=0x50006008
- ldr r1,[r0]
- bic r1,r1,#(0x3<<20)
- bic r1,r1,#(0x3<<16)
- str r1,[r0]
-
- ldr r0,=0x50007008
- ldr r1,[r0]
- bic r1,r1,#(0x3<<20)
- str r1,[r0]
-
- ldr r0,=0x50003008
- ldr r1,[r0]
- bic r1,r1,#(0x3<<12)
- str r1,[r0]
-
- ldr r0,=0x5000600c
- ldr r1,[r0]
- bic r1,r1,#(0x3<<20)
- bic r1,r1,#(0x3<<16)
- str r1,[r0]
-
- ldr r0,=0x5000700c
- ldr r1,[r0]
- bic r1,r1,#(0x3<<20)
- str r1,[r0]
-
- ldr r0,=0x5000300c
- ldr r1,[r0]
- bic r1,r1,#(0x3<<12)
- str r1,[r0]
-
- loop:
- bl led1_on
- bl delay
- bl led1_off
- bl delay
- bl led2_on
- bl delay
- bl led2_off
- bl delay
- bl led3_on
- bl delay
- bl led3_off
- bl delay
- bl bee_on
- bl delay
- bl bee_off
- bl delay
- b loop
-
-
- led1_on:
- ldr r0,=0x50006014
- ldr r1,[r0]
- orr r1,r1,#(0x1<<10)
- str r1,[r0]
- mov pc,lr
- led1_off:
- ldr r0,=0x50006014
- ldr r1,[r0]
- bic r1,r1,#(0x1<<10)
- str r1,[r0]
- mov pc,lr
- led2_on:
- ldr r0,=0x50007014
- ldr r1,[r0]
- orr r1,r1,#(0x1<<10)
- str r1,[r0]
- mov pc,lr
- led2_off:
- ldr r0,=0x50007014
- ldr r1,[r0]
- bic r1,r1,#(0x1<<10)
- str r1,[r0]
- mov pc,lr
- led3_on:
- ldr r0,=0x50006014
- ldr r1,[r0]
- orr r1,r1,#(0x1<<8)
- str r1,[r0]
- mov pc,lr
- led3_off:
- ldr r0,=0x50006014
- ldr r1,[r0]
- bic r1,r1,#(0x1<<8)
- str r1,[r0]
- mov pc,lr
- bee_on:
- ldr r0,=0x50003014
- ldr r1,[r0]
- orr r1,r1,#(0x1<<6)
- str r1,[r0]
- mov pc,lr
- bee_off:
- ldr r0,=0x50003014
- ldr r1,[r0]
- bic r1,r1,#(0x1<<6)
- str r1,[r0]
- mov pc,lr
-
- delay:
- ldr r1,=0x10000000
- mm:
- cmp r1,#0
- subne r1,r1,#1
- bne mm
- mov pc,lr
- .end