( PR# and IN# words plus special QForth locations -- 02.03.95 ) ( special locations: $AA00-$AAFF = data stack ) ( $EE = data stack pointer ) ( $F4 = data stack depth ) : depth ( -- n ) 244 c@ ; ( depth of data stack excluding n ) ( PR# -- inline code ) create (pr#) ( start code ) 166 c, 238 c, ( A6 EE LDX $EE ; get data stack pointer ) 232 c, ( E8 INX ; ptr to low bye of TOS ) 189 c, 0 c, 170 c, ( BD 00 AA LDA $AA00,X ; get TOS ) 32 c, 149 c, 254 c, ( 20 95 FE JSR $FE95 ; monitor set outport ) 96 c, ( 60 RTS ; return ) ( end code ) : PR# ( s -- ) (pr#) execute ; ( send output to the specified slot ) : printer-on 1 PR# ; ( activate printer ) : printer off 3 PR# ; ( deactivate printer ) ( IN# -- same as PR# except calls $FE8B not $FE95 ) create (in#) 166 c, 238 c, 232 c, 189 c, 0 c, 170 c, 32 c, 139 c, 254 c, 96 c, : IN# ( s -- ) (in#) execute ; ( get input from specified slot )