Adafruit 4-Channel ADC Breakouts. Created by Bill Earl

Similar documents
Adafruit MCP9808 Precision I2C Temperature Sensor Guide

Adafruit BME280 Humidity + Barometric Pressure + Temperature Sensor Breakout

Adafruit SHT31-D Temperature & Humidity Sensor Breakout

TSL2561 Luminosity Sensor

DS1307 Real Time Clock Breakout Board Kit

Tiny Arduino Music Visualizer

Data Acquisition Module with I2C interface «I2C-FLEXEL» User s Guide

Thermistor. Created by Ladyada. Last updated on :30:46 PM EDT

Data Sheet. Adaptive Design ltd. Arduino Dual L6470 Stepper Motor Shield V th November L6470 Stepper Motor Shield

Pololu DRV8835 Dual Motor Driver Shield for Arduino

RB-See-211. Seeedstudio Grove 6-15V, 2A Dual I2C Motor Driver. Grove - I2C Motor Driver. Introduction

Wireless Communication With Arduino

Atmel Norway XMEGA Introduction

MCP4725 Digital to Analog Converter Hookup Guide

How to Make a Pogo Pin Test Jig. Created by Tyler Cooper

Tire pressure monitoring

AirCasting Particle Monitor Bill of Materials

ARDUINO SEVERINO SERIAL SINGLE SIDED VERSION 3 S3v3 (REVISION 2) USER MANUAL

US-SPI New generation of High performances Ultrasonic device

ADXL345-EP. 3-Axis, ±2 g/±4 g/±8 g/±16 g Digital Accelerometer. Enhanced Product FEATURES GENERAL DESCRIPTION ENHANCED PRODUCT FEATURES APPLICATIONS

QUICK START GUIDE FOR DEMONSTRATION CIRCUIT BIT DIFFERENTIAL ADC WITH I2C LTC2485 DESCRIPTION

Introduction. Getting familiar with chipkit Pi

Flight Controller. Mini Fun Fly

Arduino Lesson 16. Stepper Motors

DIY Pocket LED Gamer - Tiny Tetris!

Arduino DUE + DAC MCP4922 (SPI)

How To Use A Watt Saver On A Microcontroller (Watt Saver) On A Cell Phone Or Mp3 Player

DATASHEET. ADAM Arduino Display Adaptor Module. Arduino Compatible Shield P/N: 4Display-Shield-FT843 For the 4D Systems 4DLCD-FT843 Display

NTE2053 Integrated Circuit 8 Bit MPU Compatible A/D Converter

Arduino ADK Back. For information on using the board with the Android OS, see Google's ADK documentation.

CryptoAuth Xplained Pro

User s Manual of Board Microcontroller ET-MEGA2560-ADK ET-MEGA2560-ADK

7 OUT1 8 OUT2 9 OUT3 10 OUT4 11 OUT5 12 OUT6 13 OUT7 14 OUT8 15 OUT9 16 OUT10 17 OUT11 18 OUT12 19 OUT13 20 OUT14 21 OUT15 22 OUT16 OUT17 23 OUT18

PLL frequency synthesizer

Web Site: Forums: forums.parallax.com Sales: Technical:

AN-812 APPLICATION NOTE

Arduino Motor Shield (L298) Manual

- 35mA Standby, mA Speaking pre-defined phrases with up to 1925 total characters.

Analog to Digital Conversion of Sound with the MSP430F2013

Programmable Single-/Dual-/Triple- Tone Gong SAE 800

Switch board datasheet EB

PN532 NFC RFID Module User Guide

US-Key New generation of High performances Ultrasonic device

PHYS 2P32 Project: MIDI for Arduino/ 8 Note Keyboard

TDA CHANNEL VOLUME CONTROLLER 1 FEATURES 2 DESCRIPTION. Figure 1. Package

Home Security System for Automatic Doors

Newhaven Display International, Inc Galvin Ct. Elgin IL, Ph: Fax:

DS1621 Digital Thermometer and Thermostat

Using Xbee in Serial Communication

AN2680 Application note

UniPi technical documentation REV 1.1

