AnsweredAssumed Answered

Multiple AD7476 (PmodAD1)

Question asked by flatmax on Nov 26, 2013
Latest reply on Aug 14, 2014 by flatmax

Hi there,

 

Following on from the successful build and test of a single PmodAD1 : http://ez.analog.com/message/123360

 

I have modified the reference design to have two AD7476A HDL blocks and also included other necessary changes to route through a dma.

My question here is w.r.t. the device tree. When I install the system and run it on the zedboard, I only see the one AD7476 iio device.

Any pointers as to why ?

 

Here is the device tree I am using :

/dts-v1/;


/include/ "zynq-zed.dtsi"


/ {
          fpga_axi: fpga-axi@0 {
                    compatible = "simple-bus";
                    #address-cells = <0x1>;
                    #size-cells = <0x1>;
                    ranges;


                    i2c@41600000 {
                              compatible = "xlnx,axi-iic-1.01.b", "xlnx,xps-iic-2.00.a";
                              interrupt-parent = <&gic>;
                              interrupts = <0 58 0x4>;
                              reg = <0x41600000 0x10000>;


                              #size-cells = <0>;
                              #address-cells = <1>;


                              adv7511: adv7511@39 {
                                        compatible = "adi,adv7511";
                                        reg = <0x39>;


                                        adi,input-style = <0x02>;
                                        adi,input-id = <0x01>;
                                        adi,input-color-depth = <0x3>;
                                        adi,sync-pulse = <0x03>;
                                        adi,bit-justification = <0x01>;
                                        adi,up-conversion = <0x00>;
                                        adi,timing-generation-sequence = <0x00>;
                                        adi,vsync-polarity = <0x02>;
                                        adi,hsync-polarity = <0x02>;
                                        adi,tdms-clock-inversion;
                                        adi,clock-delay = <0x03>;
                              };
                    };


                    axi_vdma_0: axivdma@43000000 {
                              #address-cells = <1>;
                              #size-cells = <1>;
                              #dma-cells = <1>;
                              compatible = "xlnx,axi-vdma";
                              reg = <0x43000000 0x1000>;
                              xlnx,include-sg = <0x0>;
                              xlnx,num-fstores = <0x3>;
                              dma-channel@7e200000 {
                                        compatible = "xlnx,axi-vdma-mm2s-channel";
                                        interrupts = <0 59 0x4>;
                                        xlnx,datawidth = <0x40>;
                                        xlnx,genlock-mode = <0x0>;
                                        xlnx,include-dre = <0x0>;
                              };
                    };


                    fpga_clock: fpga_clock {
                              compatible = "fixed-clock";
                              #clock-cells = <0>;
                              clock-frequency = <200000000>;
                    };


                    hdmi_clock: axi-clkgen@79000000 {
                              compatible = "adi,axi-clkgen-1.00.a";
                              reg = <0x79000000 0x10000>;
                              #clock-cells = <0>;
                              clocks = <&fpga_clock>;
                    };


                    axi_hdmi@70e00000 {
                              compatible = "adi,axi-hdmi-1.00.a";
                              reg = <0x70e00000 0x10000>;
                              encoder-slave = <&adv7511>;
                              dmas = <&axi_vdma_0 0>;
                              dma-names = "video";
                              clocks = <&hdmi_clock>;
                    };


                    audio_clock: audio_clock {
                              compatible = "fixed-clock";
                              #clock-cells = <0>;
                              clock-frequency = <12288000>;
                    };


                    axi_spdif_tx_0: axi-spdif-tx@0x75c00000 {
                              compatible = "adi,axi-spdif-tx-1.00.a";
                              reg = <0x75c00000 0x1000>;
                              dmas = <&ps7_dma 0>;
                              dma-names = "tx";
                              clocks = <&fpga_clock &audio_clock>;
                              clock-names = "axi", "spdif";
                    };


                    adv7511_hdmi_snd: adv7511_hdmi_snd {
                              compatible = "adv7511-hdmi-snd";
                              audio-codec = <&adv7511>;
                              cpu-dai = <&axi_spdif_tx_0>;
                    };

                    axi_dma_0: axidma@40400000 {
                              #address-cells = <1>;
                              #size-cells = <1>;
                              #dma-cells = <1>;
                              compatible = "xlnx,axi-dma";
                              reg = <0x40400000 0x10000>;
                              dma-channel@40400000 {
                                        compatible = "xlnx,axi-dma-s2mm-channel";
                                        interrupts = <0 52 0x4>;
                                        xlnx,datawidth = <0x40>;
                                        xlnx,sg-length-width = <23>;
                                        xlnx,include-dre = <0x0>;
                              };
                    };


                    ad_adc_0: AD7476A@79020000 {
                              compatible = "xlnx,axi-ad-adc-1.00.a";
                              reg = < 0x79020000 0x10000 >;
                              dmas = <&axi_dma_0 0>;
                              dma-names = "ad-adc-dma";
                              adc-name-id = "ad7476a";
                    }; 

                    axi_dma_1: axidma@40440000 {
                              #address-cells = <1>;
                              #size-cells = <1>;
                              #dma-cells = <1>;
                              compatible = "xlnx,axi-dma";
                              reg = <0x40440000 0x10000>;
                              dma-channel@40440000 {
                                        compatible = "xlnx,axi-dma-s2mm-channel";
                                        interrupts = <0 35 0x4>;
                                        xlnx,datawidth = <0x40>;
                                        xlnx,sg-length-width = <23>;
                                        xlnx,include-dre = <0x0>;
                              };
                    };


                    ad_adc_1: AD7476A@79040000 {
                              compatible = "xlnx,axi-ad-adc-1.00.a";
                              reg = < 0x79040000 0x10000 >;
                              dmas = <&axi_dma_1 0>;
                              dma-names = "ad-adc-dma";
                              adc-name-id = "ad7476a";
                    }; 

                    trigger: trigger@0 {
                              compatible = "iio-trigger-hrtimer";
                    };
          };
};

Outcomes