Building a DIY Turbidity sensor – Version III

The next iteration of the turbidity sensor requires more thorough waterproofing from the beginning. Prototype I started as a simple proof-of-concept of the component combination ( LED, LDR in a garden hose enclosure) and had no consideration of waterproofing. After that, the focus of Prototype II lay on improving the initial design’s lack of water-proofing and adding long cables so it can be eventually tested out in the field.

Part I: Components, cables and heat shrinking tube

For this turbidity sensor design, I used an approximately two-meter-long stranded core CAT-5 cable to connect my white LED and my LDR to my Wemos D1 board.

After assembly, I immediately sealed the components that eventually get submerged into the water with heat shrink tubing (yellow for the LED, green for the LDR).

My first attempt at running the test code with the components through the two-meter-long wire went well. I tested the incoming values roughly by concealing the LDR with my finger.

Part II: Housing the components in the “test tube.”

Similar to the previous prototype, I cut a new 10cm piece off the garden hose and drilled two opposing holes of the size of the components in the centre. To attach the LDR and the LDR I used hot glue only this time. The reasoning behind this is that hot glue has a much shorter drying/hardening time than the All Clear sealant. This allows an efficient applying of layer after layer within a relatively short period. The sealant ideally requires overnight drying which means assembly would span several days instead of hours.

The work with hot glue is messy and requires diligence. Therefor, the purpose of the first layer is to attach the components to the hose and make sure they are facing each other correctly.

After the first layer has been applied I test that the components have not been damaged in the process of hot glueing. The incoming values look good so far, but I am not entirely happy with the design. It is quite hard to apply hot glue around the components evenly. I already spot some small grooves in the glue that could cause some leaks later on.

Part III: Dear hot glue, please protect my components

While applying the next layer of hot glue, I have already made peace with the fact that this probe is going to look very odd. Basically, I am looking at a small dark-green piece of garden hose attached to a long cable with semi-transparent blobs of glue. I also notice that the wire close to the components appears to be under strain caused by the angle the components are attached to the hose. I should have immediately bent the connectors at a right angle to avoid this oddly shaped glue blob altogether.

Despite the aesthetic shortcomings of this turbidity sensor design all components seem to be working, and I am ready to compile a version that sends data wirelessly via the MQTT network so I can safely test the design in an underwater setting, without the need of a laptop attached to any submerged components.

References
donblair. (2015, August 25). Turbidity 001. Retrieved January 18, 2019, from publiclab.org/n/12168
Kelley, C., Krolick, A., Brunner, L., Burklund, A., Kahn, D., Ball, W., & Weber-Shirk, M. (2014). An Affordable Open-Source Turbidimeter. Sensors, 14(4), 7142–7155. https://doi.org/10.3390/s140407142
NIWA. (2008, December 17). Training notes. Retrieved January 28, 2019, from https://www.niwa.co.nz/our-science/freshwater/tools/shmak/manual
/15trainingnotes
Open Water Project. (n.d.). Open Water Project. Retrieved January 28, 2019, from https://github.com/OpenWaterProject

Turbidity Sensor II – Improved design with material issues

With this revised prototype I aimed to create a better, more stable design by inserting the LED and the photocell through holes into the hose while improving the sealing of electrical components from the beginning. I also wanted to use a cable with the actual length for use in the field and chose an approximately 2m long stranded core CAT-5 cable.

First I soldered the photocell to the green pair of cables and tested it with the code from yesterday.

I drilled 5mm hole into the hose to fit the LDR neatly.

The 3mm LED requires a 3mm hole respectively. I drilled the 3mm through the 5mm hole to make sure the holes are nicely aligned.

Reconnecting the wires with the breadboard from the previous prototype I ended up swapping the resistor to a 10k one which gave me more consistent readings when the LED was on half brightness.

 

For the sealing, I purchased the All Clear sealant that I have previously used for waterproofing my hydrophone. As opposed to hot glue, this material stays flexible when dried out and doesn’t run the risk of getting brittle.

Unfortunately one of the LED solder points was not well done, and I only discovered it after having added the sealant. With the cable disconnected, this prototype is unusable in the field, but the process of building it helped me understand possible avenues for improvement:

The design with the components stuck through tight-fitting holes is cleaner but needs to be revised with waterproofing in mind.

Solder points need to be stress tested and – if necessary re-done – before adding sealant.

