Interfacing ADS8319 with Arduino UNO I am using Arduino UNO and trying to interface 2 16-bit ADS8319 ADCs with it via the SPI interface.

I have interfaced the 2 ADCs with the micro-controller using the "4 Wire CS Mode Without Busy Indicator" (data sheet page number 15). 

I am using the following code to get the values from the ADCs.

#include &lt;SPI.h&gt;
#define CONVPIN 7
#define SELPIN 8
#define SELPIN2 4
#define MISOPIN 12
#define SCLKPIN 13

int adcvalue;
byte byte1; byte byte2;
const float aRefVoltage = 5;
float volts = 0;

void setup() {

  // put your setup code here, to run once:
  pinMode(SELPIN, OUTPUT); // ADC's selection pin
  pinMode(SELPIN2, OUTPUT); // 2nd ADC's selection pin
  pinMode(CONVPIN, OUTPUT); // ADC's conversion pin
  pinMode(SCLKPIN, OUTPUT); // ADC's clock pin
  pinMode(MISOPIN, INPUT);  // ADC's data out
  SPI.begin();
  Serial.begin(9600);
}

void loop() {
  // put your main code here, to run repeatedly:
  digitalWrite(CONVPIN, LOW);
  digitalWrite(SELPIN, HIGH);
  digitalWrite(SELPIN2, HIGH);
  digitalWrite(CONVPIN, HIGH);
  digitalWrite(SELPIN, LOW);

  delay(1000);

  byte1 = SPI.transfer(0x00); //transfer (read) 8 bits from the adc chip D15-8
  byte2 = SPI.transfer(0x00);  //transfer (read) the second 8 bits. D7-0

  adcvalue = (byte1 &lt;&lt;8) | (byte2 &amp; 0xff);  // combine the 2 bytes to make our 16 bit word
  Serial.print("Voltage Value: ");
  Serial.println(adcvalue,BIN);
  volts = (adcvalue*aRefVoltage/65535);
  Serial.print(" Sensor Volts: ");
  Serial.println(volts,5);
  delay(1000);
}


However i am not getting the right values. The ADC that ive selected by "digitalWrite(SELPIN, LOW);" should output 1V, whereas the values keep on changing in between 0 and 2.2 V .I am not sure if my code is correct or not. Can you please verify the code so that i should know whether the problem is in my hardware, or the code.

Below is the screenshot for my schematic :



Your helpful suggestions and comments would be appreciated !
Thankyou.
After lots and lots and changing values for resistors and capacitors and checking connections, i came to find out that my micro-controller ground was not at the same level as the ADCs ( i had already connected its ground with my circuit board ground but there was some kind of problem ). When i soldered the controllers ground just near the ADCs ground, both the ADCs started working properly.