LCD screen for the ZX81
This is quite the greatest and biggest extension for the ZX81 I ever designed. It is not only a substitute of monitor or TV, it also gives you an additional control panel and a set of functions, the ZX81 never had.
Firstly the LCD has to work without any support from the ZX81. This means, the interface must only be plugged in and has to display the ZX81 screen. Only this way it will be compatible with all programs and does not influence the ZX81 anyway. It's not easy to get access to the ZX81 screen (DFILE) out from the ZX81. All experiments with using the /BUSRQ failed. So I decided to mirror the whole Basic-RAM and access this "Dual-RAM". It worked!
The LCD interface is an outstanding Z80 computer for itselfes. Therefore, the access to the Dual-RAM must be synchronized, that no collisions can occur. I solved it this way: any write access from the ZX81 to his Basic-RAM has first priority. Read access of the ZX81 to the Dual-RAM is not needed and does therefore not exist. In any critical access, when the ZX81 wants to write and the LCD wants to read, the interface CPU recieves WAIT-states. Because the interface is running with 8 MHz CPU clock there is enough time, to access to the Dual-RAM when the ZX81 CPU is in the Refresh cycle.
Now you have a copy of the whole Basic-RAM space which you may access from out the ZX81 and without any influence to the ZX81! The interface now has to convert the characters of the ZX screen into the LCD-specific pixel-format.
Driving the display:
Therefore the interface has an additional RAM for the complete pixelscreen. Output of a pixelline to the LCD screen is similar to the video of the ZX81: a NMI routine which ends with a JP (HL), where HL is above 8000hex and A15 is high and M1 is low. This sets a logic, the CPU now only recieves NOP instructions and counts up the addresses. In this cycles the pixel data from the RAM will be separated and taken to the LCD screen. At the end of each line an INT is generated to set the end-of-line clock to the LCD and to reset a counter. This counter then sets the next NMI after a selectable time, i.e. after 256 CPU clocks.
The LCD has 240 lines, the ZX screen only needs 192 lines. So there is space for 6 charakter lines below the regular screen! In this space is displayed, that the ZX runs in SLOW or FAST (YES! you have a screen on the LCD even the ZX runs in FAST!) and the memory left.
And you may also transfer programs from the ZX81 (located in a REM line) into the LCD. So you can move a completely different operating system to the LCD. For this I have a program, which, once moved to the LCD, then displays the whole set of system variables and not the regular screen. With this feature you also can monitor the variables or what ever you want.
This is only a very short description of the LCD interface. I hope I have the time now, to finish a detailed description in English. Meanwhile I look forward to your response, maybe a large response will accelerate my work!
Kai Fischer, ZX-TEAM