Water Quality Monitoring Program - Working Build

Updated: Mar 17, 2019

This week, I continued my work on a program which interfaces a Seneye reef water quality monitor with a Raspberry pi. After successfully establishing communication with the sensor, I wrote a quick function to translate the incoming raw byte arrays into JSON (JavaScript Object Notation), which is a text-based format used for storing and organizing data structures. I designed the program to run with superuser permissions when the Raspberry Pi boots, wait for a Seneye Reef sensor to be attached (if one is not already present), and then begin taking water quality readings periodically (currently at a rate of ~0.4Hz) until the sensor is detached. After every 300 readings, or when the sensor is detached, the program writes all of the JSON text strings that it collected from the readings into a single text file. Each text file is named according to the date/time when it started and ended collection, and the serial number of the sensor used to collect the data.


The program was also designed to listen for an internet connection and upload all not-yet-uploaded data to the Amazon cloud as soon as a connection was made, using a Python script written by Fred Bailey. Our initial goal of uploading the data periodically to the Amazon cloud over a Hologram Nova cellular USB connection is no longer viable due to the Nova's restrictions on data transmissions (packets must be less than 4kB, and apparently Hologram restricts JSON data to a single, short JSON object per transmission). For the time being, the upload protocol has been disabled and data is simply being stored until we find another way to upload the data.


After spring break, I hope to resume work on the project, bringing the read frequency up to at least 1Hz and rewriting my upload protocol to send data directly to the Amazon cloud via an ethernet connection when the pi is powered on and connected to the internet.

5 views

Recent Posts

See All

© 2013-2020 by UAS Academy - LASR@™, LASRlive™, T3™, and ATAP™ are Trademarks of UAS Academy