Manual Build & Flash

Build the firmware from source and flash it with the Rust ESP toolchain. This is the route to take if you want to modify the firmware. For a deeper tour of the codebase and the build/test commands, see Architecture and Building & Testing.

Install the toolchain

If you don’t have cargo yet, install Rust via rustup first. Then install the ESP toolchain:

cargo install espup --locked
espup install
cat $HOME/export-esp.sh >> ~/.bashrc
source ~/.bashrc
cargo install espflash ldproxy

Build and flash

Clone the repository and build:

git clone https://github.com/f321x/offline-bitcoin-atm.git
cd offline-bitcoin-atm
cargo build --release
cargo run --release   # builds and flashes to the connected ESP32

cargo run uses the espflash runner configured in .cargo/config.toml.

Note

The flash step erases the NVS config partition, so the device returns to the WiFi configuration portal on the next boot. Continue with Configuration.

After flashing, the ATM starts a WiFi access point for initial configuration.