This package provides various water monitoring tools for sensor and pump integration. At the current stage of development the package includes temperature monitor, ph monitor, ph controller.This package uses the RPI-Control-center gpio engine as its driver to make RPI API-ification easy. At this current stage this python package is only for the Raspberry pi and uses DFRobot sensor library as well as the ADC integration
- Documentation: Coming soon
- Github
- pip
pip install RPi-water-tools
- source
git clone https://github.com/moha7108/water-tools
cd water_tools
pip install -e
from water_tools import monitors, ph_control
import time
if __name__ == '__main__':
temp_monitor = monitors.TempMonitor()
ph_monitor = monitors.PHMonitor(temperature_api_file = './api/TEMPERATURE.json')
ph_controller = ph_control.PHController(ph_api_file='./api/PH.json', config_file='./ph_config.json', api_dir = './api/', log_dir = './logs/')
temp_monitor.start()
ph_monitor.start()
ph_controller.start()
try:
################### Place any other code here since its non blocking
while True:
time.sleep(1)
except:
temp_monitor.stop()
ph_monitor.stop()
ph_controller.stop()
- will be updated
- Raspberrypi 3B+
- OS: Rasbian Buster +
cd
sudo apt update
sudo apt list --upgradeable
sudo apt ugrade
sudo apt autoremove
sudo apt-get install wiringpi
wget https://project-downloads.drogon.net/wiringpi-latest.deb
sudo dpkg -i wiringpi-latest.deb
gpio -v
sudo apt-get install libopenjp2-7 -y
sudo apt-get install libatlas-base-dev -y
sudo apt install libtiff -y
sudo apt install libtiff5 -y
sudo apt-get install -y i2c-tools
All kinds of feedback and contributions are welcome.
- Create an issue
- Create a pull request
- Reach out to @moha7108
- fix return values when exception is hit during get ph process of the ph monitors
- add temp and voltage attributes to ph monitor for better data handling
- return valuse based on object attributes
- Ph controller success flag when begin() is complete
- fix error handling of ph controller
- Add error handling when api is busy and parameter getters access file when they are being written to
- first working code debut