1
0
mirror of https://github.com/cc65/cc65.git synced 2024-06-13 03:29:36 +00:00
cc65/asminc/pet.inc
Greg King 3c0b8c4e86 Made the CBM Pet kbrepeat() work on both 40-column and 80-column machines.
Put the kbrepeat() description in an alphabetical position in the function document.
2017-09-05 09:19:01 -04:00

69 lines
2.1 KiB
PHP

;
; PET generic definitions.
;
; ---------------------------------------------------------------------------
; Zero page, Commodore stuff
VARTAB := $2A ; Pointer to start of BASIC variables
MEMSIZE := $34 ; Size of memory installed
TXTPTR := $77 ; Pointer into BASIC source code
TIME := $8D ; 60HZ clock
KEY_COUNT := $9E ; Number of keys in input buffer
RVS := $9F ; Reverse flag
CURS_FLAG := $A7 ; 1 = cursor off
CURS_BLINK := $A8 ; Blink counter
CURS_CHAR := $A9 ; Character under the cursor
CURS_STATE := $AA ; Cursor blink state
SCREEN_PTR := $C4 ; Pointer to current char in text screen
CURS_X := $C6 ; Cursor column
FNLEN := $D1 ; Length of filename
LFN := $D2 ; Current Logical File Number
SECADR := $D3 ; Secondary address
DEVNUM := $D4 ; Device number
SCR_LINELEN := $D5 ; Screen line length
CURS_Y := $D8 ; Cursor row
FNADR := $DA ; Pointer to file name
; 80-Column CBMs
KBDREPEAT80 := $E4
KBDRPTRATE80 := $E5
KBDRPTDELAY80 := $E6
BASIC_BUF := $200 ; Location of command-line
BASIC_BUF_LEN = 81 ; Maximum length of command-line
KEY_BUF := $26F ; Keyboard buffer
; 40-Column PETs/CBMs
KBDRPTDELAY40 := $3E9
KBDRPTRATE40 := $3EA
KBDREPEAT40 := $3EE
KBDREPEAT40B := $3F8
;----------------------------------------------------------------------------
; PET ROM type detection
PET_DETECT := $FFFB
PET_2000 = $CA
PET_3000 = $FC
PET_4000 = $FD
;----------------------------------------------------------------------------
; Vector and other locations
IRQVec := $0090
BRKVec := $0092
NMIVec := $0094
; ---------------------------------------------------------------------------
; I/O: 6522 VIA2
VIA := $E840
VIA_PRB := $E840
VIA_PRA := $E841
VIA_DDRB := $E842
VIA_DDRA := $E843