11.07.2015 Views

Here - 1000 BiT

Here - 1000 BiT

Here - 1000 BiT

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

INSTRUCTOR NOTES 29MUSICThis lesson continues the introduction of SID chip features with applications to making \^jmusic.Review the lesson on sound effects. DATA statements are used and may also need to bereviewed.We treat the ADSR parameters (attack, decay, sustain and release) in some detail. TheADSR parameters define a loudness envelope or contour for the duration of the note.^^Each parameter is one nybble in length and so two parameters can share one SID chip ^Jregister. A and D share one register, S and R share another.This is how it is done. A nybble is a number from 0 to 15. Memory is stored as bytes (anumber from 0 to 255). So each byte holds exactly two nybbles and can be represented as16*H + L where H is the high nybble and L is the low nybble. ^jThree of the ADSR parameters are times (A,D,R). The S, sustain, is a volume or loudness ^Jvalue. A table of time values for A,D, and R is given. Note that the time is not proportionalto the parameter value. A value of 5 gives an attack rise time of 0.056 seconds, but a ^value of 10 gives 0.5 seconds. A table of time values is included in the lesson. Times up to l,24 seconds are possible. Such long times are not useful in ordinary music but are usefulin sound effects. ^We refer the reader to the C-64 Programmer's Reference Guide for two of the mostadvanced features of SID: the programmable filter and the fact that voice 3 can be usedto control some feature of voices 1 and 2, for example the frequency, for vibratoor glissando. *,^SID can also accept audio from an external source (tape recorder, etc.), process it with uthe filter and add it to the internal sound. The output can be re-recorded, so you canbuild up a rich polyphonic piece in this way. ^QUESTIONS:1. What kind of sound will you get if you set the attack and decay each to the value 2, ^and sustain and release to 0?2. How do you store the pitch and length of each note of music in the program?3. How do you put the attack and decay numbers into the same POKE statement?4. How many voices does SID have? ^j5. How would you change the program to use voice 2 instead of voice 1? Would it sound Othe same?164

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!