Skip to content
Chris-Milford edited this page Feb 17, 2025 · 64 revisions

logo

Project Leads: Chris Milford

Project Members: Bryce Truong, Tyler Slaght

Past team members Annika Sundstorm, Brenda Fasse, Colin Hale-Brown

Interested in the project? Email us at: [email protected], [email protected]

To return to the OPEnS Lab wiki click HERE.

Overview

Currently, small streams are often ignored in hydrological modeling by entities that generate public data of water resources. This is primarily due to the high cost of stream surveying equipment typically only available to large organizations that can afford them. This is an issue because the water quality, habitability, and flow of large streams are significantly impacted by the many small streams flowing into them. With these data many things become possible including tracing sources of pollution, observing animal behavior, and identifying weather events.

Smart Rock aims to create a low-cost device to monitor remote streams through the ideals and goals of citizen science. The device could be used as a learning tool for students, teachers, and other citizen scientists. Deploying Smart Rock in streams will allow for more accurate data collection of small and seasonal streams.

Description

Cover

The Smart Rock is a submersible sensor suite that monitors water pressure, temperature, turbidity, and electrical conductivity of streams over time. This sensor package is designed with followable open source build guides and documentation so you can build your own with the proper equipment. The current version of the Smart Rock costs ~$300 in components, and requires the following tools to assemble from scratch: Laser cutter, fume hood, bandsaw, and a soldering iron. It is also helpful to have a heat gun for solder rework and removing bubbles from epoxy while it cures.

Included Sensors

Pressure/Temperature Sensor

General Description/how it works: The pressure sensor runs on 3 volts from a microcontroller or direct source. The MS5803 Pressure sensor uses piezoresistivity to output pressure readings. Piezoresistivity is the change in electrical resistivity of a semiconductor when mechanical strain is applied. The sensor converts an analog output into a 24 digit output that runs on the I2C protocol. The sensor additionally provides a 24 digit output for temperature. The sensor has been calibrated at 2 temperatures and 2 pressures and 6 coefficients are calculated and stored in a 128-bit PROM. When taking new readings, the device first reads this calibration data. The digital pressure data (D1) and digital temperature data (D2) are read and temperature and pressure are then calculated. Temperature is calculated in two steps: subtracting the read temperature from the reference temperature and comparing to the temperature coefficient from calibration. Then, the electrical sensitivity is read and the actual temperature calculation is used in another calculation regarding the pressure offset caused by temperature. Following I2C protocol communication, SDA (Serial Data) output conveys the pressure and temperature readings to a microcontroller.

pressure

MS580302BA Water Level Spec

Pressure Condition Min Max Unit
Operating Range Full Accuracy 300 1100 mbar
Extended Range Linear Range 10 2000 mbar
Absolute Accuracy at 25°C mbar
Absolute Accuracy at 25°C mbar
Absolute Accuracy at 25°C mbar
Absolute Accuracy at 25°C mbar
Maximum Error VDD=1.8V...3.6V -2.5 +2.5 mbar
Stability -1 +1 mbar/yr

MS580302BA Water Temperature Spec

Temperature Condition Min Max Unit
Range -40 +85 °C
Absolute Accuracy at 25°C -0.8 +0.8 °C
Absolute Accuracy -20...85°C -2.0 +2.0 °C
Absolute Accuracy -40...85°C -4.0 +4.0 °C
Maximum Error VDD=1.8V...3.6V -0.5 +0.5 °C

The data above is from the data sheet provided by the manufacturer, a complete data sheet for the sensor can be found here if you are interested in more details.

Smart Rock Use Validation: The pressure and temperature gives a two for one. Costing $20.53, this sensor provides the two primary measurements we need with one sensor. Measuring temperature and depth of a stream are the most useful in determining basic data about a remote and unknown stream. With a custom PCB designed for this sensor, connecting the sensor to the microcontroller is made easier. Following I2C protocol, the sensor is already implemented into our LOOM_Library. This allows for the programming of the system to be simple. The sensor gives accurate and useful data within our budget. The size of the sensor is also fairly small and easy to make water proof.

Turbidity Sensor

One of the most important indicators of water quality is the total particulate matter suspended in the water. We measure this characteristic by using infrared light to determine the water’s turbidity or “cloudiness”. In order to do this, we use a method of measuring the backscatter of infrared light that is emitted from a transmitter, and returned to an adjacent receiver. For this, we use Adafruit's VCNL4010 infrared proximity breakout board.

