#[doc = r" Value read from the register"]
pub struct R {
bits: u32,
}
#[doc = r" Value to write to the register"]
pub struct W {
bits: u32,
}
impl super::DCFG_CC_SOCU_DFLT {
#[doc = r" Modifies the contents of the register"]
#[inline]
pub fn modify<F>(&self, f: F)
where
for<'w> F: FnOnce(&R, &'w mut W) -> &'w mut W,
{
let bits = self.register.get();
let r = R { bits: bits };
let mut w = W { bits: bits };
f(&r, &mut w);
self.register.set(w.bits);
}
#[doc = r" Reads the contents of the register"]
#[inline]
pub fn read(&self) -> R {
R {
bits: self.register.get(),
}
}
#[doc = r" Writes to the register"]
#[inline]
pub fn write<F>(&self, f: F)
where
F: FnOnce(&mut W) -> &mut W,
{
let mut w = W::reset_value();
f(&mut w);
self.register.set(w.bits);
}
#[doc = r" Writes the reset value to the register"]
#[inline]
pub fn reset(&self) {
self.write(|w| w)
}
}
#[doc = "Possible values of the field `NIDEN`"]
#[derive(Clone, Copy, Debug, PartialEq)]
pub enum NIDENR {
#[doc = "Disable"]
DISABLE,
#[doc = "Enable"]
ENABLE,
}
impl NIDENR {
#[doc = r" Returns `true` if the bit is clear (0)"]
#[inline]
pub fn bit_is_clear(&self) -> bool {
!self.bit()
}
#[doc = r" Returns `true` if the bit is set (1)"]
#[inline]
pub fn bit_is_set(&self) -> bool {
self.bit()
}
#[doc = r" Value of the field as raw bits"]
#[inline]
pub fn bit(&self) -> bool {
match *self {
NIDENR::DISABLE => false,
NIDENR::ENABLE => true,
}
}
#[allow(missing_docs)]
#[doc(hidden)]
#[inline]
pub fn _from(value: bool) -> NIDENR {
match value {
false => NIDENR::DISABLE,
true => NIDENR::ENABLE,
}
}
#[doc = "Checks if the value of the field is `DISABLE`"]
#[inline]
pub fn is_disable(&self) -> bool {
*self == NIDENR::DISABLE
}
#[doc = "Checks if the value of the field is `ENABLE`"]
#[inline]
pub fn is_enable(&self) -> bool {
*self == NIDENR::ENABLE
}
}
#[doc = "Possible values of the field `DBGEN`"]
#[derive(Clone, Copy, Debug, PartialEq)]
pub enum DBGENR {
#[doc = "Disable"]
DISABLE,
#[doc = "Enable"]
ENABLE,
}
impl DBGENR {
#[doc = r" Returns `true` if the bit is clear (0)"]
#[inline]
pub fn bit_is_clear(&self) -> bool {
!self.bit()
}
#[doc = r" Returns `true` if the bit is set (1)"]
#[inline]
pub fn bit_is_set(&self) -> bool {
self.bit()
}
#[doc = r" Value of the field as raw bits"]
#[inline]
pub fn bit(&self) -> bool {
match *self {
DBGENR::DISABLE => false,
DBGENR::ENABLE => true,
}
}
#[allow(missing_docs)]
#[doc(hidden)]
#[inline]
pub fn _from(value: bool) -> DBGENR {
match value {
false => DBGENR::DISABLE,
true => DBGENR::ENABLE,
}
}
#[doc = "Checks if the value of the field is `DISABLE`"]
#[inline]
pub fn is_disable(&self) -> bool {
*self == DBGENR::DISABLE
}
#[doc = "Checks if the value of the field is `ENABLE`"]
#[inline]
pub fn is_enable(&self) -> bool {
*self == DBGENR::ENABLE
}
}
#[doc = "Possible values of the field `SPNIDEN`"]
#[derive(Clone, Copy, Debug, PartialEq)]
pub enum SPNIDENR {
#[doc = "Disable"]
DISABLE,
#[doc = "Enable"]
ENABLE,
}
impl SPNIDENR {
#[doc = r" Returns `true` if the bit is clear (0)"]
#[inline]
pub fn bit_is_clear(&self) -> bool {
!self.bit()
}
#[doc = r" Returns `true` if the bit is set (1)"]
#[inline]
pub fn bit_is_set(&self) -> bool {
self.bit()
}
#[doc = r" Value of the field as raw bits"]
#[inline]
pub fn bit(&self) -> bool {
match *self {
SPNIDENR::DISABLE => false,
SPNIDENR::ENABLE => true,
}
}
#[allow(missing_docs)]
#[doc(hidden)]
#[inline]
pub fn _from(value: bool) -> SPNIDENR {
match value {
false => SPNIDENR::DISABLE,
true => SPNIDENR::ENABLE,
}
}
#[doc = "Checks if the value of the field is `DISABLE`"]
#[inline]
pub fn is_disable(&self) -> bool {
*self == SPNIDENR::DISABLE
}
#[doc = "Checks if the value of the field is `ENABLE`"]
#[inline]
pub fn is_enable(&self) -> bool {
*self == SPNIDENR::ENABLE
}
}
#[doc = "Possible values of the field `SPIDEN`"]
#[derive(Clone, Copy, Debug, PartialEq)]
pub enum SPIDENR {
#[doc = "Disable"]
DISABLE,
#[doc = "Enable"]
ENABLE,
}
impl SPIDENR {
#[doc = r" Returns `true` if the bit is clear (0)"]
#[inline]
pub fn bit_is_clear(&self) -> bool {
!self.bit()
}
#[doc = r" Returns `true` if the bit is set (1)"]
#[inline]
pub fn bit_is_set(&self) -> bool {
self.bit()
}
#[doc = r" Value of the field as raw bits"]
#[inline]
pub fn bit(&self) -> bool {
match *self {
SPIDENR::DISABLE => false,
SPIDENR::ENABLE => true,
}
}
#[allow(missing_docs)]
#[doc(hidden)]
#[inline]
pub fn _from(value: bool) -> SPIDENR {
match value {
false => SPIDENR::DISABLE,
true => SPIDENR::ENABLE,
}
}
#[doc = "Checks if the value of the field is `DISABLE`"]
#[inline]
pub fn is_disable(&self) -> bool {
*self == SPIDENR::DISABLE
}
#[doc = "Checks if the value of the field is `ENABLE`"]
#[inline]
pub fn is_enable(&self) -> bool {
*self == SPIDENR::ENABLE
}
}
#[doc = "Possible values of the field `TAPEN`"]
#[derive(Clone, Copy, Debug, PartialEq)]
pub enum TAPENR {
#[doc = "Disable"]
DISABLE,
#[doc = "Enable"]
ENABLE,
}
impl TAPENR {
#[doc = r" Returns `true` if the bit is clear (0)"]
#[inline]
pub fn bit_is_clear(&self) -> bool {
!self.bit()
}
#[doc = r" Returns `true` if the bit is set (1)"]
#[inline]
pub fn bit_is_set(&self) -> bool {
self.bit()
}
#[doc = r" Value of the field as raw bits"]
#[inline]
pub fn bit(&self) -> bool {
match *self {
TAPENR::DISABLE => false,
TAPENR::ENABLE => true,
}
}
#[allow(missing_docs)]
#[doc(hidden)]
#[inline]
pub fn _from(value: bool) -> TAPENR {
match value {
false => TAPENR::DISABLE,
true => TAPENR::ENABLE,
}
}
#[doc = "Checks if the value of the field is `DISABLE`"]
#[inline]
pub fn is_disable(&self) -> bool {
*self == TAPENR::DISABLE
}
#[doc = "Checks if the value of the field is `ENABLE`"]
#[inline]
pub fn is_enable(&self) -> bool {
*self == TAPENR::ENABLE
}
}
#[doc = "Possible values of the field `MCM33_DBGEN`"]
#[derive(Clone, Copy, Debug, PartialEq)]
pub enum MCM33_DBGENR {
#[doc = "Disable"]
DISABLE,
#[doc = "Enable"]
ENABLE,
}
impl MCM33_DBGENR {
#[doc = r" Returns `true` if the bit is clear (0)"]
#[inline]
pub fn bit_is_clear(&self) -> bool {
!self.bit()
}
#[doc = r" Returns `true` if the bit is set (1)"]
#[inline]
pub fn bit_is_set(&self) -> bool {
self.bit()
}
#[doc = r" Value of the field as raw bits"]
#[inline]
pub fn bit(&self) -> bool {
match *self {
MCM33_DBGENR::DISABLE => false,
MCM33_DBGENR::ENABLE => true,
}
}
#[allow(missing_docs)]
#[doc(hidden)]
#[inline]
pub fn _from(value: bool) -> MCM33_DBGENR {
match value {
false => MCM33_DBGENR::DISABLE,
true => MCM33_DBGENR::ENABLE,
}
}
#[doc = "Checks if the value of the field is `DISABLE`"]
#[inline]
pub fn is_disable(&self) -> bool {
*self == MCM33_DBGENR::DISABLE
}
#[doc = "Checks if the value of the field is `ENABLE`"]
#[inline]
pub fn is_enable(&self) -> bool {
*self == MCM33_DBGENR::ENABLE
}
}
#[doc = "Possible values of the field `ISP_CMD_EN`"]
#[derive(Clone, Copy, Debug, PartialEq)]
pub enum ISP_CMD_ENR {
#[doc = "Disable"]
DISABLE,
#[doc = "Enable"]
ENABLE,
}
impl ISP_CMD_ENR {
#[doc = r" Returns `true` if the bit is clear (0)"]
#[inline]
pub fn bit_is_clear(&self) -> bool {
!self.bit()
}
#[doc = r" Returns `true` if the bit is set (1)"]
#[inline]
pub fn bit_is_set(&self) -> bool {
self.bit()
}
#[doc = r" Value of the field as raw bits"]
#[inline]
pub fn bit(&self) -> bool {
match *self {
ISP_CMD_ENR::DISABLE => false,
ISP_CMD_ENR::ENABLE => true,
}
}
#[allow(missing_docs)]
#[doc(hidden)]
#[inline]
pub fn _from(value: bool) -> ISP_CMD_ENR {
match value {
false => ISP_CMD_ENR::DISABLE,
true => ISP_CMD_ENR::ENABLE,
}
}
#[doc = "Checks if the value of the field is `DISABLE`"]
#[inline]
pub fn is_disable(&self) -> bool {
*self == ISP_CMD_ENR::DISABLE
}
#[doc = "Checks if the value of the field is `ENABLE`"]
#[inline]
pub fn is_enable(&self) -> bool {
*self == ISP_CMD_ENR::ENABLE
}
}
#[doc = "Possible values of the field `FA_CMD_EN`"]
#[derive(Clone, Copy, Debug, PartialEq)]
pub enum FA_CMD_ENR {
#[doc = "Disable"]
DISABLE,
#[doc = "Enable"]
ENABLE,
}
impl FA_CMD_ENR {
#[doc = r" Returns `true` if the bit is clear (0)"]
#[inline]
pub fn bit_is_clear(&self) -> bool {
!self.bit()
}
#[doc = r" Returns `true` if the bit is set (1)"]
#[inline]
pub fn bit_is_set(&self) -> bool {
self.bit()
}
#[doc = r" Value of the field as raw bits"]
#[inline]
pub fn bit(&self) -> bool {
match *self {
FA_CMD_ENR::DISABLE => false,
FA_CMD_ENR::ENABLE => true,
}
}
#[allow(missing_docs)]
#[doc(hidden)]
#[inline]
pub fn _from(value: bool) -> FA_CMD_ENR {
match value {
false => FA_CMD_ENR::DISABLE,
true => FA_CMD_ENR::ENABLE,
}
}
#[doc = "Checks if the value of the field is `DISABLE`"]
#[inline]
pub fn is_disable(&self) -> bool {
*self == FA_CMD_ENR::DISABLE
}
#[doc = "Checks if the value of the field is `ENABLE`"]
#[inline]
pub fn is_enable(&self) -> bool {
*self == FA_CMD_ENR::ENABLE
}
}
#[doc = "Possible values of the field `ME_CMD_EN`"]
#[derive(Clone, Copy, Debug, PartialEq)]
pub enum ME_CMD_ENR {
#[doc = "Disable"]
DISABLE,
#[doc = "Enable"]
ENABLE,
}
impl ME_CMD_ENR {
#[doc = r" Returns `true` if the bit is clear (0)"]
#[inline]
pub fn bit_is_clear(&self) -> bool {
!self.bit()
}
#[doc = r" Returns `true` if the bit is set (1)"]
#[inline]
pub fn bit_is_set(&self) -> bool {
self.bit()
}
#[doc = r" Value of the field as raw bits"]
#[inline]
pub fn bit(&self) -> bool {
match *self {
ME_CMD_ENR::DISABLE => false,
ME_CMD_ENR::ENABLE => true,
}
}
#[allow(missing_docs)]
#[doc(hidden)]
#[inline]
pub fn _from(value: bool) -> ME_CMD_ENR {
match value {
false => ME_CMD_ENR::DISABLE,
true => ME_CMD_ENR::ENABLE,
}
}
#[doc = "Checks if the value of the field is `DISABLE`"]
#[inline]
pub fn is_disable(&self) -> bool {
*self == ME_CMD_ENR::DISABLE
}
#[doc = "Checks if the value of the field is `ENABLE`"]
#[inline]
pub fn is_enable(&self) -> bool {
*self == ME_CMD_ENR::ENABLE
}
}
#[doc = "Possible values of the field `MCM33_NIDEN`"]
#[derive(Clone, Copy, Debug, PartialEq)]
pub enum MCM33_NIDENR {
#[doc = "Disable"]
DISABLE,
#[doc = "Enable"]
ENABLE,
}
impl MCM33_NIDENR {
#[doc = r" Returns `true` if the bit is clear (0)"]
#[inline]
pub fn bit_is_clear(&self) -> bool {
!self.bit()
}
#[doc = r" Returns `true` if the bit is set (1)"]
#[inline]
pub fn bit_is_set(&self) -> bool {
self.bit()
}
#[doc = r" Value of the field as raw bits"]
#[inline]
pub fn bit(&self) -> bool {
match *self {
MCM33_NIDENR::DISABLE => false,
MCM33_NIDENR::ENABLE => true,
}
}
#[allow(missing_docs)]
#[doc(hidden)]
#[inline]
pub fn _from(value: bool) -> MCM33_NIDENR {
match value {
false => MCM33_NIDENR::DISABLE,
true => MCM33_NIDENR::ENABLE,
}
}
#[doc = "Checks if the value of the field is `DISABLE`"]
#[inline]
pub fn is_disable(&self) -> bool {
*self == MCM33_NIDENR::DISABLE
}
#[doc = "Checks if the value of the field is `ENABLE`"]
#[inline]
pub fn is_enable(&self) -> bool {
*self == MCM33_NIDENR::ENABLE
}
}
#[doc = r" Value of the field"]
pub struct INVERSE_VALUER {
bits: u16,
}
impl INVERSE_VALUER {
#[doc = r" Value of the field as raw bits"]
#[inline]
pub fn bits(&self) -> u16 {
self.bits
}
}
#[doc = "Values that can be written to the field `NIDEN`"]
pub enum NIDENW {
#[doc = "Disable"]
DISABLE,
#[doc = "Enable"]
ENABLE,
}
impl NIDENW {
#[allow(missing_docs)]
#[doc(hidden)]
#[inline]
pub fn _bits(&self) -> bool {
match *self {
NIDENW::DISABLE => false,
NIDENW::ENABLE => true,
}
}
}
#[doc = r" Proxy"]
pub struct _NIDENW<'a> {
w: &'a mut W,
}
impl<'a> _NIDENW<'a> {
#[doc = r" Writes `variant` to the field"]
#[inline]
pub fn variant(self, variant: NIDENW) -> &'a mut W {
{
self.bit(variant._bits())
}
}
#[doc = "Disable"]
#[inline]
pub fn disable(self) -> &'a mut W {
self.variant(NIDENW::DISABLE)
}
#[doc = "Enable"]
#[inline]
pub fn enable(self) -> &'a mut W {
self.variant(NIDENW::ENABLE)
}
#[doc = r" Sets the field bit"]
pub fn set_bit(self) -> &'a mut W {
self.bit(true)
}
#[doc = r" Clears the field bit"]
pub fn clear_bit(self) -> &'a mut W {
self.bit(false)
}
#[doc = r" Writes raw bits to the field"]
#[inline]
pub fn bit(self, value: bool) -> &'a mut W {
const MASK: bool = true;
const OFFSET: u8 = 0;
self.w.bits &= !((MASK as u32) << OFFSET);
self.w.bits |= ((value & MASK) as u32) << OFFSET;
self.w
}
}
#[doc = "Values that can be written to the field `DBGEN`"]
pub enum DBGENW {
#[doc = "Disable"]
DISABLE,
#[doc = "Enable"]
ENABLE,
}
impl DBGENW {
#[allow(missing_docs)]
#[doc(hidden)]
#[inline]
pub fn _bits(&self) -> bool {
match *self {
DBGENW::DISABLE => false,
DBGENW::ENABLE => true,
}
}
}
#[doc = r" Proxy"]
pub struct _DBGENW<'a> {
w: &'a mut W,
}
impl<'a> _DBGENW<'a> {
#[doc = r" Writes `variant` to the field"]
#[inline]
pub fn variant(self, variant: DBGENW) -> &'a mut W {
{
self.bit(variant._bits())
}
}
#[doc = "Disable"]
#[inline]
pub fn disable(self) -> &'a mut W {
self.variant(DBGENW::DISABLE)
}
#[doc = "Enable"]
#[inline]
pub fn enable(self) -> &'a mut W {
self.variant(DBGENW::ENABLE)
}
#[doc = r" Sets the field bit"]
pub fn set_bit(self) -> &'a mut W {
self.bit(true)
}
#[doc = r" Clears the field bit"]
pub fn clear_bit(self) -> &'a mut W {
self.bit(false)
}
#[doc = r" Writes raw bits to the field"]
#[inline]
pub fn bit(self, value: bool) -> &'a mut W {
const MASK: bool = true;
const OFFSET: u8 = 1;
self.w.bits &= !((MASK as u32) << OFFSET);
self.w.bits |= ((value & MASK) as u32) << OFFSET;
self.w
}
}
#[doc = "Values that can be written to the field `SPNIDEN`"]
pub enum SPNIDENW {
#[doc = "Disable"]
DISABLE,
#[doc = "Enable"]
ENABLE,
}
impl SPNIDENW {
#[allow(missing_docs)]
#[doc(hidden)]
#[inline]
pub fn _bits(&self) -> bool {
match *self {
SPNIDENW::DISABLE => false,
SPNIDENW::ENABLE => true,
}
}
}
#[doc = r" Proxy"]
pub struct _SPNIDENW<'a> {
w: &'a mut W,
}
impl<'a> _SPNIDENW<'a> {
#[doc = r" Writes `variant` to the field"]
#[inline]
pub fn variant(self, variant: SPNIDENW) -> &'a mut W {
{
self.bit(variant._bits())
}
}
#[doc = "Disable"]
#[inline]
pub fn disable(self) -> &'a mut W {
self.variant(SPNIDENW::DISABLE)
}
#[doc = "Enable"]
#[inline]
pub fn enable(self) -> &'a mut W {
self.variant(SPNIDENW::ENABLE)
}
#[doc = r" Sets the field bit"]
pub fn set_bit(self) -> &'a mut W {
self.bit(true)
}
#[doc = r" Clears the field bit"]
pub fn clear_bit(self) -> &'a mut W {
self.bit(false)
}
#[doc = r" Writes raw bits to the field"]
#[inline]
pub fn bit(self, value: bool) -> &'a mut W {
const MASK: bool = true;
const OFFSET: u8 = 2;
self.w.bits &= !((MASK as u32) << OFFSET);
self.w.bits |= ((value & MASK) as u32) << OFFSET;
self.w
}
}
#[doc = "Values that can be written to the field `SPIDEN`"]
pub enum SPIDENW {
#[doc = "Disable"]
DISABLE,
#[doc = "Enable"]
ENABLE,
}
impl SPIDENW {
#[allow(missing_docs)]
#[doc(hidden)]
#[inline]
pub fn _bits(&self) -> bool {
match *self {
SPIDENW::DISABLE => false,
SPIDENW::ENABLE => true,
}
}
}
#[doc = r" Proxy"]
pub struct _SPIDENW<'a> {
w: &'a mut W,
}
impl<'a> _SPIDENW<'a> {
#[doc = r" Writes `variant` to the field"]
#[inline]
pub fn variant(self, variant: SPIDENW) -> &'a mut W {
{
self.bit(variant._bits())
}
}
#[doc = "Disable"]
#[inline]
pub fn disable(self) -> &'a mut W {
self.variant(SPIDENW::DISABLE)
}
#[doc = "Enable"]
#[inline]
pub fn enable(self) -> &'a mut W {
self.variant(SPIDENW::ENABLE)
}
#[doc = r" Sets the field bit"]
pub fn set_bit(self) -> &'a mut W {
self.bit(true)
}
#[doc = r" Clears the field bit"]
pub fn clear_bit(self) -> &'a mut W {
self.bit(false)
}
#[doc = r" Writes raw bits to the field"]
#[inline]
pub fn bit(self, value: bool) -> &'a mut W {
const MASK: bool = true;
const OFFSET: u8 = 3;
self.w.bits &= !((MASK as u32) << OFFSET);
self.w.bits |= ((value & MASK) as u32) << OFFSET;
self.w
}
}
#[doc = "Values that can be written to the field `TAPEN`"]
pub enum TAPENW {
#[doc = "Disable"]
DISABLE,
#[doc = "Enable"]
ENABLE,
}
impl TAPENW {
#[allow(missing_docs)]
#[doc(hidden)]
#[inline]
pub fn _bits(&self) -> bool {
match *self {
TAPENW::DISABLE => false,
TAPENW::ENABLE => true,
}
}
}
#[doc = r" Proxy"]
pub struct _TAPENW<'a> {
w: &'a mut W,
}
impl<'a> _TAPENW<'a> {
#[doc = r" Writes `variant` to the field"]
#[inline]
pub fn variant(self, variant: TAPENW) -> &'a mut W {
{
self.bit(variant._bits())
}
}
#[doc = "Disable"]
#[inline]
pub fn disable(self) -> &'a mut W {
self.variant(TAPENW::DISABLE)
}
#[doc = "Enable"]
#[inline]
pub fn enable(self) -> &'a mut W {
self.variant(TAPENW::ENABLE)
}
#[doc = r" Sets the field bit"]
pub fn set_bit(self) -> &'a mut W {
self.bit(true)
}
#[doc = r" Clears the field bit"]
pub fn clear_bit(self) -> &'a mut W {
self.bit(false)
}
#[doc = r" Writes raw bits to the field"]
#[inline]
pub fn bit(self, value: bool) -> &'a mut W {
const MASK: bool = true;
const OFFSET: u8 = 4;
self.w.bits &= !((MASK as u32) << OFFSET);
self.w.bits |= ((value & MASK) as u32) << OFFSET;
self.w
}
}
#[doc = "Values that can be written to the field `MCM33_DBGEN`"]
pub enum MCM33_DBGENW {
#[doc = "Disable"]
DISABLE,
#[doc = "Enable"]
ENABLE,
}
impl MCM33_DBGENW {
#[allow(missing_docs)]
#[doc(hidden)]
#[inline]
pub fn _bits(&self) -> bool {
match *self {
MCM33_DBGENW::DISABLE => false,
MCM33_DBGENW::ENABLE => true,
}
}
}
#[doc = r" Proxy"]
pub struct _MCM33_DBGENW<'a> {
w: &'a mut W,
}
impl<'a> _MCM33_DBGENW<'a> {
#[doc = r" Writes `variant` to the field"]
#[inline]
pub fn variant(self, variant: MCM33_DBGENW) -> &'a mut W {
{
self.bit(variant._bits())
}
}
#[doc = "Disable"]
#[inline]
pub fn disable(self) -> &'a mut W {
self.variant(MCM33_DBGENW::DISABLE)
}
#[doc = "Enable"]
#[inline]
pub fn enable(self) -> &'a mut W {
self.variant(MCM33_DBGENW::ENABLE)
}
#[doc = r" Sets the field bit"]
pub fn set_bit(self) -> &'a mut W {
self.bit(true)
}
#[doc = r" Clears the field bit"]
pub fn clear_bit(self) -> &'a mut W {
self.bit(false)
}
#[doc = r" Writes raw bits to the field"]
#[inline]
pub fn bit(self, value: bool) -> &'a mut W {
const MASK: bool = true;
const OFFSET: u8 = 5;
self.w.bits &= !((MASK as u32) << OFFSET);
self.w.bits |= ((value & MASK) as u32) << OFFSET;
self.w
}
}
#[doc = "Values that can be written to the field `ISP_CMD_EN`"]
pub enum ISP_CMD_ENW {
#[doc = "Disable"]
DISABLE,
#[doc = "Enable"]
ENABLE,
}
impl ISP_CMD_ENW {
#[allow(missing_docs)]
#[doc(hidden)]
#[inline]
pub fn _bits(&self) -> bool {
match *self {
ISP_CMD_ENW::DISABLE => false,
ISP_CMD_ENW::ENABLE => true,
}
}
}
#[doc = r" Proxy"]
pub struct _ISP_CMD_ENW<'a> {
w: &'a mut W,
}
impl<'a> _ISP_CMD_ENW<'a> {
#[doc = r" Writes `variant` to the field"]
#[inline]
pub fn variant(self, variant: ISP_CMD_ENW) -> &'a mut W {
{
self.bit(variant._bits())
}
}
#[doc = "Disable"]
#[inline]
pub fn disable(self) -> &'a mut W {
self.variant(ISP_CMD_ENW::DISABLE)
}
#[doc = "Enable"]
#[inline]
pub fn enable(self) -> &'a mut W {
self.variant(ISP_CMD_ENW::ENABLE)
}
#[doc = r" Sets the field bit"]
pub fn set_bit(self) -> &'a mut W {
self.bit(true)
}
#[doc = r" Clears the field bit"]
pub fn clear_bit(self) -> &'a mut W {
self.bit(false)
}
#[doc = r" Writes raw bits to the field"]
#[inline]
pub fn bit(self, value: bool) -> &'a mut W {
const MASK: bool = true;
const OFFSET: u8 = 6;
self.w.bits &= !((MASK as u32) << OFFSET);
self.w.bits |= ((value & MASK) as u32) << OFFSET;
self.w
}
}
#[doc = "Values that can be written to the field `FA_CMD_EN`"]
pub enum FA_CMD_ENW {
#[doc = "Disable"]
DISABLE,
#[doc = "Enable"]
ENABLE,
}
impl FA_CMD_ENW {
#[allow(missing_docs)]
#[doc(hidden)]
#[inline]
pub fn _bits(&self) -> bool {
match *self {
FA_CMD_ENW::DISABLE => false,
FA_CMD_ENW::ENABLE => true,
}
}
}
#[doc = r" Proxy"]
pub struct _FA_CMD_ENW<'a> {
w: &'a mut W,
}
impl<'a> _FA_CMD_ENW<'a> {
#[doc = r" Writes `variant` to the field"]
#[inline]
pub fn variant(self, variant: FA_CMD_ENW) -> &'a mut W {
{
self.bit(variant._bits())
}
}
#[doc = "Disable"]
#[inline]
pub fn disable(self) -> &'a mut W {
self.variant(FA_CMD_ENW::DISABLE)
}
#[doc = "Enable"]
#[inline]
pub fn enable(self) -> &'a mut W {
self.variant(FA_CMD_ENW::ENABLE)
}
#[doc = r" Sets the field bit"]
pub fn set_bit(self) -> &'a mut W {
self.bit(true)
}
#[doc = r" Clears the field bit"]
pub fn clear_bit(self) -> &'a mut W {
self.bit(false)
}
#[doc = r" Writes raw bits to the field"]
#[inline]
pub fn bit(self, value: bool) -> &'a mut W {
const MASK: bool = true;
const OFFSET: u8 = 7;
self.w.bits &= !((MASK as u32) << OFFSET);
self.w.bits |= ((value & MASK) as u32) << OFFSET;
self.w
}
}
#[doc = "Values that can be written to the field `ME_CMD_EN`"]
pub enum ME_CMD_ENW {
#[doc = "Disable"]
DISABLE,
#[doc = "Enable"]
ENABLE,
}
impl ME_CMD_ENW {
#[allow(missing_docs)]
#[doc(hidden)]
#[inline]
pub fn _bits(&self) -> bool {
match *self {
ME_CMD_ENW::DISABLE => false,
ME_CMD_ENW::ENABLE => true,
}
}
}
#[doc = r" Proxy"]
pub struct _ME_CMD_ENW<'a> {
w: &'a mut W,
}
impl<'a> _ME_CMD_ENW<'a> {
#[doc = r" Writes `variant` to the field"]
#[inline]
pub fn variant(self, variant: ME_CMD_ENW) -> &'a mut W {
{
self.bit(variant._bits())
}
}
#[doc = "Disable"]
#[inline]
pub fn disable(self) -> &'a mut W {
self.variant(ME_CMD_ENW::DISABLE)
}
#[doc = "Enable"]
#[inline]
pub fn enable(self) -> &'a mut W {
self.variant(ME_CMD_ENW::ENABLE)
}
#[doc = r" Sets the field bit"]
pub fn set_bit(self) -> &'a mut W {
self.bit(true)
}
#[doc = r" Clears the field bit"]
pub fn clear_bit(self) -> &'a mut W {
self.bit(false)
}
#[doc = r" Writes raw bits to the field"]
#[inline]
pub fn bit(self, value: bool) -> &'a mut W {
const MASK: bool = true;
const OFFSET: u8 = 8;
self.w.bits &= !((MASK as u32) << OFFSET);
self.w.bits |= ((value & MASK) as u32) << OFFSET;
self.w
}
}
#[doc = "Values that can be written to the field `MCM33_NIDEN`"]
pub enum MCM33_NIDENW {
#[doc = "Disable"]
DISABLE,
#[doc = "Enable"]
ENABLE,
}
impl MCM33_NIDENW {
#[allow(missing_docs)]
#[doc(hidden)]
#[inline]
pub fn _bits(&self) -> bool {
match *self {
MCM33_NIDENW::DISABLE => false,
MCM33_NIDENW::ENABLE => true,
}
}
}
#[doc = r" Proxy"]
pub struct _MCM33_NIDENW<'a> {
w: &'a mut W,
}
impl<'a> _MCM33_NIDENW<'a> {
#[doc = r" Writes `variant` to the field"]
#[inline]
pub fn variant(self, variant: MCM33_NIDENW) -> &'a mut W {
{
self.bit(variant._bits())
}
}
#[doc = "Disable"]
#[inline]
pub fn disable(self) -> &'a mut W {
self.variant(MCM33_NIDENW::DISABLE)
}
#[doc = "Enable"]
#[inline]
pub fn enable(self) -> &'a mut W {
self.variant(MCM33_NIDENW::ENABLE)
}
#[doc = r" Sets the field bit"]
pub fn set_bit(self) -> &'a mut W {
self.bit(true)
}
#[doc = r" Clears the field bit"]
pub fn clear_bit(self) -> &'a mut W {
self.bit(false)
}
#[doc = r" Writes raw bits to the field"]
#[inline]
pub fn bit(self, value: bool) -> &'a mut W {
const MASK: bool = true;
const OFFSET: u8 = 9;
self.w.bits &= !((MASK as u32) << OFFSET);
self.w.bits |= ((value & MASK) as u32) << OFFSET;
self.w
}
}
#[doc = r" Proxy"]
pub struct _INVERSE_VALUEW<'a> {
w: &'a mut W,
}
impl<'a> _INVERSE_VALUEW<'a> {
#[doc = r" Writes raw bits to the field"]
#[inline]
pub unsafe fn bits(self, value: u16) -> &'a mut W {
const MASK: u16 = 65535;
const OFFSET: u8 = 16;
self.w.bits &= !((MASK as u32) << OFFSET);
self.w.bits |= ((value & MASK) as u32) << OFFSET;
self.w
}
}
impl R {
#[doc = r" Value of the register as raw bits"]
#[inline]
pub fn bits(&self) -> u32 {
self.bits
}
#[doc = "Bit 0 - Non Secure non-invasive debug fixed state"]
#[inline]
pub fn niden(&self) -> NIDENR {
NIDENR::_from({
const MASK: bool = true;
const OFFSET: u8 = 0;
((self.bits >> OFFSET) & MASK as u32) != 0
})
}
#[doc = "Bit 1 - Non Secure debug fixed state"]
#[inline]
pub fn dbgen(&self) -> DBGENR {
DBGENR::_from({
const MASK: bool = true;
const OFFSET: u8 = 1;
((self.bits >> OFFSET) & MASK as u32) != 0
})
}
#[doc = "Bit 2 - Secure non-invasive debug fixed state"]
#[inline]
pub fn spniden(&self) -> SPNIDENR {
SPNIDENR::_from({
const MASK: bool = true;
const OFFSET: u8 = 2;
((self.bits >> OFFSET) & MASK as u32) != 0
})
}
#[doc = "Bit 3 - Secure invasive debug fixed state"]
#[inline]
pub fn spiden(&self) -> SPIDENR {
SPIDENR::_from({
const MASK: bool = true;
const OFFSET: u8 = 3;
((self.bits >> OFFSET) & MASK as u32) != 0
})
}
#[doc = "Bit 4 - JTAG TAP fixed state"]
#[inline]
pub fn tapen(&self) -> TAPENR {
TAPENR::_from({
const MASK: bool = true;
const OFFSET: u8 = 4;
((self.bits >> OFFSET) & MASK as u32) != 0
})
}
#[doc = "Bit 5 - Micro CM33 invasive debug fixed state"]
#[inline]
pub fn mcm33_dbgen(&self) -> MCM33_DBGENR {
MCM33_DBGENR::_from({
const MASK: bool = true;
const OFFSET: u8 = 5;
((self.bits >> OFFSET) & MASK as u32) != 0
})
}
#[doc = "Bit 6 - ISP Boot Command fixed state"]
#[inline]
pub fn isp_cmd_en(&self) -> ISP_CMD_ENR {
ISP_CMD_ENR::_from({
const MASK: bool = true;
const OFFSET: u8 = 6;
((self.bits >> OFFSET) & MASK as u32) != 0
})
}
#[doc = "Bit 7 - FA Command fixed state"]
#[inline]
pub fn fa_cmd_en(&self) -> FA_CMD_ENR {
FA_CMD_ENR::_from({
const MASK: bool = true;
const OFFSET: u8 = 7;
((self.bits >> OFFSET) & MASK as u32) != 0
})
}
#[doc = "Bit 8 - Flash Mass Erase Command fixed state"]
#[inline]
pub fn me_cmd_en(&self) -> ME_CMD_ENR {
ME_CMD_ENR::_from({
const MASK: bool = true;
const OFFSET: u8 = 8;
((self.bits >> OFFSET) & MASK as u32) != 0
})
}
#[doc = "Bit 9 - Micro CM33 non-invasive debug fixed state"]
#[inline]
pub fn mcm33_niden(&self) -> MCM33_NIDENR {
MCM33_NIDENR::_from({
const MASK: bool = true;
const OFFSET: u8 = 9;
((self.bits >> OFFSET) & MASK as u32) != 0
})
}
#[doc = "Bits 16:31 - inverse value of bits \\[15:0\\]"]
#[inline]
pub fn inverse_value(&self) -> INVERSE_VALUER {
let bits = {
const MASK: u16 = 65535;
const OFFSET: u8 = 16;
((self.bits >> OFFSET) & MASK as u32) as u16
};
INVERSE_VALUER { bits }
}
}
impl W {
#[doc = r" Reset value of the register"]
#[inline]
pub fn reset_value() -> W {
W { bits: 0 }
}
#[doc = r" Writes raw bits to the register"]
#[inline]
pub unsafe fn bits(&mut self, bits: u32) -> &mut Self {
self.bits = bits;
self
}
#[doc = "Bit 0 - Non Secure non-invasive debug fixed state"]
#[inline]
pub fn niden(&mut self) -> _NIDENW {
_NIDENW { w: self }
}
#[doc = "Bit 1 - Non Secure debug fixed state"]
#[inline]
pub fn dbgen(&mut self) -> _DBGENW {
_DBGENW { w: self }
}
#[doc = "Bit 2 - Secure non-invasive debug fixed state"]
#[inline]
pub fn spniden(&mut self) -> _SPNIDENW {
_SPNIDENW { w: self }
}
#[doc = "Bit 3 - Secure invasive debug fixed state"]
#[inline]
pub fn spiden(&mut self) -> _SPIDENW {
_SPIDENW { w: self }
}
#[doc = "Bit 4 - JTAG TAP fixed state"]
#[inline]
pub fn tapen(&mut self) -> _TAPENW {
_TAPENW { w: self }
}
#[doc = "Bit 5 - Micro CM33 invasive debug fixed state"]
#[inline]
pub fn mcm33_dbgen(&mut self) -> _MCM33_DBGENW {
_MCM33_DBGENW { w: self }
}
#[doc = "Bit 6 - ISP Boot Command fixed state"]
#[inline]
pub fn isp_cmd_en(&mut self) -> _ISP_CMD_ENW {
_ISP_CMD_ENW { w: self }
}
#[doc = "Bit 7 - FA Command fixed state"]
#[inline]
pub fn fa_cmd_en(&mut self) -> _FA_CMD_ENW {
_FA_CMD_ENW { w: self }
}
#[doc = "Bit 8 - Flash Mass Erase Command fixed state"]
#[inline]
pub fn me_cmd_en(&mut self) -> _ME_CMD_ENW {
_ME_CMD_ENW { w: self }
}
#[doc = "Bit 9 - Micro CM33 non-invasive debug fixed state"]
#[inline]
pub fn mcm33_niden(&mut self) -> _MCM33_NIDENW {
_MCM33_NIDENW { w: self }
}
#[doc = "Bits 16:31 - inverse value of bits \\[15:0\\]"]
#[inline]
pub fn inverse_value(&mut self) -> _INVERSE_VALUEW {
_INVERSE_VALUEW { w: self }
}
}