[alsa-devel] Writing a driver for Sound Card
Dear All,
I am new to this Advanced Linux Sound Architecture (ALSA) driver. I developed a few drivers in Linux kernel environment for PCI based devices which are of type character and block. I am going through the following link for writing a driver for my custom sound card.
http://www.kernel.org/pub/linux/kernel/people/tiwai/docs/writing-an-alsa-dri...
I have a doubt about the Linux sound driver architecture. I need to develop the driver with mixer, player, recorder, MIDI etc. components. Do I need to develop these components in single driver OR Do I need to develop as a individual component (one driver for one component).
I looked into the /usr/src/linux-2.6.35/sound directory. I did not understand it completely. Is there any driver (sample) which I can go through?
Please let me know.
Any help greatly appreciated and helpful to me.
Thanks and Regards, Srinivas G
Ramya Desai wrote:
I have a doubt about the Linux sound driver architecture. I need to develop the driver with mixer, player, recorder, MIDI etc. components. Do I need to develop these components in single driver OR Do I need to develop as a individual component (one driver for one component).
You can do this however you want; ALSA doesn't impose any restriction.
Many drivers choose put the code for different components in separate source files because the components are actually independent.
When a driver uses other modules, this is usually because that hardware is common for multiple sound cards (e.g., most MIDI interfaces are compatible with the Roland MPU-401).
I looked into the /usr/src/linux-2.6.35/sound directory. I did not understand it completely. Is there any driver (sample) which I can go through?
The basic driver structure is explained in the documentation; most of the additional code in drivers handles the quirks of actual hardware and would not be very helpful for you. Do you have any specific questions?
Please tell us more about the architecture of your hardware.
Regards, Clemens
participants (2)
-
Clemens Ladisch
-
Ramya Desai