aboutsummaryrefslogtreecommitdiff
path: root/vcs.h
blob: dbddf057b34a92804e88b45b7aabddc2add14299 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
;
; VCS system equates
;
; Vertical blank registers
;
VSYNC   =  $00
;VS_Enable = 2
;
VBLANK  =  $01
;VB_Enable      = 2
;VB_Disable     = 0
;VB_LatchEnable = 64
;VB_LatchDisable = 0
;VB_DumpPots    = 128
; I don't know a good name to un-dump the pots,
; at least that makes sense.

WSYNC   =  $02
RSYNC   =  $03   ;for sadists
;
; Size registers for players and missiles
;
NUSIZ0  =  $04
NUSIZ1  =  $05
;P_Single      = 0
;P_TwoClose    = 1
;P_TwoMedium   = 2
;P_ThreeClose  = 3
;P_TwoFar      = 4
;P_Double      = 5
;P_ThreeMedium = 6
;P_Quad        = 7

;M_Single      = $00
;M_Double      = $10
;M_Quad        = $20
;M_Oct         = $40

;
; Color registers
;
COLUP0  =  $06
COLUP1  =  $07
COLUPF  =  $08
COLUBK  =  $09

;
; Playfield Control
;
CTRLPF  =  $0A
;PF_Reflect  = $01
;PF_Score    = $02 
;PF_Priority = $04
; Use missile equates to set ball width.

REFP0   =  $0B
REFP1   =  $0C
;P_Reflect = $08

PF0     =  $0D
PF1     =  $0E
PF2     =  $0F
RESP0   =  $10
RESP1   =  $11
RESM0   =  $12
RESM1   =  $13
RESBL   =  $14
AUDC0   =  $15
AUDC1   =  $16
AUDF0   =  $17
AUDF1   =  $18
AUDV0   =  $19
AUDV1   =  $1A  ;duh

;
; Players
;
GRP0    =  $1B
GRP1    =  $1C

;
; Single-bit objects
;
ENAM0   =  $1D
ENAM1   =  $1E
ENABL   =  $1F
;M_Enable = 2

HMP0    =  $20
HMP1    =  $21
HMM0    =  $22
HMM1    =  $23
HMBL    =  $24

; Miscellaneous
VDELP0  =  $25
VDEL01  =  $26
VDELP1  =  $26
VDELBL  =  $27
RESMP0  =  $28
RESMP1  =  $29
HMOVE   =  $2A
HMCLR   =  $2B
CXCLR   =  $2C
CXM0P   =  $30
CXM1P   =  $31
CXP0FB  =  $32
CXP1FB  =  $33
CXM0FB  =  $34
CXM1FB  =  $35
CXBLPF  =  $36
CXPPMM  =  $37
INPT0   =  $38
INPT1   =  $39
INPT2   =  $3A
INPT3   =  $3B
INPT4   =  $3C
INPT5   =  $3D

;
; Switch A equates.
;
; There are more elegant ways than using all eight of these.  :-)
;
SWCHA   =  $0280
;J0_Right = $80
;J0_Left  = $40
;J0_Down  = $20
;J0_Up    = $10
;J1_Right = $08
;J1_Left  = $04
;J1_Down  = $02
;J1_up    = $01
;
; Switch B equates
;
SWCHB   =  $0282
;P0_Diff = $80
;P1_Diff = $40
;Con_Color  = $08
;Con_Select = $02
;Con_Start  = $01

;
; Switch Control
;
SWACNT = $281
SWBCNT = $283

;
; Timer
;
INTIM   =  $0284
TIM1T   =  $0294
TIM8T   =  $0295
TIM64T  =  $0296
TIM1024T = $0297