samedi 7 février 2015

Write a program that tells soundcard directly to play a simple signal?

To be written in C.


I know that for Linux there are several libraries that could be used to do this much more easily; I'm doing this completely as a learning exercise.


I want to avoid Alsa and Jack, etc. altogether; i.e., pretend they don't exist. What are the steps involved? How do I connect to my sound card's driver? How do I discover how to "talk to" it so that it will play a simple signal (a sine wave) through the computer's loudspeakers? What does it expect to hear from me?


Some thoughts I had that may or may not be correct:



  1. determine the type of soundcard I have

  2. find the driver documentation (or the code itself)

  3. study and #include the driver's header

  4. write code that produces a sine wave at 440Hz/half-maximum amplitude

  5. be done


Aucun commentaire:

Enregistrer un commentaire