medium attack (64) for a combined attack rate of 96, then add a
medium decay of 4 and. . . presto. . . POKE 54277,100.
At this point, a .sample program will better illustrate the effect. Type
the word NEW, hit .:~:lImu. and type in this program and RUN it:
5 FOR L=54272T054296:POKEL,0:NEXT ~
10 PRINT"HIT ANY KEY" ~
20 POKE54296, 15 ~
30 POKE54277,64 ~
40 POKES4273, 17:POKE54272,37~
60 GETK$:IFK$=""THEN60 ~
70 POKES4276,17:FORT=lT0200:NEXT~
S0 POKES4276, 16:FORT=lTOS0:NEXT ~
90 GOT020 ~
Duration the not. pia)".
Scr..n meuage.
Set AttocWDecay.
Poke on. note into VOICE 1.
Check the keyboard.
Set v.bveform comrol (triangle).
Turn off settings.
Loop back ond do it again.
Here, we're using VOICE 1 to create one note at a time . . . with a
MEDIUMATTACKRATEand ZERO DECAY.The key is Line 40. POKEing the
ATTACK/DECAYsetting with the number 64 activates a MEDIUMattack
rate. The result sounds like someone bouncing a ball in an oil drum.
Now for the fun part. Hit the I:Ullr"'III:I key to stop the program, then
type the word LISTand hit .:~IIIII:~I.. Now type this line and hit .:~IIIII:U.
(the new line 40 automatically replaces the old line 40):
40 POKE 54277,190
Type the word RUN and hit .:~IIIII~I. to see how it sounds. What we've
done here is combine several attack and decay settings. The settings
are: HIGH ATTACK(128) + LOW ATTACK(32)+ LOWESTATTACK(16)
+ HIGH DECAY(8) + MEDIUMDECAY(4)+ LOWDECAY(2)= 190.
This effect sounds like a sound an oboe or other "reedy" instrument
might make. If you'd like to experiment, try changing the waveform and
attack/decay numbers in the musical scale example to see how an
"oboe" sounds. Thus . . . you can see that changing the attack/decay
rates can be used to create different types of sound effects.
4. SUSTAIN/RELEASE SEnING-Like Attack/Decay, the SUSTAIN!
,
RELEASEsetting is activated by the ADSRiWAVEFORMControl. SUSTAINI
RELEASElets you "extend" (SUSTAIN)a portion of a particular sound, like
the "sustain pedal" on a piano or organ which lets you pr~long a note.
Any note or sound can be sustained at anyone of 16 levels. The
SUSTAIN!RELEASESetting may be used with a FOR. . . NEXT loop to
85