OpenBoot 3.x Quick Reference

Memory Access Commands

Table 1-24 Memory Access Commands

!

( n adr -- )

Store a number at adr.

+!

( n adr -- )

Add n to the number stored at ad.

@

( adr -- n )

Fetch a number from adr.

c!

( n adr -- )

Store low byte of n at adr.

c@

( adr -- byte )

Fetch a byte from adr.

cpeek

( adr -- false | byte true )

Fetch the byte at adr. Return the data and true if the access was successful. Return false if a read access error occurred. (Also lpeek, wpeek.)

cpoke

( byte adr -- okay? )

Store the byte to adr. Return true if the access was successful. Return false if a write access error occurred. (Also lpoke, wpoke.)

comp

( adr1 adr2 len -- n )

Compare two byte arrays, n = 0 if arrays are identical, n = 1 if first byte that is different is greater in array#1, n = -1 otherwise. 

dump

( adr len -- )

Display len bytes of memory starting at adr. 

fill

( adr size byte -- )

Set size bytes of memory to byte. 

l!

( n adr32 -- )

Store a 32-bit number at adr32. 

l@

( adr32 -- long )

Fetch a 32-bit number from adr32. 

move

( src dst u -- )

Copy u bytes from src to dst, handle overlap properly. 

w!

( n adr16 -- )

Store a 16-bit number at adr16, must be 16-bit aligned. 

w@

( adr16 -- word )

Fetch a 16-bit number from adr16, must be 16-bit aligned. 

x!

( o oaddr -- )

Store a 64-bit number at oaddr, must be 64-bit aligned. 

x@

( oaddr -- o )

Fetch a 64-bit number from oaddr, must be 64-bit aligned.