I am using the ADAU1761 audio codec on my system with the Analog Devices AXI I2S ADI IP. I have successfully validated and run the system for one ADAU1761 using the following device tree on PetaLinux 2019.2:
/include/ "system-conf.dtsi" / { fpga_axi: fpga-axi@0 { compatible = "simple-bus"; #address-cells = <0x1>; #size-cells = <0x1>; ranges; audio_clock: audio_clock { compatible = "fixed-clock"; #clock-cells = <0>; clock-frequency = <12288000>; }; zed_sound { compatible = "simple-audio-card"; simple-audio-card,name = "ZED ADAU1761"; simple-audio-card,widgets = "Microphone", "Mic In", "Headphone", "Headphone Out", "Line", "Line In", "Line", "Line Out"; simple-audio-card,routing = "Line Out", "LOUT", "Line Out", "ROUT", "Headphone Out", "LHP", "Headphone Out", "RHP", "Mic In", "MICBIAS", "LINN", "Mic In", "RINN", "Mic In", "LAUX", "Line In", "RAUX", "Line In"; simple-audio-card,dai-link@0 { format = "i2s"; cpu { sound-dai = <&axi_i2s_adi_0>; }; codec { sound-dai = <&adau1761>; }; }; }; }; }; &i2c0 { status = "okay"; compatible = "xlnx,xps-iic-2.00.a"; reg = <0x41600000 0x10000>; interrupt-parent = <&intc>; interrupts = <0 30 4>; clocks = <&clkc 15>; clock-names = "pclk"; #size-cells = <0>; #address-cells = <1>; adau1761: adau1761@3b { #sound-dai-cells = <0>; // only single DAI compatible = "adi,adau1761"; reg = <0x3b>; clocks = <&misc_clk_0>; clock-names = "mclk"; }; }; &axi_i2s_adi_0 { #sound-dai-cells = <0>; compatible = "adi,axi-i2s-1.00.a"; dmas = <&dmac_s 1 &dmac_s 2>; dma-names = "tx", "rx"; clocks = <&clkc 15>, <&audio_clock>; clock-names = "axi", "ref"; reg = <0x77600000 0x10000>; xlnx,bclk-pol = <0x0>; xlnx,dma-type = <0x1>; xlnx,has-rx = <0x1>; xlnx,has-tx = <0x1>; xlnx,lrclk-pol = <0x0>; xlnx,num-ch = <0x1>; xlnx,slot-width = <0x18>; };
Also you can see my block design below for two adau1761(i could not run this with proper device tree);
Actually my goal is that i want to use 8 ADAU1761 chips in the system. How should I modify the device tree when I increase the number of channels by updating xlnx,num-ch = <0x1>;
for the AXI I2S ADI, to accommodate this configuration?
Could you give me an example?
Thanks ,
Sincerely Emre OGUT