pub type R = crate::R<C2PR3rs>;
pub type W = crate::W<C2PR3rs>;
#[cfg_attr(feature = "defmt", derive(defmt::Format))]
#[derive(Clone, Copy, Debug, PartialEq, Eq)]
pub enum PR82R {
NotPending = 0,
Pending = 1,
}
impl From<PR82R> for bool {
#[inline(always)]
fn from(variant: PR82R) -> Self {
variant as u8 != 0
}
}
pub type PR82_R = crate::BitReader<PR82R>;
impl PR82_R {
#[inline(always)]
pub const fn variant(&self) -> PR82R {
match self.bits {
false => PR82R::NotPending,
true => PR82R::Pending,
}
}
#[inline(always)]
pub fn is_not_pending(&self) -> bool {
*self == PR82R::NotPending
}
#[inline(always)]
pub fn is_pending(&self) -> bool {
*self == PR82R::Pending
}
}
#[cfg_attr(feature = "defmt", derive(defmt::Format))]
#[derive(Clone, Copy, Debug, PartialEq, Eq)]
pub enum PR82W {
Clear = 1,
}
impl From<PR82W> for bool {
#[inline(always)]
fn from(variant: PR82W) -> Self {
variant as u8 != 0
}
}
pub type PR82_W<'a, REG> = crate::BitWriter1C<'a, REG, PR82W>;
impl<'a, REG> PR82_W<'a, REG>
where
REG: crate::Writable + crate::RegisterSpec,
{
#[inline(always)]
pub fn clear(self) -> &'a mut crate::W<REG> {
self.variant(PR82W::Clear)
}
}
pub use PR82_R as PR84_R;
pub use PR82_R as PR85_R;
pub use PR82_R as PR86_R;
pub use PR82_W as PR84_W;
pub use PR82_W as PR85_W;
pub use PR82_W as PR86_W;
impl R {
#[inline(always)]
pub fn pr82(&self) -> PR82_R {
PR82_R::new(((self.bits >> 18) & 1) != 0)
}
#[inline(always)]
pub fn pr84(&self) -> PR84_R {
PR84_R::new(((self.bits >> 20) & 1) != 0)
}
#[inline(always)]
pub fn pr85(&self) -> PR85_R {
PR85_R::new(((self.bits >> 21) & 1) != 0)
}
#[inline(always)]
pub fn pr86(&self) -> PR86_R {
PR86_R::new(((self.bits >> 22) & 1) != 0)
}
}
impl core::fmt::Debug for R {
fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
f.debug_struct("C2PR3")
.field("pr82", &self.pr82())
.field("pr84", &self.pr84())
.field("pr85", &self.pr85())
.field("pr86", &self.pr86())
.finish()
}
}
impl W {
#[inline(always)]
pub fn pr82(&mut self) -> PR82_W<C2PR3rs> {
PR82_W::new(self, 18)
}
#[inline(always)]
pub fn pr84(&mut self) -> PR84_W<C2PR3rs> {
PR84_W::new(self, 20)
}
#[inline(always)]
pub fn pr85(&mut self) -> PR85_W<C2PR3rs> {
PR85_W::new(self, 21)
}
#[inline(always)]
pub fn pr86(&mut self) -> PR86_W<C2PR3rs> {
PR86_W::new(self, 22)
}
}
pub struct C2PR3rs;
impl crate::RegisterSpec for C2PR3rs {
type Ux = u32;
}
impl crate::Readable for C2PR3rs {}
impl crate::Writable for C2PR3rs {
type Safety = crate::Unsafe;
const ONE_TO_MODIFY_FIELDS_BITMAP: u32 = 0x0074_0000;
}
impl crate::Resettable for C2PR3rs {}