Our master/slave project design will involve connecting six Arduino Unos to a Raspberry Pi 4 via serial port.
First, you'll need to install setuptools for python, using the command
python -m pip install --upgrade pip setuptools wheel
Additionally, you'll need to install the PySerial library with the commands
sudo apt-get install python-serial
sudo pip install pyserial
In order to run the pilot program, first load the appropriate INO file to the Arduino Uno for each attached sensor. Then run the command
python3 sensors.py
from inside the sensors directory.
See autofarm-os/examples
for more other examples.
- Python - Programming language
- PySerial - Module for serial port access
- Arduino IDE - Microcontroller development
- Raspberry Pi 4 Model B, Raspberry Pi - Computer
- Arduino Uno, Arduino - Microcontroller
- Non-Contact Liquid Level Sensor, DFRobot - Sensor
- SHT20 Temperature & Humidity Sensor, Sensirion - Sensor
- Analog pH Sensor, DFRobot - Sensor
- Electric Solenoid Valve, BACOENG - Actuator
- 3-Way Motorized Ball Valve, HSH-Flo - Actuator
- Booster Pump, Aquatech - Actuator
- Aquatech Pressure Switch, AFWFilters - Actuator
- SolarSystem 275, California Lightworks - Actuator
- SolarSystem Controller, California Lightworks - Actuator Controller
- Matt Cherry, MattCKU - Sensor Design, Sensor Setup
- Kyle Curry, k19c90 - Actuator Setup
- Kristi Daigh, kdaigh - Sensor Pilot Program
- Zach Freund
- Ethan Lefert, elefert400