The file COMMON\DEVTOOLS.FTH supplies words that are most used during development and debugging.
1 equ simple? \ -- n
Set this flag non-zero to generate .xWORD to avoid divisions.
On some CPUs, a division operation is slow.
: .nibble \ n --
Convert a nibble to a hex ASCII digit and display it.
: .BYTE \ b --
Display b as two hex digits.
: .WORD \ w --
Display w as four hex digits.
: .LWORD \ x --
Display x as eight hex digits.
The separator ":" makes the output easier to read.
Future releases of MPE Forths will treat the ":"
character as having no effect on number input parsing.
This character is chosen because it does not conflict
with the current use of the "." and "," characters
for numbers.
This word is only compiled for 32 bit targets.
: .DWORD \ x --
A synonym for .LWORD.
: .ASCII \ char --
The top bit of char is zeroed. If char is in the range
32..126 it is displayed, otherwise a "." is displayed.
: DUMP \ addr len --
Display (dump) len bytes of memory starting at addr.
: LDUMP \ addr len -- ; dump 32 bit long words
Display (dump) len bytes of memory starting at addr
as 32 bit words.
: WDUMP \ addr len -- ; dump 16 bit half words
Display (dump) len bytes of memory starting at addr
as 16 bit half-words.
: .S \ --
Display the contents of the data stack without affecting it.
: ? \ a-addr --
Display contents of a memory location as a cell.