collapseos/blk/364
Virgil Dupras bd38d80f9c Move Cross-compiled core from B390 to B350
and renamed it "Core words". Also, reworded the presentation.
2020-05-15 22:44:49 -04:00

15 lines
399 B
Plaintext

: C<? 0x06 RAM+ @ ;
: C<
0x08 RAM+ @ ( 08 == C<* override )
DUP NOT IF DROP 0x0c RAM+ @ THEN ( 0c == C<* )
EXECUTE
;
: , HERE @ ! HERE @ 2+ HERE ! ;
: C, HERE @ C! HERE @ 1+ HERE ! ;
: BIT@ ( bit addr -- f ) C@ SWAP RSHIFT 0x01 AND ;
: BIT! ( f bit addr -- )
SWAP 0x01 SWAP LSHIFT ROT ( addr mask f )
IF OVER C@ OR
ELSE 0xff XOR OVER C@ AND THEN ( addr flg )
SWAP C! ;