SDI-12 USB adapter


This SDI-12 USB adapter is a great way to add SDI-12 sensors to a PC running windows, Linux, Mac OSX, or single board computers such as Raspberry pi and Beagle Bone Black. Similar products on the market sell for a lot more with less features. This adapter essentially allows you to send SDI-12 commands directly to your sensors and read back their responses. You may decide to run the free and open-source data logger code I provide and maintain, or develop your own code.

To integrate SDI-12 sensor on your Arduino instead of on PC, Raspberry Pi, or Beagle Bone Black, check out my SDI-12 data logging shield and dongle:

SDI-12 sensors are widely used in environmental monitoring including soil, streams, plants etc. On the other hand, data loggers designed for SDI-12 sensors are usually expensive and proprietary, making it harder to monitor and study soils and streams on a budget. This SDI-12 USB adapter makes it possible to directly interface SDI-12 sensors with a PC running Windows, Mac, Linux, Raspberry Pi, or Beagle Bone Black, on a budget. I have built numerous SDI-12 sensor data loggers. This is my latest design that is very easy to use. All you need is the adapter and a PC/Raspberry Pi/Beagle Bone BlackCS215 Air Temperature and Relative Humidity Sensors (Thank Lee!). It also comes with free data logger program (Python script) for all the above operating systems. A section on SDI-12 sensors will guide you through it. FYI, a $150 windows 10 netbook running on Intel ATOM Z3000 series or faster is more than enough to log data. All of the examples in this manual came from one such netbook. A first-generation Raspberry Pi is more than enough for data logging.

Data logging with a Beagle Bone Black



Introduction to the adapter

Live data stream

I provide free open-source data logging scripts in Python. The following link is a live data stream from a test logger

Sensor: METERS group ECH2O 5TM soil sensor (formally Decagon 5TM)

Data: dielectric constant, temperature (DegC)

Logger: Raspberry Pi Zero W

Description: The soil sensor is not buried in soil and indoors. I use this sensor to test new batches of SDI-12 USB adapters so I don’t bury it in soil. As a result, the dielectric constant is close to 1 (air, or carpet) and temperature is indoor (DegC).

SDI-12 sensors tested

In theory, all SDI-12 sensors should work with my adapter. In practice, not all sensors were made equal. So far, I have been able to test the following sensors with the adapter, with some help from users like you. There has not been reports of any SDI-12 sensors that are incompatible. The following list keeps expanding. If you tested other sensors, please inform me.

  • SI-411 (standard field of view infrared radiometer sensor)


  • CKC 6 sensor probe

Campbell Scientific:

  • CS215 Air Temperature and Relative Humidity Sensors (Thank Lee!)
  • CS650 30cm Soil Volumetric Water Content Probe (Thanks Stan!)
  • CS655 12cm Soil Volumetric Water Content Probe (Thanks Nick!)

Decagon (Now part of METER group):

  • DS-2 (Sonic Anemometer)
  • VP-3 (temperature, barometer, humidity sensor)
  • PRI SRS (spectral reflectance sensor)
  • NDVI SRS (spectral reflectance sensor)
  • GS3 (Ruggedized Soil Moisture, Temperature, and Electrical Conductivity Sensor)
  • MPS-6 (Calibrated Water Potential Sensor)
  • 5TE (Volumetric Water Content, Electrical Conductivity, and Temperature)
  • 5TM (Soil Moisture and Temperature Sensor)

Gill Instruments:

  • WindSonic Ultrasonic Wind Sensor (Thanks MG!)

