Investigating a headphone driver for RPI

Michael Zoran mzoran at crowfest.net
Sat Mar 4 07:13:17 PST 2017


	I'm doing some investigation into potentially making a
headphone audio driver for the Raspberry PI that doesn't use the
firmware.  The idea is to use the PWM hardware that the RPI has to
generate the audio.

	A soc driver in concept should be easy enough, and I'm trying
to modify the HDMI driver that was submitted earlier.   The only issue
is that to drive the PWM, the format of of the audio needs to be rather
exotic(12 bit unsigned 48KHz, or 8 bit unsigned 960KHz).  

	I'm having massive issues getting a ASoc driver to work with
these formats.   I either get issues that the codec and cpu driver
can't agree on the format(The codec is a fake codec that doesn't do
anything), or the DMA engine errors out with error -22.

Questions:

	1. I like the ASoc concept, but I'm wondering if perhaps a
regular ALSA driver would be better here.  A regular ALSA driver would
be like 10x the lines of code, but I would have much more flexibility
to do SOME signal conditioning in the driver itself and could report as
supporting a S16_LE format which everything works with.

	2. Are regular ALSA drivers still being accepted for SBC like
the RPI, or is ASoc mandatory?

	Thanks.	 



More information about the linux-rpi-kernel mailing list