MAKE YOUR OWN PH AND SALINITY MONITORING SYSTEM WITH LED INDICATORS

Introduction: MAKE YOUR OWN PH AND SALINITY MONITORING SYSTEM WITH LED INDICATORS

About: Founded in 2005, Atlas Scientific specializes in building laboratory grade sensing equipment for robots, appliances, and industrial control systems. Thousands of Atlas Scientific sensors can be found in a wide…

In this project, we will be making a pH and salinity/conductivity monitoring system with LED indicators. The pH and salinity sensors from Atlas Scientific are used. Operation is via I2C protocol and readings are displayed on the Arduino serial monitor.

The LEDs are turned on if the sensor readings go out of the predefined limits. In this case, the limits are as follows: If the conductivity reading goes over 500 μS/cm, the yellow LED will turn on; if the pH reading goes over 10, the red LED will turn on. The use of LEDs offers a demonstration of how sensor readings can be used to trigger other hardware.

WARNINGS:

  • Atlas Scientific does not make consumer electronics. This equipment is intended for electrical engineers. If you are not familiar with electrical engineering or embedded systems programming, these products may not be for you.
  • This device was developed and tested using a Windows computer. It was not tested on Mac, Atlas Scientific does not know if these instructions are compatible with a Mac system.

ADVANTAGES:

  • Real-time pH and salinity readings.
  • Can be expanded to include more types of Atlas's EZO sensors.
  • Ability to use sensor readings to control other hardware.
  • Minimum programming skills needed unless you plan on modifying the project.

MATERIALS:

Step 1: PRE-ASSEMBLY REQUIREMENTS

a) Calibrate the sensors. Each sensor has a unique calibration process. Refer to the following: Ezo pH datasheet, Ezo EC datasheet.

b) Set sensors' protocol to I2C. Each sensor needs a unique I2C address. In accordance with the sample code for this project, the following addresses are used: pH sensor address is 99, and salinity sensor address is 100. For information on how to change between protocols and assign addresses, refer to this LINK.

The calibration and the switch to I2C MUST be done before implementing the sensors into this project.

Step 2: ASSEMBLE HARDWARE

Connect the hardware as shown in the schematic above.

You can use either an Arduino UNO or a STEMTera board. The STEMTera board was used in this project for its compact design where the Arduino is combined with the breadboard.

The 220Ω resistors limit the current to the LEDs, preventing them from blowing out.

The Inline Voltage Isolator isolates the pH circuit from the salinity circuit, thus protecting it from any electrical interference (noise) that may originate from the salinity sensor or other electronics in the system.

Step 3: LOAD PROGRAM ONTO ARDUINO

The code for this project makes use of a customized library and header file for the EZO circuits in I2C mode. You will have to add them to your Arduino IDE in order to use the code. The steps below include the process of making this addition to the IDE.

a) Download Ezo_I2c_lib, a zip folder from GitHub onto your computer.

b) On your computer, open the Arduino IDE (You can download the IDE from HERE if you do not have it). In the IDE, go to Sketch -> Include Library -> Add .ZIP Library -> Select the Ezo_I2c_lib folder you just downloaded. The appropriate files are now included.

c) Copy the code from pH_EC_led_indicator onto your IDE work panel. You can also access it from the Ezo_I2c_lib zip folder downloaded above.

d) Compile and upload the pH_EC_led_indicator code to your Arduino Uno or StemTera board.

e) In your IDE, go to Tools -> Serial Monitor or press Ctrl+Shift+M on your keyboard. The serial monitor will open. Set the baud rate to 9600 and select "Carriage return"

Step 4: DEMONSTRATION

Summary of the experiment shown in the video:

  • The initial pH and EC of water are measured.
  • Some NaCl (salt) is added to the water, the conductivity reading rises and as soon as it crosses 500μS/cm the yellow LED turns on.
  • Then some pH UP solution is poured into the beaker, the pH increases and upon crossing 10 and the red LED turns on.
  • Finally, some pH DOWN solution is added and the pH decreases. When the reading is less than 10, the red LED turns off.

Be the First to Share

    Recommendations

    • Tinkercad Student Design Contest

      Tinkercad Student Design Contest
    • Back to School: Student Design Challenge

      Back to School: Student Design Challenge
    • Rocks, Gems, and Stones Speed Challenge

      Rocks, Gems, and Stones Speed Challenge

    2 Comments

    0
    arayy098
    arayy098

    11 months ago on Step 4

    Good evening, i want to ask you bout this project. how if i use it with UART communication? is there any refer i can do?

    0
    AtlasScientific
    AtlasScientific

    Reply 11 months ago

    We do not have any example of this project using UART communication but it can be done. The hardware setup and coding would be different.