This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

Linux/TLV320AIC3105: tlv320aic3105 playback hangs

Part Number: TLV320AIC3105

Tool/software: Linux

Hi,

In my application, I use BeagleBone Green as host and have the customised audio cape using tlv320aic3105. I use TI processor SDK to modify the device tree am335x-bonegreen.dts and replace it in BeagleBone Green. I see that the sound card is set up as following:

**** List of PLAYBACK Hardware Devices ****

card 0: EVM [DA830 EVM], device 0: AIC3X tlv320aic3x-hifi-0 []

  Subdevices: 1/1

  Subdevice #0: subdevice #0

But, when I run a playback test, the test hangs. Below is the test result:

aplay /usr/share/sounds/alsa/Front_Center.wav

Playing WAVE '/usr/share/sounds/alsa/Front_Center.wav' : Signed 16 bit Little Endian, Rate 48000 Hz, Mono

There is one issue here: when I try to configure tlv320aic3105, I have to force to change the values of registers using i2cset -f -y, for example:

I2cset -f -y 2 0x18 0x00 0x00

I don't know what causes this issue, I am not sure if the playback hangs because of this issue.

Regards,

Bruce

 

 

  • Hi, Bruce,

    Unfortunately we don't have active Linux support, the only available Linux codes are mentioned in this post. My colleague in charge of the '3105 has been notified about your question, maybe he can could provide more information.

    Best Regards,

      -Diego Meléndez López
       Audio Applications Engineer

  • Thanks for your information.
    Bruce
     
  • Hi Diego,

    Thanks for sending me the link, but my question is why tlv320aic3105 is busy when probing using i2cdetect -r 0x18, it indicates that it is busy, I have to force to change the values of registers. Here is the device tree for supporting aic3105:

    mcasp0_pins_default: mcasp0_pins_default {
    pinctrl-single,pins = <

    0x190 ( PIN_OUTPUT | MUX_MODE0 ) /* refer to BBB audio cape*/
    0x194 ( PIN_OUTPUT | MUX_MODE0 )
    0x198 ( PIN_INPUT | MUX_MODE0 ) /* (D12) mcasp0_axr0.mcasp0_axr0 */
    0x19c ( PIN_OUTPUT | MUX_MODE2 ) /* (C12) mcasp0_ahclkr.mcasp0_axr2 */

    0x86c ( PIN_OUTPUT_PULLDOWN | MUX_MODE7) /* gpmc_a11.GPIO1_27 */

    >;
    };

    /* Optional sleep pin settings. Must manually enter values in the below skeleton. */
    mcasp0_pins_sleep: mcasp0_pins_sleep {
    pinctrl-single,pins = <
    0x190 ( PIN_INPUT_PULLDOWN | MUX_MODE7 ) /* (A13) mcasp0_aclkx.mcasp0_aclkx */
    0x194 ( PIN_INPUT_PULLDOWN | MUX_MODE7 ) /* (B13) mcasp0_fsx.mcasp0_fsx */
    0x198 ( PIN_INPUT_PULLDOWN | MUX_MODE7 ) /* (D12) mcasp0_axr0.mcasp0_axr0 */
    0x19c ( PIN_INPUT_PULLDOWN | MUX_MODE7 ) /* (C12) mcasp0_ahclkr.mcasp0_axr2 */

    0x86c ( PIN_INPUT_PULLDOWN | MUX_MODE7) /* gpmc_a11.GPIO1_27 */
    >;
    };


    i2c2_pins: pinmux_i2c2_pins {
    pinctrl-single,pins = <
    0x178 0x73
    0x17c 0x73
    /* 0x178 (PIN_INPUT_PULLUP | MUX_MODE3)*/ /* uart1_ctsn.i2c2_sda */
    /* 0x17c (PIN_INPUT_PULLUP | MUX_MODE3)*/ /* uart1_rtsn.i2c2_scl */
    >;
    };

    &i2c2 {
    pinctrl-names = "default";
    pinctrl-0 = <&i2c2_pins>;

    status = "okay";
    clock-frequency = <100000>;

    tlv320aic3x: tlv320aic3x@18 {
    compatible = "ti,tlv320aic3x";
    reg = <0x18>;
    status = "okay";
    };
    };

    &mcasp0 {
    pinctrl-names = "default", "sleep";
    pinctrl-0 = <&mcasp0_pins_default>;
    pinctrl-1 = <&mcasp0_pins_sleep>;
    status = "okay";

    op-mode = <0>; /* MCASP_IIS_MODE */
    tdm-slots = <2>;
    num-serializer = <16>;
    serial-dir = < /* 0: INACTIVE, 1: TX, 2: RX */
    0 2 1 0
    0 0 0 0
    0 0 0 0
    0 0 0 0
    >;
    tx-num-evt = <1>;
    rx-num-evt = <1>;
    };

    / {
    clk_mcasp0_fixed: clk_mcasp0_fixed {
    #clock-cells = <0>;
    compatible = "fixed-clock";
    clock-frequency = <24576000>;
    };

    clk_mcasp0: clk_mcasp0 {
    #clock-cells = <0>;
    compatible = "gpio-gate-clock";
    clocks = <&clk_mcasp0_fixed>;
    enable-gpios = <&gpio1 27 0>; /* change back, BG 05/10/17 */
    };

    sound {
    compatible = "ti,da830-evm-audio";
    ti,model = "DA830 EVM";
    ti,audio-codec = <&tlv320aic3x>;
    ti,mcasp-controller = <&mcasp0>;
    ti,audio-routing =
    "Headphone Jack", "HPLOUT",
    "Headphone Jack", "HPROUT";

    clocks = <&clk_mcasp0_fixed>;
    clock-names = "mclk";
    };

    I made those changes on am335x-bonegreen.dts and am335x-bone-common.dtsi, then compile them from TI processor SDK (ti-processor-sdk-linux-am335x-evm-03.02.00.05)

    I don't know where it goes wrong.


    Regards,
    Bruce
  • Hi, Bruce,

    Unfortunately, we are not providing support to linux drivers. All the information that we have about linux drivers is located in the link that my colleague provided.

    Best regards,
    Luis Fernando Rodríguez S.