Skip to content

Lab 6: AC97-lite PCM audio ​

Generated folder: labs/audio/

Lab 6 introduces audio as a stream of samples. You fill an audio buffer with PCM data and ask the runtime to play it.

The analogy with graphics helps. A framebuffer becomes an image; an audio buffer becomes pressure changes in the air. In both cases the device consumes bytes in a format, and the program must produce those bytes consistently.

ConceptMeaning
PCM samplenumeric amplitude at one point in time
sample ratesamples per second
channel countmono or stereo layout
buffermapped memory for samples
byte countamount the device should consume

Learn PCM audio, complete the tasks, run the checks, and compare with modern audio stacks.

TIP

Audio bugs are often unit bugs: samples, frames, channels, and bytes are not interchangeable.

Course/docs licensed CC BY 4.0. Code licensed MIT.