Crate va416xx_hal

Source
Expand description

This is the Hardware Abstraction Layer (HAL) for the VA416xx MCU family.

It is an additional hardware abstraction on top of the peripheral access API.

It is the result of reading the datasheet for the device and encoding a type-safe layer over the raw PAC. This crate also implements traits specified by the embedded-hal project, making it compatible with various drivers in the embedded rust ecosystem.

It is generally advised to enable ONE of the following device features to use this crate depending on which chip you are using:

  • va41630
  • va41629
  • va41628
  • va41620

If no option is specified, only access to APIs which are common for all families or which are not disabled for specific families is granted.

When using this HAL and writing applications for the VA416xx family in general, it is strongly recommended that you set up the clock properly, because the default internal HBO clock is not very accurate. You can use the crate::clock module for this. If you are working with interrupts, it is strongly recommended to set up the IRQ router with the crate::irq_router module at the very least because that peripheral has confusing and/or faulty register reset values which might lead to weird bugs and glitches.

Re-exports§

pub use va416xx as device;
pub use va416xx as pac;

Modules§

adcNon-va41628
Analog to Digital Converter (ADC) driver.
clock
API for using the crate::pac::Clkgen peripheral.
dacNon-va41628
Digital to Analog Converter (DAC) driver.
dma
API for the DMA peripheral
edac
gpio
API for the GPIO peripheral
i2c
API for the I2C peripheral
irq_router
IRQ Router peripheral support.
nvmva41630
Non-volatile memory (NVM) driver.
prelude
Prelude
pwm
API for Pulse-Width Modulation (PWM)
spi
API for the SPI peripheral
time
Time units
timer
API for the TIM peripherals
typelevel
Module supporting type-level programming
uart
API for the UART peripheral
wdt
API for the Watchdog peripheral

Structs§

InvalidPinError

Enums§

FunSel

Functions§

disable_nvic_interrupt
Disable a specific interrupt using the NVIC peripheral.
enable_nvic_interrupt
Enable a specific interrupt using the NVIC peripheral.
port_function_select
Can be used to manually manipulate the function select of port pins.