RegisterBlock

Struct RegisterBlock 

#[repr(C)]
pub struct RegisterBlock {
Show 28 fields sc1: [Sc1; 16], cfg1: Cfg1, cfg2: Cfg2, r: [R; 16], cv: [Cv; 2], sc2: Sc2, sc3: Sc3, base_ofs: BaseOfs, ofs: Ofs, usr_ofs: UsrOfs, xofs: Xofs, yofs: Yofs, g: G, ug: Ug, clps: Clps, clp3: Clp3, clp2: Clp2, clp1: Clp1, clp0: Clp0, clpx: Clpx, clp9: Clp9, clps_ofs: ClpsOfs, clp3_ofs: Clp3Ofs, clp2_ofs: Clp2Ofs, clp1_ofs: Clp1Ofs, clp0_ofs: Clp0Ofs, clpx_ofs: ClpxOfs, clp9_ofs: Clp9Ofs,
}
Expand description

Register block

Fields§

§sc1: [Sc1; 16]§cfg1: Cfg1§cfg2: Cfg2§r: [R; 16]§cv: [Cv; 2]§sc2: Sc2§sc3: Sc3§base_ofs: BaseOfs§ofs: Ofs§usr_ofs: UsrOfs§xofs: Xofs§yofs: Yofs§g: G§ug: Ug§clps: Clps§clp3: Clp3§clp2: Clp2§clp1: Clp1§clp0: Clp0§clpx: Clpx§clp9: Clp9§clps_ofs: ClpsOfs§clp3_ofs: Clp3Ofs§clp2_ofs: Clp2Ofs§clp1_ofs: Clp1Ofs§clp0_ofs: Clp0Ofs§clpx_ofs: ClpxOfs§clp9_ofs: Clp9Ofs

Implementations§

§

impl RegisterBlock

pub const fn sc1(&self, n: usize) -> &Sc1

0x00..0x40 - ADC Status and Control Register 1

`n` is the index of register in the array. `n == 0` corresponds to `SC1A` register.

pub fn sc1_iter(&self) -> impl Iterator<Item = &Sc1>

Iterator for array of: 0x00..0x40 - ADC Status and Control Register 1

pub const fn sc1a(&self) -> &Sc1

0x00 - ADC Status and Control Register 1

pub const fn sc1b(&self) -> &Sc1

0x04 - ADC Status and Control Register 1

pub const fn sc1c(&self) -> &Sc1

0x08 - ADC Status and Control Register 1

pub const fn sc1d(&self) -> &Sc1

0x0c - ADC Status and Control Register 1

pub const fn sc1e(&self) -> &Sc1

0x10 - ADC Status and Control Register 1

pub const fn sc1f(&self) -> &Sc1

0x14 - ADC Status and Control Register 1

pub const fn sc1g(&self) -> &Sc1

0x18 - ADC Status and Control Register 1

pub const fn sc1h(&self) -> &Sc1

0x1c - ADC Status and Control Register 1

pub const fn sc1i(&self) -> &Sc1

0x20 - ADC Status and Control Register 1

pub const fn sc1j(&self) -> &Sc1

0x24 - ADC Status and Control Register 1

pub const fn sc1k(&self) -> &Sc1

0x28 - ADC Status and Control Register 1

pub const fn sc1l(&self) -> &Sc1

0x2c - ADC Status and Control Register 1

pub const fn sc1m(&self) -> &Sc1

0x30 - ADC Status and Control Register 1

pub const fn sc1n(&self) -> &Sc1

0x34 - ADC Status and Control Register 1

pub const fn sc1o(&self) -> &Sc1

0x38 - ADC Status and Control Register 1

pub const fn sc1p(&self) -> &Sc1

0x3c - ADC Status and Control Register 1

pub const fn cfg1(&self) -> &Cfg1

0x40 - ADC Configuration Register 1

pub const fn cfg2(&self) -> &Cfg2

0x44 - ADC Configuration Register 2

pub const fn r(&self, n: usize) -> &R

0x48..0x88 - ADC Data Result Registers

`n` is the index of register in the array. `n == 0` corresponds to `RA` register.

pub fn r_iter(&self) -> impl Iterator<Item = &R>

Iterator for array of: 0x48..0x88 - ADC Data Result Registers

pub const fn ra(&self) -> &R

0x48 - ADC Data Result Registers

