This crate provides a type-safe Rust API for working with the Adafruit ItsyBitsy M4 Express board.
rustup target add thumbv7em-none-eabihf
Check out the repository for examples:
https://github.com/atsamd-rs/atsamd/tree/master/boards/itsybitsy_m4/examples
cd boards/itsybitsy_m4
$ cargo hf2 --release --example blinky_basic
Finished release [optimized + debuginfo] target(s) in 0.19s
Searching for a connected device with known vid/pid pair.
Trying Ok(Some("Adafruit Industries")) Ok(Some("PyBadge"))
Flashing "/Users/User/atsamd/boards/itsybitsy_m4/target/thumbv7em-none-eabihf/release/examples/blinky_basic"
Finished in 0.079s
$
Note some examples will tell you they need more features enabled
$ cargo hf2 --release --example usb_serial
error: target `usb_serial` in package `itsybitsy_m4` requires the features: `usb`, `use_uart_debug`
Consider enabling them by passing, e.g., `--features="usb use_uart_debug"`
Just follow the instructions to add --features like
cargo hf2 --release --example usb_serial --features="usb use_uart_debug"
Finished release [optimized + debuginfo] target(s) in 0.09s
Searching for a connected device with known vid/pid pair.
Trying Ok(Some("Adafruit Industries")) Ok(Some("PyBadge"))
Flashing "/Users/User/atsamd/boards/itsybitsy_m4/target/thumbv7em-none-eabihf/release/examples/usb_serial"
Finished in 0.167s
$