Skip to content
This repository has been archived by the owner on Aug 7, 2021. It is now read-only.
/ nrf9160-pac Public archive

Peripheral Access Crate for the nRF9160 microcontroller

License

Notifications You must be signed in to change notification settings

nrf-rs/nrf9160-pac

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

32 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

MOVED! This repository has been moved to https://github.com/nrf-rs/nrf-pacs.

nrf9160-pac

This crate is a Peripheral Access Crate (or PAC) for the nRF9160 generated using svd2rust and the official SVD file. A Peripheral Access Crate contains low-level register defintions.

For most purposes, you want the HAL instead.

Regenerating

To regenerate the crate, first make sure that svd2rust and form are installed and up-to-date. Put nrf9160.svd into the repo directory and run:

# Fixup
sed -i 's/read-writeonce/read-writeOnce/' nrf9160.svd

# Generate
svd2rust -i nrf9160.svd
form -i lib.rs -o src
cargo fmt

# Clean up
rm lib.rs

Note that some things in the generated Rust code might need to be fixed manually after these steps.