Last change
on this file was 7, checked in by chronos, 3 months ago |
- Added: More instructions implemented.
|
File size:
387 bytes
|
Line | |
---|
1 | LDC (1000), Text
|
---|
2 | CALL PrintText
|
---|
3 | LDC (1000), Text
|
---|
4 | CALL PrintText
|
---|
5 | CALL PrintInc
|
---|
6 | CALL PrintInc
|
---|
7 | HALT
|
---|
8 |
|
---|
9 |
|
---|
10 | PrintInc:
|
---|
11 | LDC (1000), 65
|
---|
12 | LDC (1001), 30
|
---|
13 | Label:
|
---|
14 | OUT (0), (1000)
|
---|
15 | INC (1000)
|
---|
16 | DEC (1001)
|
---|
17 | JPNZ (1001), Label
|
---|
18 | RET
|
---|
19 |
|
---|
20 | PrintText:
|
---|
21 | LDM (1001), ((1000))
|
---|
22 | JPZ (1001), Label2
|
---|
23 | OUT (0), (1001)
|
---|
24 | INC (1000)
|
---|
25 | JP PrintText
|
---|
26 | Label2:
|
---|
27 | RET
|
---|
28 |
|
---|
29 | Text:
|
---|
30 | DB 'Text ', 0
|
---|
Note:
See
TracBrowser
for help on using the repository browser.