ZX-NUNCHUK (# )

DS1621 Digital Thermometer and Thermostat

PACKAGE OUTLINE DALLAS DS2434 DS2434 GND. PR 35 PACKAGE See Mech. Drawings Section

Adding a Real Time Clock to Raspberry Pi

Hardware Connections between Arduino and IMU Nori Wilkins Apr. 5, 2013

Conversion Between Analog and Digital Signals

Supply voltage Supervisor TL77xx Series. Author: Eilhard Haseloff

2.2" TFT Display. Created by Ladyada. Last updated on :15:09 PM EDT

MXL5007T TUNER RADIO

Cold-Junction-Compensated K-Thermocoupleto-Digital Converter (0 C to C)

TX 2C/RX 2C TOY CAR REMOTE CONTROLLER WITH FIVE FUNCTIONS

Arduino Due Back. Warning: Unlike other Arduino boards, the Arduino Due board runs at 3.3V. The maximum. Overview

Adafruit Si4713 FM Radio Transmitter with RDS/RDBS Support

POCKET SCOPE 2. The idea 2. Design criteria 3

MCP3426/7/8. 16-Bit, Multi-Channel ΔΣ Analog-to-Digital Converter with I 2 C Interface and On-Board Reference. Features.

DEMO MANUAL DC1338B LTC2990 I 2 C Temperature Voltage and Current Monitor DESCRIPTION

HDMM01 V1.0. Dual-axis Magnetic Sensor Module With I 2 C Interface FEATURES. Signal Path X

PCAN-MicroMod Universal I/O Module with CAN Interface. User Manual. Document version ( )

+5 V Powered RS-232/RS-422 Transceiver AD7306

XBee USB Adapter Board (#32400)

Adafruit Music Maker Shield

PenMount 1302 PCI Control Board

10-Bit Digital Temperature Sensor (AD7416) and Four/Single-Channel ADC (AD7417/AD7418) AD7416/AD7417/AD7418

Building a Basic Communication Network using XBee DigiMesh. Keywords: XBee, Networking, Zigbee, Digimesh, Mesh, Python, Smart Home

Tutorial. replace them with cell-phone operated module. The advantages of a cell-phone operated bot are:-

SG6520 FEATURES DESCRIPTION TYPICAL APPLICATION. Product Specification. PC Power Supply Supervisors

10Gbps XFP Bi-Directional Transceiver, 10km Reach 1270/1330nm TX / 1330/1270 nm RX

Character LCDs. Created by Ladyada. Last updated on :45:29 PM EDT

Low-Jitter I 2 C/SPI Programmable Dual CMOS Oscillator

Arduino Lesson 13. DC Motors. Created by Simon Monk

1.5" & 2.1" Monochrome 128x64 OLED Display Module

Trinket Bluetooth Alarm System

DS Wire Digital Thermometer and Thermostat

CAN-Bus Shield Hookup Guide

1.8" TFT Display Breakout and Shield

AUTOMATIC NIGHT LAMP WITH MORNING ALARM USING MICROPROCESSOR

CMOS OV7660 Camera Module 1/5-Inch 0.3-Megapixel Module Datasheet

Ingar Fredriksen AVR Applications Manager. Tromsø August 12, 2005

Chapter 6 PLL and Clock Generator

MAX6683 Evaluation System/Evaluation Kit

How to Move Canon EF Lenses. Yosuke Bando

Connecting instruments serially to your computer

The FT6x06 series ICs include FT6206 /FT6306, the difference of their specifications will be listed individually in this datasheet.

YAS532B MS-3R Magnetic Field Sensor Type 3R

24-Bit Analog-to-Digital Converter (ADC) for Weigh Scales FEATURES S8550 VFB. Analog Supply Regulator. Input MUX. 24-bit Σ ADC. PGA Gain = 32, 64, 128

Lecture 7: Programming for the Arduino

TSic 101/106/201/206/301/306/506 Rapid Response, Low-Cost Temperature Sensor IC with Analog or digital Output Voltage

KTA-223 Arduino Compatible Relay Controller

Transcription:

Adafruit 4-Channel ADC Breakouts Created by Bill Earl

Guide Contents Guide Contents Overview ADS1115 Features: ADS1015 Features: Assembly and Wiring Assembly: Prepare the header strip Position the breakout board Solder! Wiring: Power I2C Connections I2C "Classic" I2C Addressing Multiple Boards Signal Connections Single Ended vs. Differential Inputs: Which should I use? Single Ended Connections: Differential Connections: Programming Construction and Initialization: Single Ended Conversion: Differential Conversion: Comparator Operation: Downloads Library: Board Files: Data Sheets: 2 3 3 3 5 5 5 5 6 6 6 6 7 7 8 9 9 9 9 10 11 11 11 12 13 14 14 14 14 Adafruit Industries http://learn.adafruit.com/adafruit-4-channel-adc-breakouts Page 2 of 14

Overview The ADS1115 and ADS1015 4-channel breakout boards are perfect for adding high-resolution analog to digital conversion to any microprocessor-based project. These boards can run with power and logic signals between 2v to 5v, so they are compatible with all common 3.3v and 5v processors. As many of 4 of these boards can be controlled from the same 2-wire I2C bus, giving you up to 16 single-ended or 8 differential channels. A programmable gain amplifier provides up to x16 gain for small signals. These two boards are very similar, differing only in resolution and speed. The ADS1115 has higher resolution and the ADS1015 has a higher sample rate. ADS1115 Features: Resolution: 16 Bits Programmable Sample Rate: 8 to 860 Samples/Second Power Supply/Logic Levels: 2.0V to 5.5V Low Current Consumption: Continuous Mode: Only 150µA Single-Shot Mode: Auto Shut- Down Internal Low-Drift Voltage Reference Internal Oscillator Internal PGA: up to x16 I2C Interface: 4-Pin-Selectable Addresses Four Single-Ended or 2 Differential Inputs Programmable Comparator ADS1015 Features: Adafruit Industries http://learn.adafruit.com/adafruit-4-channel-adc-breakouts Page 3 of 14

Resolution: 12 Bits Programmable Sample Rate: 128 to 3300 Samples/Second Power Supply/Logic Levels: 2.0V to 5.5V Low Current Consumption: Continuous Mode: Only 150µA Single-Shot Mode: Auto Shut- Down Internal Low-Drift Voltage Reference Internal Oscillator Internal PGA: up to x16 I2C Interface: 4-Pin-Selectable Addresses Four Single-Ended or 2 Differential Inputs Programmable Comparator Adafruit Industries http://learn.adafruit.com/adafruit-4-channel-adc-breakouts Page 4 of 14

Assembly and Wiring Assembly: The board comes with all surface-mount parts pre-soldered. For breadboard use, the included header-strip should be soldered on: Prepare the header strip Cut the supplied header strip to length and insert it long-pins-down in your breadboard to hold it for soldering. Position the breakout board Place the breakout board on the header pins. Adafruit Industries http://learn.adafruit.com/adafruit-4-channel-adc-breakouts Page 5 of 14

Solder! Solder each pin for a good electrical connection. Wiring: Power First connect VDD and GND. These boards will work with either a 3.3v or a 5v supply. The diagram below shows connection to the Arduino 5v pin. The absolute maximum analog input voltage is VDD + 0.3v. To avoid damage to the chip, do not attempt to measure voltages greater than VDD. I2C Connections I2C requires just 2 pins to communicate. These can be shared with other I2C devices. For R3 and later Arduinos (including MEGA and DUE models), connect SDA->SDA and SCL->SCL. Adafruit Industries http://learn.adafruit.com/adafruit-4-channel-adc-breakouts Page 6 of 14

I2C "Classic" For older Arduino boards without dedicated SDA and SCL pins, connect as shown below. (For older Arduino Megas, SDA and SCL are on pins 20 and 21) I2C Addressing The ADS11x5 chips have a base 7-bit I2C address of 0x48 (1001000) and a clever addressing scheme that allows four different addresses using just one address pin (named ADR for ADdRess). To program the address, connect the address pin as follows: 0x48 (1001000) ADR -> GND 0x49 (1001001) ADR -> VDD 0x4A (1001010) ADR -> SDA 0x4B (1001011) ADR -> SCL The following diagram shows one board addressed as 0x48: Adafruit Industries http://learn.adafruit.com/adafruit-4-channel-adc-breakouts Page 7 of 14

Multiple Boards By assigning each board a different address, up to 4 boards can be connected as below: Adafruit Industries http://learn.adafruit.com/adafruit-4-channel-adc-breakouts Page 8 of 14

Signal Connections Single Ended vs. Differential Inputs: The ADS1x15 breakouts support up to 4 SIngle Ended or 2 Differential inputs. Single Ended inputs measure the voltage between the analog input channel (A0-A3) and analog ground (GND). Differential inputs measure the voltage between two analog input channels. (A0&A1 or A2&A3). Which should I use? Single ended inputs give you twice as many inputs. So why would you want to use differential inputs? Differential measurements offer more immunity from electromagnetic noise. This is useful when using long signal wires or operating in an electrically noisy environment. This is also desirable when dealing with small signals requiring high gain, since the gain will amplify the noise as well as the signal. Single Ended Connections: Connect the signal wire to one of the analog input channels (A0 - A3). Connect the ground wire to GND. This diagram shows how to connect an ADXL335 to for measurement of the X, Y and Z axis on analog channels A0, A1 and A2. Adafruit Industries http://learn.adafruit.com/adafruit-4-channel-adc-breakouts Page 9 of 14

Differential Connections: Differential measurements use a pair of input pins, either A0&A1 or A2&A3. No ground connection is necessary. The following diagram shows connections for differential measurement of the battery voltage on a LiPo charger board. Adafruit Industries http://learn.adafruit.com/adafruit-4-channel-adc-breakouts Page 10 of 14

Programming The Adafruit_ADS1x15 library supports both single-ended and differential readings as well as comparator operations on both the ADS1015 and ADS1115 breakout boards. The library uses the wiring library for I2C communication, so wiring.h must be included. Construction and Initialization: Adafruit_ADS1015(); Construct an instance of an ADS1015 with the default address (0x48) Adafruit_ADS1015(uint8_t addr); Construct an instance of an ADS1015 with the specified address (0x48-0x4B) Adafruit_ADS1115(); Construct an instance of an ADS1115 with the default address (0x48) Adafruit_ADS1115(uint8_t addr); Construct an instance of an ADS1115 with the specified address (0x48-0x4B) vo id begin(vo id); Initialize the ADC for operation. Example: #include <Wire.h> #include <Adafruit_ADS1015.h> Adafruit_ADS1015 ads1015; // Construct an ads1015 at the default address: 0x48 Adafruit_ADS1115 ads1115(0x49); // construct an ads1115 at address 0x49 void setup(void) { ads1015.begin(); // Initialize ads1015 ads1115.begin(); // Initialize ads1115 } Single Ended Conversion: uint16_t readadc_singleended(uint8_t channel); Perform a single-ended analog to digital conversion on the specified channel. Example: #include <Wire.h> #include <Adafruit_ADS1015.h> Adafruit_ADS1015 ads1015; Adafruit Industries http://learn.adafruit.com/adafruit-4-channel-adc-breakouts Page 11 of 14

void setup(void) { Serial.begin(9600); Serial.println("Hello!"); Serial.println("Getting single-ended readings from AIN0..3"); Serial.println("ADC Range: +/- 6.144V (1 bit = 3mV)"); ads1015.begin(); } void loop(void) { int16_t adc0, adc1, adc2, adc3; adc0 = ads1015.readadc_singleended(0); adc1 = ads1015.readadc_singleended(1); adc2 = ads1015.readadc_singleended(2); adc3 = ads1015.readadc_singleended(3); Serial.print("AIN0: "); Serial.println(adc0); Serial.print("AIN1: "); Serial.println(adc1); Serial.print("AIN2: "); Serial.println(adc2); Serial.print("AIN3: "); Serial.println(adc3); Serial.println(" "); delay(1000); } Differential Conversion: int16_t readadc_differential_0_1(void); Perform a differential analog to digital conversion on the voltage between channels 0 and 1. int16_t readadc_differential_2_3(void); Perform a differential analog to digital conversion on the voltage between channels 2 and 3. Example: #include <Wire.h> #include <Adafruit_ADS1015.h> Adafruit_ADS1015 ads1015; void setup(void) { Serial.begin(9600); Serial.println("Hello!"); Serial.println("Getting differential reading from AIN0 (P) and AIN1 (N)"); Serial.println("ADC Range: +/- 6.144V (1 bit = 3mV)"); ads1015.begin(); } void loop(void) { int16_t results; Adafruit Industries http://learn.adafruit.com/adafruit-4-channel-adc-breakouts Page 12 of 14

results = ads1015.readadc_differential_0_1(); Serial.print("Differential: "); Serial.print(results); Serial.print("("); Serial.print(results * 3); Serial.println delay(1000); } Comparator Operation: Comparator mode allows you to compare an input voltage with a threshold level and generate an alert signal (on the ALRT pin) if the threshold is exceeded. This pin can be polled with a digital input pin, or it can be configured to generate an interrupt. void startcomparator_singleended(uint8_t channel, int16_t threshold); Set the threshold and channel for comparator operation. int16_t getlastco nversio nresults(); Get the last conversion result and clear the comparator. Example: #include <Wire.h> #include <Adafruit_ADS1015.h> Adafruit_ADS1015 ads1015; void setup(void) { Serial.begin(9600); Serial.println("Hello!"); Serial.println("Single-ended readings from AIN0 with >3.0V comparator"); Serial.println("ADC Range: +/- 6.144V (1 bit = 3mV)"); Serial.println("Comparator Threshold: 1000 (3.000V)"); ads1015.begin(); // Setup 3V comparator on channel 0 ads1015.startcomparator_singleended(0, 1000); } void loop(void) { int16_t adc0; // Comparator will only de-assert after a read adc0 = ads1015.getlastconversionresults(); Serial.print("AIN0: "); Serial.println(adc0); delay(100); } Adafruit Industries http://learn.adafruit.com/adafruit-4-channel-adc-breakouts Page 13 of 14

Downloads Library: ADS1x15 Library for Arduino (http://adafru.it/ast) Board Files: Board Files and Schematics (http://adafru.it/asu) Data Sheets: ADS1015 Data Sheet (http://adafru.it/asv) ADS1115 Data Sheet (http://adafru.it/asw) Adafruit Industries Last Updated: 2013-01-23 01:15:27 PM EST Page 14 of 14