METER group (formally Decagon and UMS):

  • Atmos 22 (DS-2) (Sonic Anemometer)
  • Atoms 14 (VP-4) (temperature, vapor pressure, relative humidity sensor)
  • Atoms 41 weather station (solar radiation, precipitation, vapor pressure, relative humidity, air temperature, barometric pressor, horizontal wind speed, wind gust, wind direction, compass heading, tilt, lightning strike count, lightning average distance) (Thanks CD!)
  • PRI (spectral reflectance sensor)
  • NDVI SRS (spectral reflectance sensor)
  • GS3 (Ruggedized Soil Moisture, Temperature, and Electrical Conductivity Sensor)
  • TEROS 21 (MPS-6) (Calibrated Water Potential Sensor)
  • ECH2O 5TE (5TE) (Volumetric Water Content, Electrical Conductivity, and Temperature)
  • ECH2O 5TM (5TM) (Soil Moisture and Temperature Sensor)


  • Digital turbidity sensor


  • TriSCAN (12 moisture salinity temperature sensor probes)


  • Accubar SDI-12 Barometric Pressure Sensor, Model 5600-0120-3 (Thanks Meidad!)


Analog sensors tested:

Resistive sensors:

  • Any sensors having resistance between 100Ω and 100KΩ can be measured with SDI-12 + Analog USB adapter
  • PT1000 temperature probe

Voltage sensors:

  • Any sensors producing up to 6V of DC voltage can be measured with SDI-12 + Analog USB adapter
  • Apogee SP-110 Self-Powered Pyranometer (Decagon sells them under PYR part number)
  • Apogee SQ-500 Self-Powered full spectrum quantum sensor
  • METER group ECH2O EC-5 (Decagon EC-5) (Soil volumetric water content sensor)

Data Logging (Windows/Mac/Linux/Raspberry pi/Beagle Bone Black)

The adapter has been designed for long-term data logging, not just hours, days, or weeks, months at a time. The data logging software can also run without problems for months. You can sit back and watch the Python data collection script collect data automatically. My Python script is free and open source and has the following features.

  • Automatically names files with start date such as 20160426.CSV
  • Uploads data to a server so you can remotely access you data, or plot them with Google Charts (Python logger code)
  • A free web page is provided so you can start making your own remote dashboard for your logger (Python logger code)
  • Select sensor address
  • Enter total data points
  • Enter delay between data points
  • Select GMT or Local time zone for time stamp stored in local log file


Data logger running on a Raspberry PI 2 B

 Plot from data uploaded to

soil logger webpageWeb page dashboard for my sample data logger (use it for free)

Just run the python data logger script in Tera Term. Your data will be stored where this script is so if you store the script in a cloud drive, you will be able to view your data remotely. Otherwise, use the data server to store your data and retrieve them.

The following shows temperature of a 30-day run:

30-day temperature




Your PC or raspberry pi must have access to the internet. Your data are sent to a server and stored there ready for retrieval and plotting in a web browser. With Python data logger code V1.1 and up, your data is sent to a phant server run by sparkfun electronics. You can retrieve data remotely. So if your logger is in your lab or in the field, you can retrieve your data wherever you are if you have internet. You will still have a local logger file just in case.
I have made a sample webpage that has the links for data download and graphs to show the most recent data. You are welcome to use the webpage for free, modify it and improve it. Link
If you require your data to be uploaded to your own server with your specific formats, I will be able to help you achieve that as well. Consulting fee applies.





Local data log file Format
Your data will be stored in comma-separated-value (.CSV) format. The file name is the date and time when the script starts logging data. There are at least three columns. The first column is the date and time the data point is collected. Depending on your choice, it is either in GMT/UTC or local time. The next column is the sensor address. The third column is the first value returned by your sensor. If your sensor returns more than one value, additional columns will contain additional values.

This file format is ready to be read by any major data analysis tools such as Excel, Open Office Calc, or the more expensive Origin Pro. Here is a sample of data collected from a Decagon 5TM soil temperature and moisture sensor. The first data column is the relative dielectric constant (1 for air, yes, it’s NOT in soil). The second data column is temperature.

2015/10/31 18:30:59, 1, +1.04, +25.0
2015/10/31 18:31:27, 1, +1.04, +24.9
2015/10/31 18:31:56, 1, +1.04, +24.9

Data imported in Microsoft Excel and plotted

Where to buy:

This hardware is for sale in several online stores that ship all over the world from USA.

Buy directly on my blog:

SDI-12 USB + adapterBuy an assembled SDI-12 USB adapter (1st class shipping within US)

Buy an assembled SDI-12 USB adapter (International 1st class shipping)


