Manual control of the internal speaker of the PC

Is there any way in any language (preferred C) for the PC internal speaker interface directly under Windows / Linux? (without DOS) I don’t want to control it with a certain frequency for a given duration (without a sound signal (frq, msecs)), but I prefer to send signals directly.

I assume this is a one-bit resolution, so I plan to use PWM driving to play the sound of the waves.

+3
source share
3 answers

On Linux, you probably want to make a kernel driver to control the speaker and provide, for example. a / dev to access it.

, , PCM Linux, ALSA. : http://lxr.linux.no/linux+v2.6.39/sound/drivers/pcsp/

, -, pscp_input.c: pcspkr_do_sound(...)

+3

, , ASM . pascal . , .

+1

Found this one from the wikipedia links for pc-speakers

may be useful :)

+1
source

All Articles