Hello,
I'm trying to use the AIC3254 with the OMAPL138 Logic PD SOM.
The codec is connected to the OMAP with I2C and McASP. I'm using it with Linux 2.6.33 / Alsa on the GPP side. DSP BIOS 5 is running on the DSP side.
Playing audio works fine, but if I try to use the codec after I've started the DSP application the I2C bus crashes. The Linux I2C driver reports that the wait_for_completion_interruptible_timeout call in i2c_davinci_xfer_msg function has timed out. It tries to recover the bus but can't.
If do then following steps:
Start audio playback (issues I2C write commands to configure the codec)
Start DSP
Stop DSP
Stop audio (issues I2C write commands)
The I2C bus does not become locked, but it will if I start another audio playback.
Waiting for some time between these steps doesn't make any difference.
I tracked the responsible I2C call down to the aic3254_hw_params function, when the value 6 is written to register 30 of the codec (it powers the BCLK divider down). When this occurs, the i2c driver in linux receives the "Transmit-data-ready interrupt", but the "Stop condition detected interrupt" isn't triggered, so I2C request times out.
I tried to comment the aic3254_write call, a I2C crash still occurs a few write after. However if I try to read the register value before writing it, it looks like the I2C bus crashes during the read operation.
While searching on these forums I found some topics talking about I2C and deactivating V/F scaling, but setting bios.PWRM.SCALING = 0 doesn't change anything.
If I disable power management (bios.PWRM.ENABLE = 0) in DSPBIOS, then the codec works fine. However I need to use UPP, but it doesn't work anymore, probably because it is not being powered up. I couldn't find out how to use the UPP bus without PWRM enabled, but if you could tell me how, that would be good enough.
Regards,
Pep