Buy an assembled SDI-12 + Analog USB adapter (1st class shipping within US)

Buy an assembled SDI-12 + Analog USB adapter (International 1st class shipping)

Buy an assembled SDI-12 + GPS USB adapter (needs separate GPS module)  (1st class shipping within US)

Buy an assembled SDI-12 + GPS USB adapter (needs separate GPS module) (International 1st class shipping)

Buy an Ultimate GPS module from

Buy from online store:

Here is my store front at

There are many options. You can buy just the adapter. You will need a mini-USB cable to connect it to your computer or raspberry pi. Or you can add a Molex mini-USB cable (I stock from Digikey). If you are interested in logging data with a raspberry pi, you can add a 16GB microSD card with the necessary program ready to go. My blog has a much simpler option, the adapter(s) only. My inmojo store has all the extra options.


Manual 2018-03-19

Sensor connection guide 2016-08-18

Data logger programs:

All my code are in Python. You can run them on Windows PC, Linux, Raspberry Pi, and Mac OSX. For Beagle Bone Black, please install the necessary components per this post.

Data Logger V1.6.0 download (2018-07-10) experimental release

  • This version has incorporated a lot of new features.
  • Multiple adapters on the same computer/raspberry pi
  • Multiple sensing commands per sensor, such as M!, M1!, M2! etc.
  • Serial ports are opened by unique ID instead of device name such as COM3 or /dev/ttyUSB0 to make sure always the correct port is opened
  • Updates to make the script more stable.

Changes in V1.6.0

multiple sensor and adapter deployment

Data Logger V1.5.0 download (2017-11-06) stable release

This version has replaced with for data upload and basic visualization.



* Logging multiple sensors to local storage

Just enter all sensor addresses when prompted for sensor address, for instance “12345” if you have five sensors 1 thru 5.

* Data upload to

* Option to read analog channels with SDI-12 +Analog USB adapter

* Lists vendor ID for each serial port

Many computers have virtual serial ports that get listed in the list. To find which one is the adapter, just choose the port that has VID=0403.

Data Logger V1.4.1 download (2017-02-02)

This version has added support to multiple sensors. Just enter all sensor addresses when prompted for instance “12345” if you have five sensors 1 thru 5. Yeah!

Data Logger V1.3 download (2016-11-12)

This version adds support to reading 4 analog inputs on the SDI-12 + Analog USB adapter. There is an additional interactive question asking you whether to read analog inputs (Y/N). Select N if you have a regular SDI-12 USB adapter. If you stored answers to these interactive questions in a file to start the logger program without human interaction, you will need to add an additional answer Y or N to your answer file.

Data Logger V1.2 download (2016-07-01)

This version lists USB vendor ID (VID) of each serial port. The VID for my adapter is 0403. This helps you identify which serial port is the adapter.

Data Logger V1.1 download (2016-04-25)

This version also logs data to a phant server and to a local file. You need internet connection for telemetry.

Data logger V1.0 download (2016-02-09)

This version logs data to a local file.

Sensor configuration download (2016-02-09)

This script discovers the address of the sensor and gives you the option to change its address. It MUST run with a single sensor on the bus. Run this script with each new sensor to set their addresses to a unique value 0-9, A-Z, A-y (z is used by the adapter).

SDI-12 bus scanner V1.0 download (2016-09-25)

This script scans the bus and prints all discovered sensor addresses and information. It helps with system diagnostics. The sensors on the bus MUST have been configured with unique address, with sensor config script. Otherwise they may all be at address zero.

Firmware update

If your simple adapter is already version 1.2, you don’t need any update. Analog adapter has firmware version 1.3 and GPS adapter had firmware version 1.4, both of which are up to date.

Firmware update instructions (also in the manual)

V 1.2 update files (2016-06-06):

Need some help?

If you need more sophisticated data logging scripts such as logging multiple sensors or sensor with more than 6 output values or integrating SDI-12 sensors in projects using Arduino, I should be able to help. Contact me on or leave a message on my blog. I am a full-time physics professor so my time during semesters may be limited. I have more time during the summer though.


%d bloggers like this: