.. | ||
include | ||
arduino-cli.yml | ||
CanGrow.geany | ||
CanGrow.ino | ||
cangrow.sh | ||
README.md | ||
Screenshot_WebUI_root.png |
CanGrow - An OpenSource grow controller firmware
Build environment
The helper script cangrow.sh
is written for a Debian 12 system.
To install all dependencies you need for building the firmware, run the cangrow.sh setup:
$ ./cangrow.sh help
./cangrow.sh [setup|build|upload|webupload|monitor]
setup: setup build environment, download arduino-cli, install all dependencies for arduino ide
build: build firmware binary. will be saved into build/
upload: upload firmware by serial connection /dev/ttyUSB0
webupload: upload firmware with webupload to 192.168.4.20
monitor: serial monitor /dev/ttyUSB0
# Install all dependencies for build environment
$ ./cangrow.sh setup
The script installs arduino-cli to ~/.local/bin/arduino-cli
.
Compile
# compile and output to build/CanGrow_v0.2...bin
# Default Target is ESP8266 D1 Mini
$ ./cangrow.sh build
# Compile for ESP32 D1 Mini
$ export BOARD="esp32:esp32:d1_mini32"
$ ./cangrow.sh build
# Build and webupload to IP
$ export IP="192.168.4.69"
$ ./cangrow.sh build # need to make .bin first
$ ./cangrow.sh webupload # upload
# listen to serial monitor on /dev/ttyUSB2
$ export TTY="/dev/ttyUSB2"
./cangrow.sh monitor
I wrote this project using Geany IDE. . The Geany Projectfile is also included, just run
$ geany CanGrow.geany
F8 compiles the project, F9 uploads firmware to /dev/ttyUSB0. You can change these settings for .ino and .h files in Project -> Settings -> Create/Make.