-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathSound.asm
More file actions
108 lines (102 loc) · 1.98 KB
/
Copy pathSound.asm
File metadata and controls
108 lines (102 loc) · 1.98 KB
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
Sound_PlaySound1
lda #VOICE_OFF
sta VCREG1
lda volume
sta SIDVOL
lda voice1Attack
asl
asl
asl
asl
ora voice1Decay
sta ATDCY1
lda voice1Sustain
asl
asl
asl
asl
ora voice1Release
sta SUREL1
lda voice1FreqL
sta FREL1
lda voice1FreqH
sta FREH1
lda voice1PulseL
sta PWL1
lda voice1PulseH
sta PWH1
ldx voice1Voice
lda voice1RingMod
asl
asl
ora tbl_VoiceTypeValue,x
sta VCREG1
rts
Sound_PlaySound2
lda #VOICE_OFF
sta VCREG2
lda volume
sta SIDVOL
lda voice2Attack
asl
asl
asl
asl
ora voice2Decay
sta ATDCY2
lda voice2Sustain
asl
asl
asl
asl
ora voice2Release
sta SUREL2
lda voice2FreqL
sta FREL2
lda voice2FreqH
sta FREH2
lda voice2PulseL
sta PWL2
lda voice2PulseH
sta PWH2
ldx voice2Voice
lda voice2RingMod
asl
asl
ora tbl_VoiceTypeValue,x
sta VCREG2
rts
Sound_PlaySound3
lda #VOICE_OFF
sta VCREG3
lda volume
sta SIDVOL
lda voice3Attack
asl
asl
asl
asl
ora voice3Decay
sta ATDCY3
lda voice3Sustain
asl
asl
asl
asl
ora voice3Release
sta SUREL3
lda voice3FreqL
sta FREL3
lda voice3FreqH
sta FREH3
lda voice3PulseL
sta PWL3
lda voice3PulseH
sta PWH3
ldx voice3Voice
lda voice3RingMod
asl
asl
ora tbl_VoiceTypeValue,x
sta VCREG3
rts