insert VCNL4010 pic

This allows us to measure turbidity without seeing changes due to ambient light . Additionally, because the sensor is a one-point infrared sensor we don't need to cut a hole in the faceplate for it to sit in the water, and can instead measure the turbidity through the clear acrylic faceplate, reducing our possible leak points.

Electrical Conductivity Sensor

General Description/How it works: Electrical conductivity (in uS/cm) is the measurement of how well a sample of water conducts electricity. This is dependent on the number of dissolved ions in the water which means electrical conductivity is proportional, but not identical to total dissolved solids (TDS). The sensor being used to measure electrical conductivity is a small four probe tab attached to an in house PCB. The in house PCB is a Wenner circuit designed to drive current through the four probes and output voltage and current through the probes in digital values that are easy to convert to uS/cm with a calibration curve.

Smart Rock Use Validation: Having an electrical conductivity measurement on the Smart Rock is cost effective and important to proving the capability of the sensor package. Electrical conductivity can be very good for assessing water quality on a chemical scale and measuring metrics such as pollution, purity, drinkability, and salinity.

Central Electronics System

The central electronics of the Smart Rock consist of an Adafruit FeatherM0 Proto microcontroller and an OPEnS Lab Hypnos manager board.

Insert pic of Feather/Hypnos stack

The Feather M0 Basic Proto is an Arduino-compatible microcontroller that runs on 3.3 volts. The Feather acts as the main microcontroller for Smart Rock. Integrated into the electronics stack, the Feather runs the Smart Rock code and operates the I2C interface to connect all of the peripheral devices together. The Feather saves data to the SD card as a .xlsx from the stream on Hypnos.

The Hypnos board is an attachable precision I2C integrated real time clock and data logger. A coin cell battery is plugged into the board to keep time even when a battery is not connected through the Feather. The Hypnos also controls the rails on the central electronics stack to allow the device to "sleep" and save power between measurements. Data is saved and read to/from an SD card via I2C through the Hypnos.

More information about the Hypnos Board can be found here.

4-Pin Electrical Conductivity Breakout Board

General Description/How it works: The EC Breakout board is the baseboard of the Smart Rock. This breakout board ties all of the electronics together. It includes headers for the OPEnS Lab Hypnos and Adafruit Feather M0 to stack on, and four I2C ports for the other sensors. This board also hosts the signal processing for the Wenner-circuit EC sensor, which is sampled via the ADS1115 (our Analog to digital converter) to be sent to the Hypnos through the I2C bus. We have recently finished designing the newest version of this board to include a higher range, accuracy, and precision on the EC sensor, check it out here! Board layout shown below.

EC_Breakout

The newly designed version 5 of our 4-pin EC breakout board has yielded promising initial results, with an increased range between 10 uS/cm and 12800 uS/cm! This new version also has much higher precision and accuracy, with reduced noise and variance due to the method of sampling the measured signals form the water. In previous versions, we have tried rectifying the AC signal at the input of the ADS1115 which can be inconsistent and cause other issues. In this version however, we are using a track and hold method for sampling the signal, giving us a more accurate value from the signal. Below are some images from our early calibrations with this new board.

For more information on the version 5 of the 4-pin EC breakout board, check out Paul Gasper's paper.

Last Edited: 2/17/2025

Casing Design

The outer case is made of a piece of PVC with an union fitting at one end and a cap at the other. The union fitting and cap are mounted to the PVC using a layer of primer, then a layer of PVC cement. The smaller diameter, unthreaded, section of the union fitting is discarded and replaced with a circular piece of acrylic. This piece of acrylic has laser-cut holes for the sensors to be epoxied to make water-tight. The o-ring in the union fitting is coated in silicone grease to ensure a waterproof seal when the end of the union fitting is screwed back on with the acrylic. This modded union fitting design is used so that the electronics may be accessed and so that we can have the sensors protruding from one end without getting their wires twisted and tangled when the end is removed.

SmartRock_Enclosure *Note this image is just the PVC enclosure.

The internal structure is made up of an acrylic platform that slides into the PVC enclosure. The electronics are then mounted this acrylic structure and slid into the case. Using the acrylic structure makes it easy to remove/access the electronics and holds everything in place. The electronics stack up on the slide allowing for a compact design.

SmartRock_AcrylicStructure *Note that the image above does not include electronics.

