volt-cli

module
v0.2.5 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Nov 1, 2026 License: AGPL-3.0

README

volt-cli

The volt command of Volt Embedded. Volt is a typed language for microcontroller firmware; this one program creates projects, checks and compiles them, installs the chip toolchains, builds firmware, flashes the board and shows its serial output. Volt IDE runs the same program underneath.

Install

macOS and Linux:

curl -fsSL https://voltembedded.com/install.sh | sh

Windows: download volt-windows-amd64.zip and put volt.exe on your PATH. Every build is listed at dl.voltembedded.com with its checksum. volt update installs the latest release.

Quick start

volt new blink --chip esp32
cd blink
volt check        # type-check and validate the hardware, no build
volt run          # build, flash the connected board, then monitor it

The first build for a chip installs its toolchain into ~/.volt/toolchains; downloads are signature-checked.

Commands

Command What it does
volt new <name> Create a project: volt.toml and a starting main.volt
volt check Type-check and validate the hardware without building
volt compile Compile to C
volt fmt Format .volt files
volt build Build firmware into <project>/build/<chip>/
volt flash Flash the last build to a connected board
volt run Build, flash, then monitor
volt monitor Show a board's serial output
volt ports List connected boards
volt toolchain Check, install or repair a chip's toolchain
volt sdk sync Update the device library
volt trust Show or record which device libraries you approved
volt history The project's automatic change history, with diffs and undo
volt spec Print the language reference
volt mcp Serve Volt's tools (check, device cards, the language reference) to coding agents over MCP
volt update Update volt to the latest release

volt help lists every command with its options.

Develop

Requires Go 1.26. The CLI builds against volt-compiler, which go.mod expects in a sibling folder named compiler:

git clone https://github.com/PhilemonChiro/volt-compiler compiler
git clone https://github.com/PhilemonChiro/volt-cli cli
cd cli
go build ./cmd/volt
go test ./...

On macOS the build needs cgo (serial port listing uses IOKit). Releases are built with scripts/release.sh.

Path Contents
cmd/volt/ The commands
internal/build/ Firmware builds (ESP-IDF, Pico SDK), size reports
internal/toolchain/ Toolchain download, verification and install
internal/esptool/, internal/device/ Flashing and serial ports
internal/libtrust/ Device library approval records
internal/sdk/, internal/sdkfiles/ The bundled runtime and device library

License

GNU AGPL v3. A commercial licence is available: contact pchiro29@gmail.com. Contributions are made under the Contributor License Agreement; see CONTRIBUTING.md.

Directories

Path Synopsis
cmd
volt command
Command volt is the Volt command-line tool: check, compile and format Volt programs, manage build toolchains, and serve the IDE worker protocol.
Command volt is the Volt command-line tool: check, compile and format Volt programs, manage build toolchains, and serve the IDE worker protocol.
internal
build
Package build turns compiled Volt C into firmware: it generates a per-project build directory against the read-only framework and runs the chip's native build, reporting progress the way the IDE shows it.
Package build turns compiled Volt C into firmware: it generates a per-project build directory against the read-only framework and runs the chip's native build, reporting progress the way the IDE shows it.
device
Package device finds connected boards and talks to them over serial.
Package device finds connected boards and talks to them over serial.
esptool
Package esptool does in Go what Volt used Espressif's esptool (Python) for: making an app image from an ELF (elf2image) and writing images to a board.
Package esptool does in Go what Volt used Espressif's esptool (Python) for: making an app image from an ELF (elf2image) and writing images to a board.
history
Package history keeps a private, automatic git history of a Volt project: every save, AI edit and outside change becomes a commit whose author says who made it (you, Volt Assistant, an AI app, or a change outside the IDE).
Package history keeps a private, automatic git history of a Volt project: every save, AI edit and outside change becomes a commit whose author says who made it (you, Volt Assistant, an AI app, or a change outside the IDE).
libtrust
Package libtrust decides whether the device libraries and framework a build compiles are ones the user approved.
Package libtrust decides whether the device libraries and framework a build compiles are ones the user approved.
proc
Package proc starts external tools so that cancelling volt (Ctrl-C, or the IDE killing it with SIGTERM) also stops everything they spawned: idf.py, install.sh and git leave grandchildren (ninja, gcc, pip) that would otherwise keep running and holding the build dir or serial port.
Package proc starts external tools so that cancelling volt (Ctrl-C, or the IDE killing it with SIGTERM) also stops everything they spawned: idf.py, install.sh and git leave grandchildren (ninja, gcc, pip) that would otherwise keep running and holding the build dir or serial port.
sdk
Package sdk makes and uses prebuilt ESP-IDF packs: everything an ESP32 firmware build needs from ESP-IDF (component archives, headers, linker scripts, bootloader, partition table, exact flags), harvested from one real ESP-IDF build of a reference project.
Package sdk makes and uses prebuilt ESP-IDF packs: everything an ESP32 firmware build needs from ESP-IDF (component archives, headers, linker scripts, bootloader, partition table, exact flags), harvested from one real ESP-IDF build of a reference project.
sdkfiles
Package sdkfiles ships the device library and framework inside the volt binary, so a plain install can build without the IDE.
Package sdkfiles ships the device library and framework inside the volt binary, so a plain install can build without the IDE.
term
Package term renders the compiler's Rich-style markup ([red bold]…[/red bold]) as ANSI colour, or strips it when the output is not a terminal.
Package term renders the compiler's Rich-style markup ([red bold]…[/red bold]) as ANSI colour, or strips it when the output is not a terminal.
toolchain
Package toolchain provisions the build tools each chip needs: manifest assets (SHA-256 pinned, from a signed or built-in manifest), pinned SDK clones and vendor installers.
Package toolchain provisions the build tools each chip needs: manifest assets (SHA-256 pinned, from a signed or built-in manifest), pinned SDK clones and vendor installers.
scripts
embedsdk command
Command embedsdk refreshes the SDK built into volt (internal/sdkfiles/sdk) from the repo: the framework, the device examples, and only the default device libraries listed in volt/default-libraries.txt.
Command embedsdk refreshes the SDK built into volt (internal/sdkfiles/sdk) from the repo: the framework, the device examples, and only the default device libraries listed in volt/default-libraries.txt.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL