projects
/
calu.git
/ blob
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
history
|
raw
|
HEAD
progs/timer: angepasst
[calu.git]
/
progs
/
testbench.s
1
#include "dt_inc.s"
2
.text
3
.org 0x0
4
start:
5
br+ main
6
br+ main
7
ret
8
main:
9
call+ u_init
10
call+ u_recv_byte
11
call u_send_newline
12
13
ldis r1, 0x42
14
call u_send_byte
15
16
call t_init
17
call t_start
18
19
loop:
20
call u_recv_byte
21
cmpi r0, 0x42
22
breq reset_timer
23
call t_valget
24
addi r1, r0, 0
25
call u_send_uint
26
call u_send_newline
27
br loop
28
29
reset_timer:
30
ldis r1, 0
31
call t_valset
32
br loop