Hi!
For a pilot project i'm trying to interfacing my Beaglebone Black with the AIC320TLV3206 codec mounted on USB evalutation board.
I phisically removed the TAS1020 chip and the EPROM, then i connected Beaglebone pins to AIC320 board according to this schema
This is the picture about how they're connected:
I loaded a dtbo generated from this dts
/* * 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/; /plugin/; / { compatible = "ti,beaglebone", "ti,beaglebone-black"; /* identification */ part-number = "BB-BONE-AUDI-02"; version = "00A0", "A0"; /* state the resources this cape uses */ exclusive-use = /* the pin header uses */ "P9.31", /* mcasp0: mcasp0_aclkx */ "P9.29", /* mcasp0: mcasp0_fsx */ "P9.28", /* mcasp0: mcasp0_axr2 */ "P9.25", /* mcasp0: mcasp0_ahclkx */ /* the hardware ip uses */ "gpio1_18", "gpio1_19", "mcasp0"; fragment@0 { target = <&am33xx_pinmux>; __overlay__ { i2c2_pins: pinmux_i2c2_pins { pinctrl-single,pins = < 0x150 0x72 /*spi0_scl.i2c2_sda,SLEWCTRL_SLOW | INPUT_PULLUP |MODE2*/ 0x154 0x72 /*spi0_d0.i2c2_scl,SLEWCTRL_SLOW | INPUT_PULLUP | MODE2*/ >; }; bone_audio_cape_audio_pins: pinmux_bone_audio_cape_audio_pins { pinctrl-single,pins = < 0x1ac 0x00 /* mcasp0_ahclkx, MODE0 | INPUT */ 0x19c 0x22 /* mcasp0_ahclkr, */ 0x194 0x20 /* mcasp0_fsx, MODE0 | OUTPUT */ 0x190 0x20 /* mcasp0_aclkr.mcasp0_aclkx, MODE0 | OUTPUT_PULLDOWN */ 0x198 0x20 >; }; }; }; fragment@1 { target = <&i2c2>; __overlay__ { #address-cells = <1>; #size-cells = <0>; clock-frequency = <100000>; status = "okay"; pinctrl-names = "default"; pinctrl-0 = <&i2c2_pins>; tlv320aic3x: tlv320aic3x@18 { compatible = "ti,tlv320aic3x"; reg = <0x18>; status = "okay"; }; }; }; fragment@2 { target = <&mcasp0>; __overlay__ { 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>; }; }; fragment@3 { target = <&ocp>; __overlay__ { sound { compatible = "ti,da830-evm-audio"; ti,model = "DA830 EVM"; ti,audio-codec = <&tlv320aic3x>; ti,mcasp-controller = <&mcasp0>; ti,codec-clock-rate = <12000000>; ti,audio-routing = "Headphone Jack", "HPLOUT", "Headphone Jack", "HPROUT", "LINE1L", "Line In", "LINE1R", "Line In"; }; }; }; };
Obviously HDMI and HDMIN are not loaded during startup to keep the above pins free to be used by the codec interface.
Result: I2C bus is setup correctly, i can write and read the chip registers (while DTBO is not loaded) and the audio card appears when the DTBO is loaded.
[ 3513.934952] bone-capemgr bone_capemgr.9: part_number 'BB-BONE-AUDI-02', version 'N/A' [ 3513.935138] bone-capemgr bone_capemgr.9: slot #9: generic override [ 3513.935188] bone-capemgr bone_capemgr.9: bone: Using override eeprom data at slot 9 [ 3513.935240] bone-capemgr bone_capemgr.9: slot #9: 'Override Board Name,00A0,Override Manuf,BB-BONE-AUDI-02' [ 3513.935548] bone-capemgr bone_capemgr.9: slot #9: Requesting part number/version based 'BB-BONE-AUDI-02-00A0.dtbo [ 3513.935602] bone-capemgr bone_capemgr.9: slot #9: Requesting firmware 'BB-BONE-AUDI-02-00A0.dtbo' for board-name 'Override Board Name', version '00A0' [ 3513.941180] bone-capemgr bone_capemgr.9: slot #9: dtbo 'BB-BONE-AUDI-02-00A0.dtbo' loaded; converting to live tree [ 3513.943677] bone-capemgr bone_capemgr.9: slot #9: #4 overlays [ 3513.969706] of_get_named_gpio_flags: can't parse gpios property [ 3513.979851] 1-0018 supply IOVDD not found, using dummy regulator [ 3513.980096] 1-0018 supply DVDD not found, using dummy regulator [ 3513.980259] 1-0018 supply AVDD not found, using dummy regulator [ 3513.980442] 1-0018 supply DRVDD not found, using dummy regulator [ 3514.002711] davinci_evm sound.13: tlv320aic3x-hifi <-> 48038000.mcasp mapping ok [ 3514.033187] bone-capemgr bone_capemgr.9: slot #9: Applied #4 overlays.
arecord -l **** List of CAPTURE Hardware Devices **** card 0: EVM [DA830 EVM], device 0: AIC3X tlv320aic3x-hifi-0 [] Subdevices: 1/1 Subdevice #0: subdevice #0
Unfortunally i can't get any audio when i run this command
arecord -r 44100 -c 1 -f S16_LE -t wav -vv -d 25 /tmp/example.wav
looks like nothing is sent through the I2S interface as only 44 bytes of WAV header are dumped into the file.
I've noticed the TLV320 codec got a pin (P1.2) called I2S_ENABLE. Should i pull it up during startup despite TAS1020 chip and the EPROM were phisically removed?
Can this evaluation board intended to be used this way?
Any ideas?