What's New?

Switching to a new Turbidity Sensor!

Through Smart Rock version 4, we were using DFRobot's Analog Turbidity Sensor as it was cost effective, easy to use, and gave reliable qualitative results in a controlled setting.

Turbidity

Unfortunately, this turbidity sensor is sensitive to ambient light. This means that there is some ambiguity of what causes turbidity data to rise or fall, actual TSS or light hitting the sensor. This was a major issue for Smart Rock as its intended use is outside where light changes frequently. To remedy this we designed 3d printed caps to cover the sensor in an attempt to reduce incoming ambient light.

Turbidity cap

The full test can be viewed here

In this test we observed marginal benefit from using the black turbidity cap, but we decided to look for a new way to measure turbidity moving forward.

Turb Test

Luckily, we found a method described in a research paper by Theodore Langhorst, that is unaffected by ambient light making it much more suitable for environmental use than our previous sensor. This sensor is also contained in a smaller footprint, creates one less leak point in the faceplate, and is cheaper than the previous sensor making it an all around upgrade to our previous version.

Insert VCNL on smart rock pic

From our lab tests with this sensor, we can retrieve accurate measurements of turbidity in NTU after calibrating each sensor upon assembly. For our initial smart rocks, we calibrated these sensors with turbidity standard solutions. An example of one of these calibrations is shown below.

Insert normal calibration here

This method of calibration is unsustainable however, as turbidity standard solutions are very expensive. Instead, we used these calibrated sensors to assign turbidity values in NTU to various concentrations of suspended bentonite clay mixed into clear water. This equation can now be used to calibrate all future sensors with the far cheaper bentonite clay. Below is our resulting calibration graph relating the concentration of bentonite clay (x-axis) to the measured NTU (y-axis).

insert NTU->bentonite calibration here

Adding Dissolved Oxygen to the Smart Rock!

Now that we are arriving at a finalized state on the four main water characteristics we aimed to measure with the Smart Rock, it's time we tried exploring with some other crucial sensors. To start off, we are experimenting with a new I2C dissolved oxygen sensor that uses a semi-permeable membrane to separate the gasses from the surrounding water and measure oxygen concentration. This method can also be used to measure other important gasses, but oxygen will be the starting point for the Smart Rock.

inset pic of DO sensor on faceplate

One of the biggest roadblocks we are working to move past is the physical space limitation of the Smart Rock faceplate. With the current sensor layout, it is difficult to find a way to make the D.O. sensor fit, but we are looking into ways we can allocate more space for it.

Objectives

  • Low cost

  • Durable

  • Senses underwater pressure for depth

  • Senses stream temperature

  • Senses turbidity

  • Senses salinity

  • Battery life of at least 3 months

  • Clean and user-friendly electronics packaging

  • Keeps time for data collections

  • Connects to user easily

  • Waterproof

  • Remains in the location of placement

  • Safe for the environment

  • Withstand freezing temperatures

  • Easy internal access

  • Easy to retrieve and transport

Outcomes

Current capabilities of Smart Rock sensors are depth measurement with accuracy within 0.13 mbar resolution as compared to an out of water pressure sensor, temperature accuracy of fewer than 0.01°C, turbidity measured in JTU, and a salinity measurement with an accuracy of less than 5 parts per million. Future developments will have flow sensing from the use of multiple high-accuracy pressure sensors. Battery life for Smart Rock is up to 3 months with low power sleep, a function that limits power usage from the device when dormant. This can be extended by taking data less often than once every 20 minutes. The device currently costs ~ $250 with these specifications and custom parts and takes about 10 hours to assemble and program.

Future

The Smart Rock team is developing and revising the Smart Rock to improve the user experience and improve the quality of the Smart Rock.

Resource List

Github repository where code, design files, and guides can be found.

Tutorials

Here are resources from the 2020 and 2021 CUAHSI workshops.

Key Words

OPEnS, SmartRock, Smart Rock, Feather M0, Adalogger, Arduino, Stream, Water Monitor, Hydrological Data, Hydrological Monitoring, Pressure, Temperature, Electrical Conductivity, Dissolved Solids, Turbidity, seasonal streams, small streams

References

Software

  • Fusion 360. (2018). San Rafael, California: Autodesk.

  • EAGLE CAD. (2018). San Rafael, California: Autodesk.

  • Arduino IDE. (2020). Turin, Italy: Arduino