1
0
mirror of https://github.com/hsoft/collapseos.git synced 2024-11-10 09:38:06 +11:00
collapseos/blk/441
Virgil Dupras 8bf6258673 Add word TICKS
Adding a delay such as the 20ms one we have in AVR programmer's
initialization routine is tricky without a word like TICKS.

This implementation is highly inaccurate, but more accurate and
reliable than a "ballpark" DO..LOOP...
2020-09-25 17:31:06 -04:00

14 lines
634 B
Plaintext

STABLE ABI: As a compatible binary, this binary follows the
same stable ABI as its z80 counterpart.
PS CHECKS: Unlike z80 boot code, we don't check PS at each next
call (we do check RS though). It is the responsibility of every
native PSP-modifying word to call chkPS, . Also, chkPS, is a
bit different than in z80: it is parametrizable. The idea is
that we always call chkPS, before popping, telling the expected
size of stack. This allows for some interesting optimization.
For example, in SWAP, no need to pop, chkPS, then push, we can
chkPS and then proceed to optimized swapping in PS.
To assemble, load blocks 445 through 461