Note: I have changed this to reflect the module now being called ZXGame.
I've had the idea for a while about making coprocessor for the ZX81 from the propeller by basically connecting the propeller pins directly (almost) to the ZX81 bus.
I wanted the propeller to be memory-mapped because ZX81 BASIC doesn't have anyway to "talk" to I/O ports. And I wanted it to be usable from BASIC.
I wasn't sure if the propeller would be fast enough, but with the right code, it handles it with no problem.
The ZX81 has it's ROM at address 0 to 8191, and it's RAM starts at 16384. So I memory mapped the propeller right at the 8K memory location.
Because I wanted to use as many of the propeller pin as possible for user I/O the module is only partially decode.
It only decodes A15,A14,A13 and A0 and A1. So the module's address repeats every 4 bytes between 8K and 16K, and I only have 4 address that I can read/write.
The base address is 8192,8193,8194, and 8195.
I also needed to connect the /WR /RD and /MREQ pins as well as the 8 data bits (D0 thru D7). So it takes a lot of pins to pull it off.
With only 4 memory address available, I took a "register" type approach to using the module.
I have reserved memory address 8195 for module status. Bit 7 is high when the module is busy.
The ZXGame module supports VGA, Sound, and Wii Classic Controllers