feat: add display UI with splash screen, dashboard, and RSSI sparkline
Implement full SSD1306 OLED display support: - Splash screen on boot (1.5s) with project name, version, board - Dashboard showing radio state, config, counters, RSSI/SNR - RSSI history sparkline (64-sample ring buffer, 2px-wide bars) - DisplayOn/DisplayOff host commands routed via dedicated channel - Pure render functions against generic DrawTarget (no hardware coupling) - Display on/off control bypasses radio task entirely Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
17624 files changed
+4564928
-38
No files matched your search
@@ -0,0 +1,127 @@
|
||||
#[doc = "Register `EVENTS_KEYSLOT_ERROR` reader"]
|
||||
pub struct R(crate::R<EVENTS_KEYSLOT_ERROR_SPEC>);
|
||||
impl core::ops::Deref for R {
|
||||
type Target = crate::R<EVENTS_KEYSLOT_ERROR_SPEC>;
|
||||
#[inline(always)]
|
||||
fn deref(&self) -> &Self::Target {
|
||||
&self.0
|
||||
}
|
||||
}
|
||||
impl From<crate::R<EVENTS_KEYSLOT_ERROR_SPEC>> for R {
|
||||
#[inline(always)]
|
||||
fn from(reader: crate::R<EVENTS_KEYSLOT_ERROR_SPEC>) -> Self {
|
||||
R(reader)
|
||||
}
|
||||
}
|
||||
#[doc = "Register `EVENTS_KEYSLOT_ERROR` writer"]
|
||||
pub struct W(crate::W<EVENTS_KEYSLOT_ERROR_SPEC>);
|
||||
impl core::ops::Deref for W {
|
||||
type Target = crate::W<EVENTS_KEYSLOT_ERROR_SPEC>;
|
||||
#[inline(always)]
|
||||
fn deref(&self) -> &Self::Target {
|
||||
&self.0
|
||||
}
|
||||
}
|
||||
impl core::ops::DerefMut for W {
|
||||
#[inline(always)]
|
||||
fn deref_mut(&mut self) -> &mut Self::Target {
|
||||
&mut self.0
|
||||
}
|
||||
}
|
||||
impl From<crate::W<EVENTS_KEYSLOT_ERROR_SPEC>> for W {
|
||||
#[inline(always)]
|
||||
fn from(writer: crate::W<EVENTS_KEYSLOT_ERROR_SPEC>) -> Self {
|
||||
W(writer)
|
||||
}
|
||||
}
|
||||
#[doc = "Field `EVENTS_KEYSLOT_ERROR` reader - No key slot selected, no destination address defined, or error during push operation"]
|
||||
pub type EVENTS_KEYSLOT_ERROR_R = crate::BitReader<EVENTS_KEYSLOT_ERROR_A>;
|
||||
#[doc = "No key slot selected, no destination address defined, or error during push operation\n\nValue on reset: 0"]
|
||||
#[derive(Clone, Copy, Debug, PartialEq)]
|
||||
pub enum EVENTS_KEYSLOT_ERROR_A {
|
||||
#[doc = "0: Event not generated"]
|
||||
NOT_GENERATED = 0,
|
||||
#[doc = "1: Event generated"]
|
||||
GENERATED = 1,
|
||||
}
|
||||
impl From<EVENTS_KEYSLOT_ERROR_A> for bool {
|
||||
#[inline(always)]
|
||||
fn from(variant: EVENTS_KEYSLOT_ERROR_A) -> Self {
|
||||
variant as u8 != 0
|
||||
}
|
||||
}
|
||||
impl EVENTS_KEYSLOT_ERROR_R {
|
||||
#[doc = "Get enumerated values variant"]
|
||||
#[inline(always)]
|
||||
pub fn variant(&self) -> EVENTS_KEYSLOT_ERROR_A {
|
||||
match self.bits {
|
||||
false => EVENTS_KEYSLOT_ERROR_A::NOT_GENERATED,
|
||||
true => EVENTS_KEYSLOT_ERROR_A::GENERATED,
|
||||
}
|
||||
}
|
||||
#[doc = "Checks if the value of the field is `NOT_GENERATED`"]
|
||||
#[inline(always)]
|
||||
pub fn is_not_generated(&self) -> bool {
|
||||
*self == EVENTS_KEYSLOT_ERROR_A::NOT_GENERATED
|
||||
}
|
||||
#[doc = "Checks if the value of the field is `GENERATED`"]
|
||||
#[inline(always)]
|
||||
pub fn is_generated(&self) -> bool {
|
||||
*self == EVENTS_KEYSLOT_ERROR_A::GENERATED
|
||||
}
|
||||
}
|
||||
#[doc = "Field `EVENTS_KEYSLOT_ERROR` writer - No key slot selected, no destination address defined, or error during push operation"]
|
||||
pub type EVENTS_KEYSLOT_ERROR_W<'a, const O: u8> =
|
||||
crate::BitWriter<'a, u32, EVENTS_KEYSLOT_ERROR_SPEC, EVENTS_KEYSLOT_ERROR_A, O>;
|
||||
impl<'a, const O: u8> EVENTS_KEYSLOT_ERROR_W<'a, O> {
|
||||
#[doc = "Event not generated"]
|
||||
#[inline(always)]
|
||||
pub fn not_generated(self) -> &'a mut W {
|
||||
self.variant(EVENTS_KEYSLOT_ERROR_A::NOT_GENERATED)
|
||||
}
|
||||
#[doc = "Event generated"]
|
||||
#[inline(always)]
|
||||
pub fn generated(self) -> &'a mut W {
|
||||
self.variant(EVENTS_KEYSLOT_ERROR_A::GENERATED)
|
||||
}
|
||||
}
|
||||
impl R {
|
||||
#[doc = "Bit 0 - No key slot selected, no destination address defined, or error during push operation"]
|
||||
#[inline(always)]
|
||||
pub fn events_keyslot_error(&self) -> EVENTS_KEYSLOT_ERROR_R {
|
||||
EVENTS_KEYSLOT_ERROR_R::new((self.bits & 1) != 0)
|
||||
}
|
||||
}
|
||||
impl W {
|
||||
#[doc = "Bit 0 - No key slot selected, no destination address defined, or error during push operation"]
|
||||
#[inline(always)]
|
||||
pub fn events_keyslot_error(&mut self) -> EVENTS_KEYSLOT_ERROR_W<0> {
|
||||
EVENTS_KEYSLOT_ERROR_W::new(self)
|
||||
}
|
||||
#[doc = "Writes raw bits to the register."]
|
||||
#[inline(always)]
|
||||
pub unsafe fn bits(&mut self, bits: u32) -> &mut Self {
|
||||
self.0.bits(bits);
|
||||
self
|
||||
}
|
||||
}
|
||||
#[doc = "No key slot selected, no destination address defined, or error during push operation\n\nThis register you can [`read`](crate::generic::Reg::read), [`write_with_zero`](crate::generic::Reg::write_with_zero), [`reset`](crate::generic::Reg::reset), [`write`](crate::generic::Reg::write), [`modify`](crate::generic::Reg::modify). See [API](https://docs.rs/svd2rust/#read--modify--write-api).\n\nFor information about available fields see [events_keyslot_error](index.html) module"]
|
||||
pub struct EVENTS_KEYSLOT_ERROR_SPEC;
|
||||
impl crate::RegisterSpec for EVENTS_KEYSLOT_ERROR_SPEC {
|
||||
type Ux = u32;
|
||||
}
|
||||
#[doc = "`read()` method returns [events_keyslot_error::R](R) reader structure"]
|
||||
impl crate::Readable for EVENTS_KEYSLOT_ERROR_SPEC {
|
||||
type Reader = R;
|
||||
}
|
||||
#[doc = "`write(|w| ..)` method takes [events_keyslot_error::W](W) writer structure"]
|
||||
impl crate::Writable for EVENTS_KEYSLOT_ERROR_SPEC {
|
||||
type Writer = W;
|
||||
}
|
||||
#[doc = "`reset()` method sets EVENTS_KEYSLOT_ERROR to value 0"]
|
||||
impl crate::Resettable for EVENTS_KEYSLOT_ERROR_SPEC {
|
||||
#[inline(always)]
|
||||
fn reset_value() -> Self::Ux {
|
||||
0
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,127 @@
|
||||
#[doc = "Register `EVENTS_KEYSLOT_PUSHED` reader"]
|
||||
pub struct R(crate::R<EVENTS_KEYSLOT_PUSHED_SPEC>);
|
||||
impl core::ops::Deref for R {
|
||||
type Target = crate::R<EVENTS_KEYSLOT_PUSHED_SPEC>;
|
||||
#[inline(always)]
|
||||
fn deref(&self) -> &Self::Target {
|
||||
&self.0
|
||||
}
|
||||
}
|
||||
impl From<crate::R<EVENTS_KEYSLOT_PUSHED_SPEC>> for R {
|
||||
#[inline(always)]
|
||||
fn from(reader: crate::R<EVENTS_KEYSLOT_PUSHED_SPEC>) -> Self {
|
||||
R(reader)
|
||||
}
|
||||
}
|
||||
#[doc = "Register `EVENTS_KEYSLOT_PUSHED` writer"]
|
||||
pub struct W(crate::W<EVENTS_KEYSLOT_PUSHED_SPEC>);
|
||||
impl core::ops::Deref for W {
|
||||
type Target = crate::W<EVENTS_KEYSLOT_PUSHED_SPEC>;
|
||||
#[inline(always)]
|
||||
fn deref(&self) -> &Self::Target {
|
||||
&self.0
|
||||
}
|
||||
}
|
||||
impl core::ops::DerefMut for W {
|
||||
#[inline(always)]
|
||||
fn deref_mut(&mut self) -> &mut Self::Target {
|
||||
&mut self.0
|
||||
}
|
||||
}
|
||||
impl From<crate::W<EVENTS_KEYSLOT_PUSHED_SPEC>> for W {
|
||||
#[inline(always)]
|
||||
fn from(writer: crate::W<EVENTS_KEYSLOT_PUSHED_SPEC>) -> Self {
|
||||
W(writer)
|
||||
}
|
||||
}
|
||||
#[doc = "Field `EVENTS_KEYSLOT_PUSHED` reader - Key slot successfully pushed over secure APB"]
|
||||
pub type EVENTS_KEYSLOT_PUSHED_R = crate::BitReader<EVENTS_KEYSLOT_PUSHED_A>;
|
||||
#[doc = "Key slot successfully pushed over secure APB\n\nValue on reset: 0"]
|
||||
#[derive(Clone, Copy, Debug, PartialEq)]
|
||||
pub enum EVENTS_KEYSLOT_PUSHED_A {
|
||||
#[doc = "0: Event not generated"]
|
||||
NOT_GENERATED = 0,
|
||||
#[doc = "1: Event generated"]
|
||||
GENERATED = 1,
|
||||
}
|
||||
impl From<EVENTS_KEYSLOT_PUSHED_A> for bool {
|
||||
#[inline(always)]
|
||||
fn from(variant: EVENTS_KEYSLOT_PUSHED_A) -> Self {
|
||||
variant as u8 != 0
|
||||
}
|
||||
}
|
||||
impl EVENTS_KEYSLOT_PUSHED_R {
|
||||
#[doc = "Get enumerated values variant"]
|
||||
#[inline(always)]
|
||||
pub fn variant(&self) -> EVENTS_KEYSLOT_PUSHED_A {
|
||||
match self.bits {
|
||||
false => EVENTS_KEYSLOT_PUSHED_A::NOT_GENERATED,
|
||||
true => EVENTS_KEYSLOT_PUSHED_A::GENERATED,
|
||||
}
|
||||
}
|
||||
#[doc = "Checks if the value of the field is `NOT_GENERATED`"]
|
||||
#[inline(always)]
|
||||
pub fn is_not_generated(&self) -> bool {
|
||||
*self == EVENTS_KEYSLOT_PUSHED_A::NOT_GENERATED
|
||||
}
|
||||
#[doc = "Checks if the value of the field is `GENERATED`"]
|
||||
#[inline(always)]
|
||||
pub fn is_generated(&self) -> bool {
|
||||
*self == EVENTS_KEYSLOT_PUSHED_A::GENERATED
|
||||
}
|
||||
}
|
||||
#[doc = "Field `EVENTS_KEYSLOT_PUSHED` writer - Key slot successfully pushed over secure APB"]
|
||||
pub type EVENTS_KEYSLOT_PUSHED_W<'a, const O: u8> =
|
||||
crate::BitWriter<'a, u32, EVENTS_KEYSLOT_PUSHED_SPEC, EVENTS_KEYSLOT_PUSHED_A, O>;
|
||||
impl<'a, const O: u8> EVENTS_KEYSLOT_PUSHED_W<'a, O> {
|
||||
#[doc = "Event not generated"]
|
||||
#[inline(always)]
|
||||
pub fn not_generated(self) -> &'a mut W {
|
||||
self.variant(EVENTS_KEYSLOT_PUSHED_A::NOT_GENERATED)
|
||||
}
|
||||
#[doc = "Event generated"]
|
||||
#[inline(always)]
|
||||
pub fn generated(self) -> &'a mut W {
|
||||
self.variant(EVENTS_KEYSLOT_PUSHED_A::GENERATED)
|
||||
}
|
||||
}
|
||||
impl R {
|
||||
#[doc = "Bit 0 - Key slot successfully pushed over secure APB"]
|
||||
#[inline(always)]
|
||||
pub fn events_keyslot_pushed(&self) -> EVENTS_KEYSLOT_PUSHED_R {
|
||||
EVENTS_KEYSLOT_PUSHED_R::new((self.bits & 1) != 0)
|
||||
}
|
||||
}
|
||||
impl W {
|
||||
#[doc = "Bit 0 - Key slot successfully pushed over secure APB"]
|
||||
#[inline(always)]
|
||||
pub fn events_keyslot_pushed(&mut self) -> EVENTS_KEYSLOT_PUSHED_W<0> {
|
||||
EVENTS_KEYSLOT_PUSHED_W::new(self)
|
||||
}
|
||||
#[doc = "Writes raw bits to the register."]
|
||||
#[inline(always)]
|
||||
pub unsafe fn bits(&mut self, bits: u32) -> &mut Self {
|
||||
self.0.bits(bits);
|
||||
self
|
||||
}
|
||||
}
|
||||
#[doc = "Key slot successfully pushed over secure APB\n\nThis register you can [`read`](crate::generic::Reg::read), [`write_with_zero`](crate::generic::Reg::write_with_zero), [`reset`](crate::generic::Reg::reset), [`write`](crate::generic::Reg::write), [`modify`](crate::generic::Reg::modify). See [API](https://docs.rs/svd2rust/#read--modify--write-api).\n\nFor information about available fields see [events_keyslot_pushed](index.html) module"]
|
||||
pub struct EVENTS_KEYSLOT_PUSHED_SPEC;
|
||||
impl crate::RegisterSpec for EVENTS_KEYSLOT_PUSHED_SPEC {
|
||||
type Ux = u32;
|
||||
}
|
||||
#[doc = "`read()` method returns [events_keyslot_pushed::R](R) reader structure"]
|
||||
impl crate::Readable for EVENTS_KEYSLOT_PUSHED_SPEC {
|
||||
type Reader = R;
|
||||
}
|
||||
#[doc = "`write(|w| ..)` method takes [events_keyslot_pushed::W](W) writer structure"]
|
||||
impl crate::Writable for EVENTS_KEYSLOT_PUSHED_SPEC {
|
||||
type Writer = W;
|
||||
}
|
||||
#[doc = "`reset()` method sets EVENTS_KEYSLOT_PUSHED to value 0"]
|
||||
impl crate::Resettable for EVENTS_KEYSLOT_PUSHED_SPEC {
|
||||
#[inline(always)]
|
||||
fn reset_value() -> Self::Ux {
|
||||
0
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,127 @@
|
||||
#[doc = "Register `EVENTS_KEYSLOT_REVOKED` reader"]
|
||||
pub struct R(crate::R<EVENTS_KEYSLOT_REVOKED_SPEC>);
|
||||
impl core::ops::Deref for R {
|
||||
type Target = crate::R<EVENTS_KEYSLOT_REVOKED_SPEC>;
|
||||
#[inline(always)]
|
||||
fn deref(&self) -> &Self::Target {
|
||||
&self.0
|
||||
}
|
||||
}
|
||||
impl From<crate::R<EVENTS_KEYSLOT_REVOKED_SPEC>> for R {
|
||||
#[inline(always)]
|
||||
fn from(reader: crate::R<EVENTS_KEYSLOT_REVOKED_SPEC>) -> Self {
|
||||
R(reader)
|
||||
}
|
||||
}
|
||||
#[doc = "Register `EVENTS_KEYSLOT_REVOKED` writer"]
|
||||
pub struct W(crate::W<EVENTS_KEYSLOT_REVOKED_SPEC>);
|
||||
impl core::ops::Deref for W {
|
||||
type Target = crate::W<EVENTS_KEYSLOT_REVOKED_SPEC>;
|
||||
#[inline(always)]
|
||||
fn deref(&self) -> &Self::Target {
|
||||
&self.0
|
||||
}
|
||||
}
|
||||
impl core::ops::DerefMut for W {
|
||||
#[inline(always)]
|
||||
fn deref_mut(&mut self) -> &mut Self::Target {
|
||||
&mut self.0
|
||||
}
|
||||
}
|
||||
impl From<crate::W<EVENTS_KEYSLOT_REVOKED_SPEC>> for W {
|
||||
#[inline(always)]
|
||||
fn from(writer: crate::W<EVENTS_KEYSLOT_REVOKED_SPEC>) -> Self {
|
||||
W(writer)
|
||||
}
|
||||
}
|
||||
#[doc = "Field `EVENTS_KEYSLOT_REVOKED` reader - Key slot has been revoked and cannot be tasked for selection"]
|
||||
pub type EVENTS_KEYSLOT_REVOKED_R = crate::BitReader<EVENTS_KEYSLOT_REVOKED_A>;
|
||||
#[doc = "Key slot has been revoked and cannot be tasked for selection\n\nValue on reset: 0"]
|
||||
#[derive(Clone, Copy, Debug, PartialEq)]
|
||||
pub enum EVENTS_KEYSLOT_REVOKED_A {
|
||||
#[doc = "0: Event not generated"]
|
||||
NOT_GENERATED = 0,
|
||||
#[doc = "1: Event generated"]
|
||||
GENERATED = 1,
|
||||
}
|
||||
impl From<EVENTS_KEYSLOT_REVOKED_A> for bool {
|
||||
#[inline(always)]
|
||||
fn from(variant: EVENTS_KEYSLOT_REVOKED_A) -> Self {
|
||||
variant as u8 != 0
|
||||
}
|
||||
}
|
||||
impl EVENTS_KEYSLOT_REVOKED_R {
|
||||
#[doc = "Get enumerated values variant"]
|
||||
#[inline(always)]
|
||||
pub fn variant(&self) -> EVENTS_KEYSLOT_REVOKED_A {
|
||||
match self.bits {
|
||||
false => EVENTS_KEYSLOT_REVOKED_A::NOT_GENERATED,
|
||||
true => EVENTS_KEYSLOT_REVOKED_A::GENERATED,
|
||||
}
|
||||
}
|
||||
#[doc = "Checks if the value of the field is `NOT_GENERATED`"]
|
||||
#[inline(always)]
|
||||
pub fn is_not_generated(&self) -> bool {
|
||||
*self == EVENTS_KEYSLOT_REVOKED_A::NOT_GENERATED
|
||||
}
|
||||
#[doc = "Checks if the value of the field is `GENERATED`"]
|
||||
#[inline(always)]
|
||||
pub fn is_generated(&self) -> bool {
|
||||
*self == EVENTS_KEYSLOT_REVOKED_A::GENERATED
|
||||
}
|
||||
}
|
||||
#[doc = "Field `EVENTS_KEYSLOT_REVOKED` writer - Key slot has been revoked and cannot be tasked for selection"]
|
||||
pub type EVENTS_KEYSLOT_REVOKED_W<'a, const O: u8> =
|
||||
crate::BitWriter<'a, u32, EVENTS_KEYSLOT_REVOKED_SPEC, EVENTS_KEYSLOT_REVOKED_A, O>;
|
||||
impl<'a, const O: u8> EVENTS_KEYSLOT_REVOKED_W<'a, O> {
|
||||
#[doc = "Event not generated"]
|
||||
#[inline(always)]
|
||||
pub fn not_generated(self) -> &'a mut W {
|
||||
self.variant(EVENTS_KEYSLOT_REVOKED_A::NOT_GENERATED)
|
||||
}
|
||||
#[doc = "Event generated"]
|
||||
#[inline(always)]
|
||||
pub fn generated(self) -> &'a mut W {
|
||||
self.variant(EVENTS_KEYSLOT_REVOKED_A::GENERATED)
|
||||
}
|
||||
}
|
||||
impl R {
|
||||
#[doc = "Bit 0 - Key slot has been revoked and cannot be tasked for selection"]
|
||||
#[inline(always)]
|
||||
pub fn events_keyslot_revoked(&self) -> EVENTS_KEYSLOT_REVOKED_R {
|
||||
EVENTS_KEYSLOT_REVOKED_R::new((self.bits & 1) != 0)
|
||||
}
|
||||
}
|
||||
impl W {
|
||||
#[doc = "Bit 0 - Key slot has been revoked and cannot be tasked for selection"]
|
||||
#[inline(always)]
|
||||
pub fn events_keyslot_revoked(&mut self) -> EVENTS_KEYSLOT_REVOKED_W<0> {
|
||||
EVENTS_KEYSLOT_REVOKED_W::new(self)
|
||||
}
|
||||
#[doc = "Writes raw bits to the register."]
|
||||
#[inline(always)]
|
||||
pub unsafe fn bits(&mut self, bits: u32) -> &mut Self {
|
||||
self.0.bits(bits);
|
||||
self
|
||||
}
|
||||
}
|
||||
#[doc = "Key slot has been revoked and cannot be tasked for selection\n\nThis register you can [`read`](crate::generic::Reg::read), [`write_with_zero`](crate::generic::Reg::write_with_zero), [`reset`](crate::generic::Reg::reset), [`write`](crate::generic::Reg::write), [`modify`](crate::generic::Reg::modify). See [API](https://docs.rs/svd2rust/#read--modify--write-api).\n\nFor information about available fields see [events_keyslot_revoked](index.html) module"]
|
||||
pub struct EVENTS_KEYSLOT_REVOKED_SPEC;
|
||||
impl crate::RegisterSpec for EVENTS_KEYSLOT_REVOKED_SPEC {
|
||||
type Ux = u32;
|
||||
}
|
||||
#[doc = "`read()` method returns [events_keyslot_revoked::R](R) reader structure"]
|
||||
impl crate::Readable for EVENTS_KEYSLOT_REVOKED_SPEC {
|
||||
type Reader = R;
|
||||
}
|
||||
#[doc = "`write(|w| ..)` method takes [events_keyslot_revoked::W](W) writer structure"]
|
||||
impl crate::Writable for EVENTS_KEYSLOT_REVOKED_SPEC {
|
||||
type Writer = W;
|
||||
}
|
||||
#[doc = "`reset()` method sets EVENTS_KEYSLOT_REVOKED to value 0"]
|
||||
impl crate::Resettable for EVENTS_KEYSLOT_REVOKED_SPEC {
|
||||
#[inline(always)]
|
||||
fn reset_value() -> Self::Ux {
|
||||
0
|
||||
}
|
||||
}
|
||||
+249
@@ -0,0 +1,249 @@
|
||||
#[doc = "Register `INTEN` reader"]
|
||||
pub struct R(crate::R<INTEN_SPEC>);
|
||||
impl core::ops::Deref for R {
|
||||
type Target = crate::R<INTEN_SPEC>;
|
||||
#[inline(always)]
|
||||
fn deref(&self) -> &Self::Target {
|
||||
&self.0
|
||||
}
|
||||
}
|
||||
impl From<crate::R<INTEN_SPEC>> for R {
|
||||
#[inline(always)]
|
||||
fn from(reader: crate::R<INTEN_SPEC>) -> Self {
|
||||
R(reader)
|
||||
}
|
||||
}
|
||||
#[doc = "Register `INTEN` writer"]
|
||||
pub struct W(crate::W<INTEN_SPEC>);
|
||||
impl core::ops::Deref for W {
|
||||
type Target = crate::W<INTEN_SPEC>;
|
||||
#[inline(always)]
|
||||
fn deref(&self) -> &Self::Target {
|
||||
&self.0
|
||||
}
|
||||
}
|
||||
impl core::ops::DerefMut for W {
|
||||
#[inline(always)]
|
||||
fn deref_mut(&mut self) -> &mut Self::Target {
|
||||
&mut self.0
|
||||
}
|
||||
}
|
||||
impl From<crate::W<INTEN_SPEC>> for W {
|
||||
#[inline(always)]
|
||||
fn from(writer: crate::W<INTEN_SPEC>) -> Self {
|
||||
W(writer)
|
||||
}
|
||||
}
|
||||
#[doc = "Field `KEYSLOT_PUSHED` reader - Enable or disable interrupt for event KEYSLOT_PUSHED"]
|
||||
pub type KEYSLOT_PUSHED_R = crate::BitReader<KEYSLOT_PUSHED_A>;
|
||||
#[doc = "Enable or disable interrupt for event KEYSLOT_PUSHED\n\nValue on reset: 0"]
|
||||
#[derive(Clone, Copy, Debug, PartialEq)]
|
||||
pub enum KEYSLOT_PUSHED_A {
|
||||
#[doc = "0: Disable"]
|
||||
DISABLED = 0,
|
||||
#[doc = "1: Enable"]
|
||||
ENABLED = 1,
|
||||
}
|
||||
impl From<KEYSLOT_PUSHED_A> for bool {
|
||||
#[inline(always)]
|
||||
fn from(variant: KEYSLOT_PUSHED_A) -> Self {
|
||||
variant as u8 != 0
|
||||
}
|
||||
}
|
||||
impl KEYSLOT_PUSHED_R {
|
||||
#[doc = "Get enumerated values variant"]
|
||||
#[inline(always)]
|
||||
pub fn variant(&self) -> KEYSLOT_PUSHED_A {
|
||||
match self.bits {
|
||||
false => KEYSLOT_PUSHED_A::DISABLED,
|
||||
true => KEYSLOT_PUSHED_A::ENABLED,
|
||||
}
|
||||
}
|
||||
#[doc = "Checks if the value of the field is `DISABLED`"]
|
||||
#[inline(always)]
|
||||
pub fn is_disabled(&self) -> bool {
|
||||
*self == KEYSLOT_PUSHED_A::DISABLED
|
||||
}
|
||||
#[doc = "Checks if the value of the field is `ENABLED`"]
|
||||
#[inline(always)]
|
||||
pub fn is_enabled(&self) -> bool {
|
||||
*self == KEYSLOT_PUSHED_A::ENABLED
|
||||
}
|
||||
}
|
||||
#[doc = "Field `KEYSLOT_PUSHED` writer - Enable or disable interrupt for event KEYSLOT_PUSHED"]
|
||||
pub type KEYSLOT_PUSHED_W<'a, const O: u8> =
|
||||
crate::BitWriter<'a, u32, INTEN_SPEC, KEYSLOT_PUSHED_A, O>;
|
||||
impl<'a, const O: u8> KEYSLOT_PUSHED_W<'a, O> {
|
||||
#[doc = "Disable"]
|
||||
#[inline(always)]
|
||||
pub fn disabled(self) -> &'a mut W {
|
||||
self.variant(KEYSLOT_PUSHED_A::DISABLED)
|
||||
}
|
||||
#[doc = "Enable"]
|
||||
#[inline(always)]
|
||||
pub fn enabled(self) -> &'a mut W {
|
||||
self.variant(KEYSLOT_PUSHED_A::ENABLED)
|
||||
}
|
||||
}
|
||||
#[doc = "Field `KEYSLOT_REVOKED` reader - Enable or disable interrupt for event KEYSLOT_REVOKED"]
|
||||
pub type KEYSLOT_REVOKED_R = crate::BitReader<KEYSLOT_REVOKED_A>;
|
||||
#[doc = "Enable or disable interrupt for event KEYSLOT_REVOKED\n\nValue on reset: 0"]
|
||||
#[derive(Clone, Copy, Debug, PartialEq)]
|
||||
pub enum KEYSLOT_REVOKED_A {
|
||||
#[doc = "0: Disable"]
|
||||
DISABLED = 0,
|
||||
#[doc = "1: Enable"]
|
||||
ENABLED = 1,
|
||||
}
|
||||
impl From<KEYSLOT_REVOKED_A> for bool {
|
||||
#[inline(always)]
|
||||
fn from(variant: KEYSLOT_REVOKED_A) -> Self {
|
||||
variant as u8 != 0
|
||||
}
|
||||
}
|
||||
impl KEYSLOT_REVOKED_R {
|
||||
#[doc = "Get enumerated values variant"]
|
||||
#[inline(always)]
|
||||
pub fn variant(&self) -> KEYSLOT_REVOKED_A {
|
||||
match self.bits {
|
||||
false => KEYSLOT_REVOKED_A::DISABLED,
|
||||
true => KEYSLOT_REVOKED_A::ENABLED,
|
||||
}
|
||||
}
|
||||
#[doc = "Checks if the value of the field is `DISABLED`"]
|
||||
#[inline(always)]
|
||||
pub fn is_disabled(&self) -> bool {
|
||||
*self == KEYSLOT_REVOKED_A::DISABLED
|
||||
}
|
||||
#[doc = "Checks if the value of the field is `ENABLED`"]
|
||||
#[inline(always)]
|
||||
pub fn is_enabled(&self) -> bool {
|
||||
*self == KEYSLOT_REVOKED_A::ENABLED
|
||||
}
|
||||
}
|
||||
#[doc = "Field `KEYSLOT_REVOKED` writer - Enable or disable interrupt for event KEYSLOT_REVOKED"]
|
||||
pub type KEYSLOT_REVOKED_W<'a, const O: u8> =
|
||||
crate::BitWriter<'a, u32, INTEN_SPEC, KEYSLOT_REVOKED_A, O>;
|
||||
impl<'a, const O: u8> KEYSLOT_REVOKED_W<'a, O> {
|
||||
#[doc = "Disable"]
|
||||
#[inline(always)]
|
||||
pub fn disabled(self) -> &'a mut W {
|
||||
self.variant(KEYSLOT_REVOKED_A::DISABLED)
|
||||
}
|
||||
#[doc = "Enable"]
|
||||
#[inline(always)]
|
||||
pub fn enabled(self) -> &'a mut W {
|
||||
self.variant(KEYSLOT_REVOKED_A::ENABLED)
|
||||
}
|
||||
}
|
||||
#[doc = "Field `KEYSLOT_ERROR` reader - Enable or disable interrupt for event KEYSLOT_ERROR"]
|
||||
pub type KEYSLOT_ERROR_R = crate::BitReader<KEYSLOT_ERROR_A>;
|
||||
#[doc = "Enable or disable interrupt for event KEYSLOT_ERROR\n\nValue on reset: 0"]
|
||||
#[derive(Clone, Copy, Debug, PartialEq)]
|
||||
pub enum KEYSLOT_ERROR_A {
|
||||
#[doc = "0: Disable"]
|
||||
DISABLED = 0,
|
||||
#[doc = "1: Enable"]
|
||||
ENABLED = 1,
|
||||
}
|
||||
impl From<KEYSLOT_ERROR_A> for bool {
|
||||
#[inline(always)]
|
||||
fn from(variant: KEYSLOT_ERROR_A) -> Self {
|
||||
variant as u8 != 0
|
||||
}
|
||||
}
|
||||
impl KEYSLOT_ERROR_R {
|
||||
#[doc = "Get enumerated values variant"]
|
||||
#[inline(always)]
|
||||
pub fn variant(&self) -> KEYSLOT_ERROR_A {
|
||||
match self.bits {
|
||||
false => KEYSLOT_ERROR_A::DISABLED,
|
||||
true => KEYSLOT_ERROR_A::ENABLED,
|
||||
}
|
||||
}
|
||||
#[doc = "Checks if the value of the field is `DISABLED`"]
|
||||
#[inline(always)]
|
||||
pub fn is_disabled(&self) -> bool {
|
||||
*self == KEYSLOT_ERROR_A::DISABLED
|
||||
}
|
||||
#[doc = "Checks if the value of the field is `ENABLED`"]
|
||||
#[inline(always)]
|
||||
pub fn is_enabled(&self) -> bool {
|
||||
*self == KEYSLOT_ERROR_A::ENABLED
|
||||
}
|
||||
}
|
||||
#[doc = "Field `KEYSLOT_ERROR` writer - Enable or disable interrupt for event KEYSLOT_ERROR"]
|
||||
pub type KEYSLOT_ERROR_W<'a, const O: u8> =
|
||||
crate::BitWriter<'a, u32, INTEN_SPEC, KEYSLOT_ERROR_A, O>;
|
||||
impl<'a, const O: u8> KEYSLOT_ERROR_W<'a, O> {
|
||||
#[doc = "Disable"]
|
||||
#[inline(always)]
|
||||
pub fn disabled(self) -> &'a mut W {
|
||||
self.variant(KEYSLOT_ERROR_A::DISABLED)
|
||||
}
|
||||
#[doc = "Enable"]
|
||||
#[inline(always)]
|
||||
pub fn enabled(self) -> &'a mut W {
|
||||
self.variant(KEYSLOT_ERROR_A::ENABLED)
|
||||
}
|
||||
}
|
||||
impl R {
|
||||
#[doc = "Bit 0 - Enable or disable interrupt for event KEYSLOT_PUSHED"]
|
||||
#[inline(always)]
|
||||
pub fn keyslot_pushed(&self) -> KEYSLOT_PUSHED_R {
|
||||
KEYSLOT_PUSHED_R::new((self.bits & 1) != 0)
|
||||
}
|
||||
#[doc = "Bit 1 - Enable or disable interrupt for event KEYSLOT_REVOKED"]
|
||||
#[inline(always)]
|
||||
pub fn keyslot_revoked(&self) -> KEYSLOT_REVOKED_R {
|
||||
KEYSLOT_REVOKED_R::new(((self.bits >> 1) & 1) != 0)
|
||||
}
|
||||
#[doc = "Bit 2 - Enable or disable interrupt for event KEYSLOT_ERROR"]
|
||||
#[inline(always)]
|
||||
pub fn keyslot_error(&self) -> KEYSLOT_ERROR_R {
|
||||
KEYSLOT_ERROR_R::new(((self.bits >> 2) & 1) != 0)
|
||||
}
|
||||
}
|
||||
impl W {
|
||||
#[doc = "Bit 0 - Enable or disable interrupt for event KEYSLOT_PUSHED"]
|
||||
#[inline(always)]
|
||||
pub fn keyslot_pushed(&mut self) -> KEYSLOT_PUSHED_W<0> {
|
||||
KEYSLOT_PUSHED_W::new(self)
|
||||
}
|
||||
#[doc = "Bit 1 - Enable or disable interrupt for event KEYSLOT_REVOKED"]
|
||||
#[inline(always)]
|
||||
pub fn keyslot_revoked(&mut self) -> KEYSLOT_REVOKED_W<1> {
|
||||
KEYSLOT_REVOKED_W::new(self)
|
||||
}
|
||||
#[doc = "Bit 2 - Enable or disable interrupt for event KEYSLOT_ERROR"]
|
||||
#[inline(always)]
|
||||
pub fn keyslot_error(&mut self) -> KEYSLOT_ERROR_W<2> {
|
||||
KEYSLOT_ERROR_W::new(self)
|
||||
}
|
||||
#[doc = "Writes raw bits to the register."]
|
||||
#[inline(always)]
|
||||
pub unsafe fn bits(&mut self, bits: u32) -> &mut Self {
|
||||
self.0.bits(bits);
|
||||
self
|
||||
}
|
||||
}
|
||||
#[doc = "Enable or disable interrupt\n\nThis register you can [`read`](crate::generic::Reg::read), [`write_with_zero`](crate::generic::Reg::write_with_zero), [`reset`](crate::generic::Reg::reset), [`write`](crate::generic::Reg::write), [`modify`](crate::generic::Reg::modify). See [API](https://docs.rs/svd2rust/#read--modify--write-api).\n\nFor information about available fields see [inten](index.html) module"]
|
||||
pub struct INTEN_SPEC;
|
||||
impl crate::RegisterSpec for INTEN_SPEC {
|
||||
type Ux = u32;
|
||||
}
|
||||
#[doc = "`read()` method returns [inten::R](R) reader structure"]
|
||||
impl crate::Readable for INTEN_SPEC {
|
||||
type Reader = R;
|
||||
}
|
||||
#[doc = "`write(|w| ..)` method takes [inten::W](W) writer structure"]
|
||||
impl crate::Writable for INTEN_SPEC {
|
||||
type Writer = W;
|
||||
}
|
||||
#[doc = "`reset()` method sets INTEN to value 0"]
|
||||
impl crate::Resettable for INTEN_SPEC {
|
||||
#[inline(always)]
|
||||
fn reset_value() -> Self::Ux {
|
||||
0
|
||||
}
|
||||
}
|
||||
+270
@@ -0,0 +1,270 @@
|
||||
#[doc = "Register `INTENCLR` reader"]
|
||||
pub struct R(crate::R<INTENCLR_SPEC>);
|
||||
impl core::ops::Deref for R {
|
||||
type Target = crate::R<INTENCLR_SPEC>;
|
||||
#[inline(always)]
|
||||
fn deref(&self) -> &Self::Target {
|
||||
&self.0
|
||||
}
|
||||
}
|
||||
impl From<crate::R<INTENCLR_SPEC>> for R {
|
||||
#[inline(always)]
|
||||
fn from(reader: crate::R<INTENCLR_SPEC>) -> Self {
|
||||
R(reader)
|
||||
}
|
||||
}
|
||||
#[doc = "Register `INTENCLR` writer"]
|
||||
pub struct W(crate::W<INTENCLR_SPEC>);
|
||||
impl core::ops::Deref for W {
|
||||
type Target = crate::W<INTENCLR_SPEC>;
|
||||
#[inline(always)]
|
||||
fn deref(&self) -> &Self::Target {
|
||||
&self.0
|
||||
}
|
||||
}
|
||||
impl core::ops::DerefMut for W {
|
||||
#[inline(always)]
|
||||
fn deref_mut(&mut self) -> &mut Self::Target {
|
||||
&mut self.0
|
||||
}
|
||||
}
|
||||
impl From<crate::W<INTENCLR_SPEC>> for W {
|
||||
#[inline(always)]
|
||||
fn from(writer: crate::W<INTENCLR_SPEC>) -> Self {
|
||||
W(writer)
|
||||
}
|
||||
}
|
||||
#[doc = "Field `KEYSLOT_PUSHED` reader - Write '1' to disable interrupt for event KEYSLOT_PUSHED"]
|
||||
pub type KEYSLOT_PUSHED_R = crate::BitReader<KEYSLOT_PUSHED_A>;
|
||||
#[doc = "Write '1' to disable interrupt for event KEYSLOT_PUSHED\n\nValue on reset: 0"]
|
||||
#[derive(Clone, Copy, Debug, PartialEq)]
|
||||
pub enum KEYSLOT_PUSHED_A {
|
||||
#[doc = "0: Read: Disabled"]
|
||||
DISABLED = 0,
|
||||
#[doc = "1: Read: Enabled"]
|
||||
ENABLED = 1,
|
||||
}
|
||||
impl From<KEYSLOT_PUSHED_A> for bool {
|
||||
#[inline(always)]
|
||||
fn from(variant: KEYSLOT_PUSHED_A) -> Self {
|
||||
variant as u8 != 0
|
||||
}
|
||||
}
|
||||
impl KEYSLOT_PUSHED_R {
|
||||
#[doc = "Get enumerated values variant"]
|
||||
#[inline(always)]
|
||||
pub fn variant(&self) -> KEYSLOT_PUSHED_A {
|
||||
match self.bits {
|
||||
false => KEYSLOT_PUSHED_A::DISABLED,
|
||||
true => KEYSLOT_PUSHED_A::ENABLED,
|
||||
}
|
||||
}
|
||||
#[doc = "Checks if the value of the field is `DISABLED`"]
|
||||
#[inline(always)]
|
||||
pub fn is_disabled(&self) -> bool {
|
||||
*self == KEYSLOT_PUSHED_A::DISABLED
|
||||
}
|
||||
#[doc = "Checks if the value of the field is `ENABLED`"]
|
||||
#[inline(always)]
|
||||
pub fn is_enabled(&self) -> bool {
|
||||
*self == KEYSLOT_PUSHED_A::ENABLED
|
||||
}
|
||||
}
|
||||
#[doc = "Write '1' to disable interrupt for event KEYSLOT_PUSHED\n\nValue on reset: 0"]
|
||||
#[derive(Clone, Copy, Debug, PartialEq)]
|
||||
pub enum KEYSLOT_PUSHED_AW {
|
||||
#[doc = "1: Disable"]
|
||||
CLEAR = 1,
|
||||
}
|
||||
impl From<KEYSLOT_PUSHED_AW> for bool {
|
||||
#[inline(always)]
|
||||
fn from(variant: KEYSLOT_PUSHED_AW) -> Self {
|
||||
variant as u8 != 0
|
||||
}
|
||||
}
|
||||
#[doc = "Field `KEYSLOT_PUSHED` writer - Write '1' to disable interrupt for event KEYSLOT_PUSHED"]
|
||||
pub type KEYSLOT_PUSHED_W<'a, const O: u8> =
|
||||
crate::BitWriter<'a, u32, INTENCLR_SPEC, KEYSLOT_PUSHED_AW, O>;
|
||||
impl<'a, const O: u8> KEYSLOT_PUSHED_W<'a, O> {
|
||||
#[doc = "Disable"]
|
||||
#[inline(always)]
|
||||
pub fn clear(self) -> &'a mut W {
|
||||
self.variant(KEYSLOT_PUSHED_AW::CLEAR)
|
||||
}
|
||||
}
|
||||
#[doc = "Field `KEYSLOT_REVOKED` reader - Write '1' to disable interrupt for event KEYSLOT_REVOKED"]
|
||||
pub type KEYSLOT_REVOKED_R = crate::BitReader<KEYSLOT_REVOKED_A>;
|
||||
#[doc = "Write '1' to disable interrupt for event KEYSLOT_REVOKED\n\nValue on reset: 0"]
|
||||
#[derive(Clone, Copy, Debug, PartialEq)]
|
||||
pub enum KEYSLOT_REVOKED_A {
|
||||
#[doc = "0: Read: Disabled"]
|
||||
DISABLED = 0,
|
||||
#[doc = "1: Read: Enabled"]
|
||||
ENABLED = 1,
|
||||
}
|
||||
impl From<KEYSLOT_REVOKED_A> for bool {
|
||||
#[inline(always)]
|
||||
fn from(variant: KEYSLOT_REVOKED_A) -> Self {
|
||||
variant as u8 != 0
|
||||
}
|
||||
}
|
||||
impl KEYSLOT_REVOKED_R {
|
||||
#[doc = "Get enumerated values variant"]
|
||||
#[inline(always)]
|
||||
pub fn variant(&self) -> KEYSLOT_REVOKED_A {
|
||||
match self.bits {
|
||||
false => KEYSLOT_REVOKED_A::DISABLED,
|
||||
true => KEYSLOT_REVOKED_A::ENABLED,
|
||||
}
|
||||
}
|
||||
#[doc = "Checks if the value of the field is `DISABLED`"]
|
||||
#[inline(always)]
|
||||
pub fn is_disabled(&self) -> bool {
|
||||
*self == KEYSLOT_REVOKED_A::DISABLED
|
||||
}
|
||||
#[doc = "Checks if the value of the field is `ENABLED`"]
|
||||
#[inline(always)]
|
||||
pub fn is_enabled(&self) -> bool {
|
||||
*self == KEYSLOT_REVOKED_A::ENABLED
|
||||
}
|
||||
}
|
||||
#[doc = "Write '1' to disable interrupt for event KEYSLOT_REVOKED\n\nValue on reset: 0"]
|
||||
#[derive(Clone, Copy, Debug, PartialEq)]
|
||||
pub enum KEYSLOT_REVOKED_AW {
|
||||
#[doc = "1: Disable"]
|
||||
CLEAR = 1,
|
||||
}
|
||||
impl From<KEYSLOT_REVOKED_AW> for bool {
|
||||
#[inline(always)]
|
||||
fn from(variant: KEYSLOT_REVOKED_AW) -> Self {
|
||||
variant as u8 != 0
|
||||
}
|
||||
}
|
||||
#[doc = "Field `KEYSLOT_REVOKED` writer - Write '1' to disable interrupt for event KEYSLOT_REVOKED"]
|
||||
pub type KEYSLOT_REVOKED_W<'a, const O: u8> =
|
||||
crate::BitWriter<'a, u32, INTENCLR_SPEC, KEYSLOT_REVOKED_AW, O>;
|
||||
impl<'a, const O: u8> KEYSLOT_REVOKED_W<'a, O> {
|
||||
#[doc = "Disable"]
|
||||
#[inline(always)]
|
||||
pub fn clear(self) -> &'a mut W {
|
||||
self.variant(KEYSLOT_REVOKED_AW::CLEAR)
|
||||
}
|
||||
}
|
||||
#[doc = "Field `KEYSLOT_ERROR` reader - Write '1' to disable interrupt for event KEYSLOT_ERROR"]
|
||||
pub type KEYSLOT_ERROR_R = crate::BitReader<KEYSLOT_ERROR_A>;
|
||||
#[doc = "Write '1' to disable interrupt for event KEYSLOT_ERROR\n\nValue on reset: 0"]
|
||||
#[derive(Clone, Copy, Debug, PartialEq)]
|
||||
pub enum KEYSLOT_ERROR_A {
|
||||
#[doc = "0: Read: Disabled"]
|
||||
DISABLED = 0,
|
||||
#[doc = "1: Read: Enabled"]
|
||||
ENABLED = 1,
|
||||
}
|
||||
impl From<KEYSLOT_ERROR_A> for bool {
|
||||
#[inline(always)]
|
||||
fn from(variant: KEYSLOT_ERROR_A) -> Self {
|
||||
variant as u8 != 0
|
||||
}
|
||||
}
|
||||
impl KEYSLOT_ERROR_R {
|
||||
#[doc = "Get enumerated values variant"]
|
||||
#[inline(always)]
|
||||
pub fn variant(&self) -> KEYSLOT_ERROR_A {
|
||||
match self.bits {
|
||||
false => KEYSLOT_ERROR_A::DISABLED,
|
||||
true => KEYSLOT_ERROR_A::ENABLED,
|
||||
}
|
||||
}
|
||||
#[doc = "Checks if the value of the field is `DISABLED`"]
|
||||
#[inline(always)]
|
||||
pub fn is_disabled(&self) -> bool {
|
||||
*self == KEYSLOT_ERROR_A::DISABLED
|
||||
}
|
||||
#[doc = "Checks if the value of the field is `ENABLED`"]
|
||||
#[inline(always)]
|
||||
pub fn is_enabled(&self) -> bool {
|
||||
*self == KEYSLOT_ERROR_A::ENABLED
|
||||
}
|
||||
}
|
||||
#[doc = "Write '1' to disable interrupt for event KEYSLOT_ERROR\n\nValue on reset: 0"]
|
||||
#[derive(Clone, Copy, Debug, PartialEq)]
|
||||
pub enum KEYSLOT_ERROR_AW {
|
||||
#[doc = "1: Disable"]
|
||||
CLEAR = 1,
|
||||
}
|
||||
impl From<KEYSLOT_ERROR_AW> for bool {
|
||||
#[inline(always)]
|
||||
fn from(variant: KEYSLOT_ERROR_AW) -> Self {
|
||||
variant as u8 != 0
|
||||
}
|
||||
}
|
||||
#[doc = "Field `KEYSLOT_ERROR` writer - Write '1' to disable interrupt for event KEYSLOT_ERROR"]
|
||||
pub type KEYSLOT_ERROR_W<'a, const O: u8> =
|
||||
crate::BitWriter<'a, u32, INTENCLR_SPEC, KEYSLOT_ERROR_AW, O>;
|
||||
impl<'a, const O: u8> KEYSLOT_ERROR_W<'a, O> {
|
||||
#[doc = "Disable"]
|
||||
#[inline(always)]
|
||||
pub fn clear(self) -> &'a mut W {
|
||||
self.variant(KEYSLOT_ERROR_AW::CLEAR)
|
||||
}
|
||||
}
|
||||
impl R {
|
||||
#[doc = "Bit 0 - Write '1' to disable interrupt for event KEYSLOT_PUSHED"]
|
||||
#[inline(always)]
|
||||
pub fn keyslot_pushed(&self) -> KEYSLOT_PUSHED_R {
|
||||
KEYSLOT_PUSHED_R::new((self.bits & 1) != 0)
|
||||
}
|
||||
#[doc = "Bit 1 - Write '1' to disable interrupt for event KEYSLOT_REVOKED"]
|
||||
#[inline(always)]
|
||||
pub fn keyslot_revoked(&self) -> KEYSLOT_REVOKED_R {
|
||||
KEYSLOT_REVOKED_R::new(((self.bits >> 1) & 1) != 0)
|
||||
}
|
||||
#[doc = "Bit 2 - Write '1' to disable interrupt for event KEYSLOT_ERROR"]
|
||||
#[inline(always)]
|
||||
pub fn keyslot_error(&self) -> KEYSLOT_ERROR_R {
|
||||
KEYSLOT_ERROR_R::new(((self.bits >> 2) & 1) != 0)
|
||||
}
|
||||
}
|
||||
impl W {
|
||||
#[doc = "Bit 0 - Write '1' to disable interrupt for event KEYSLOT_PUSHED"]
|
||||
#[inline(always)]
|
||||
pub fn keyslot_pushed(&mut self) -> KEYSLOT_PUSHED_W<0> {
|
||||
KEYSLOT_PUSHED_W::new(self)
|
||||
}
|
||||
#[doc = "Bit 1 - Write '1' to disable interrupt for event KEYSLOT_REVOKED"]
|
||||
#[inline(always)]
|
||||
pub fn keyslot_revoked(&mut self) -> KEYSLOT_REVOKED_W<1> {
|
||||
KEYSLOT_REVOKED_W::new(self)
|
||||
}
|
||||
#[doc = "Bit 2 - Write '1' to disable interrupt for event KEYSLOT_ERROR"]
|
||||
#[inline(always)]
|
||||
pub fn keyslot_error(&mut self) -> KEYSLOT_ERROR_W<2> {
|
||||
KEYSLOT_ERROR_W::new(self)
|
||||
}
|
||||
#[doc = "Writes raw bits to the register."]
|
||||
#[inline(always)]
|
||||
pub unsafe fn bits(&mut self, bits: u32) -> &mut Self {
|
||||
self.0.bits(bits);
|
||||
self
|
||||
}
|
||||
}
|
||||
#[doc = "Disable interrupt\n\nThis register you can [`read`](crate::generic::Reg::read), [`write_with_zero`](crate::generic::Reg::write_with_zero), [`reset`](crate::generic::Reg::reset), [`write`](crate::generic::Reg::write), [`modify`](crate::generic::Reg::modify). See [API](https://docs.rs/svd2rust/#read--modify--write-api).\n\nFor information about available fields see [intenclr](index.html) module"]
|
||||
pub struct INTENCLR_SPEC;
|
||||
impl crate::RegisterSpec for INTENCLR_SPEC {
|
||||
type Ux = u32;
|
||||
}
|
||||
#[doc = "`read()` method returns [intenclr::R](R) reader structure"]
|
||||
impl crate::Readable for INTENCLR_SPEC {
|
||||
type Reader = R;
|
||||
}
|
||||
#[doc = "`write(|w| ..)` method takes [intenclr::W](W) writer structure"]
|
||||
impl crate::Writable for INTENCLR_SPEC {
|
||||
type Writer = W;
|
||||
}
|
||||
#[doc = "`reset()` method sets INTENCLR to value 0"]
|
||||
impl crate::Resettable for INTENCLR_SPEC {
|
||||
#[inline(always)]
|
||||
fn reset_value() -> Self::Ux {
|
||||
0
|
||||
}
|
||||
}
|
||||
+270
@@ -0,0 +1,270 @@
|
||||
#[doc = "Register `INTENSET` reader"]
|
||||
pub struct R(crate::R<INTENSET_SPEC>);
|
||||
impl core::ops::Deref for R {
|
||||
type Target = crate::R<INTENSET_SPEC>;
|
||||
#[inline(always)]
|
||||
fn deref(&self) -> &Self::Target {
|
||||
&self.0
|
||||
}
|
||||
}
|
||||
impl From<crate::R<INTENSET_SPEC>> for R {
|
||||
#[inline(always)]
|
||||
fn from(reader: crate::R<INTENSET_SPEC>) -> Self {
|
||||
R(reader)
|
||||
}
|
||||
}
|
||||
#[doc = "Register `INTENSET` writer"]
|
||||
pub struct W(crate::W<INTENSET_SPEC>);
|
||||
impl core::ops::Deref for W {
|
||||
type Target = crate::W<INTENSET_SPEC>;
|
||||
#[inline(always)]
|
||||
fn deref(&self) -> &Self::Target {
|
||||
&self.0
|
||||
}
|
||||
}
|
||||
impl core::ops::DerefMut for W {
|
||||
#[inline(always)]
|
||||
fn deref_mut(&mut self) -> &mut Self::Target {
|
||||
&mut self.0
|
||||
}
|
||||
}
|
||||
impl From<crate::W<INTENSET_SPEC>> for W {
|
||||
#[inline(always)]
|
||||
fn from(writer: crate::W<INTENSET_SPEC>) -> Self {
|
||||
W(writer)
|
||||
}
|
||||
}
|
||||
#[doc = "Field `KEYSLOT_PUSHED` reader - Write '1' to enable interrupt for event KEYSLOT_PUSHED"]
|
||||
pub type KEYSLOT_PUSHED_R = crate::BitReader<KEYSLOT_PUSHED_A>;
|
||||
#[doc = "Write '1' to enable interrupt for event KEYSLOT_PUSHED\n\nValue on reset: 0"]
|
||||
#[derive(Clone, Copy, Debug, PartialEq)]
|
||||
pub enum KEYSLOT_PUSHED_A {
|
||||
#[doc = "0: Read: Disabled"]
|
||||
DISABLED = 0,
|
||||
#[doc = "1: Read: Enabled"]
|
||||
ENABLED = 1,
|
||||
}
|
||||
impl From<KEYSLOT_PUSHED_A> for bool {
|
||||
#[inline(always)]
|
||||
fn from(variant: KEYSLOT_PUSHED_A) -> Self {
|
||||
variant as u8 != 0
|
||||
}
|
||||
}
|
||||
impl KEYSLOT_PUSHED_R {
|
||||
#[doc = "Get enumerated values variant"]
|
||||
#[inline(always)]
|
||||
pub fn variant(&self) -> KEYSLOT_PUSHED_A {
|
||||
match self.bits {
|
||||
false => KEYSLOT_PUSHED_A::DISABLED,
|
||||
true => KEYSLOT_PUSHED_A::ENABLED,
|
||||
}
|
||||
}
|
||||
#[doc = "Checks if the value of the field is `DISABLED`"]
|
||||
#[inline(always)]
|
||||
pub fn is_disabled(&self) -> bool {
|
||||
*self == KEYSLOT_PUSHED_A::DISABLED
|
||||
}
|
||||
#[doc = "Checks if the value of the field is `ENABLED`"]
|
||||
#[inline(always)]
|
||||
pub fn is_enabled(&self) -> bool {
|
||||
*self == KEYSLOT_PUSHED_A::ENABLED
|
||||
}
|
||||
}
|
||||
#[doc = "Write '1' to enable interrupt for event KEYSLOT_PUSHED\n\nValue on reset: 0"]
|
||||
#[derive(Clone, Copy, Debug, PartialEq)]
|
||||
pub enum KEYSLOT_PUSHED_AW {
|
||||
#[doc = "1: Enable"]
|
||||
SET = 1,
|
||||
}
|
||||
impl From<KEYSLOT_PUSHED_AW> for bool {
|
||||
#[inline(always)]
|
||||
fn from(variant: KEYSLOT_PUSHED_AW) -> Self {
|
||||
variant as u8 != 0
|
||||
}
|
||||
}
|
||||
#[doc = "Field `KEYSLOT_PUSHED` writer - Write '1' to enable interrupt for event KEYSLOT_PUSHED"]
|
||||
pub type KEYSLOT_PUSHED_W<'a, const O: u8> =
|
||||
crate::BitWriter<'a, u32, INTENSET_SPEC, KEYSLOT_PUSHED_AW, O>;
|
||||
impl<'a, const O: u8> KEYSLOT_PUSHED_W<'a, O> {
|
||||
#[doc = "Enable"]
|
||||
#[inline(always)]
|
||||
pub fn set(self) -> &'a mut W {
|
||||
self.variant(KEYSLOT_PUSHED_AW::SET)
|
||||
}
|
||||
}
|
||||
#[doc = "Field `KEYSLOT_REVOKED` reader - Write '1' to enable interrupt for event KEYSLOT_REVOKED"]
|
||||
pub type KEYSLOT_REVOKED_R = crate::BitReader<KEYSLOT_REVOKED_A>;
|
||||
#[doc = "Write '1' to enable interrupt for event KEYSLOT_REVOKED\n\nValue on reset: 0"]
|
||||
#[derive(Clone, Copy, Debug, PartialEq)]
|
||||
pub enum KEYSLOT_REVOKED_A {
|
||||
#[doc = "0: Read: Disabled"]
|
||||
DISABLED = 0,
|
||||
#[doc = "1: Read: Enabled"]
|
||||
ENABLED = 1,
|
||||
}
|
||||
impl From<KEYSLOT_REVOKED_A> for bool {
|
||||
#[inline(always)]
|
||||
fn from(variant: KEYSLOT_REVOKED_A) -> Self {
|
||||
variant as u8 != 0
|
||||
}
|
||||
}
|
||||
impl KEYSLOT_REVOKED_R {
|
||||
#[doc = "Get enumerated values variant"]
|
||||
#[inline(always)]
|
||||
pub fn variant(&self) -> KEYSLOT_REVOKED_A {
|
||||
match self.bits {
|
||||
false => KEYSLOT_REVOKED_A::DISABLED,
|
||||
true => KEYSLOT_REVOKED_A::ENABLED,
|
||||
}
|
||||
}
|
||||
#[doc = "Checks if the value of the field is `DISABLED`"]
|
||||
#[inline(always)]
|
||||
pub fn is_disabled(&self) -> bool {
|
||||
*self == KEYSLOT_REVOKED_A::DISABLED
|
||||
}
|
||||
#[doc = "Checks if the value of the field is `ENABLED`"]
|
||||
#[inline(always)]
|
||||
pub fn is_enabled(&self) -> bool {
|
||||
*self == KEYSLOT_REVOKED_A::ENABLED
|
||||
}
|
||||
}
|
||||
#[doc = "Write '1' to enable interrupt for event KEYSLOT_REVOKED\n\nValue on reset: 0"]
|
||||
#[derive(Clone, Copy, Debug, PartialEq)]
|
||||
pub enum KEYSLOT_REVOKED_AW {
|
||||
#[doc = "1: Enable"]
|
||||
SET = 1,
|
||||
}
|
||||
impl From<KEYSLOT_REVOKED_AW> for bool {
|
||||
#[inline(always)]
|
||||
fn from(variant: KEYSLOT_REVOKED_AW) -> Self {
|
||||
variant as u8 != 0
|
||||
}
|
||||
}
|
||||
#[doc = "Field `KEYSLOT_REVOKED` writer - Write '1' to enable interrupt for event KEYSLOT_REVOKED"]
|
||||
pub type KEYSLOT_REVOKED_W<'a, const O: u8> =
|
||||
crate::BitWriter<'a, u32, INTENSET_SPEC, KEYSLOT_REVOKED_AW, O>;
|
||||
impl<'a, const O: u8> KEYSLOT_REVOKED_W<'a, O> {
|
||||
#[doc = "Enable"]
|
||||
#[inline(always)]
|
||||
pub fn set(self) -> &'a mut W {
|
||||
self.variant(KEYSLOT_REVOKED_AW::SET)
|
||||
}
|
||||
}
|
||||
#[doc = "Field `KEYSLOT_ERROR` reader - Write '1' to enable interrupt for event KEYSLOT_ERROR"]
|
||||
pub type KEYSLOT_ERROR_R = crate::BitReader<KEYSLOT_ERROR_A>;
|
||||
#[doc = "Write '1' to enable interrupt for event KEYSLOT_ERROR\n\nValue on reset: 0"]
|
||||
#[derive(Clone, Copy, Debug, PartialEq)]
|
||||
pub enum KEYSLOT_ERROR_A {
|
||||
#[doc = "0: Read: Disabled"]
|
||||
DISABLED = 0,
|
||||
#[doc = "1: Read: Enabled"]
|
||||
ENABLED = 1,
|
||||
}
|
||||
impl From<KEYSLOT_ERROR_A> for bool {
|
||||
#[inline(always)]
|
||||
fn from(variant: KEYSLOT_ERROR_A) -> Self {
|
||||
variant as u8 != 0
|
||||
}
|
||||
}
|
||||
impl KEYSLOT_ERROR_R {
|
||||
#[doc = "Get enumerated values variant"]
|
||||
#[inline(always)]
|
||||
pub fn variant(&self) -> KEYSLOT_ERROR_A {
|
||||
match self.bits {
|
||||
false => KEYSLOT_ERROR_A::DISABLED,
|
||||
true => KEYSLOT_ERROR_A::ENABLED,
|
||||
}
|
||||
}
|
||||
#[doc = "Checks if the value of the field is `DISABLED`"]
|
||||
#[inline(always)]
|
||||
pub fn is_disabled(&self) -> bool {
|
||||
*self == KEYSLOT_ERROR_A::DISABLED
|
||||
}
|
||||
#[doc = "Checks if the value of the field is `ENABLED`"]
|
||||
#[inline(always)]
|
||||
pub fn is_enabled(&self) -> bool {
|
||||
*self == KEYSLOT_ERROR_A::ENABLED
|
||||
}
|
||||
}
|
||||
#[doc = "Write '1' to enable interrupt for event KEYSLOT_ERROR\n\nValue on reset: 0"]
|
||||
#[derive(Clone, Copy, Debug, PartialEq)]
|
||||
pub enum KEYSLOT_ERROR_AW {
|
||||
#[doc = "1: Enable"]
|
||||
SET = 1,
|
||||
}
|
||||
impl From<KEYSLOT_ERROR_AW> for bool {
|
||||
#[inline(always)]
|
||||
fn from(variant: KEYSLOT_ERROR_AW) -> Self {
|
||||
variant as u8 != 0
|
||||
}
|
||||
}
|
||||
#[doc = "Field `KEYSLOT_ERROR` writer - Write '1' to enable interrupt for event KEYSLOT_ERROR"]
|
||||
pub type KEYSLOT_ERROR_W<'a, const O: u8> =
|
||||
crate::BitWriter<'a, u32, INTENSET_SPEC, KEYSLOT_ERROR_AW, O>;
|
||||
impl<'a, const O: u8> KEYSLOT_ERROR_W<'a, O> {
|
||||
#[doc = "Enable"]
|
||||
#[inline(always)]
|
||||
pub fn set(self) -> &'a mut W {
|
||||
self.variant(KEYSLOT_ERROR_AW::SET)
|
||||
}
|
||||
}
|
||||
impl R {
|
||||
#[doc = "Bit 0 - Write '1' to enable interrupt for event KEYSLOT_PUSHED"]
|
||||
#[inline(always)]
|
||||
pub fn keyslot_pushed(&self) -> KEYSLOT_PUSHED_R {
|
||||
KEYSLOT_PUSHED_R::new((self.bits & 1) != 0)
|
||||
}
|
||||
#[doc = "Bit 1 - Write '1' to enable interrupt for event KEYSLOT_REVOKED"]
|
||||
#[inline(always)]
|
||||
pub fn keyslot_revoked(&self) -> KEYSLOT_REVOKED_R {
|
||||
KEYSLOT_REVOKED_R::new(((self.bits >> 1) & 1) != 0)
|
||||
}
|
||||
#[doc = "Bit 2 - Write '1' to enable interrupt for event KEYSLOT_ERROR"]
|
||||
#[inline(always)]
|
||||
pub fn keyslot_error(&self) -> KEYSLOT_ERROR_R {
|
||||
KEYSLOT_ERROR_R::new(((self.bits >> 2) & 1) != 0)
|
||||
}
|
||||
}
|
||||
impl W {
|
||||
#[doc = "Bit 0 - Write '1' to enable interrupt for event KEYSLOT_PUSHED"]
|
||||
#[inline(always)]
|
||||
pub fn keyslot_pushed(&mut self) -> KEYSLOT_PUSHED_W<0> {
|
||||
KEYSLOT_PUSHED_W::new(self)
|
||||
}
|
||||
#[doc = "Bit 1 - Write '1' to enable interrupt for event KEYSLOT_REVOKED"]
|
||||
#[inline(always)]
|
||||
pub fn keyslot_revoked(&mut self) -> KEYSLOT_REVOKED_W<1> {
|
||||
KEYSLOT_REVOKED_W::new(self)
|
||||
}
|
||||
#[doc = "Bit 2 - Write '1' to enable interrupt for event KEYSLOT_ERROR"]
|
||||
#[inline(always)]
|
||||
pub fn keyslot_error(&mut self) -> KEYSLOT_ERROR_W<2> {
|
||||
KEYSLOT_ERROR_W::new(self)
|
||||
}
|
||||
#[doc = "Writes raw bits to the register."]
|
||||
#[inline(always)]
|
||||
pub unsafe fn bits(&mut self, bits: u32) -> &mut Self {
|
||||
self.0.bits(bits);
|
||||
self
|
||||
}
|
||||
}
|
||||
#[doc = "Enable interrupt\n\nThis register you can [`read`](crate::generic::Reg::read), [`write_with_zero`](crate::generic::Reg::write_with_zero), [`reset`](crate::generic::Reg::reset), [`write`](crate::generic::Reg::write), [`modify`](crate::generic::Reg::modify). See [API](https://docs.rs/svd2rust/#read--modify--write-api).\n\nFor information about available fields see [intenset](index.html) module"]
|
||||
pub struct INTENSET_SPEC;
|
||||
impl crate::RegisterSpec for INTENSET_SPEC {
|
||||
type Ux = u32;
|
||||
}
|
||||
#[doc = "`read()` method returns [intenset::R](R) reader structure"]
|
||||
impl crate::Readable for INTENSET_SPEC {
|
||||
type Reader = R;
|
||||
}
|
||||
#[doc = "`write(|w| ..)` method takes [intenset::W](W) writer structure"]
|
||||
impl crate::Writable for INTENSET_SPEC {
|
||||
type Writer = W;
|
||||
}
|
||||
#[doc = "`reset()` method sets INTENSET to value 0"]
|
||||
impl crate::Resettable for INTENSET_SPEC {
|
||||
#[inline(always)]
|
||||
fn reset_value() -> Self::Ux {
|
||||
0
|
||||
}
|
||||
}
|
||||
+156
@@ -0,0 +1,156 @@
|
||||
#[doc = "Register `INTPEND` reader"]
|
||||
pub struct R(crate::R<INTPEND_SPEC>);
|
||||
impl core::ops::Deref for R {
|
||||
type Target = crate::R<INTPEND_SPEC>;
|
||||
#[inline(always)]
|
||||
fn deref(&self) -> &Self::Target {
|
||||
&self.0
|
||||
}
|
||||
}
|
||||
impl From<crate::R<INTPEND_SPEC>> for R {
|
||||
#[inline(always)]
|
||||
fn from(reader: crate::R<INTPEND_SPEC>) -> Self {
|
||||
R(reader)
|
||||
}
|
||||
}
|
||||
#[doc = "Field `KEYSLOT_PUSHED` reader - Read pending status of interrupt for event KEYSLOT_PUSHED"]
|
||||
pub type KEYSLOT_PUSHED_R = crate::BitReader<KEYSLOT_PUSHED_A>;
|
||||
#[doc = "Read pending status of interrupt for event KEYSLOT_PUSHED\n\nValue on reset: 0"]
|
||||
#[derive(Clone, Copy, Debug, PartialEq)]
|
||||
pub enum KEYSLOT_PUSHED_A {
|
||||
#[doc = "0: Read: Not pending"]
|
||||
NOT_PENDING = 0,
|
||||
#[doc = "1: Read: Pending"]
|
||||
PENDING = 1,
|
||||
}
|
||||
impl From<KEYSLOT_PUSHED_A> for bool {
|
||||
#[inline(always)]
|
||||
fn from(variant: KEYSLOT_PUSHED_A) -> Self {
|
||||
variant as u8 != 0
|
||||
}
|
||||
}
|
||||
impl KEYSLOT_PUSHED_R {
|
||||
#[doc = "Get enumerated values variant"]
|
||||
#[inline(always)]
|
||||
pub fn variant(&self) -> KEYSLOT_PUSHED_A {
|
||||
match self.bits {
|
||||
false => KEYSLOT_PUSHED_A::NOT_PENDING,
|
||||
true => KEYSLOT_PUSHED_A::PENDING,
|
||||
}
|
||||
}
|
||||
#[doc = "Checks if the value of the field is `NOT_PENDING`"]
|
||||
#[inline(always)]
|
||||
pub fn is_not_pending(&self) -> bool {
|
||||
*self == KEYSLOT_PUSHED_A::NOT_PENDING
|
||||
}
|
||||
#[doc = "Checks if the value of the field is `PENDING`"]
|
||||
#[inline(always)]
|
||||
pub fn is_pending(&self) -> bool {
|
||||
*self == KEYSLOT_PUSHED_A::PENDING
|
||||
}
|
||||
}
|
||||
#[doc = "Field `KEYSLOT_REVOKED` reader - Read pending status of interrupt for event KEYSLOT_REVOKED"]
|
||||
pub type KEYSLOT_REVOKED_R = crate::BitReader<KEYSLOT_REVOKED_A>;
|
||||
#[doc = "Read pending status of interrupt for event KEYSLOT_REVOKED\n\nValue on reset: 0"]
|
||||
#[derive(Clone, Copy, Debug, PartialEq)]
|
||||
pub enum KEYSLOT_REVOKED_A {
|
||||
#[doc = "0: Read: Not pending"]
|
||||
NOT_PENDING = 0,
|
||||
#[doc = "1: Read: Pending"]
|
||||
PENDING = 1,
|
||||
}
|
||||
impl From<KEYSLOT_REVOKED_A> for bool {
|
||||
#[inline(always)]
|
||||
fn from(variant: KEYSLOT_REVOKED_A) -> Self {
|
||||
variant as u8 != 0
|
||||
}
|
||||
}
|
||||
impl KEYSLOT_REVOKED_R {
|
||||
#[doc = "Get enumerated values variant"]
|
||||
#[inline(always)]
|
||||
pub fn variant(&self) -> KEYSLOT_REVOKED_A {
|
||||
match self.bits {
|
||||
false => KEYSLOT_REVOKED_A::NOT_PENDING,
|
||||
true => KEYSLOT_REVOKED_A::PENDING,
|
||||
}
|
||||
}
|
||||
#[doc = "Checks if the value of the field is `NOT_PENDING`"]
|
||||
#[inline(always)]
|
||||
pub fn is_not_pending(&self) -> bool {
|
||||
*self == KEYSLOT_REVOKED_A::NOT_PENDING
|
||||
}
|
||||
#[doc = "Checks if the value of the field is `PENDING`"]
|
||||
#[inline(always)]
|
||||
pub fn is_pending(&self) -> bool {
|
||||
*self == KEYSLOT_REVOKED_A::PENDING
|
||||
}
|
||||
}
|
||||
#[doc = "Field `KEYSLOT_ERROR` reader - Read pending status of interrupt for event KEYSLOT_ERROR"]
|
||||
pub type KEYSLOT_ERROR_R = crate::BitReader<KEYSLOT_ERROR_A>;
|
||||
#[doc = "Read pending status of interrupt for event KEYSLOT_ERROR\n\nValue on reset: 0"]
|
||||
#[derive(Clone, Copy, Debug, PartialEq)]
|
||||
pub enum KEYSLOT_ERROR_A {
|
||||
#[doc = "0: Read: Not pending"]
|
||||
NOT_PENDING = 0,
|
||||
#[doc = "1: Read: Pending"]
|
||||
PENDING = 1,
|
||||
}
|
||||
impl From<KEYSLOT_ERROR_A> for bool {
|
||||
#[inline(always)]
|
||||
fn from(variant: KEYSLOT_ERROR_A) -> Self {
|
||||
variant as u8 != 0
|
||||
}
|
||||
}
|
||||
impl KEYSLOT_ERROR_R {
|
||||
#[doc = "Get enumerated values variant"]
|
||||
#[inline(always)]
|
||||
pub fn variant(&self) -> KEYSLOT_ERROR_A {
|
||||
match self.bits {
|
||||
false => KEYSLOT_ERROR_A::NOT_PENDING,
|
||||
true => KEYSLOT_ERROR_A::PENDING,
|
||||
}
|
||||
}
|
||||
#[doc = "Checks if the value of the field is `NOT_PENDING`"]
|
||||
#[inline(always)]
|
||||
pub fn is_not_pending(&self) -> bool {
|
||||
*self == KEYSLOT_ERROR_A::NOT_PENDING
|
||||
}
|
||||
#[doc = "Checks if the value of the field is `PENDING`"]
|
||||
#[inline(always)]
|
||||
pub fn is_pending(&self) -> bool {
|
||||
*self == KEYSLOT_ERROR_A::PENDING
|
||||
}
|
||||
}
|
||||
impl R {
|
||||
#[doc = "Bit 0 - Read pending status of interrupt for event KEYSLOT_PUSHED"]
|
||||
#[inline(always)]
|
||||
pub fn keyslot_pushed(&self) -> KEYSLOT_PUSHED_R {
|
||||
KEYSLOT_PUSHED_R::new((self.bits & 1) != 0)
|
||||
}
|
||||
#[doc = "Bit 1 - Read pending status of interrupt for event KEYSLOT_REVOKED"]
|
||||
#[inline(always)]
|
||||
pub fn keyslot_revoked(&self) -> KEYSLOT_REVOKED_R {
|
||||
KEYSLOT_REVOKED_R::new(((self.bits >> 1) & 1) != 0)
|
||||
}
|
||||
#[doc = "Bit 2 - Read pending status of interrupt for event KEYSLOT_ERROR"]
|
||||
#[inline(always)]
|
||||
pub fn keyslot_error(&self) -> KEYSLOT_ERROR_R {
|
||||
KEYSLOT_ERROR_R::new(((self.bits >> 2) & 1) != 0)
|
||||
}
|
||||
}
|
||||
#[doc = "Pending interrupts\n\nThis register you can [`read`](crate::generic::Reg::read). See [API](https://docs.rs/svd2rust/#read--modify--write-api).\n\nFor information about available fields see [intpend](index.html) module"]
|
||||
pub struct INTPEND_SPEC;
|
||||
impl crate::RegisterSpec for INTPEND_SPEC {
|
||||
type Ux = u32;
|
||||
}
|
||||
#[doc = "`read()` method returns [intpend::R](R) reader structure"]
|
||||
impl crate::Readable for INTPEND_SPEC {
|
||||
type Reader = R;
|
||||
}
|
||||
#[doc = "`reset()` method sets INTPEND to value 0"]
|
||||
impl crate::Resettable for INTPEND_SPEC {
|
||||
#[inline(always)]
|
||||
fn reset_value() -> Self::Ux {
|
||||
0
|
||||
}
|
||||
}
|
||||
+88
@@ -0,0 +1,88 @@
|
||||
#[doc = "Register `SELECTKEYSLOT` reader"]
|
||||
pub struct R(crate::R<SELECTKEYSLOT_SPEC>);
|
||||
impl core::ops::Deref for R {
|
||||
type Target = crate::R<SELECTKEYSLOT_SPEC>;
|
||||
#[inline(always)]
|
||||
fn deref(&self) -> &Self::Target {
|
||||
&self.0
|
||||
}
|
||||
}
|
||||
impl From<crate::R<SELECTKEYSLOT_SPEC>> for R {
|
||||
#[inline(always)]
|
||||
fn from(reader: crate::R<SELECTKEYSLOT_SPEC>) -> Self {
|
||||
R(reader)
|
||||
}
|
||||
}
|
||||
#[doc = "Register `SELECTKEYSLOT` writer"]
|
||||
pub struct W(crate::W<SELECTKEYSLOT_SPEC>);
|
||||
impl core::ops::Deref for W {
|
||||
type Target = crate::W<SELECTKEYSLOT_SPEC>;
|
||||
#[inline(always)]
|
||||
fn deref(&self) -> &Self::Target {
|
||||
&self.0
|
||||
}
|
||||
}
|
||||
impl core::ops::DerefMut for W {
|
||||
#[inline(always)]
|
||||
fn deref_mut(&mut self) -> &mut Self::Target {
|
||||
&mut self.0
|
||||
}
|
||||
}
|
||||
impl From<crate::W<SELECTKEYSLOT_SPEC>> for W {
|
||||
#[inline(always)]
|
||||
fn from(writer: crate::W<SELECTKEYSLOT_SPEC>) -> Self {
|
||||
W(writer)
|
||||
}
|
||||
}
|
||||
#[doc = "Field `ID` reader - Select key slot ID to be read over AHB, or pushed over secure APB, when TASKS_PUSH_KEYSLOT is started. NOTE: ID=0 is not a valid key slot ID. The 0 ID should be used when the KMU is idle or not in use. NOTE: Index N in UICR->KEYSLOT.KEY\\[N\\]
|
||||
and UICR->KEYSLOT.CONFIG\\[N\\]
|
||||
corresponds to KMU key slot ID=N+1."]
|
||||
pub type ID_R = crate::FieldReader<u8, u8>;
|
||||
#[doc = "Field `ID` writer - Select key slot ID to be read over AHB, or pushed over secure APB, when TASKS_PUSH_KEYSLOT is started. NOTE: ID=0 is not a valid key slot ID. The 0 ID should be used when the KMU is idle or not in use. NOTE: Index N in UICR->KEYSLOT.KEY\\[N\\]
|
||||
and UICR->KEYSLOT.CONFIG\\[N\\]
|
||||
corresponds to KMU key slot ID=N+1."]
|
||||
pub type ID_W<'a, const O: u8> = crate::FieldWriter<'a, u32, SELECTKEYSLOT_SPEC, u8, u8, 8, O>;
|
||||
impl R {
|
||||
#[doc = "Bits 0:7 - Select key slot ID to be read over AHB, or pushed over secure APB, when TASKS_PUSH_KEYSLOT is started. NOTE: ID=0 is not a valid key slot ID. The 0 ID should be used when the KMU is idle or not in use. NOTE: Index N in UICR->KEYSLOT.KEY\\[N\\]
|
||||
and UICR->KEYSLOT.CONFIG\\[N\\]
|
||||
corresponds to KMU key slot ID=N+1."]
|
||||
#[inline(always)]
|
||||
pub fn id(&self) -> ID_R {
|
||||
ID_R::new((self.bits & 0xff) as u8)
|
||||
}
|
||||
}
|
||||
impl W {
|
||||
#[doc = "Bits 0:7 - Select key slot ID to be read over AHB, or pushed over secure APB, when TASKS_PUSH_KEYSLOT is started. NOTE: ID=0 is not a valid key slot ID. The 0 ID should be used when the KMU is idle or not in use. NOTE: Index N in UICR->KEYSLOT.KEY\\[N\\]
|
||||
and UICR->KEYSLOT.CONFIG\\[N\\]
|
||||
corresponds to KMU key slot ID=N+1."]
|
||||
#[inline(always)]
|
||||
pub fn id(&mut self) -> ID_W<0> {
|
||||
ID_W::new(self)
|
||||
}
|
||||
#[doc = "Writes raw bits to the register."]
|
||||
#[inline(always)]
|
||||
pub unsafe fn bits(&mut self, bits: u32) -> &mut Self {
|
||||
self.0.bits(bits);
|
||||
self
|
||||
}
|
||||
}
|
||||
#[doc = "Select key slot to be read over AHB or pushed over secure APB when TASKS_PUSH_KEYSLOT is started\n\nThis register you can [`read`](crate::generic::Reg::read), [`write_with_zero`](crate::generic::Reg::write_with_zero), [`reset`](crate::generic::Reg::reset), [`write`](crate::generic::Reg::write), [`modify`](crate::generic::Reg::modify). See [API](https://docs.rs/svd2rust/#read--modify--write-api).\n\nFor information about available fields see [selectkeyslot](index.html) module"]
|
||||
pub struct SELECTKEYSLOT_SPEC;
|
||||
impl crate::RegisterSpec for SELECTKEYSLOT_SPEC {
|
||||
type Ux = u32;
|
||||
}
|
||||
#[doc = "`read()` method returns [selectkeyslot::R](R) reader structure"]
|
||||
impl crate::Readable for SELECTKEYSLOT_SPEC {
|
||||
type Reader = R;
|
||||
}
|
||||
#[doc = "`write(|w| ..)` method takes [selectkeyslot::W](W) writer structure"]
|
||||
impl crate::Writable for SELECTKEYSLOT_SPEC {
|
||||
type Writer = W;
|
||||
}
|
||||
#[doc = "`reset()` method sets SELECTKEYSLOT to value 0"]
|
||||
impl crate::Resettable for SELECTKEYSLOT_SPEC {
|
||||
#[inline(always)]
|
||||
fn reset_value() -> Self::Ux {
|
||||
0
|
||||
}
|
||||
}
|
||||
+115
@@ -0,0 +1,115 @@
|
||||
#[doc = "Register `STATUS` reader"]
|
||||
pub struct R(crate::R<STATUS_SPEC>);
|
||||
impl core::ops::Deref for R {
|
||||
type Target = crate::R<STATUS_SPEC>;
|
||||
#[inline(always)]
|
||||
fn deref(&self) -> &Self::Target {
|
||||
&self.0
|
||||
}
|
||||
}
|
||||
impl From<crate::R<STATUS_SPEC>> for R {
|
||||
#[inline(always)]
|
||||
fn from(reader: crate::R<STATUS_SPEC>) -> Self {
|
||||
R(reader)
|
||||
}
|
||||
}
|
||||
#[doc = "Field `SELECTED` reader - Key slot ID successfully selected by the KMU"]
|
||||
pub type SELECTED_R = crate::BitReader<SELECTED_A>;
|
||||
#[doc = "Key slot ID successfully selected by the KMU\n\nValue on reset: 0"]
|
||||
#[derive(Clone, Copy, Debug, PartialEq)]
|
||||
pub enum SELECTED_A {
|
||||
#[doc = "0: No key slot ID selected by KMU"]
|
||||
DISABLED = 0,
|
||||
#[doc = "1: Key slot ID successfully selected by KMU"]
|
||||
ENABLED = 1,
|
||||
}
|
||||
impl From<SELECTED_A> for bool {
|
||||
#[inline(always)]
|
||||
fn from(variant: SELECTED_A) -> Self {
|
||||
variant as u8 != 0
|
||||
}
|
||||
}
|
||||
impl SELECTED_R {
|
||||
#[doc = "Get enumerated values variant"]
|
||||
#[inline(always)]
|
||||
pub fn variant(&self) -> SELECTED_A {
|
||||
match self.bits {
|
||||
false => SELECTED_A::DISABLED,
|
||||
true => SELECTED_A::ENABLED,
|
||||
}
|
||||
}
|
||||
#[doc = "Checks if the value of the field is `DISABLED`"]
|
||||
#[inline(always)]
|
||||
pub fn is_disabled(&self) -> bool {
|
||||
*self == SELECTED_A::DISABLED
|
||||
}
|
||||
#[doc = "Checks if the value of the field is `ENABLED`"]
|
||||
#[inline(always)]
|
||||
pub fn is_enabled(&self) -> bool {
|
||||
*self == SELECTED_A::ENABLED
|
||||
}
|
||||
}
|
||||
#[doc = "Field `BLOCKED` reader - Violation status"]
|
||||
pub type BLOCKED_R = crate::BitReader<BLOCKED_A>;
|
||||
#[doc = "Violation status\n\nValue on reset: 0"]
|
||||
#[derive(Clone, Copy, Debug, PartialEq)]
|
||||
pub enum BLOCKED_A {
|
||||
#[doc = "0: No access violation detected"]
|
||||
DISABLED = 0,
|
||||
#[doc = "1: Access violation detected and blocked"]
|
||||
ENABLED = 1,
|
||||
}
|
||||
impl From<BLOCKED_A> for bool {
|
||||
#[inline(always)]
|
||||
fn from(variant: BLOCKED_A) -> Self {
|
||||
variant as u8 != 0
|
||||
}
|
||||
}
|
||||
impl BLOCKED_R {
|
||||
#[doc = "Get enumerated values variant"]
|
||||
#[inline(always)]
|
||||
pub fn variant(&self) -> BLOCKED_A {
|
||||
match self.bits {
|
||||
false => BLOCKED_A::DISABLED,
|
||||
true => BLOCKED_A::ENABLED,
|
||||
}
|
||||
}
|
||||
#[doc = "Checks if the value of the field is `DISABLED`"]
|
||||
#[inline(always)]
|
||||
pub fn is_disabled(&self) -> bool {
|
||||
*self == BLOCKED_A::DISABLED
|
||||
}
|
||||
#[doc = "Checks if the value of the field is `ENABLED`"]
|
||||
#[inline(always)]
|
||||
pub fn is_enabled(&self) -> bool {
|
||||
*self == BLOCKED_A::ENABLED
|
||||
}
|
||||
}
|
||||
impl R {
|
||||
#[doc = "Bit 0 - Key slot ID successfully selected by the KMU"]
|
||||
#[inline(always)]
|
||||
pub fn selected(&self) -> SELECTED_R {
|
||||
SELECTED_R::new((self.bits & 1) != 0)
|
||||
}
|
||||
#[doc = "Bit 1 - Violation status"]
|
||||
#[inline(always)]
|
||||
pub fn blocked(&self) -> BLOCKED_R {
|
||||
BLOCKED_R::new(((self.bits >> 1) & 1) != 0)
|
||||
}
|
||||
}
|
||||
#[doc = "Status bits for KMU operation\n\nThis register you can [`read`](crate::generic::Reg::read). See [API](https://docs.rs/svd2rust/#read--modify--write-api).\n\nFor information about available fields see [status](index.html) module"]
|
||||
pub struct STATUS_SPEC;
|
||||
impl crate::RegisterSpec for STATUS_SPEC {
|
||||
type Ux = u32;
|
||||
}
|
||||
#[doc = "`read()` method returns [status::R](R) reader structure"]
|
||||
impl crate::Readable for STATUS_SPEC {
|
||||
type Reader = R;
|
||||
}
|
||||
#[doc = "`reset()` method sets STATUS to value 0"]
|
||||
impl crate::Resettable for STATUS_SPEC {
|
||||
#[inline(always)]
|
||||
fn reset_value() -> Self::Ux {
|
||||
0
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,72 @@
|
||||
#[doc = "Register `TASKS_PUSH_KEYSLOT` writer"]
|
||||
pub struct W(crate::W<TASKS_PUSH_KEYSLOT_SPEC>);
|
||||
impl core::ops::Deref for W {
|
||||
type Target = crate::W<TASKS_PUSH_KEYSLOT_SPEC>;
|
||||
#[inline(always)]
|
||||
fn deref(&self) -> &Self::Target {
|
||||
&self.0
|
||||
}
|
||||
}
|
||||
impl core::ops::DerefMut for W {
|
||||
#[inline(always)]
|
||||
fn deref_mut(&mut self) -> &mut Self::Target {
|
||||
&mut self.0
|
||||
}
|
||||
}
|
||||
impl From<crate::W<TASKS_PUSH_KEYSLOT_SPEC>> for W {
|
||||
#[inline(always)]
|
||||
fn from(writer: crate::W<TASKS_PUSH_KEYSLOT_SPEC>) -> Self {
|
||||
W(writer)
|
||||
}
|
||||
}
|
||||
#[doc = "Push a key slot over secure APB\n\nValue on reset: 0"]
|
||||
#[derive(Clone, Copy, Debug, PartialEq)]
|
||||
pub enum TASKS_PUSH_KEYSLOT_AW {
|
||||
#[doc = "1: Trigger task"]
|
||||
TRIGGER = 1,
|
||||
}
|
||||
impl From<TASKS_PUSH_KEYSLOT_AW> for bool {
|
||||
#[inline(always)]
|
||||
fn from(variant: TASKS_PUSH_KEYSLOT_AW) -> Self {
|
||||
variant as u8 != 0
|
||||
}
|
||||
}
|
||||
#[doc = "Field `TASKS_PUSH_KEYSLOT` writer - Push a key slot over secure APB"]
|
||||
pub type TASKS_PUSH_KEYSLOT_W<'a, const O: u8> =
|
||||
crate::BitWriter<'a, u32, TASKS_PUSH_KEYSLOT_SPEC, TASKS_PUSH_KEYSLOT_AW, O>;
|
||||
impl<'a, const O: u8> TASKS_PUSH_KEYSLOT_W<'a, O> {
|
||||
#[doc = "Trigger task"]
|
||||
#[inline(always)]
|
||||
pub fn trigger(self) -> &'a mut W {
|
||||
self.variant(TASKS_PUSH_KEYSLOT_AW::TRIGGER)
|
||||
}
|
||||
}
|
||||
impl W {
|
||||
#[doc = "Bit 0 - Push a key slot over secure APB"]
|
||||
#[inline(always)]
|
||||
pub fn tasks_push_keyslot(&mut self) -> TASKS_PUSH_KEYSLOT_W<0> {
|
||||
TASKS_PUSH_KEYSLOT_W::new(self)
|
||||
}
|
||||
#[doc = "Writes raw bits to the register."]
|
||||
#[inline(always)]
|
||||
pub unsafe fn bits(&mut self, bits: u32) -> &mut Self {
|
||||
self.0.bits(bits);
|
||||
self
|
||||
}
|
||||
}
|
||||
#[doc = "Push a key slot over secure APB\n\nThis register you can [`write_with_zero`](crate::generic::Reg::write_with_zero), [`reset`](crate::generic::Reg::reset), [`write`](crate::generic::Reg::write). See [API](https://docs.rs/svd2rust/#read--modify--write-api).\n\nFor information about available fields see [tasks_push_keyslot](index.html) module"]
|
||||
pub struct TASKS_PUSH_KEYSLOT_SPEC;
|
||||
impl crate::RegisterSpec for TASKS_PUSH_KEYSLOT_SPEC {
|
||||
type Ux = u32;
|
||||
}
|
||||
#[doc = "`write(|w| ..)` method takes [tasks_push_keyslot::W](W) writer structure"]
|
||||
impl crate::Writable for TASKS_PUSH_KEYSLOT_SPEC {
|
||||
type Writer = W;
|
||||
}
|
||||
#[doc = "`reset()` method sets TASKS_PUSH_KEYSLOT to value 0"]
|
||||
impl crate::Resettable for TASKS_PUSH_KEYSLOT_SPEC {
|
||||
#[inline(always)]
|
||||
fn reset_value() -> Self::Ux {
|
||||
0
|
||||
}
|
||||
}
|
||||
Reference in new issue
Block a user