sam3x-flash

Crates.iosam3x-flash
lib.rssam3x-flash
version0.2.5
created_at2025-12-28 01:31:35.535603+00
updated_at2025-12-28 01:52:58.927746+00
descriptionFlash algorithm for the Atmel SAM3X/A family.
homepagehttps://sr.ht/~az1/sam3x-rs/
repositoryhttps://git.sr.ht/~az1/sam3x-flash
max_upload_size
id2008103
size77,440
(inferiorhumanorgans)

documentation

README

sam3x-flash

A flash algorithm for the Atmel SAM3X/A family of Arm Cortex M3 based microcontrollers. Its big advantages over the stock Atmel algorithm are that it will allow probe-rs to properly reset the board after writing a program and that it defines a contiguous RAM region that represents the entirety of the on-chip RAM. The latter is required for probe-rs to instantiate RTT.

The generated algorithm and probe-rs compatible chip description file are located in the generated directory.

Dependencies

target-gen must be installed in your path via e.g. cargo install.

Usage

To use as-is with probe-rs set the --chip-description-path option to point at the appropriate YAML file in the generated directory.

To build an algorithm simply run cargo run --bin=VARIANT where VARIANT is the chip you're targeting. Supported variants:

  • sam3a4c
  • sam3x4c
  • sam3x4e
  • sam3a8c
  • sam3x8c
  • sam3x8e
  • sam3x8h

Unless you have a probe connected to your computer and to a supported device the build will "fail", but the ELF and YAML artifacts will be generated successfully. If you have a probe and target device connected its flash will be wiped per the algorithm.

The YAML artifacts for probe-rs are located in: target/. The Open-CMSIS-Pack compliant ELF artifacts for other tools are located in: target/thumbv7m-none-eabi/.

Commit count: 0

cargo fmt