CPU-Z80-Disassembler

 view release on metacpan or  search on metacpan

t/data/zx81.asm  view on Meta::CPAN

                                ; 

; -----------------------
; THE 'INTERRUPT' RESTART
; -----------------------
;   The Mode 1 Interrupt routine is concerned solely with generating the central
;   television picture.
;   On the ZX81 interrupts are enabled only during the interrupt routine,
;   although the interrupt
;   This Interrupt Service Routine automatically disables interrupts at the
;   outset and the last interrupt in a cascade exits before the interrupts are
;   enabled.
;   There is no DI instruction in the ZX81 ROM.
;   An maskable interrupt is triggered when bit 6 of the Z80's Refresh register
;   changes from set to reset.
;   The Z80 will always be executing a HALT (NEWLINE) when the interrupt occurs.
;   A HALT instruction repeatedly executes NOPS but the seven lower bits
;   of the Refresh register are incremented each time as they are when any
;   simple instruction is executed. (The lower 7 bits are incremented twice for
;   a prefixed instruction)
;   This is controlled by the Sinclair Computer Logic Chip - manufactured from
;   a Ferranti Uncommitted Logic Array.
;
;   When a Mode 1 Interrupt occurs the Program Counter, which is the address in
;   the upper echo display following the NEWLINE/HALT instruction, goes on the
;   machine stack.  193 interrupts are required to generate the last part of
;   the 56th border line and then the 192 lines of the central TV picture and,
;   although each interrupt interrupts the previous one, there are no stack
;   problems as the 'return address' is discarded each time.
;
;   The scan line counter in C counts down from 8 to 1 within the generation of
;   each text line. For the first interrupt in a cascade the initial value of
;   C is set to 1 for the last border line.
;   Timing is of the utmost importance as the RH border, horizontal retrace
;   and LH border are mostly generated in the 58 clock cycles this routine
;   takes .

;; INTERRUPT

INTERRUPT:
        dec c                   ; (4)  decrement C - the scan line counter.
        jp nz, SCAN_LINE        ; (10/10) JUMP forward if not zero to SCAN-LINE

t/data/zx81.ctl  view on Meta::CPAN


0038:C
	:#; -----------------------
	:#; THE 'INTERRUPT' RESTART
	:#; -----------------------
	:#;   The Mode 1 Interrupt routine is concerned solely with generating the central
	:#;   television picture.
	:#;   On the ZX81 interrupts are enabled only during the interrupt routine, 
	:#;   although the interrupt 
	:#;   This Interrupt Service Routine automatically disables interrupts at the 
	:#;   outset and the last interrupt in a cascade exits before the interrupts are
	:#;   enabled.
	:#;   There is no DI instruction in the ZX81 ROM.
	:#;   An maskable interrupt is triggered when bit 6 of the Z80's Refresh register
	:#;   changes from set to reset.
	:#;   The Z80 will always be executing a HALT (NEWLINE) when the interrupt occurs.
	:#;   A HALT instruction repeatedly executes NOPS but the seven lower bits
	:#;   of the Refresh register are incremented each time as they are when any 
	:#;   simple instruction is executed. (The lower 7 bits are incremented twice for
	:#;   a prefixed instruction)
	:#;   This is controlled by the Sinclair Computer Logic Chip - manufactured from 
	:#;   a Ferranti Uncommitted Logic Array.
	:#;
	:#;   When a Mode 1 Interrupt occurs the Program Counter, which is the address in
	:#;   the upper echo display following the NEWLINE/HALT instruction, goes on the 
	:#;   machine stack.  193 interrupts are required to generate the last part of
	:#;   the 56th border line and then the 192 lines of the central TV picture and, 
	:#;   although each interrupt interrupts the previous one, there are no stack 
	:#;   problems as the 'return address' is discarded each time.
	:#;
	:#;   The scan line counter in C counts down from 8 to 1 within the generation of
	:#;   each text line. For the first interrupt in a cascade the initial value of 
	:#;   C is set to 1 for the last border line.
	:#;   Timing is of the utmost importance as the RH border, horizontal retrace
	:#;   and LH border are mostly generated in the 58 clock cycles this routine 
	:#;   takes .
	:#
	:#;; INTERRUPT
0038 0D         dec c	:C INTERRUPT
	:; (4)  decrement C - the scan line counter.

0039:C

t/data/zx81_version_2_rom_source.asm  view on Meta::CPAN

        JP      L1488           ; jump forward to continue at RESERVE.

; -----------------------
; THE 'INTERRUPT' RESTART
; -----------------------
;   The Mode 1 Interrupt routine is concerned solely with generating the central
;   television picture.
;   On the ZX81 interrupts are enabled only during the interrupt routine, 
;   although the interrupt 
;   This Interrupt Service Routine automatically disables interrupts at the 
;   outset and the last interrupt in a cascade exits before the interrupts are
;   enabled.
;   There is no DI instruction in the ZX81 ROM.
;   An maskable interrupt is triggered when bit 6 of the Z80's Refresh register
;   changes from set to reset.
;   The Z80 will always be executing a HALT (NEWLINE) when the interrupt occurs.
;   A HALT instruction repeatedly executes NOPS but the seven lower bits
;   of the Refresh register are incremented each time as they are when any 
;   simple instruction is executed. (The lower 7 bits are incremented twice for
;   a prefixed instruction)
;   This is controlled by the Sinclair Computer Logic Chip - manufactured from 
;   a Ferranti Uncommitted Logic Array.
;
;   When a Mode 1 Interrupt occurs the Program Counter, which is the address in
;   the upper echo display following the NEWLINE/HALT instruction, goes on the 
;   machine stack.  193 interrupts are required to generate the last part of
;   the 56th border line and then the 192 lines of the central TV picture and, 
;   although each interrupt interrupts the previous one, there are no stack 
;   problems as the 'return address' is discarded each time.
;
;   The scan line counter in C counts down from 8 to 1 within the generation of
;   each text line. For the first interrupt in a cascade the initial value of 
;   C is set to 1 for the last border line.
;   Timing is of the utmost importance as the RH border, horizontal retrace
;   and LH border are mostly generated in the 58 clock cycles this routine 
;   takes .

;; INTERRUPT
L0038:  DEC     C               ; (4)  decrement C - the scan line counter.
        JP      NZ,L0045        ; (10/10) JUMP forward if not zero to SCAN-LINE

        POP     HL              ; (10) point to start of next row in display 



( run in 0.504 second using v1.01-cache-2.11-cpan-49f99fa48dc )