| Routines

08020: THE 'BREAK-KEY' SUBROUTINE

Used by the routines at COPY_LINE and STMT_RET. This subroutine is called in several instances to read the BREAK key. The carry flag is returned reset only if the SHIFT and the BREAK keys are both being pressed.
BREAK_KEY | 08020 | LD A,127 | Form the port address 32766 and read in a byte.
| 08022 | IN A,(254)
| 08024 | RRA | Examine only bit 0 by shifting it into the carry position.
| 08025 | RET C | Return if the BREAK key is not being pressed.
| 08026 | LD A,254 | Form the port address 65278 and read in a byte.
| 08028 | IN A,(254)
| 08030 | RRA | Again examine bit 0.
| 08031 | RET | Return with carry reset if both keys are being pressed.