Owen Campbell; Dolapo Toki; Samantha Yu
- Mount
cmpt433/publicfolder to BeagleBone over NFS- See http://www.cs.sfu.ca/CourseCentral/433/bfraser/other/NFSGuide.pdf for more information
- We'll assume that
cmpt433/publicon host gets mapped to$(HOME)/cmpt433/public/on the BeagleBone
$ cd BeagleBone$ make- Creates the executable
plantManagerincmpt433/public - Copies
sql/init.sqlto BeagleBone's$(HOME)/cmpt433/public/myApps/init.sql - Copies
scripts/createPlantDBto BeagleBone's$(HOME)/createPlantDBand makes this script executable
- Creates the executable
- Run
./createPlantDBto create the plant database in$HOME/plants.db$ - Run
./plantManagerto start the plant manager application
# cd ~# sqlite3 plants.db
- Run
$ npm installin website/plantmanager folder - Run
$ pip install -r requirements.txtin website/backend directory - Run
$ make websitefrom the BeagleBone folder - Run
# ./start_flask.shon the target to launch the web server - Connect to
http://target-ip:5000
$ cd esp- Use
PlatformIOto build and send to the connected ESP8266 - To view print statements on the ESP8266, open the serial monitor
- If the ESP8266 does not have network credentials saved, it will create a
PLANTWiFi Access Point - Connect to this Access Point and enter the SSID and password of the network the BeagleBone is connected to
- ESP8266 will automatically connect to that network moving forward
- ESP8266 main.cpp needs to contain the IP Address of the BeagleBone
- MOSFET gate pin should be connected to the D0 pin of the ESP8266
- SH (sensor's first pin): Humidity/Temperature
- Connect to a digital pin: GPIO_39 - P8_4
- SM (sensor's second pin): Moisture
- Connect to an analog pin: AIN1 - P9_40
- + (sensor's third pin): 3.3V/5V
- - (sensor's fourth pin): Gnd
- Don't forget to add pull-up resistors
- BeagleBone analog inputs take in only 1.8V; sensor operates at 3V-5V max
- SH (sensor's first pin): Humidity/Temperature
- Connect to a digital pin: D2
- SM (sensor's second pin): Moisture
- Connect to an analog pin: A0
- + (sensor's third pin): 3.3V/5V
- - (sensor's fourth pin): Gnd