EasyManua.ls Logo

Commodore 128 - The Sound Statement

Commodore 128
448 pages
Print Icon
To Next Page IconTo Next Page
To Next Page IconTo Next Page
To Previous Page IconTo Previous Page
To Previous Page IconTo Previous Page
Loading...
THE SOUND STATEMENT
The SOUND statement is designed primarily for quick and easy
sound effects in your programs. You will learn a more intricate
way of playing complete musical arrangements with the other
sound statements later in this section.
The format for the SOUND statement is as follows:
SOUND VC, FREQ, DUR[, DIR[, MIN[, SV[, WF[, PW]]]]]
Here’s what the parameters mean:
VC Select VoiCe 1, 2 or 3
FREQ Set the FREQuency level of sound (0-65535)
DUR Set DURation of the sound (in sixtieths of a
second)
DIR Set the DIRection in which the sound is
incremented/decremented
0 = Increment the frequency upward
1 = Decrement the frequency downward
2 = Oscillate the frequency up and down
MIN Select the MINimum frequency (0-65535) if the
sweep (DIR) is specified
SV Choose the Step Value for the sweep (0-32767)
WF Select the WaveForm (0-3)
0 = Triangle
1 = Sawtooth
2 = Variable Pulse (Square)
3 = White Noise
PW Set the Pulse Width, the width of the variable
pulse waveform
Note that the DIR, MIN, SV, WF and PW parameters are optional.
7-4

Table of Contents

Other manuals for Commodore 128

Related product manuals