#[doc = r" Value read from the register"]
pub struct R {
bits: u32,
}
impl super::IOCONF {
#[doc = r" Reads the contents of the register"]
#[inline]
pub fn read(&self) -> R {
R { bits: self.register.get() }
}
}
#[doc = r" Value of the field"]
pub struct RESERVED7R {
bits: u32,
}
impl RESERVED7R {
#[doc = r" Value of the field as raw bits"]
#[inline]
pub fn bits(&self) -> u32 {
self.bits
}
}
#[doc = r" Value of the field"]
pub struct GPIO_CNTR {
bits: u8,
}
impl GPIO_CNTR {
#[doc = r" Value of the field as raw bits"]
#[inline]
pub fn bits(&self) -> u8 {
self.bits
}
}
impl R {
#[doc = r" Value of the register as raw bits"]
#[inline]
pub fn bits(&self) -> u32 {
self.bits
}
#[doc = "Bits 7:31 - Software should not rely on the value of a reserved. Writing any other value than the reset value may result in undefined behavior."]
#[inline]
pub fn reserved7(&self) -> RESERVED7R {
let bits = {
const MASK: u32 = 33554431;
const OFFSET: u8 = 7;
((self.bits >> OFFSET) & MASK as u32) as u32
};
RESERVED7R { bits }
}
#[doc = "Bits 0:6 - Number of available DIOs."]
#[inline]
pub fn gpio_cnt(&self) -> GPIO_CNTR {
let bits = {
const MASK: u8 = 127;
const OFFSET: u8 = 0;
((self.bits >> OFFSET) & MASK as u32) as u8
};
GPIO_CNTR { bits }
}
}