pub const fn rb(&self) -> &R

0x4c - ADC Data Result Registers

pub const fn rc(&self) -> &R

0x50 - ADC Data Result Registers

pub const fn rd(&self) -> &R

0x54 - ADC Data Result Registers

pub const fn re(&self) -> &R

0x58 - ADC Data Result Registers

pub const fn rf(&self) -> &R

0x5c - ADC Data Result Registers

pub const fn rg(&self) -> &R

0x60 - ADC Data Result Registers

pub const fn rh(&self) -> &R

0x64 - ADC Data Result Registers

pub const fn ri(&self) -> &R

0x68 - ADC Data Result Registers

pub const fn rj(&self) -> &R

0x6c - ADC Data Result Registers

pub const fn rk(&self) -> &R

0x70 - ADC Data Result Registers

pub const fn rl(&self) -> &R

0x74 - ADC Data Result Registers

pub const fn rm(&self) -> &R

0x78 - ADC Data Result Registers

pub const fn rn(&self) -> &R

0x7c - ADC Data Result Registers

pub const fn ro(&self) -> &R

0x80 - ADC Data Result Registers

pub const fn rp(&self) -> &R

0x84 - ADC Data Result Registers

pub const fn cv(&self, n: usize) -> &Cv

0x88..0x90 - Compare Value Registers

`n` is the index of register in the array. `n == 0` corresponds to `CV1` register.

pub fn cv_iter(&self) -> impl Iterator<Item = &Cv>

Iterator for array of: 0x88..0x90 - Compare Value Registers

pub const fn cv1(&self) -> &Cv

0x88 - Compare Value Registers

pub const fn cv2(&self) -> &Cv

0x8c - Compare Value Registers

pub const fn sc2(&self) -> &Sc2

0x90 - Status and Control Register 2

pub const fn sc3(&self) -> &Sc3

0x94 - Status and Control Register 3

pub const fn base_ofs(&self) -> &BaseOfs

0x98 - BASE Offset Register

pub const fn ofs(&self) -> &Ofs

0x9c - ADC Offset Correction Register

pub const fn usr_ofs(&self) -> &UsrOfs

0xa0 - USER Offset Correction Register

pub const fn xofs(&self) -> &Xofs

0xa4 - ADC X Offset Correction Register

pub const fn yofs(&self) -> &Yofs

0xa8 - ADC Y Offset Correction Register

pub const fn g(&self) -> &G

0xac - ADC Gain Register

pub const fn ug(&self) -> &Ug

0xb0 - ADC User Gain Register

pub const fn clps(&self) -> &Clps

0xb4 - ADC General Calibration Value Register S

pub const fn clp3(&self) -> &Clp3

0xb8 - ADC Plus-Side General Calibration Value Register 3

pub const fn clp2(&self) -> &Clp2

0xbc - ADC Plus-Side General Calibration Value Register 2

pub const fn clp1(&self) -> &Clp1

0xc0 - ADC Plus-Side General Calibration Value Register 1

pub const fn clp0(&self) -> &Clp0

0xc4 - ADC Plus-Side General Calibration Value Register 0

pub const fn clpx(&self) -> &Clpx

0xc8 - ADC Plus-Side General Calibration Value Register X

pub const fn clp9(&self) -> &Clp9

0xcc - ADC Plus-Side General Calibration Value Register 9

pub const fn clps_ofs(&self) -> &ClpsOfs

0xd0 - ADC General Calibration Offset Value Register S

pub const fn clp3_ofs(&self) -> &Clp3Ofs

0xd4 - ADC Plus-Side General Calibration Offset Value Register 3

pub const fn clp2_ofs(&self) -> &Clp2Ofs

0xd8 - ADC Plus-Side General Calibration Offset Value Register 2

pub const fn clp1_ofs(&self) -> &Clp1Ofs

0xdc - ADC Plus-Side General Calibration Offset Value Register 1

pub const fn clp0_ofs(&self) -> &Clp0Ofs

0xe0 - ADC Plus-Side General Calibration Offset Value Register 0

pub const fn clpx_ofs(&self) -> &ClpxOfs

0xe4 - ADC Plus-Side General Calibration Offset Value Register X

pub const fn clp9_ofs(&self) -> &Clp9Ofs

0xe8 - ADC Plus-Side General Calibration Offset Value Register 9

Auto Trait Implementations§

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.