Revamped persistent storage ops to Forth-like 1K-aligned blocks
This commit is contained in:
@@ -22,7 +22,7 @@ Main features of an Equi machine:
|
||||
- Minification mode (MM) flag;
|
||||
- 16-bit input buffer pointer;
|
||||
- 42752 bytes of main RAM (0x0000-0xa6ff), 41984 bytes of which are available for the program and data and 768 bytes hold the three stacks and necessary service registers listed above;
|
||||
- Up to 4GB flat persistent storage (tape, disk, flash etc);
|
||||
- Up to 64 MiB flat persistent storage (tape, disk, flash etc);
|
||||
- Serial terminal input and output;
|
||||
- Up to 65535 peripheral extension ports, including several virtual ports.
|
||||
|
||||
@@ -116,8 +116,8 @@ Op |Stack state |Meaning
|
||||
`,`|`( -- a ) ` |Non-blocking key input of an ASCII (or Unicode, if supported) value from the standard terminal
|
||||
`?`|`( -- a ) ` |Blocking key input of an ASCII (or Unicode, if supported) value from the standard terminal
|
||||
`P`|`( p1 p2 port -- r1 r2 status )`|**P**ort I/O: pass two 16-bit parameters to the port and read the operation status and results into the words on the stack top
|
||||
`}`|`( adh adl len maddr -- status)`|Persistent storage write operation. Stack parameters: persistent address high 2 bytes, low 2 bytes, data length, RAM address
|
||||
`{`|`( adh adl len maddr -- status)`|Persistent storage read operation. Stack parameters: persistent address high 2 bytes, low 2 bytes, data length, RAM address
|
||||
`}`|`( blk len maddr -- status)` |Persistent storage write operation. Stack parameters: block number (x1K), data length, RAM address
|
||||
`{`|`( blk len maddr -- status)` |Persistent storage read operation. Stack parameters: block number (x1K), data length, RAM address
|
||||
`Q`|`( -- )` |**Q**uit the interpretation mode (unset IM flag if set), or the interpreter shell itself if in command mode (halt the machine when it's nowhere to exit to)
|
||||
|
||||
Note that, due to the dynamic nature of word allocation and ability to reconfigure the runtime environment for different offsets depending on the target, absolute jumps are not directly supported in Equi and generally not recommended, although one can easily do them with `]R` sequence and/or calculate absolute positions using `X` instruction.
|
||||
|
||||
Reference in New Issue
Block a user