Some Alsa SoC questions
Hello, I hope that this is the correct place to post.
I have a few questions about the Also SoC development.
I am trying to write a driver for ASoC that will connect an S3C2410 cpu to an AK4550 codec via an I2S bus.
The AK4550 codec appears to be completely unconfigurable, with no onboard registers (if I am wrong on this, please let me know. All the data sheets I have show no registers, which I find 'interesting'). All that should be required to get output from the codec is to power the module and send audio data via the I2S bus. To this end I've started with the ./s3c24xx/smdk2440.c file and ripped all the I2C control stuff out, and added code that powers the module via machine-specific GPIOs.
On the codec side I've started with the AK4535, and pulled out almost everything interesting. The AK4550 has two input pins which control a de-emphasis filter for when the codec does ADC conversions, but I don't really know what to do with them.
On to the questions:
1) Is the AK4550 codec really without registers like I think it is?
2) What is the best way to hook up the de-emphasis pins and expose them? I feel like I need generic functions in the codec to control them, and those generics should somehow hook to machine-specific functions. I don't know how to do this.
3) Am I basically on the right track here?
4) Does ASoC have a canonical repository that I should be pulling the latest code from?
5) Does ASoC have its own mailing list/IRC channel?
Thanks
Brad
-------------------------------------------------------------------------
Using Tomcat but need to do more? Need to support web services, security? Get stuff done quickly with pre-integrated technology to make your job easier. Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642
Quoted 1 line · Brad Beveridge
Hello, I hope that this is the correct place to post.
It is :)
Quoted 7 lines
I have a few questions about the Also SoC development.
I am trying to write a driver for ASoC that will connect an S3C2410 cpu to an AK4550 codec via an I2S bus.
The AK4550 codec appears to be completely unconfigurable, with no onboard registers (if I am wrong on this, please let me know. All the data sheets I have show no registers, which I find 'interesting').
I'm sorry, I can't really help with the AK4550 as I don't know anything about it.
Quoted 5 lines
All that should be required to get output from the codec is to power the module and send audio data via the I2S bus. To this end I've started with the
./s3c24xx/smdk2440.cfile and ripped all the I2C control stuff out, and added code that powers the module via machine-specific GPIOs.
Fwiw, the S3C24xx code works well. You may want to configure it as I2S master and see what happens when you apply power to the codec.
Quoted 5 lines
On the codec side I've started with the AK4535, and pulled out almost everything interesting. The AK4550 has two input pins which control a de-emphasis filter for when the codec does ADC conversions, but I don't really know what to do with them.
I would suggest contacting AKM for information on the input pins.
Quoted 7 lines
On to the questions:
1) Is the AK4550 codec really without registers like I think it is?
2) What is the best way to hook up the de-emphasis pins and expose them? I feel like I need generic functions in the codec to control them, and those generics should somehow hook to machine-specific functions. I don't know how to do this.
3) Am I basically on the right track here?
Please check 1,2 and 3 with AKM.
Quoted 2 lines
4) Does ASoC have a canonical repository that I should be pulling the latest code from?
It soon will. We are about a week or 2 away from hosting our git tree.
Snapshots are here atm :-
http://opensource.wolfsonmicro.com/~lg/asoc/
Quoted 1 line
5) Does ASoC have its own mailing list/IRC channel?
Mailing list is here (i.e. this list), although I'm not aware of any development IRC channel for alsa - this would probably be a good thing to have.....
Liam
-------------------------------------------------------------------------
Using Tomcat but need to do more? Need to support web services, security? Get stuff done quickly with pre-integrated technology to make your job easier. Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642
Quoted 18 lines · Liam Girdwood
Quoted 5 lines · Brad Beveridge
On the codec side I've started with the AK4535, and pulled out almost everything interesting. The AK4550 has two input pins which control a de-emphasis filter for when the codec does ADC conversions, but I don't really know what to do with them.
I would suggest contacting AKM for information on the input pins.
Quoted 7 lines
On to the questions:
1) Is the AK4550 codec really without registers like I think it is?
2) What is the best way to hook up the de-emphasis pins and expose them? I feel like I need generic functions in the codec to control them, and those generics should somehow hook to machine-specific functions. I don't know how to do this.
3) Am I basically on the right track here?
Quoted 1 line
Please check 1,2 and 3 with AKM.
Hi, and thanks for the quick reply.
I think I spoke imprecisely with regard to #2. I know how the de-emphasis pins are physically hooked up to the SA2410, they are just GPIOs. What I am unsure about is exactly how to expose control of these GPIOs. My thoughts are that control of these pins is somewhat analogous to reading/writing registers on a codec, and so therefore the codec driver should expose an interface to the outside world that lets you turn on/off the de-emphasis input filter. To actually configure the pins, the codec needs to call out to functions in the machine-specific driver - analogous to the hw_read/hw_write functions.
Hmm, using these functions may actually be the correct thing to do in
this case. If they are the correct way to access machine specific stuff, do I just setup the hw_read/write pointers in my machine_codec_init function? (ie the function smdk2440_uda1341_init in smdk2440.c).
Quoted 5 lines
Quoted 3 lines
4) Does ASoC have a canonical repository that I should be pulling the latest code from?
It soon will. We are about a week or 2 away from hosting our git tree.
Cool, that'll me nice.
Thanks again,
Brad
-------------------------------------------------------------------------
Using Tomcat but need to do more? Need to support web services, security? Get stuff done quickly with pre-integrated technology to make your job easier. Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642
Quoted 19 lines · Brad Beveridge
Quoted 18 lines · Liam Girdwood
Quoted 5 lines · Brad Beveridge
On the codec side I've started with the AK4535, and pulled out almost everything interesting. The AK4550 has two input pins which control a de-emphasis filter for when the codec does ADC conversions, but I don't really know what to do with them.
I would suggest contacting AKM for information on the input pins.
Quoted 7 lines
On to the questions:
1) Is the AK4550 codec really without registers like I think it is?
2) What is the best way to hook up the de-emphasis pins and expose them? I feel like I need generic functions in the codec to control them, and those generics should somehow hook to machine-specific functions. I don't know how to do this.
3) Am I basically on the right track here?
Quoted 6 lines
Quoted 1 line
Please check 1,2 and 3 with AKM.
Hi, and thanks for the quick reply.
I think I spoke imprecisely with regard to #2. I know how the de-emphasis pins are physically hooked up to the SA2410, they are just GPIOs. What I am unsure about is exactly how to expose control of these GPIOs.
I see now, I thought you were asking what they should be routed to in the schematics.
Quoted 12 lines
My thoughts are that control of these pins is somewhat
analogous to reading/writing registers on a codec, and so therefore the codec driver should expose an interface to the outside world that lets you turn on/off the de-emphasis input filter. To actually configure the pins, the codec needs to call out to functions in the machine-specific driver - analogous to the hw_read/hw_write functions.
Hmm, using these functions may actually be the correct thing to do in
this case. If they are the correct way to access machine specific stuff, do I just setup the hw_read/write pointers in mymachine_codec_initfunction? (ie the functionsmdk2440_uda1341_initinsmdk2440.c).
I would probably create a mixer kcontrol in your machine driver for the deemphasis. I know it's technically codec specific, but the hardware control method is very machine specific.
I would also probably stick a comment in you codec driver stating this. Anyone then creating a new machine driver for this codec can then copy and modify your original kcontrol.
Liam
-------------------------------------------------------------------------
Using Tomcat but need to do more? Need to support web services, security? Get stuff done quickly with pre-integrated technology to make your job easier. Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642