Other Parts Discussed in Thread: TAS2505
PAGE1
0x2E set 0x00
0x30 set 0x50
clk:
ACLKX:5.670MHz
AFSX: 44.13Khz
The device tree is set up as follows:
&mcasp1 {
#sound-dai-cells = <0>;
pinctrl-names = "default";
pinctrl-0 = <&main_mcasp1_pins_default>;
status = "okay";
op-mode = <0>; /* MCASP_IIS_MODE */
tdm-slots = <2>;
serial-dir = < /* 0: INACTIVE, 1: TX, 2: RX */
1 0 2 0
>;
// serial-dir = < /* 0: INACTIVE, 1: TX, 2: RX */
// 2 2 1 0
// >;
tx-num-evt = <32>;
rx-num-evt = <32>;
};
main_mcasp1_pins_default: main-mcasp1-default-pins {
pinctrl-single,pins = <
AM62AX_IOPAD(0x090, PIN_INPUT, 2) /* (L19) GPMC0_BE0n_CLE.MCASP1_ACLKX */
AM62AX_IOPAD(0x098, PIN_INPUT, 2) /* (R18) GPMC0_WAIT0.MCASP1_AFSX */
AM62AX_IOPAD(0x08c, PIN_OUTPUT, 2) /* (K19) GPMC0_WEn.MCASP1_AXR0 */
AM62AX_IOPAD(0x084, PIN_INPUT, 2) /* (L18) GPMC0_ADVn_ALE.MCASP1_AXR2 */
>;
};
clk_mcasp1_fixed: clk_mcasp1_fixed {
#clock-cells = <0>;
compatible = "fixed-clock";
// clock-frequency = <24576000>;
clock-frequency = <12288000>;
};
clk_mcasp1: clk_mcasp1 {
#clock-cells = <0>;
// compatible = "gpio-gate-clock";
compatible = "fixed-clock";
clocks = <&clk_mcasp1_fixed>;
//enable-gpios = <&main_gpio1 27 0>; /* BeagleBone Black Clk enable on GPIO1_27 */
};
sound {
status = "okay";
compatible = "simple-audio-card";
simple-audio-card,name = "AM62Ax-tas2505";
simple-audio-card,dai-link@0 {
format = "i2s";
bitclock-master = <&sound0_master>;
frame-master = <&sound0_master>;
sound0_master: cpu {
sound-dai = <&mcasp1>;
system-clock-direction-out;
};
codec {
clocks = <&clk_mcasp1>;
sound-dai = <&tas2505>;
};
};
};
The device tree is set up as follows:
tas2505: tas2505@18 {
#sound-dai-cells = <0>;
compatible = "ti,tas2505";
reg = <0x18>;
gpio-reset = <&main_gpio1 11 GPIO_ACTIVE_LOW>;
clock-source = <1>;/* 0: MCLK, 1: BCLK */
status = "okay";
};
schematic diagram: