commit b2c463b1c28e913b3e95a691f05f3a57d81ea26d parent a892593ea5248ec9a474b999f98ce1fe545149e7 Author: Daniel Barlow <dan@telent.net> Date: Wed, 4 Feb 2026 19:30:06 +0000 "make install" to flash locally Diffstat:
| M | Makefile | | | 9 | ++++++--- |
| M | README.md | | | 2 | +- |
2 files changed, 7 insertions(+), 4 deletions(-)
diff --git a/Makefile b/Makefile @@ -1,18 +1,21 @@ IMAGE=./target/riscv32imc-unknown-none-elf/release/ecu-esp32 -$(IMAGE): $(wildcard ecu-esp32/src/*.rs) pubkey.bin ecu-esp32/Cargo.toml Cargo.toml +$(IMAGE): $(wildcard ecu-esp32/src/*.rs) Makefile pubkey.bin ecu-esp32/Cargo.toml Cargo.toml echo $< cargo build --release -.PHONY: build +.PHONY: build ota install build: $(IMAGE) Makefile ota.bin: $(IMAGE) espflash save-image --chip esp32c3 $< $@ -install: ota.bin +ota: ota.bin time python otaclient.py $< +install: $(IMAGE) + espflash flash --erase-parts otadata --partition-table ./partitions.csv --monitor --chip esp32c3 $< + privkey.pem: openssl genpkey -algorithm ed25519 -out privkey.pem diff --git a/README.md b/README.md @@ -20,7 +20,7 @@ so you can test it only by running it. ``` cargo test -p ecu-portable --target x86_64-unknown-linux-gnu - SSID=my-wifi PASSWORD="my-wifi-password" cargo run --release + make BUILD_ID=$(date +%y%m%d-%H%M%S) install ```