pub type W = crate::W<CFRrs>;
#[cfg_attr(feature = "defmt", derive(defmt::Format))]
#[derive(Clone, Copy, Debug, PartialEq, Eq)]
pub enum CSOF0W {
Clear = 1,
}
impl From<CSOF0W> for bool {
#[inline(always)]
fn from(variant: CSOF0W) -> Self {
variant as u8 != 0
}
}
pub type CSOF_W<'a, REG> = crate::BitWriter1C<'a, REG, CSOF0W>;
impl<'a, REG> CSOF_W<'a, REG>
where
REG: crate::Writable + crate::RegisterSpec,
{
#[inline(always)]
pub fn clear(self) -> &'a mut crate::W<REG> {
self.variant(CSOF0W::Clear)
}
}
impl core::fmt::Debug for crate::generic::Reg<CFRrs> {
fn fmt(&self, f: &mut core::fmt::Formatter<'_>) -> core::fmt::Result {
write!(f, "(not readable)")
}
}
impl W {
#[inline(always)]
pub fn csof(&mut self, n: u8) -> CSOF_W<CFRrs> {
#[allow(clippy::no_effect)]
[(); 7][n as usize];
CSOF_W::new(self, n)
}
#[inline(always)]
pub fn csof0(&mut self) -> CSOF_W<CFRrs> {
CSOF_W::new(self, 0)
}
#[inline(always)]
pub fn csof1(&mut self) -> CSOF_W<CFRrs> {
CSOF_W::new(self, 1)
}
#[inline(always)]
pub fn csof2(&mut self) -> CSOF_W<CFRrs> {
CSOF_W::new(self, 2)
}
#[inline(always)]
pub fn csof3(&mut self) -> CSOF_W<CFRrs> {
CSOF_W::new(self, 3)
}
#[inline(always)]
pub fn csof4(&mut self) -> CSOF_W<CFRrs> {
CSOF_W::new(self, 4)
}
#[inline(always)]
pub fn csof5(&mut self) -> CSOF_W<CFRrs> {
CSOF_W::new(self, 5)
}
#[inline(always)]
pub fn csof6(&mut self) -> CSOF_W<CFRrs> {
CSOF_W::new(self, 6)
}
}
pub struct CFRrs;
impl crate::RegisterSpec for CFRrs {
type Ux = u32;
}
impl crate::Writable for CFRrs {
type Safety = crate::Unsafe;
const ONE_TO_MODIFY_FIELDS_BITMAP: u32 = 0x7f;
}
impl crate::Resettable for CFRrs {}