Other Parts Discussed in Thread: TLV320AIC3104
Tool/software: Linux
Hi all,
I am using beagle bone black with kernel 4.4.41-rt50-g968d071ce9. (am335x-evm-linux-rt-sdk-src-03.03.00.04.tar.tar package)
I want to run audio subsystem with the tlv320aic3104 codec.
My goal is to use internal clock for MCLK ( instead of externall clock provided by oscillator) and the codec become master.
I edited the base dts and added the proper nodes for configuring audio subsystem.
But when i run speaker-test utility, it gets follows error:
Write error: -5,input/output error
xrun_recovery failed: -5 input/output error
Transfer failed: input/output error
also I have no signal on the ahclkx pin.
where is the source of the problem?
here is my dts file:
/* * Copyright (C) 2012 Texas Instruments Incorporated - http://www.ti.com/ * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License version 2 as * published by the Free Software Foundation. */ /dts-v1/; #include "am33xx.dtsi" #include "am33xx-es2.dtsi" #include "am335x-bone-common.dtsi" #include <dt-bindings/board/am335x-bbw-bbb-base.h> #include <dt-bindings/pinctrl/am33xx.h> / { model = "TI AM335x BeagleBone Black"; compatible = "ti,am335x-bone-black", "ti,am335x-bone", "ti,am33xx"; sound { compatible = "simple-audio-card"; simple-audio-card,name = "AudioCape Rev B"; simple-audio-card,widgets = "Headphone", "Headphone Jack", "Line", "Line In"; simple-audio-card,routing = "Headphone Jack", "HPLOUT", "Headphone Jack", "HPROUT", "LINE1L", "Line In", "LINE1R", "Line In"; simple-audio-card,format = "dsp_b"; simple-audio-card,bitclock-master = <&sound_master>; simple-audio-card,frame-master = <&sound_master>; simple-audio-card,bitclock-inversion; simple-audio-card,cpu { sound-dai = <&mcasp0>; }; sound_master: simple-audio-card,codec { #sound-dai-cells = <0>; sound-dai = <&tlv320aic3104>; system-clock-frequency = <24576000>; }; }; }; &ldo3_reg { regulator-min-microvolt = <1800000>; regulator-max-microvolt = <1800000>; regulator-always-on; }; &mmc1 { vmmc-supply = <&vmmcsd_fixed>; }; &mmc2 { vmmc-supply = <&vmmcsd_fixed>; pinctrl-names = "default"; pinctrl-0 = <&emmc_pins>; bus-width = <8>; status = "okay"; }; &am33xx_pinmux { bone_audio_cape_audio_pins: pinmux_bone_audio_cape_audio_pins { pinctrl-single,pins = < 0x190 (PIN_INPUT_PULLDOWN | MUX_MODE0) /* mcasp0_aclkx.mcasp0_aclkx */ 0x194 (PIN_INPUT_PULLDOWN | MUX_MODE0) /* mcasp0_fsx.mcasp0_fsx, INPUT */ 0x198 (PIN_INPUT_PULLDOWN | MUX_MODE0) /* mcasp0_axr0.mcasp0_axr0 */ 0x19c (PIN_INPUT_PULLDOWN | MUX_MODE2) /* mcasp0_ahclkr.mcasp0_axr2 */ 0x1ac (PIN_INPUT_PULLDOWN | MUX_MODE0) /* MCASP0_AHCLKX -> MCASP0_AHCLKX (I2S_MCLK_OUT)- in */ >; }; i2c2_pins: pinmux_i2c2_pins { pinctrl-single,pins = < /* P9_20: uart1_ctsn.i2c2_sda */ BONE_P9_20 (SLEWCTRL_SLOW | PIN_INPUT_PULLUP | MUX_MODE3) /* P9_19: uart1_rtsn.i2c2_scl */ BONE_P9_19 (SLEWCTRL_SLOW | PIN_INPUT_PULLUP | MUX_MODE3) >; }; }; &i2c2 { #address-cells = <1>; #size-cells = <0>; clock-frequency = <100000>; status = "okay"; pinctrl-names = "default"; pinctrl-0 = <&i2c2_pins>; tlv320aic3104: tlv320aic3104@18 { #sound-dai-cells = <0>; compatible = "ti,tlv320aic3104"; reg = <0x18>; }; }; &mcasp0 { #sound-dai-cells = <0>; pinctrl-names = "default"; pinctrl-0 = <&bone_audio_cape_audio_pins>; status = "okay"; op-mode = <0>; /* MCASP_IIS_MODE */ tdm-slots = <2>; num-serializer = <16>; serial-dir = < /* 0: INACTIVE, 1: TX, 2: RX */ 2 0 1 0 0 0 0 0 0 0 0 0 0 0 0 0 >; tx-num-evt = <1>; rx-num-evt = <1>; };