;*************************************************
;	TIAPIA EQUATES
;*************************************************
;*** COLOR EQUATES
WHITE	=	$0F
BLACK	=	$0
GREY	=	$0F
GOLD	=	$1F
ORANGE	=	$2F
REDORG	=	$3F
PINK	=	$4F
PURPLE	=	$5F
PURPBLUE =	$6F
BLUE1	=	$7F
BLUE2	=	$8F
LTBLUE	=	$9F
TURQUOISE = 	$AF
GREENBLUE =	$BF
GREEN	=	$CF
YELLOWGREEN =	$DF
ORANGEGREEN =	$EF
LIGHTORG =	$FF


;GREY	=	$00
;GOLD	=	$01
;ORANGE	=	$02
;REDORG	=	$03
;PINK	=	$04
;PURPLE	=	$05
;PURPBLUE =	$06
;BLUE1	=	$07
;BLUE2	=	$08
;LTBLUE	=	$09
;TURQUOISE = 	$0A
;GREENBLUE =	$0B
;GREEN	=	$0C
;YELLOWGREEN =	$0D
;ORANGEGREEN =	$0E
;LIGHTORG =	$0F
;***************************************************
TIA	=	$00	;BASE ADDRESS FOR TIA CHIP
;**************************************************
;******* WRITE TIA REGISTORS ************
VSYNC	=	$00	;TURN VERTICAL SYNC ON/OFF
VBLANK	=	$01	;VERTICAL BLANK
WSYNC	=	$02	;WAIT FOR VERTICAL SYNC
RSYNC	=	$03	;RESET HORIZONTAL SYNC COUNTER
NUSIZ0	=	$04	;NUMBER AND SIZE OF PLAYER 0/MISSILE 0
NUSIZ1	=	$05	;NUMBER AND SIZE OF PLAYER 1/MISSILE 1
COLUP0	=	$06	;COLOR-LUM PLAYER 0
COLUP1	=	$07	;COLOR-LUM PLAYER1
COLUPF	=	$08	;COLOR-LUM PLAY FIELD
COLUBK	=	$09	;COLOR-LUM BACKGROUND
CTRLPF	=	$0A	;CONTROL PLAYFIELD BALL SIZE AND COLLISIONS
REFP0	=	$0B	;REFLECT PLAYER 0
REFP1	=	$0C	;REFLECT PLAYER1
PF0	=	$0D	;PLAYFEILD REGISTOR 0
PF1	=	$0E	;PLAYFIELD REGISTOR 1
PF2	=	$0F	;PLAYFILED REGISTOR 2
RESP0	=	$10	;RESET PLAYER 0
RESP1	=	$11	;RESET PLAYER1
RESM0	=	$12	;RESET MISSILE 0
RESM1	=	$13	;RESET MISSILE 1
RESBL	=	$14	;RERSET BALL
AUDC0	=	$15	;AUDIO CONTROL CHANNEL 0
AUDC1	=	$16	;AUDIO CONTROL CHANNEL 1
AUDF0	=	$17	;AUDIO FREQUENCY CHANNEL 0
AUDF1	=	$18	;AUDIO FREQUENCY CHANNEL 1
AUDV0	=	$19	;AUDIO VOLUME CHANNEL 0
AUDV1	=	$1A	;AUDIO VOLUME CHANNEL 1
GRP0	=	$1B	;GRAPHICS PLAYER 0
GRP1	=	$1C	;GRAPHICS PLAYER 1
ENAM0	=	$1D	;ENABLE MISILE 0
ENAM1	=	$1E	;ENABLE MISILE 1
ENABL	=	$1F	;ENABLE BALL
HMP0	=	$20	;HORIZANTAL MOTION PLAYER 0
HMP1	=	$21	;HORIZANTAL MOTION PLAYER 1
HMM0	=	$22	;HORIZANTAL MOTION MISSILE 0
HMM1	=	$23	;HORIZANTAL MOTION MISSILE 1
HMBL	=	$24	;HORIZANTAL MOTION BALL
VDELP0	=	$25	;VERTICAL DELAY PLAYER 0
VDELP1	=	$26	;VERTICAL DELAY PLAYER 1
VDELBL	=	$27	;VERTICAL DELAY BALL
RESMP0	=	$28	;RESET MISSILE 0 TO PLAYER 0
RESMP1	=	$29	;RESET MISSILE 1 TO PLAYER 1
HMOVE	=	$2A	;APPLY HORIZANTAL MOTION 
HMCLR	=	$2B	;CLEAR HORIZANTAL MOTION REGISTORS
CXCLR	=	$2C	;CLEAR COLLISION LATCHES
;*************** READ TIA REGISTORS *********************
CXM0P	=	$00	;READ COLLISION LATCHES MISSILE 0 AND PLAYERS
CXM1P	=	$01	;READ COLLISION LATCHES MISSILE 1 AND PLAYERS
CXP0FB	=	$02	;READ COLLISION LATCHES PLAYER 0 AND FORGROUND/BALL
CXP1FB	=	$03	;READ COLLISION LATCHES PLAYER 1 AND FORGROUND/BALL
CXM0FB	=	$04	;READ COLLISION LATCHES MISSILE 0 AND FORGROUND/BALL
CXM1FB	=	$05	;READ COLLISION LATCHES MISSILE 1 AND FORGROUND/BALL
CXPBLPF	=	$06	;READ COLLISION LATCHES BALL AND PLAYFEILD
CXPPPMM	=	$07	;READ COLLISION LATCHES PLAYERS AMD MISSILES
INPT0	=	$08	;PADDLE CONTROL INPUT 0
INPT1	=	$09	;PADDLE CONTROL INPUT 1
;100
INPT2	=	$0A	;PADDLE CONTROL INPUT 2
INPT3	=	$0B	;PADDLE CONTROL INPUT 3
INPT4	=	$0C	;PLAYER 0 FIRE BUTTON INPUT
INPT5	=	$0D	;PLAYER 1 FIRE BUTTON INPUT

;
;******************************************************************************
;
;
; PIA and TIMER (6532) locations
;

SWCHA	=	$0280	;player	and player 1 joysticks
CTLSWA	=	$0281	;I/O CONTROL FOR SWCHA

RESETBIT =	1	;bits for consle switches
SELECTBIT =	2
PAUSE	=	8
SWCHB	=	$0282	;console switches
CTLSWB	=	$0283	;I/O CONTROL FOR SWCHB
INTIM	=	$0284	;
TIMIT	=	$0294	;
TIM8T	=	$0295	;
TIM64T	=	$0296	;
T1024T	=	$0297	;
;*******************************************************************
; END OF TIA PIA EQUATES
;*******************************************************************
