#[doc = "Reader of register FMSTAT"]
pub type R = crate::R<u32, super::FMSTAT>;
#[doc = "Writer for register FMSTAT"]
pub type W = crate::W<u32, super::FMSTAT>;
#[doc = "Register FMSTAT `reset()`'s with value 0"]
impl crate::ResetValue for super::FMSTAT {
type Type = u32;
#[inline(always)]
fn reset_value() -> Self::Type {
0
}
}
#[doc = "Reader of field `RESERVED18`"]
pub type RESERVED18_R = crate::R<u16, u16>;
#[doc = "Write proxy for field `RESERVED18`"]
pub struct RESERVED18_W<'a> {
w: &'a mut W,
}
impl<'a> RESERVED18_W<'a> {
#[doc = r"Writes raw bits to the field"]
#[inline(always)]
pub unsafe fn bits(self, value: u16) -> &'a mut W {
self.w.bits = (self.w.bits & !(0x3fff << 18)) | (((value as u32) & 0x3fff) << 18);
self.w
}
}
#[doc = "Reader of field `RVSUSP`"]
pub type RVSUSP_R = crate::R<bool, bool>;
#[doc = "Write proxy for field `RVSUSP`"]
pub struct RVSUSP_W<'a> {
w: &'a mut W,
}
impl<'a> RVSUSP_W<'a> {
#[doc = r"Sets the field bit"]
#[inline(always)]
pub fn set_bit(self) -> &'a mut W {
self.bit(true)
}
#[doc = r"Clears the field bit"]
#[inline(always)]
pub fn clear_bit(self) -> &'a mut W {
self.bit(false)
}
#[doc = r"Writes raw bits to the field"]
#[inline(always)]
pub fn bit(self, value: bool) -> &'a mut W {
self.w.bits = (self.w.bits & !(0x01 << 17)) | (((value as u32) & 0x01) << 17);
self.w
}
}
#[doc = "Reader of field `RDVER`"]
pub type RDVER_R = crate::R<bool, bool>;
#[doc = "Write proxy for field `RDVER`"]
pub struct RDVER_W<'a> {
w: &'a mut W,
}
impl<'a> RDVER_W<'a> {
#[doc = r"Sets the field bit"]
#[inline(always)]
pub fn set_bit(self) -> &'a mut W {
self.bit(true)
}
#[doc = r"Clears the field bit"]
#[inline(always)]
pub fn clear_bit(self) -> &'a mut W {
self.bit(false)
}
#[doc = r"Writes raw bits to the field"]
#[inline(always)]
pub fn bit(self, value: bool) -> &'a mut W {
self.w.bits = (self.w.bits & !(0x01 << 16)) | (((value as u32) & 0x01) << 16);
self.w
}
}
#[doc = "Reader of field `RVF`"]
pub type RVF_R = crate::R<bool, bool>;
#[doc = "Write proxy for field `RVF`"]
pub struct RVF_W<'a> {
w: &'a mut W,
}
impl<'a> RVF_W<'a> {
#[doc = r"Sets the field bit"]
#[inline(always)]
pub fn set_bit(self) -> &'a mut W {
self.bit(true)
}
#[doc = r"Clears the field bit"]
#[inline(always)]
pub fn clear_bit(self) -> &'a mut W {
self.bit(false)
}
#[doc = r"Writes raw bits to the field"]
#[inline(always)]
pub fn bit(self, value: bool) -> &'a mut W {
self.w.bits = (self.w.bits & !(0x01 << 15)) | (((value as u32) & 0x01) << 15);
self.w
}
}
#[doc = "Reader of field `ILA`"]
pub type ILA_R = crate::R<bool, bool>;
#[doc = "Write proxy for field `ILA`"]
pub struct ILA_W<'a> {
w: &'a mut W,
}
impl<'a> ILA_W<'a> {
#[doc = r"Sets the field bit"]
#[inline(always)]
pub fn set_bit(self) -> &'a mut W {
self.bit(true)
}
#[doc = r"Clears the field bit"]
#[inline(always)]
pub fn clear_bit(self) -> &'a mut W {
self.bit(false)
}
#[doc = r"Writes raw bits to the field"]
#[inline(always)]
pub fn bit(self, value: bool) -> &'a mut W {
self.w.bits = (self.w.bits & !(0x01 << 14)) | (((value as u32) & 0x01) << 14);
self.w
}
}
#[doc = "Reader of field `DBF`"]
pub type DBF_R = crate::R<bool, bool>;
#[doc = "Write proxy for field `DBF`"]
pub struct DBF_W<'a> {
w: &'a mut W,
}
impl<'a> DBF_W<'a> {
#[doc = r"Sets the field bit"]
#[inline(always)]
pub fn set_bit(self) -> &'a mut W {
self.bit(true)
}
#[doc = r"Clears the field bit"]
#[inline(always)]
pub fn clear_bit(self) -> &'a mut W {
self.bit(false)
}
#[doc = r"Writes raw bits to the field"]
#[inline(always)]
pub fn bit(self, value: bool) -> &'a mut W {
self.w.bits = (self.w.bits & !(0x01 << 13)) | (((value as u32) & 0x01) << 13);
self.w
}
}
#[doc = "Reader of field `PGV`"]
pub type PGV_R = crate::R<bool, bool>;
#[doc = "Write proxy for field `PGV`"]
pub struct PGV_W<'a> {
w: &'a mut W,
}
impl<'a> PGV_W<'a> {
#[doc = r"Sets the field bit"]
#[inline(always)]
pub fn set_bit(self) -> &'a mut W {
self.bit(true)
}
#[doc = r"Clears the field bit"]
#[inline(always)]
pub fn clear_bit(self) -> &'a mut W {
self.bit(false)
}
#[doc = r"Writes raw bits to the field"]
#[inline(always)]
pub fn bit(self, value: bool) -> &'a mut W {
self.w.bits = (self.w.bits & !(0x01 << 12)) | (((value as u32) & 0x01) << 12);
self.w
}
}
#[doc = "Reader of field `PCV`"]
pub type PCV_R = crate::R<bool, bool>;
#[doc = "Write proxy for field `PCV`"]
pub struct PCV_W<'a> {
w: &'a mut W,
}
impl<'a> PCV_W<'a> {
#[doc = r"Sets the field bit"]
#[inline(always)]
pub fn set_bit(self) -> &'a mut W {
self.bit(true)
}
#[doc = r"Clears the field bit"]
#[inline(always)]
pub fn clear_bit(self) -> &'a mut W {
self.bit(false)
}
#[doc = r"Writes raw bits to the field"]
#[inline(always)]
pub fn bit(self, value: bool) -> &'a mut W {
self.w.bits = (self.w.bits & !(0x01 << 11)) | (((value as u32) & 0x01) << 11);
self.w
}
}
#[doc = "Reader of field `EV`"]
pub type EV_R = crate::R<bool, bool>;
#[doc = "Write proxy for field `EV`"]
pub struct EV_W<'a> {
w: &'a mut W,
}
impl<'a> EV_W<'a> {
#[doc = r"Sets the field bit"]
#[inline(always)]
pub fn set_bit(self) -> &'a mut W {
self.bit(true)
}
#[doc = r"Clears the field bit"]
#[inline(always)]
pub fn clear_bit(self) -> &'a mut W {
self.bit(false)
}
#[doc = r"Writes raw bits to the field"]
#[inline(always)]
pub fn bit(self, value: bool) -> &'a mut W {
self.w.bits = (self.w.bits & !(0x01 << 10)) | (((value as u32) & 0x01) << 10);
self.w
}
}
#[doc = "Reader of field `CV`"]
pub type CV_R = crate::R<bool, bool>;
#[doc = "Write proxy for field `CV`"]
pub struct CV_W<'a> {
w: &'a mut W,
}
impl<'a> CV_W<'a> {
#[doc = r"Sets the field bit"]
#[inline(always)]
pub fn set_bit(self) -> &'a mut W {
self.bit(true)
}
#[doc = r"Clears the field bit"]
#[inline(always)]
pub fn clear_bit(self) -> &'a mut W {
self.bit(false)
}
#[doc = r"Writes raw bits to the field"]
#[inline(always)]
pub fn bit(self, value: bool) -> &'a mut W {
self.w.bits = (self.w.bits & !(0x01 << 9)) | (((value as u32) & 0x01) << 9);
self.w
}
}
#[doc = "Reader of field `BUSY`"]
pub type BUSY_R = crate::R<bool, bool>;
#[doc = "Write proxy for field `BUSY`"]
pub struct BUSY_W<'a> {
w: &'a mut W,
}
impl<'a> BUSY_W<'a> {
#[doc = r"Sets the field bit"]
#[inline(always)]
pub fn set_bit(self) -> &'a mut W {
self.bit(true)
}
#[doc = r"Clears the field bit"]
#[inline(always)]
pub fn clear_bit(self) -> &'a mut W {
self.bit(false)
}
#[doc = r"Writes raw bits to the field"]
#[inline(always)]
pub fn bit(self, value: bool) -> &'a mut W {
self.w.bits = (self.w.bits & !(0x01 << 8)) | (((value as u32) & 0x01) << 8);
self.w
}
}
#[doc = "Reader of field `ERS`"]
pub type ERS_R = crate::R<bool, bool>;
#[doc = "Write proxy for field `ERS`"]
pub struct ERS_W<'a> {
w: &'a mut W,
}
impl<'a> ERS_W<'a> {
#[doc = r"Sets the field bit"]
#[inline(always)]
pub fn set_bit(self) -> &'a mut W {
self.bit(true)
}
#[doc = r"Clears the field bit"]
#[inline(always)]
pub fn clear_bit(self) -> &'a mut W {
self.bit(false)
}
#[doc = r"Writes raw bits to the field"]
#[inline(always)]
pub fn bit(self, value: bool) -> &'a mut W {
self.w.bits = (self.w.bits & !(0x01 << 7)) | (((value as u32) & 0x01) << 7);
self.w
}
}
#[doc = "Reader of field `PGM`"]
pub type PGM_R = crate::R<bool, bool>;
#[doc = "Write proxy for field `PGM`"]
pub struct PGM_W<'a> {
w: &'a mut W,
}
impl<'a> PGM_W<'a> {
#[doc = r"Sets the field bit"]
#[inline(always)]
pub fn set_bit(self) -> &'a mut W {
self.bit(true)
}
#[doc = r"Clears the field bit"]
#[inline(always)]
pub fn clear_bit(self) -> &'a mut W {
self.bit(false)
}
#[doc = r"Writes raw bits to the field"]
#[inline(always)]
pub fn bit(self, value: bool) -> &'a mut W {
self.w.bits = (self.w.bits & !(0x01 << 6)) | (((value as u32) & 0x01) << 6);
self.w
}
}
#[doc = "Reader of field `INVDAT`"]
pub type INVDAT_R = crate::R<bool, bool>;
#[doc = "Write proxy for field `INVDAT`"]
pub struct INVDAT_W<'a> {
w: &'a mut W,
}
impl<'a> INVDAT_W<'a> {
#[doc = r"Sets the field bit"]
#[inline(always)]
pub fn set_bit(self) -> &'a mut W {
self.bit(true)
}
#[doc = r"Clears the field bit"]
#[inline(always)]
pub fn clear_bit(self) -> &'a mut W {
self.bit(false)
}
#[doc = r"Writes raw bits to the field"]
#[inline(always)]
pub fn bit(self, value: bool) -> &'a mut W {
self.w.bits = (self.w.bits & !(0x01 << 5)) | (((value as u32) & 0x01) << 5);
self.w
}
}
#[doc = "Reader of field `CSTAT`"]
pub type CSTAT_R = crate::R<bool, bool>;
#[doc = "Write proxy for field `CSTAT`"]
pub struct CSTAT_W<'a> {
w: &'a mut W,
}
impl<'a> CSTAT_W<'a> {
#[doc = r"Sets the field bit"]
#[inline(always)]
pub fn set_bit(self) -> &'a mut W {
self.bit(true)
}
#[doc = r"Clears the field bit"]
#[inline(always)]
pub fn clear_bit(self) -> &'a mut W {
self.bit(false)
}
#[doc = r"Writes raw bits to the field"]
#[inline(always)]
pub fn bit(self, value: bool) -> &'a mut W {
self.w.bits = (self.w.bits & !(0x01 << 4)) | (((value as u32) & 0x01) << 4);
self.w
}
}
#[doc = "Reader of field `VOLSTAT`"]
pub type VOLSTAT_R = crate::R<bool, bool>;
#[doc = "Write proxy for field `VOLSTAT`"]
pub struct VOLSTAT_W<'a> {
w: &'a mut W,
}
impl<'a> VOLSTAT_W<'a> {
#[doc = r"Sets the field bit"]
#[inline(always)]
pub fn set_bit(self) -> &'a mut W {
self.bit(true)
}
#[doc = r"Clears the field bit"]
#[inline(always)]
pub fn clear_bit(self) -> &'a mut W {
self.bit(false)
}
#[doc = r"Writes raw bits to the field"]
#[inline(always)]
pub fn bit(self, value: bool) -> &'a mut W {
self.w.bits = (self.w.bits & !(0x01 << 3)) | (((value as u32) & 0x01) << 3);
self.w
}
}
#[doc = "Reader of field `ESUSP`"]
pub type ESUSP_R = crate::R<bool, bool>;
#[doc = "Write proxy for field `ESUSP`"]
pub struct ESUSP_W<'a> {
w: &'a mut W,
}
impl<'a> ESUSP_W<'a> {
#[doc = r"Sets the field bit"]
#[inline(always)]
pub fn set_bit(self) -> &'a mut W {
self.bit(true)
}
#[doc = r"Clears the field bit"]
#[inline(always)]
pub fn clear_bit(self) -> &'a mut W {
self.bit(false)
}
#[doc = r"Writes raw bits to the field"]
#[inline(always)]
pub fn bit(self, value: bool) -> &'a mut W {
self.w.bits = (self.w.bits & !(0x01 << 2)) | (((value as u32) & 0x01) << 2);
self.w
}
}
#[doc = "Reader of field `PSUSP`"]
pub type PSUSP_R = crate::R<bool, bool>;
#[doc = "Write proxy for field `PSUSP`"]
pub struct PSUSP_W<'a> {
w: &'a mut W,
}
impl<'a> PSUSP_W<'a> {
#[doc = r"Sets the field bit"]
#[inline(always)]
pub fn set_bit(self) -> &'a mut W {
self.bit(true)
}
#[doc = r"Clears the field bit"]
#[inline(always)]
pub fn clear_bit(self) -> &'a mut W {
self.bit(false)
}
#[doc = r"Writes raw bits to the field"]
#[inline(always)]
pub fn bit(self, value: bool) -> &'a mut W {
self.w.bits = (self.w.bits & !(0x01 << 1)) | (((value as u32) & 0x01) << 1);
self.w
}
}
#[doc = "Reader of field `SLOCK`"]
pub type SLOCK_R = crate::R<bool, bool>;
#[doc = "Write proxy for field `SLOCK`"]
pub struct SLOCK_W<'a> {
w: &'a mut W,
}
impl<'a> SLOCK_W<'a> {
#[doc = r"Sets the field bit"]
#[inline(always)]
pub fn set_bit(self) -> &'a mut W {
self.bit(true)
}
#[doc = r"Clears the field bit"]
#[inline(always)]
pub fn clear_bit(self) -> &'a mut W {
self.bit(false)
}
#[doc = r"Writes raw bits to the field"]
#[inline(always)]
pub fn bit(self, value: bool) -> &'a mut W {
self.w.bits = (self.w.bits & !0x01) | ((value as u32) & 0x01);
self.w
}
}
impl R {
#[doc = "Bits 18:31 - 31:18\\]
Internal. Only to be used through TI provided API."]
#[inline(always)]
pub fn reserved18(&self) -> RESERVED18_R {
RESERVED18_R::new(((self.bits >> 18) & 0x3fff) as u16)
}
#[doc = "Bit 17 - 17:17\\]
Internal. Only to be used through TI provided API."]
#[inline(always)]
pub fn rvsusp(&self) -> RVSUSP_R {
RVSUSP_R::new(((self.bits >> 17) & 0x01) != 0)
}
#[doc = "Bit 16 - 16:16\\]
Internal. Only to be used through TI provided API."]
#[inline(always)]
pub fn rdver(&self) -> RDVER_R {
RDVER_R::new(((self.bits >> 16) & 0x01) != 0)
}
#[doc = "Bit 15 - 15:15\\]
Internal. Only to be used through TI provided API."]
#[inline(always)]
pub fn rvf(&self) -> RVF_R {
RVF_R::new(((self.bits >> 15) & 0x01) != 0)
}
#[doc = "Bit 14 - 14:14\\]
Internal. Only to be used through TI provided API."]
#[inline(always)]
pub fn ila(&self) -> ILA_R {
ILA_R::new(((self.bits >> 14) & 0x01) != 0)
}
#[doc = "Bit 13 - 13:13\\]
Internal. Only to be used through TI provided API."]
#[inline(always)]
pub fn dbf(&self) -> DBF_R {
DBF_R::new(((self.bits >> 13) & 0x01) != 0)
}
#[doc = "Bit 12 - 12:12\\]
Internal. Only to be used through TI provided API."]
#[inline(always)]
pub fn pgv(&self) -> PGV_R {
PGV_R::new(((self.bits >> 12) & 0x01) != 0)
}
#[doc = "Bit 11 - 11:11\\]
Internal. Only to be used through TI provided API."]
#[inline(always)]
pub fn pcv(&self) -> PCV_R {
PCV_R::new(((self.bits >> 11) & 0x01) != 0)
}
#[doc = "Bit 10 - 10:10\\]
Internal. Only to be used through TI provided API."]
#[inline(always)]
pub fn ev(&self) -> EV_R {
EV_R::new(((self.bits >> 10) & 0x01) != 0)
}
#[doc = "Bit 9 - 9:9\\]
Internal. Only to be used through TI provided API."]
#[inline(always)]
pub fn cv(&self) -> CV_R {
CV_R::new(((self.bits >> 9) & 0x01) != 0)
}
#[doc = "Bit 8 - 8:8\\]
Internal. Only to be used through TI provided API."]
#[inline(always)]
pub fn busy(&self) -> BUSY_R {
BUSY_R::new(((self.bits >> 8) & 0x01) != 0)
}
#[doc = "Bit 7 - 7:7\\]
Internal. Only to be used through TI provided API."]
#[inline(always)]
pub fn ers(&self) -> ERS_R {
ERS_R::new(((self.bits >> 7) & 0x01) != 0)
}
#[doc = "Bit 6 - 6:6\\]
Internal. Only to be used through TI provided API."]
#[inline(always)]
pub fn pgm(&self) -> PGM_R {
PGM_R::new(((self.bits >> 6) & 0x01) != 0)
}
#[doc = "Bit 5 - 5:5\\]
Internal. Only to be used through TI provided API."]
#[inline(always)]
pub fn invdat(&self) -> INVDAT_R {
INVDAT_R::new(((self.bits >> 5) & 0x01) != 0)
}
#[doc = "Bit 4 - 4:4\\]
Internal. Only to be used through TI provided API."]
#[inline(always)]
pub fn cstat(&self) -> CSTAT_R {
CSTAT_R::new(((self.bits >> 4) & 0x01) != 0)
}
#[doc = "Bit 3 - 3:3\\]
Internal. Only to be used through TI provided API."]
#[inline(always)]
pub fn volstat(&self) -> VOLSTAT_R {
VOLSTAT_R::new(((self.bits >> 3) & 0x01) != 0)
}
#[doc = "Bit 2 - 2:2\\]
Internal. Only to be used through TI provided API."]
#[inline(always)]
pub fn esusp(&self) -> ESUSP_R {
ESUSP_R::new(((self.bits >> 2) & 0x01) != 0)
}
#[doc = "Bit 1 - 1:1\\]
Internal. Only to be used through TI provided API."]
#[inline(always)]
pub fn psusp(&self) -> PSUSP_R {
PSUSP_R::new(((self.bits >> 1) & 0x01) != 0)
}
#[doc = "Bit 0 - 0:0\\]
Internal. Only to be used through TI provided API."]
#[inline(always)]
pub fn slock(&self) -> SLOCK_R {
SLOCK_R::new((self.bits & 0x01) != 0)
}
}
impl W {
#[doc = "Bits 18:31 - 31:18\\]
Internal. Only to be used through TI provided API."]
#[inline(always)]
pub fn reserved18(&mut self) -> RESERVED18_W {
RESERVED18_W { w: self }
}
#[doc = "Bit 17 - 17:17\\]
Internal. Only to be used through TI provided API."]
#[inline(always)]
pub fn rvsusp(&mut self) -> RVSUSP_W {
RVSUSP_W { w: self }
}
#[doc = "Bit 16 - 16:16\\]
Internal. Only to be used through TI provided API."]
#[inline(always)]
pub fn rdver(&mut self) -> RDVER_W {
RDVER_W { w: self }
}
#[doc = "Bit 15 - 15:15\\]
Internal. Only to be used through TI provided API."]
#[inline(always)]
pub fn rvf(&mut self) -> RVF_W {
RVF_W { w: self }
}
#[doc = "Bit 14 - 14:14\\]
Internal. Only to be used through TI provided API."]
#[inline(always)]
pub fn ila(&mut self) -> ILA_W {
ILA_W { w: self }
}
#[doc = "Bit 13 - 13:13\\]
Internal. Only to be used through TI provided API."]
#[inline(always)]
pub fn dbf(&mut self) -> DBF_W {
DBF_W { w: self }
}
#[doc = "Bit 12 - 12:12\\]
Internal. Only to be used through TI provided API."]
#[inline(always)]
pub fn pgv(&mut self) -> PGV_W {
PGV_W { w: self }
}
#[doc = "Bit 11 - 11:11\\]
Internal. Only to be used through TI provided API."]
#[inline(always)]
pub fn pcv(&mut self) -> PCV_W {
PCV_W { w: self }
}
#[doc = "Bit 10 - 10:10\\]
Internal. Only to be used through TI provided API."]
#[inline(always)]
pub fn ev(&mut self) -> EV_W {
EV_W { w: self }
}
#[doc = "Bit 9 - 9:9\\]
Internal. Only to be used through TI provided API."]
#[inline(always)]
pub fn cv(&mut self) -> CV_W {
CV_W { w: self }
}
#[doc = "Bit 8 - 8:8\\]
Internal. Only to be used through TI provided API."]
#[inline(always)]
pub fn busy(&mut self) -> BUSY_W {
BUSY_W { w: self }
}
#[doc = "Bit 7 - 7:7\\]
Internal. Only to be used through TI provided API."]
#[inline(always)]
pub fn ers(&mut self) -> ERS_W {
ERS_W { w: self }
}
#[doc = "Bit 6 - 6:6\\]
Internal. Only to be used through TI provided API."]
#[inline(always)]
pub fn pgm(&mut self) -> PGM_W {
PGM_W { w: self }
}
#[doc = "Bit 5 - 5:5\\]
Internal. Only to be used through TI provided API."]
#[inline(always)]
pub fn invdat(&mut self) -> INVDAT_W {
INVDAT_W { w: self }
}
#[doc = "Bit 4 - 4:4\\]
Internal. Only to be used through TI provided API."]
#[inline(always)]
pub fn cstat(&mut self) -> CSTAT_W {
CSTAT_W { w: self }
}
#[doc = "Bit 3 - 3:3\\]
Internal. Only to be used through TI provided API."]
#[inline(always)]
pub fn volstat(&mut self) -> VOLSTAT_W {
VOLSTAT_W { w: self }
}
#[doc = "Bit 2 - 2:2\\]
Internal. Only to be used through TI provided API."]
#[inline(always)]
pub fn esusp(&mut self) -> ESUSP_W {
ESUSP_W { w: self }
}
#[doc = "Bit 1 - 1:1\\]
Internal. Only to be used through TI provided API."]
#[inline(always)]
pub fn psusp(&mut self) -> PSUSP_W {
PSUSP_W { w: self }
}
#[doc = "Bit 0 - 0:0\\]
Internal. Only to be used through TI provided API."]
#[inline(always)]
pub fn slock(&mut self) -> SLOCK_W {
SLOCK_W { w: self }
}
}