PAC for the Vorago VA108xx microcontroller family
This repository contains the Peripheral Access Crate (PAC) for Voragos VA108xx series of Cortex-M0 based microcontrollers.
The crate was generated using svd2rust.
If you are interested in higher-level abstractions, it is recommended you visit
the va108xx-hal HAL crate and the vorago-reb1 BSP crate which build on top of this PAC.
Usage
To use this crate, add this to your Cargo.toml
[]
= "<Most Recent Version>"
= ["rt"]
The rt feature is optional and recommended. It brings in support for cortex-m-rt.
For full details on the autgenerated API, please see the svd2rust documentation.
Optional Features
defmt: Add support fordefmtby adding thedefmt::Formatderive on many types.debug: AddDebugderives for various structures
Regenerating the PAC
If you want to re-generate the PAC, for example if the register file va416xx.svd changes
or the svd2rust version is updated, you can do some using the following these steps:
-
Make sure all necessary tools are installed:
svd2rust,svdtoolsandform. You can install all tools withcargo: -
Patch the vendor-provided SVD file
svd/va41xx.svd. This can be done usingsvdtoolsin conjunction with thesvd/va108xx-patch.ymlfile. -
Use
svd2rustto generate the Rust library -
Use the
formtool to split the generatedlib.rsinto individual modules.
The gen-helper.sh automates steps 2-4.