Cables need to be fixed into place before adding sealant. Sealing might need to be re-done in the 3D workshop with proper ventilation and safety gear as this might require the use of turpentine.

Sealant might need to be changed as it might not be ideal in combination with cables/electronics.

 

Component List:

Hardware:

  • Computer with USB interface
  • Wemos D1 mini (know known as LOLIN
  • 1 LDR
  • 1 10k Resistor
  • 1 3mm white LED
  • Drill with 3mm and 5mm bits
  • All Clear Sealant

Software

Building a turbidity sensor – prototype I

Asked for what kind of sensor they would like to see added to the kit, participants indicated the interest to know more about the clarity of the stream water.

The SHMAK kit (see for example NIWA, 2008) also features the measurement of water clarity either with the Clarity Tube the Black Dish method. The training guide states that

“What you are looking for in your clarity results is any change over time. If there is a change to more turbid, then you then need to look for reasons.” (NIWA, 2008)

Hence a probe constantly measuring the clarity of the water appears to be a useful addition to the sensor family.

Research on other DIY turbidity sensors:

donblair (2015) provides a good  overview of turbidity, “how it’s usually assessed, and various approaches one might take to measuring it.” The Open Water Project Github repository features comprehensive documentation of their turbidity sensor design.

The most simple DIY design involves only two components, a light source aimed at a light-sensitive photocell (see for example Marchetto’s design as described in donblair (2015). With all components (an LED, an LDR and various resistors) at hand in the lab, the next step involves considering different enclosures and ways of waterproofing the components. An option suitable for Papawai Stream needs to work in relatively shallow waters and should obstruct the natural course of the stream as little as possible. Hence, a tube with a diameter of around 1-3cm, akin to the usually shallow depth of Papawai Stream would be a good first prototype. The tube should be dark to minimise ambient light impacting the sensor readings.

Prototype 1: Garden Hose enclosure

A relatively cheap and easy to recycle material that is suitable to be used in water is a garden hose. For the Prototype 1, I use a piece of garden hose of about 10cm.

Image showing a garden hose being cut with a craft knife
Preparing the hose

First I connected the LDR sensor and the LED on a breadboard to test the sensor readings via Serial. The Arduino code used for this version of the prototype can be found here.

Image showing the Wemos D1 mini microcontroller on a breadboard connected to an LDR (light dependent resistor) and a white LED.
Wemos D1 breadboard setup

It turned out that a 2K resistor for the LDR and a relatively low brightness value for the white LED shows a consistent change in the tube.

analogWrite(ledPin, 64);

These values are good enough for general testing of the design and will likely need to be adjusted to the conditions in the field.

Image showing the inside of the garden hose containing the white LED pointing at the LDR
Image of the inside of the garden house with the LDR and LED

I cut the hose in half to position the components inside and used transparent sellotape to attach the two halves back together. This design generally worked but required some work making sure that the electonics don’t short circuit.

Image showing a top down view of the garden hose and the breadboard
Breadboard Setup including garden hose

The next challenge is to waterproof the design. For this first iteration, I chose hot glue to seal the exposed wires of the components, similar to Marchetto’s design (as cited in donblair, 2015, see image).

The four wires sticking out of the submerged part of the sensor need careful waterproofing. While hot glue generally works, it runs the risk to break once set. A flexible waterproof sealant would be safer.

Image showing the garden hose and components in a vice covered in hotglue
Attempt of using hot glue to attach the sensor and LED to the use

I will redo the design with proper cables connected to the sensors for more safety and the ability to test the sensor submerged in water.

Component List:

Hardware:

  • Computer with USB interface
  • Wemos D1 mini (know known as LOLIN
  • 1 LDR
  • 1 2k Resistor
  • 1 3mm white LED

Software

Arduino… Tools… Board showing list of ESP8266 boards

 

 

donblair. (2015, August 25). Turbidity 001. Retrieved January 18, 2019, from publiclab.org/n/12168
Kelley, C., Krolick, A., Brunner, L., Burklund, A., Kahn, D., Ball, W., & Weber-Shirk, M. (2014). An Affordable Open-Source Turbidimeter. Sensors, 14(4), 7142–7155. https://doi.org/10.3390/s140407142
NIWA. (2008, December 17). Training notes. Retrieved January 28, 2019, from https://www.niwa.co.nz/our-science/freshwater/tools/shmak/manual/15trainingnotes
Open Water Project. (n.d.). Open Water Project. Retrieved January 28, 2019, from https://github.com/OpenWaterProject