Overview

The Raspberry Pi is an excellent small board computer that you can use to control digital inputs & outputs.  However what do you do when you want to read an analog signal, like what you might get from a thermistor, potentiometer, or many other types of sensors?  Don't give up!  By connecting a small analog to digital converter (ADC) chip to the Pi you can open up the world of analog signals to your Raspberry Pi programs!

This guide will show you a couple great options for reading analog values from Python with a Raspberry Pi.  You can use a simple MCP3008 analog to digital converter (ADC) to read up to 8 channels of analog input with 10-bit precision.  Or use a fancier ADS1x15 series ADC to read 4 channels with 12 to 16-bit precision, and a programmable gain stage--wow, fancy!  You'll be up and running in no time with a Python library and examples to read analog inputs from both these ADCs.

Before you get started you'll want to be familiar with the basics of using a Raspberry Pi like loading an operating system, setting up networking, and connecting to a terminal using SSH.  Check out the Learn Raspberry Pi series for more information.

Also make sure your Raspberry Pi is running the latest Raspbian Jessie operating system (either the full or lite version) before starting the guide.

Continue on to learn about using the MCP3008, or the ADS1015 / ADS1115 analog to digital convert with the Raspberry Pi.

Last updated on 2016-02-09 at 04.51.13 PM Published on 2016-02-09 at 01.57.17 PM