Cirkit Designer LogoCirkit DesignerYour all-in-one circuit design IDE Launch Cirkit Designer App

Arduino UNO and ADS1220-Based Precision Voltage Measurement System

View and Edit Project In Cirkit DesignerImage of Arduino UNO and ADS1220-Based Precision Voltage Measurement System

Circuit Documentation

Summary

This circuit involves an Arduino UNO microcontroller interfacing with an ADS1220 analog-to-digital converter (ADC). The Arduino UNO reads analog signals from the ADS1220 and processes them. The communication between the Arduino and the ADS1220 is facilitated through the SPI protocol.

Component List

Arduino UNO

ADS1220

Wiring Details

Arduino UNO

ADS1220

Code Documentation

Arduino UNO Code

#include <Protocentral_ADS1220.h>

const float VREF = 5;       // Reference voltage in volts
const int32_t ADC_MAX = 8388607; // Max value for 24-bit ADC (2^23 - 1)
const int Gain = 1;           // Gain setting (adjust if different)
Protocentral_ADS1220 myADC; // Create an instance of the ADS1220 class

void setup() {
  Serial.begin(9600);          // Initialize Serial communication
  myADC.begin(7, 6);           // Initialize the ADS1220 with CS_PIN and DRDY_PIN
}

void loop() {
  myADC.set_conv_mode_continuous(); // Set the ADC to continuous mode conversion
  myADC.select_mux_channels(MUX_SE_CH0);    // Choose channel 0 to read (adjust as needed)

  int32_t rawADC = myADC.Read_WaitForData(); // Read ADC data registers
   
  float voltage = (rawADC * VREF) / (Gain * ADC_MAX);

  Serial.println(voltage);                    // Print read data
  //delay(10);
}

ADS1220 Code

void setup() {
  // put your setup code here, to run once:
}

void loop() {
  // put your main code here, to run repeatedly:
}

This documentation provides a comprehensive overview of the circuit, including the components used, their wiring details, and the code running on the microcontrollers.