Arduino Due SPI communication issue

Im trying to read 2 no ADS1262 ADC in Arduino due via SPI communication. I can able to read single ADC without any problem but im facing a issue while using 2 slaves on SPI bus. I cant able to read any of them while im using 2 slaves on my SPI bus.

I tried to read single ADC after connecting both the devices on my SPI bus, it gives false value. But when i remove MISO pin of my second ADS1262 i can get correct reading of single ADC without any problem. Please give any solution.

I have attached my code for the reference.

Thanks in advance.

ADS1262_DUE_2SPI_Slaves.ino (5.02 KB)

Your connections with the SPI pins are not the right ones for a DUE.

Can you please explain?

I assume you're using the SPI header and not the pins listed at the top of that sketch?
Where are ADS1262_CS_PIN1 and ADS1262_CS_PIN2 defined? Without knowing more, my best guess is that they are both being accessed at the same time.

Sorry i forgot to clear those commented lines. Actually the example code for arduino uno. I made few changes according to extendedSPI library for using that ADC on arduino due. Sorry for the inconvenience.

I had attached full code here for reference.

ads1262.cpp (5.75 KB)

ads1262.h (2.48 KB)

ADS1262_DUE_2SPI_Slaves.ino (5.16 KB)

You can try out firstly Shiftin and Shiftout functions to get ADC samplings at a low frequency. Once you have understood how your ADC works, it will be much easier to swap to the SPI library.

There is a tutorial for using the SPI library with a DUE and an external DAC. The initialization steps might be interesting too. Google DUE DAC SPI to find the .pdf.

Actually it works fine with single ADC. But when i try to interface 2 slaves on the SPI bus it gives random values. What may be the problem?

How fast is shiftin and shiftout operation? Can i utilize full speed of ADS1262.? Because i need 2 high speed ADC for my project.

https://www.dorkbotpdx.org/blog/paul/better_spi_bus_design_in_3_steps