Skip to content

InzynierDomu/PhECMeter

Repository files navigation

PhECMeter

GitHub Workflow Status GitHub release (latest SemVer) GitHub docs deployments Discord GitHub support

Description

The video with the entire project can be watched on this video

The device has 4 possible states:

  • measure pH
  • measure EC
  • calibartion pH
  • calibration EC

photo

The device start in pH measure mode. To chnage pH/EC measure mode - press up button for more than 1s.
To enter calibration mode press both buttons more 1s.
Measure pH -> calibration pH.
Measure EC -> calibartion EC.
Calibration mode needs 2 points to save.
Set the value to which sample the probe is immersed. For that use up and dwn(down) buttons to decrease or increase the value. In EC calibration possible is to change the digit position by pressing 1s up button. To save points press 1s on both buttons. After saving two points, the device changes state to measure.

When SD card is plugged, after short press down button measurements will be save in file on SD.

Future

  • Use accumulator.
  • Add some communication maybe RS232 or RS485.

Scheme

schem

Part list

  • pH probe and board like this
  • EC probe and board like this
  • A1 Arduino Nano
  • U1 ds18b20 temperature sensor
  • J1 is socket for pH board.
  • J2 is socket for I2C screen OLED SSD1306 128x32 or HD44780 via PCF8574.
  • R1 Resistor 4,7 kohm
  • SW1, SW2 micro switch
  • SW3 switch to turning on/of power
  • J3 connect to battery box
  • J5 SD card socket (optional)

IDE

If you prefer not to use the VS Code environment or prefer simpler solutions, you can use an alternative approach For specific screen is the prepared environment:
OLED SSD1306 128x32 :nanoatmega328_oled
HD44780 via PCF8574 :nanoatmega328_lcd

The project is prepared for the Platform IO environment. A video on how to install such an environment can be watched on this video.

Formatting is done using clang-format. The description of the tool configuration is in the video.

The code contains a comment prepared for doxygen, their use is described in the video.

Quick deployment without using VS Code environment

You don't need vscode, platformio is not needed, it will be installed with the script.

Requirements

  • Python 3.x must be installed on your computer. You can download the latest version of Python from Python.org.

Usage

  • Connect the Arduino board to your computer using a USB cable.
  • Ensure that Python is available in the system environment.
  • Run the autodeploy.bat file by double-clicking on it or running it from the command prompt (cmd). This script will automatically detect the connected Arduino board and upload the project to it.

Notes

  • It's version for oled.
  • Make sure that the path to Python is added to the PATH environment variable in the Windows operating system.
  • The atodeploy.bat script works only on Windows.