Congrats on taking this concept far beyond 'proof of concept'; well done.
Done many years ago now, there is a preemptive multitasking OS for the Z80 for the "kiss TNC" used in ham radio: https://github.com/cheponis/KISS-TNC2/blob/master/KISS-TNC.a... This only used the interrupts to permit the modem (receive) side to generate interrupts, but the concepts are the same as if the interrupt would have come from a timer source. Yes, it uses the EXX and EX AF,AF' instructions.
The best Z80 book, which describes the little-known W and Z registers is http://www.z80.info/zip/zaks_book.pdf start on page 86 for their description.
Done many years ago now, there is a preemptive multitasking OS for the Z80 for the "kiss TNC" used in ham radio: https://github.com/cheponis/KISS-TNC2/blob/master/KISS-TNC.a... This only used the interrupts to permit the modem (receive) side to generate interrupts, but the concepts are the same as if the interrupt would have come from a timer source. Yes, it uses the EXX and EX AF,AF' instructions.
The best Z80 book, which describes the little-known W and Z registers is http://www.z80.info/zip/zaks_book.pdf start on page 86 for their description.