Welcome to EnviroDIY, a community for do-it-yourself environmental science and monitoring. EnviroDIY is part of WikiWatershed, an initiative of Stroud Water Research Center designed to help people advance knowledge and stewardship of fresh water.
New to EnviroDIY? Start here

Reply To: Hydros 21/Decagon CTD: reading error

Home Forums Environmental Sensors Hydros 21/Decagon CTD: reading error Reply To: Hydros 21/Decagon CTD: reading error


We wrote Program for Interfacing Hydros sensor 21 with Arduino Uno board using SDI-12 interface and saw the result on serial monitor . We tried a lot in implementing a program for connecting sensor directly to the digital Pin (Pin7/Pin2) of the Arduino UNO board using SDI-12 interface and viewing the result on the serial monitor. We found only garbage data coming on the serial Monitor.

We uploaded program here.

#include <SDI12.h>

const int dataPin = 2; // Connect the data pin to digital pin 2
SDI12 sdi12;

void setup() {

void loop() {
// Request data from the sensor

// Wait for the sensor to respond

// Read and print the sensor response
while (sdi12.available()) {
char c = sdi12.read();

// Wait for a moment before taking the next reading

Can you guide whether we require any digital hardware between Hydros sensor21 and Arduino Uno board?