(third day, third attempt to send this, apologies if the other
attempts arrive too and spam the list, but since the replies from
other lists are reaching this list I thought it better I keep trying
or the conversation would seem rather one sided)
It's been a while since I last posted something. Here is the latest
version of my code. It is somewhat of a mess at the moment, but I plan
to tidy it all up when it works better, any // comments are not
permanent features. I have been using trial and error to find why it
play too fast.
I am glad to say that it does play sound correctly, bar one little
issue that has me stuck at the moment, it plays too fast (for any
sample frequency). Also how fast appears to depend on the player
(tried aplay and ogg123).
I have cc the ALSA dev too in the hope that between the two lists
someone may spot something. Please can anyone who replies cc me.
The patch was built against (applies to) linux-220.127.116.11 from
linux-mips.org. It'll probably work on other versions.
Notes on the module it self...
There are two code 'paths' depending on sma_indirect=1|0, this var
will be made a module load argument. When 0 ALSA will be writing
directly to the MACE ring buffer, currently the state of this code is
believed very broken I have not been working on it for a while. When 1
ALSA will be writing to a bounce buffer and the module will copy data
to the ring buffer as per the original driver.
Currently sma_indirect is hard coded 1 and it is this 'path' i'm
currently interested in fixing.
The module has some proc files for debugging, the contents of the
ad1843 regs, and for values in in mace. There is a _spy version of the
module (which wont exist in my final patch) that provides just these
proc files without making any (init) changes to any of the hardware
(ie read only). This allowed me to see what state the O2 jingle left
the various bit in.
The module has a limited mixer, which I want to do a lot more with in
future, and the front volume buttons are supported.
DAC1/ADC map to dev0 on the card, while DAC2 maps to dev1.
I don't know what else to say, please have a listen and a look. It
will play any samples 8k to 48k, and any bit format that ALSA knows
Description: Text Data