summaryrefslogtreecommitdiff
path: root/asm/test.asm
diff options
context:
space:
mode:
authorAlex AUVOLAT <alex.auvolat@ens.fr>2014-01-08 18:19:21 +0100
committerAlex AUVOLAT <alex.auvolat@ens.fr>2014-01-08 18:19:21 +0100
commit1f228ce77e8a71475930b433fb2c72521203aa99 (patch)
tree8a9db2a92abb2265905b737bc935f6b299f1fb95 /asm/test.asm
parentfa2e69bf68346d653d194d863c019674ea0fd7e2 (diff)
downloadSystDigit-Projet-1f228ce77e8a71475930b433fb2c72521203aa99.tar.gz
SystDigit-Projet-1f228ce77e8a71475930b433fb2c72521203aa99.zip
Petites modifications
Diffstat (limited to 'asm/test.asm')
-rw-r--r--asm/test.asm28
1 files changed, 28 insertions, 0 deletions
diff --git a/asm/test.asm b/asm/test.asm
new file mode 100644
index 0000000..d37ca61
--- /dev/null
+++ b/asm/test.asm
@@ -0,0 +1,28 @@
+.text
+ liuz SP 0xFF
+ add D Z Z
+init:
+ liuz B 0x40
+ lw B 0(B)
+ jz B init
+ add D D B
+ push D
+ la A msgtick
+ jal ser_out_msg
+ pop D
+ j init
+
+ser_out_msg:
+ liuz C 0x41
+ lil C 0x02
+ser_out_msg_loop:
+ lb B 0(A)
+ jz B ser_out_msg_ret
+ sb B 0(C)
+ incri A 1
+ j ser_out_msg_loop
+ser_out_msg_ret:
+ jr RA
+
+msgtick:
+ asciiz "Tick!"