Commodore 64 User Manual page 97

Hide thumbs Also See for 64:
Table of Contents

Advertisement

Commodore 64's eight octave range. The HIGH and LOW FREQUENCY
POKE COMMANDS are different for each VOICE you use-this allows
you to program all 3 voices independently to create 3-voice music or
exotic sound effects.
The HIGH and LOW FREQUENCY POKE COMMANDS for each voice
are shown in the chart below, which also contains the NOTE VALUES for
the middle (fifth) octave.
VOICE NUMBER POKE
SAMPLE MUSICAL NOTES -FIFTH OCTAVE
& FREQUENCY NUMBER
C
C#
D
D#
E
F
F#
G G#
A A#
B
C C#
VOICEI/HIGH
54273
34
36
38
40
43
45
48
51
54
57
61
64
68
72
VOICEI/LOW
54272
75
85 126 200
52 198 127
97, 111 172 126 188 149 169
VOICE2/HIGH
54280
34
36
3
440
43
45
48
51
54
57
61
64
68
72
VOICE2/LOW
54279
75
85 126 200
52 198 127
97 111 172 126 188 149 169
VOICE3/HIGH 54287
34
36 38
40
43 45
48
51
54
57
61
64
68
72
VOICE3/LOW 54286
75
85 126 200
52 198 127
97 111 172 126 188 149 169
As you can see, there are 2 settings for each voice, a HIGH FRE-
QUENCY setting and a LOW FREQUENCY setting. To play a musical note,
you must POKE a value into the HIGH FREQUENCY location and POKE
another value into the LOW FREQUENCY location. Using the settings in
our VOICE/FREQUENCY/NOTE VALUE table, here's the setting that plays
a C note from the 5th octave (VOICED:
POKE 54273,34:POKE 54272,75.
The same note on VOICE2 would be:
POKE 54280,34:POKE 54279,75.
Used in a program, it looks like this:
5 FORL=54272TO54296:POKE L,O:NEXT
10 V=54296:W=54276:A=54277:
Set numbers equal to letters.
S=54278:H =54273:L=54272
20 POKEV,15:POKEA,190:POKES, 89
^- POKE
.oIume,
woveform , ottac
k/de<ay.
30 POKEH,34:POKEL,75
POKE hi/lo freq. notes
40 POKEW,33:FORT=1TO200:NEXTstart note, let it play
50 POKEW,32 ( stop note
87

Hide quick links:

Advertisement

Table of Contents
loading

Related Products for Commodore 64

Table of Contents