-
Notifications
You must be signed in to change notification settings - Fork 0
/
Const.asm
102 lines (98 loc) · 2.11 KB
/
Const.asm
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
;************************************************************************
;* Costanti
;************************************************************************
;---------------------------------------------------
; Standard TV
NTSC = 0
PAL = 1
SECAM = 2
SYSTEM = PAL
;---------------------------------------------------
; NTSC
IF SYSTEM == NTSC
; Vertical Blank scan lines
VBlankSL = 37
; TV Picture scan lines
PictureSL = 192
; Overscan scan lines
OverSSL = 30
;---------------------------------------------------
; PAL
ELSE
IF SYSTEM == PAL
; Vertical Blank scan lines
VBlankSL = 45
; TV Picture scan lines
PictureSL = 228
; Overscan scan lines
OverSSL = 36
;---------------------------------------------------
; SECAM
ELSE
IF SYSTEM == SECAM
; Vertical Blank scan lines
VBlankSL = 45
; TV Picture scan lines
PictureSL = 228
; Overscan scan lines
OverSSL = 36
ELSE
ECHO "UNKNOWN TV SYSTEM"
ENDIF
ENDIF
ENDIF
; Vertical Blank TIM64T ticks
T64VBlank = VBlankSL * 76 / 64
; Overscan TIM64 ticks
T64OverS = OverSSL * 76 / 64
;---------------------------------------------------
; Colori
;---------------------------------------------------
; NTSC
IF SYSTEM == NTSC
Yellow = $1C
LightGray = $0C
DarkGray = $02
Gray = $04
Cyan = $AE
Green = $C8
Violet = $56
Red = $40
Blue = $84
Black = $00
DarkBlue = $80
White = $0E
DarkViolet = $60
ELSE
IF SYSTEM == PAL
Yellow = $2E
LightGray = $0E
DarkGray = $02
Gray = $04
Cyan = $7F
Green = $5A
Violet = $86
Red = $66
Blue = $D4
Black = $00
DarkBlue = $B0
White = $0E
DarkViolet = $A0
ELSE
IF SYSTEM == SECAM
Yellow = $0C
LightGray = $0E
DarkGray = $00
Gray = $00
Cyan = $0A
Green = $08
Violet = $06
Red = $04
Blue = $02
Black = $00
DarkBlue = $02
White = $0E
DarkViolet = $06
ENDIF
ENDIF
ENDIF