05-05-2022, 06:10 PM
(05-05-2022, 04:42 PM)ejwords Wrote:(05-05-2022, 02:37 PM)Under4Mhz Wrote: Thanks, I can work around that.
Do you know what the bits are?
It seems bit 5 is vsync and bit 6 is the keyboard press?
Status register
bit 5 (Vertical Blanking) : 0 - Scan not in vertical Blanking area, 1 - scan currently in vertical blanking area.
bit 6 (LPEN Register Full ) : 0 - Bit goes to '0' whenever Register 16 or Register 17 is read : 1 - Bit goes to '1' whenever a LPEN strobe occurs
bit 7 (Update Ready) : 0 - Bit goes to '0' whenever Register 31 (dummy register) is read or written by the CPU
: 1 - Bit goes to '1' whenever an Update Strobe occurs
If you are writing your game for your own use, it is probably easier to connect up VSync to the PIO as mentioned above.
However, if you are writing your game for general distribution, you don't want people to have to do this modification just so they
can play the game. In this case, it would be better to find some other way of timing the game, or using polling somehow to use
detection of the blanking period for your timebase.
The CRTC status register needs to be polled and is slow.
Robotman polls the abovementioned register as not to generate black flicks on the display.
(i.e. screen updates in VBLANK period)
This hassle was caused when the Z80 CTC was dropped from the original microbee design.
(i.e. Z80 CTC at PORT04.)
If you've got a Alpha Plus and you don't want to mod your microbee, you can connect its VSYNC or HSYNC pin from the colour port to one of the serial port or tape inputs with a piece of wire leaving the User Port free for game controllers.
