uxn11/test/detect.tal

21 lines
709 B
Tal
Raw Normal View History

2023-12-18 22:54:59 -05:00
|00 @System [
&unused $2 &expansion $2 &wst $1 &rst $1 &metadata $2
&red $2 &green $2 &blue $2 &debug $1 &state $1 ]
|10 @Console [
&vect $2 &stdin $1 &pad1 $1 &proc-get $1 &host-get $1 &pad2 $1 &type $1
&stdout $1 &stderr $1 &proc-put $1 &pad3 $1 &param $2 &opts $1 &host-put $1 ]
|0100
;query .System/expansion DEO2
;query/flags LDA2 #00ff EQU2 ?{ ;no !&done } ;yes
&done println #80 .System/state DEO BRK
@query 03 10 ( uuid ) 0123 1250 d878 4462 bc41 d092 7645 a2fa &flags 0000
@yes "ok: 20 "uxn11 20 "console 20 "detected 0a 00
@no "FAIL: 20 "uxn11 20 "console 20 "NOT 20 "detected 0a 00
@println ( s* -> )
&loop LDAk ?{ POP2 JMP2r } LDAk .Console/stdout DEO INC2 !&loop