23 lines
355 B
Tal
23 lines
355 B
Tal
( usage: uxncli console.write.rom )
|
|
|
|
|10 @Console &vector $2 &read $1 &pad $4 &type $1 &write $1 &error $1
|
|
|
|
|0100
|
|
|
|
@on-reset ( -> )
|
|
( | write )
|
|
{ "Hello 20 "Write 0a 00 }
|
|
STH2r
|
|
&wa ( -- )
|
|
LDAk .Console/write DEO
|
|
INC2 LDAk ?&wa
|
|
POP2
|
|
( | error )
|
|
{ "Hello 20 "Error 0a 00 }
|
|
STH2r
|
|
&wb ( -- )
|
|
LDAk .Console/error DEO
|
|
INC2 LDAk ?&wb
|
|
POP2 BRK
|
|
|