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
Vendored
+80
@@ -0,0 +1,80 @@
|
||||
#[doc = "Register `ADDRESS` reader"]
|
||||
pub struct R(crate::R<ADDRESS_SPEC>);
|
||||
impl core::ops::Deref for R {
|
||||
type Target = crate::R<ADDRESS_SPEC>;
|
||||
#[inline(always)]
|
||||
fn deref(&self) -> &Self::Target {
|
||||
&self.0
|
||||
}
|
||||
}
|
||||
impl From<crate::R<ADDRESS_SPEC>> for R {
|
||||
#[inline(always)]
|
||||
fn from(reader: crate::R<ADDRESS_SPEC>) -> Self {
|
||||
R(reader)
|
||||
}
|
||||
}
|
||||
#[doc = "Register `ADDRESS` writer"]
|
||||
pub struct W(crate::W<ADDRESS_SPEC>);
|
||||
impl core::ops::Deref for W {
|
||||
type Target = crate::W<ADDRESS_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<ADDRESS_SPEC>> for W {
|
||||
#[inline(always)]
|
||||
fn from(writer: crate::W<ADDRESS_SPEC>) -> Self {
|
||||
W(writer)
|
||||
}
|
||||
}
|
||||
#[doc = "Field `ADDRESS` reader - Two-wire address."]
|
||||
pub type ADDRESS_R = crate::FieldReader<u8, u8>;
|
||||
#[doc = "Field `ADDRESS` writer - Two-wire address."]
|
||||
pub type ADDRESS_W<'a, const O: u8> = crate::FieldWriter<'a, u32, ADDRESS_SPEC, u8, u8, 7, O>;
|
||||
impl R {
|
||||
#[doc = "Bits 0:6 - Two-wire address."]
|
||||
#[inline(always)]
|
||||
pub fn address(&self) -> ADDRESS_R {
|
||||
ADDRESS_R::new((self.bits & 0x7f) as u8)
|
||||
}
|
||||
}
|
||||
impl W {
|
||||
#[doc = "Bits 0:6 - Two-wire address."]
|
||||
#[inline(always)]
|
||||
pub fn address(&mut self) -> ADDRESS_W<0> {
|
||||
ADDRESS_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 = "Address used in the two-wire transfer.\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 [address](index.html) module"]
|
||||
pub struct ADDRESS_SPEC;
|
||||
impl crate::RegisterSpec for ADDRESS_SPEC {
|
||||
type Ux = u32;
|
||||
}
|
||||
#[doc = "`read()` method returns [address::R](R) reader structure"]
|
||||
impl crate::Readable for ADDRESS_SPEC {
|
||||
type Reader = R;
|
||||
}
|
||||
#[doc = "`write(|w| ..)` method takes [address::W](W) writer structure"]
|
||||
impl crate::Writable for ADDRESS_SPEC {
|
||||
type Writer = W;
|
||||
}
|
||||
#[doc = "`reset()` method sets ADDRESS to value 0"]
|
||||
impl crate::Resettable for ADDRESS_SPEC {
|
||||
#[inline(always)]
|
||||
fn reset_value() -> Self::Ux {
|
||||
0
|
||||
}
|
||||
}
|
||||
Vendored
+128
@@ -0,0 +1,128 @@
|
||||
#[doc = "Register `ENABLE` reader"]
|
||||
pub struct R(crate::R<ENABLE_SPEC>);
|
||||
impl core::ops::Deref for R {
|
||||
type Target = crate::R<ENABLE_SPEC>;
|
||||
#[inline(always)]
|
||||
fn deref(&self) -> &Self::Target {
|
||||
&self.0
|
||||
}
|
||||
}
|
||||
impl From<crate::R<ENABLE_SPEC>> for R {
|
||||
#[inline(always)]
|
||||
fn from(reader: crate::R<ENABLE_SPEC>) -> Self {
|
||||
R(reader)
|
||||
}
|
||||
}
|
||||
#[doc = "Register `ENABLE` writer"]
|
||||
pub struct W(crate::W<ENABLE_SPEC>);
|
||||
impl core::ops::Deref for W {
|
||||
type Target = crate::W<ENABLE_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<ENABLE_SPEC>> for W {
|
||||
#[inline(always)]
|
||||
fn from(writer: crate::W<ENABLE_SPEC>) -> Self {
|
||||
W(writer)
|
||||
}
|
||||
}
|
||||
#[doc = "Field `ENABLE` reader - Enable or disable W2M"]
|
||||
pub type ENABLE_R = crate::FieldReader<u8, ENABLE_A>;
|
||||
#[doc = "Enable or disable W2M\n\nValue on reset: 0"]
|
||||
#[derive(Clone, Copy, Debug, PartialEq)]
|
||||
#[repr(u8)]
|
||||
pub enum ENABLE_A {
|
||||
#[doc = "0: Disabled."]
|
||||
DISABLED = 0,
|
||||
#[doc = "5: Enabled."]
|
||||
ENABLED = 5,
|
||||
}
|
||||
impl From<ENABLE_A> for u8 {
|
||||
#[inline(always)]
|
||||
fn from(variant: ENABLE_A) -> Self {
|
||||
variant as _
|
||||
}
|
||||
}
|
||||
impl ENABLE_R {
|
||||
#[doc = "Get enumerated values variant"]
|
||||
#[inline(always)]
|
||||
pub fn variant(&self) -> Option<ENABLE_A> {
|
||||
match self.bits {
|
||||
0 => Some(ENABLE_A::DISABLED),
|
||||
5 => Some(ENABLE_A::ENABLED),
|
||||
_ => None,
|
||||
}
|
||||
}
|
||||
#[doc = "Checks if the value of the field is `DISABLED`"]
|
||||
#[inline(always)]
|
||||
pub fn is_disabled(&self) -> bool {
|
||||
*self == ENABLE_A::DISABLED
|
||||
}
|
||||
#[doc = "Checks if the value of the field is `ENABLED`"]
|
||||
#[inline(always)]
|
||||
pub fn is_enabled(&self) -> bool {
|
||||
*self == ENABLE_A::ENABLED
|
||||
}
|
||||
}
|
||||
#[doc = "Field `ENABLE` writer - Enable or disable W2M"]
|
||||
pub type ENABLE_W<'a, const O: u8> = crate::FieldWriter<'a, u32, ENABLE_SPEC, u8, ENABLE_A, 3, O>;
|
||||
impl<'a, const O: u8> ENABLE_W<'a, O> {
|
||||
#[doc = "Disabled."]
|
||||
#[inline(always)]
|
||||
pub fn disabled(self) -> &'a mut W {
|
||||
self.variant(ENABLE_A::DISABLED)
|
||||
}
|
||||
#[doc = "Enabled."]
|
||||
#[inline(always)]
|
||||
pub fn enabled(self) -> &'a mut W {
|
||||
self.variant(ENABLE_A::ENABLED)
|
||||
}
|
||||
}
|
||||
impl R {
|
||||
#[doc = "Bits 0:2 - Enable or disable W2M"]
|
||||
#[inline(always)]
|
||||
pub fn enable(&self) -> ENABLE_R {
|
||||
ENABLE_R::new((self.bits & 7) as u8)
|
||||
}
|
||||
}
|
||||
impl W {
|
||||
#[doc = "Bits 0:2 - Enable or disable W2M"]
|
||||
#[inline(always)]
|
||||
pub fn enable(&mut self) -> ENABLE_W<0> {
|
||||
ENABLE_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 two-wire master.\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 [enable](index.html) module"]
|
||||
pub struct ENABLE_SPEC;
|
||||
impl crate::RegisterSpec for ENABLE_SPEC {
|
||||
type Ux = u32;
|
||||
}
|
||||
#[doc = "`read()` method returns [enable::R](R) reader structure"]
|
||||
impl crate::Readable for ENABLE_SPEC {
|
||||
type Reader = R;
|
||||
}
|
||||
#[doc = "`write(|w| ..)` method takes [enable::W](W) writer structure"]
|
||||
impl crate::Writable for ENABLE_SPEC {
|
||||
type Writer = W;
|
||||
}
|
||||
#[doc = "`reset()` method sets ENABLE to value 0"]
|
||||
impl crate::Resettable for ENABLE_SPEC {
|
||||
#[inline(always)]
|
||||
fn reset_value() -> Self::Ux {
|
||||
0
|
||||
}
|
||||
}
|
||||
+267
@@ -0,0 +1,267 @@
|
||||
#[doc = "Register `ERRORSRC` reader"]
|
||||
pub struct R(crate::R<ERRORSRC_SPEC>);
|
||||
impl core::ops::Deref for R {
|
||||
type Target = crate::R<ERRORSRC_SPEC>;
|
||||
#[inline(always)]
|
||||
fn deref(&self) -> &Self::Target {
|
||||
&self.0
|
||||
}
|
||||
}
|
||||
impl From<crate::R<ERRORSRC_SPEC>> for R {
|
||||
#[inline(always)]
|
||||
fn from(reader: crate::R<ERRORSRC_SPEC>) -> Self {
|
||||
R(reader)
|
||||
}
|
||||
}
|
||||
#[doc = "Register `ERRORSRC` writer"]
|
||||
pub struct W(crate::W<ERRORSRC_SPEC>);
|
||||
impl core::ops::Deref for W {
|
||||
type Target = crate::W<ERRORSRC_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<ERRORSRC_SPEC>> for W {
|
||||
#[inline(always)]
|
||||
fn from(writer: crate::W<ERRORSRC_SPEC>) -> Self {
|
||||
W(writer)
|
||||
}
|
||||
}
|
||||
#[doc = "Field `OVERRUN` reader - Byte received in RXD register before read of the last received byte (data loss)."]
|
||||
pub type OVERRUN_R = crate::BitReader<OVERRUN_A>;
|
||||
#[doc = "Byte received in RXD register before read of the last received byte (data loss).\n\nValue on reset: 0"]
|
||||
#[derive(Clone, Copy, Debug, PartialEq)]
|
||||
pub enum OVERRUN_A {
|
||||
#[doc = "0: Error not present."]
|
||||
NOT_PRESENT = 0,
|
||||
#[doc = "1: Error present."]
|
||||
PRESENT = 1,
|
||||
}
|
||||
impl From<OVERRUN_A> for bool {
|
||||
#[inline(always)]
|
||||
fn from(variant: OVERRUN_A) -> Self {
|
||||
variant as u8 != 0
|
||||
}
|
||||
}
|
||||
impl OVERRUN_R {
|
||||
#[doc = "Get enumerated values variant"]
|
||||
#[inline(always)]
|
||||
pub fn variant(&self) -> OVERRUN_A {
|
||||
match self.bits {
|
||||
false => OVERRUN_A::NOT_PRESENT,
|
||||
true => OVERRUN_A::PRESENT,
|
||||
}
|
||||
}
|
||||
#[doc = "Checks if the value of the field is `NOT_PRESENT`"]
|
||||
#[inline(always)]
|
||||
pub fn is_not_present(&self) -> bool {
|
||||
*self == OVERRUN_A::NOT_PRESENT
|
||||
}
|
||||
#[doc = "Checks if the value of the field is `PRESENT`"]
|
||||
#[inline(always)]
|
||||
pub fn is_present(&self) -> bool {
|
||||
*self == OVERRUN_A::PRESENT
|
||||
}
|
||||
}
|
||||
#[doc = "Byte received in RXD register before read of the last received byte (data loss).\n\nValue on reset: 0"]
|
||||
#[derive(Clone, Copy, Debug, PartialEq)]
|
||||
pub enum OVERRUN_AW {
|
||||
#[doc = "1: Clear error on write."]
|
||||
CLEAR = 1,
|
||||
}
|
||||
impl From<OVERRUN_AW> for bool {
|
||||
#[inline(always)]
|
||||
fn from(variant: OVERRUN_AW) -> Self {
|
||||
variant as u8 != 0
|
||||
}
|
||||
}
|
||||
#[doc = "Field `OVERRUN` writer - Byte received in RXD register before read of the last received byte (data loss)."]
|
||||
pub type OVERRUN_W<'a, const O: u8> = crate::BitWriter<'a, u32, ERRORSRC_SPEC, OVERRUN_AW, O>;
|
||||
impl<'a, const O: u8> OVERRUN_W<'a, O> {
|
||||
#[doc = "Clear error on write."]
|
||||
#[inline(always)]
|
||||
pub fn clear(self) -> &'a mut W {
|
||||
self.variant(OVERRUN_AW::CLEAR)
|
||||
}
|
||||
}
|
||||
#[doc = "Field `ANACK` reader - NACK received after sending the address."]
|
||||
pub type ANACK_R = crate::BitReader<ANACK_A>;
|
||||
#[doc = "NACK received after sending the address.\n\nValue on reset: 0"]
|
||||
#[derive(Clone, Copy, Debug, PartialEq)]
|
||||
pub enum ANACK_A {
|
||||
#[doc = "0: Error not present."]
|
||||
NOT_PRESENT = 0,
|
||||
#[doc = "1: Error present."]
|
||||
PRESENT = 1,
|
||||
}
|
||||
impl From<ANACK_A> for bool {
|
||||
#[inline(always)]
|
||||
fn from(variant: ANACK_A) -> Self {
|
||||
variant as u8 != 0
|
||||
}
|
||||
}
|
||||
impl ANACK_R {
|
||||
#[doc = "Get enumerated values variant"]
|
||||
#[inline(always)]
|
||||
pub fn variant(&self) -> ANACK_A {
|
||||
match self.bits {
|
||||
false => ANACK_A::NOT_PRESENT,
|
||||
true => ANACK_A::PRESENT,
|
||||
}
|
||||
}
|
||||
#[doc = "Checks if the value of the field is `NOT_PRESENT`"]
|
||||
#[inline(always)]
|
||||
pub fn is_not_present(&self) -> bool {
|
||||
*self == ANACK_A::NOT_PRESENT
|
||||
}
|
||||
#[doc = "Checks if the value of the field is `PRESENT`"]
|
||||
#[inline(always)]
|
||||
pub fn is_present(&self) -> bool {
|
||||
*self == ANACK_A::PRESENT
|
||||
}
|
||||
}
|
||||
#[doc = "NACK received after sending the address.\n\nValue on reset: 0"]
|
||||
#[derive(Clone, Copy, Debug, PartialEq)]
|
||||
pub enum ANACK_AW {
|
||||
#[doc = "1: Clear error on write."]
|
||||
CLEAR = 1,
|
||||
}
|
||||
impl From<ANACK_AW> for bool {
|
||||
#[inline(always)]
|
||||
fn from(variant: ANACK_AW) -> Self {
|
||||
variant as u8 != 0
|
||||
}
|
||||
}
|
||||
#[doc = "Field `ANACK` writer - NACK received after sending the address."]
|
||||
pub type ANACK_W<'a, const O: u8> = crate::BitWriter<'a, u32, ERRORSRC_SPEC, ANACK_AW, O>;
|
||||
impl<'a, const O: u8> ANACK_W<'a, O> {
|
||||
#[doc = "Clear error on write."]
|
||||
#[inline(always)]
|
||||
pub fn clear(self) -> &'a mut W {
|
||||
self.variant(ANACK_AW::CLEAR)
|
||||
}
|
||||
}
|
||||
#[doc = "Field `DNACK` reader - NACK received after sending a data byte."]
|
||||
pub type DNACK_R = crate::BitReader<DNACK_A>;
|
||||
#[doc = "NACK received after sending a data byte.\n\nValue on reset: 0"]
|
||||
#[derive(Clone, Copy, Debug, PartialEq)]
|
||||
pub enum DNACK_A {
|
||||
#[doc = "0: Error not present."]
|
||||
NOT_PRESENT = 0,
|
||||
#[doc = "1: Error present."]
|
||||
PRESENT = 1,
|
||||
}
|
||||
impl From<DNACK_A> for bool {
|
||||
#[inline(always)]
|
||||
fn from(variant: DNACK_A) -> Self {
|
||||
variant as u8 != 0
|
||||
}
|
||||
}
|
||||
impl DNACK_R {
|
||||
#[doc = "Get enumerated values variant"]
|
||||
#[inline(always)]
|
||||
pub fn variant(&self) -> DNACK_A {
|
||||
match self.bits {
|
||||
false => DNACK_A::NOT_PRESENT,
|
||||
true => DNACK_A::PRESENT,
|
||||
}
|
||||
}
|
||||
#[doc = "Checks if the value of the field is `NOT_PRESENT`"]
|
||||
#[inline(always)]
|
||||
pub fn is_not_present(&self) -> bool {
|
||||
*self == DNACK_A::NOT_PRESENT
|
||||
}
|
||||
#[doc = "Checks if the value of the field is `PRESENT`"]
|
||||
#[inline(always)]
|
||||
pub fn is_present(&self) -> bool {
|
||||
*self == DNACK_A::PRESENT
|
||||
}
|
||||
}
|
||||
#[doc = "NACK received after sending a data byte.\n\nValue on reset: 0"]
|
||||
#[derive(Clone, Copy, Debug, PartialEq)]
|
||||
pub enum DNACK_AW {
|
||||
#[doc = "1: Clear error on write."]
|
||||
CLEAR = 1,
|
||||
}
|
||||
impl From<DNACK_AW> for bool {
|
||||
#[inline(always)]
|
||||
fn from(variant: DNACK_AW) -> Self {
|
||||
variant as u8 != 0
|
||||
}
|
||||
}
|
||||
#[doc = "Field `DNACK` writer - NACK received after sending a data byte."]
|
||||
pub type DNACK_W<'a, const O: u8> = crate::BitWriter<'a, u32, ERRORSRC_SPEC, DNACK_AW, O>;
|
||||
impl<'a, const O: u8> DNACK_W<'a, O> {
|
||||
#[doc = "Clear error on write."]
|
||||
#[inline(always)]
|
||||
pub fn clear(self) -> &'a mut W {
|
||||
self.variant(DNACK_AW::CLEAR)
|
||||
}
|
||||
}
|
||||
impl R {
|
||||
#[doc = "Bit 0 - Byte received in RXD register before read of the last received byte (data loss)."]
|
||||
#[inline(always)]
|
||||
pub fn overrun(&self) -> OVERRUN_R {
|
||||
OVERRUN_R::new((self.bits & 1) != 0)
|
||||
}
|
||||
#[doc = "Bit 1 - NACK received after sending the address."]
|
||||
#[inline(always)]
|
||||
pub fn anack(&self) -> ANACK_R {
|
||||
ANACK_R::new(((self.bits >> 1) & 1) != 0)
|
||||
}
|
||||
#[doc = "Bit 2 - NACK received after sending a data byte."]
|
||||
#[inline(always)]
|
||||
pub fn dnack(&self) -> DNACK_R {
|
||||
DNACK_R::new(((self.bits >> 2) & 1) != 0)
|
||||
}
|
||||
}
|
||||
impl W {
|
||||
#[doc = "Bit 0 - Byte received in RXD register before read of the last received byte (data loss)."]
|
||||
#[inline(always)]
|
||||
pub fn overrun(&mut self) -> OVERRUN_W<0> {
|
||||
OVERRUN_W::new(self)
|
||||
}
|
||||
#[doc = "Bit 1 - NACK received after sending the address."]
|
||||
#[inline(always)]
|
||||
pub fn anack(&mut self) -> ANACK_W<1> {
|
||||
ANACK_W::new(self)
|
||||
}
|
||||
#[doc = "Bit 2 - NACK received after sending a data byte."]
|
||||
#[inline(always)]
|
||||
pub fn dnack(&mut self) -> DNACK_W<2> {
|
||||
DNACK_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 = "Two-wire error source. Write error field to 1 to clear error.\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 [errorsrc](index.html) module"]
|
||||
pub struct ERRORSRC_SPEC;
|
||||
impl crate::RegisterSpec for ERRORSRC_SPEC {
|
||||
type Ux = u32;
|
||||
}
|
||||
#[doc = "`read()` method returns [errorsrc::R](R) reader structure"]
|
||||
impl crate::Readable for ERRORSRC_SPEC {
|
||||
type Reader = R;
|
||||
}
|
||||
#[doc = "`write(|w| ..)` method takes [errorsrc::W](W) writer structure"]
|
||||
impl crate::Writable for ERRORSRC_SPEC {
|
||||
type Writer = W;
|
||||
}
|
||||
#[doc = "`reset()` method sets ERRORSRC to value 0"]
|
||||
impl crate::Resettable for ERRORSRC_SPEC {
|
||||
#[inline(always)]
|
||||
fn reset_value() -> Self::Ux {
|
||||
0
|
||||
}
|
||||
}
|
||||
+64
@@ -0,0 +1,64 @@
|
||||
#[doc = "Register `EVENTS_BB` reader"]
|
||||
pub struct R(crate::R<EVENTS_BB_SPEC>);
|
||||
impl core::ops::Deref for R {
|
||||
type Target = crate::R<EVENTS_BB_SPEC>;
|
||||
#[inline(always)]
|
||||
fn deref(&self) -> &Self::Target {
|
||||
&self.0
|
||||
}
|
||||
}
|
||||
impl From<crate::R<EVENTS_BB_SPEC>> for R {
|
||||
#[inline(always)]
|
||||
fn from(reader: crate::R<EVENTS_BB_SPEC>) -> Self {
|
||||
R(reader)
|
||||
}
|
||||
}
|
||||
#[doc = "Register `EVENTS_BB` writer"]
|
||||
pub struct W(crate::W<EVENTS_BB_SPEC>);
|
||||
impl core::ops::Deref for W {
|
||||
type Target = crate::W<EVENTS_BB_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_BB_SPEC>> for W {
|
||||
#[inline(always)]
|
||||
fn from(writer: crate::W<EVENTS_BB_SPEC>) -> Self {
|
||||
W(writer)
|
||||
}
|
||||
}
|
||||
impl W {
|
||||
#[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 = "Two-wire byte boundary.\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_bb](index.html) module"]
|
||||
pub struct EVENTS_BB_SPEC;
|
||||
impl crate::RegisterSpec for EVENTS_BB_SPEC {
|
||||
type Ux = u32;
|
||||
}
|
||||
#[doc = "`read()` method returns [events_bb::R](R) reader structure"]
|
||||
impl crate::Readable for EVENTS_BB_SPEC {
|
||||
type Reader = R;
|
||||
}
|
||||
#[doc = "`write(|w| ..)` method takes [events_bb::W](W) writer structure"]
|
||||
impl crate::Writable for EVENTS_BB_SPEC {
|
||||
type Writer = W;
|
||||
}
|
||||
#[doc = "`reset()` method sets EVENTS_BB to value 0"]
|
||||
impl crate::Resettable for EVENTS_BB_SPEC {
|
||||
#[inline(always)]
|
||||
fn reset_value() -> Self::Ux {
|
||||
0
|
||||
}
|
||||
}
|
||||
+64
@@ -0,0 +1,64 @@
|
||||
#[doc = "Register `EVENTS_ERROR` reader"]
|
||||
pub struct R(crate::R<EVENTS_ERROR_SPEC>);
|
||||
impl core::ops::Deref for R {
|
||||
type Target = crate::R<EVENTS_ERROR_SPEC>;
|
||||
#[inline(always)]
|
||||
fn deref(&self) -> &Self::Target {
|
||||
&self.0
|
||||
}
|
||||
}
|
||||
impl From<crate::R<EVENTS_ERROR_SPEC>> for R {
|
||||
#[inline(always)]
|
||||
fn from(reader: crate::R<EVENTS_ERROR_SPEC>) -> Self {
|
||||
R(reader)
|
||||
}
|
||||
}
|
||||
#[doc = "Register `EVENTS_ERROR` writer"]
|
||||
pub struct W(crate::W<EVENTS_ERROR_SPEC>);
|
||||
impl core::ops::Deref for W {
|
||||
type Target = crate::W<EVENTS_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_ERROR_SPEC>> for W {
|
||||
#[inline(always)]
|
||||
fn from(writer: crate::W<EVENTS_ERROR_SPEC>) -> Self {
|
||||
W(writer)
|
||||
}
|
||||
}
|
||||
impl W {
|
||||
#[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 = "Two-wire error detected.\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_error](index.html) module"]
|
||||
pub struct EVENTS_ERROR_SPEC;
|
||||
impl crate::RegisterSpec for EVENTS_ERROR_SPEC {
|
||||
type Ux = u32;
|
||||
}
|
||||
#[doc = "`read()` method returns [events_error::R](R) reader structure"]
|
||||
impl crate::Readable for EVENTS_ERROR_SPEC {
|
||||
type Reader = R;
|
||||
}
|
||||
#[doc = "`write(|w| ..)` method takes [events_error::W](W) writer structure"]
|
||||
impl crate::Writable for EVENTS_ERROR_SPEC {
|
||||
type Writer = W;
|
||||
}
|
||||
#[doc = "`reset()` method sets EVENTS_ERROR to value 0"]
|
||||
impl crate::Resettable for EVENTS_ERROR_SPEC {
|
||||
#[inline(always)]
|
||||
fn reset_value() -> Self::Ux {
|
||||
0
|
||||
}
|
||||
}
|
||||
+64
@@ -0,0 +1,64 @@
|
||||
#[doc = "Register `EVENTS_RXDREADY` reader"]
|
||||
pub struct R(crate::R<EVENTS_RXDREADY_SPEC>);
|
||||
impl core::ops::Deref for R {
|
||||
type Target = crate::R<EVENTS_RXDREADY_SPEC>;
|
||||
#[inline(always)]
|
||||
fn deref(&self) -> &Self::Target {
|
||||
&self.0
|
||||
}
|
||||
}
|
||||
impl From<crate::R<EVENTS_RXDREADY_SPEC>> for R {
|
||||
#[inline(always)]
|
||||
fn from(reader: crate::R<EVENTS_RXDREADY_SPEC>) -> Self {
|
||||
R(reader)
|
||||
}
|
||||
}
|
||||
#[doc = "Register `EVENTS_RXDREADY` writer"]
|
||||
pub struct W(crate::W<EVENTS_RXDREADY_SPEC>);
|
||||
impl core::ops::Deref for W {
|
||||
type Target = crate::W<EVENTS_RXDREADY_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_RXDREADY_SPEC>> for W {
|
||||
#[inline(always)]
|
||||
fn from(writer: crate::W<EVENTS_RXDREADY_SPEC>) -> Self {
|
||||
W(writer)
|
||||
}
|
||||
}
|
||||
impl W {
|
||||
#[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 = "Two-wire ready to deliver new RXD byte received.\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_rxdready](index.html) module"]
|
||||
pub struct EVENTS_RXDREADY_SPEC;
|
||||
impl crate::RegisterSpec for EVENTS_RXDREADY_SPEC {
|
||||
type Ux = u32;
|
||||
}
|
||||
#[doc = "`read()` method returns [events_rxdready::R](R) reader structure"]
|
||||
impl crate::Readable for EVENTS_RXDREADY_SPEC {
|
||||
type Reader = R;
|
||||
}
|
||||
#[doc = "`write(|w| ..)` method takes [events_rxdready::W](W) writer structure"]
|
||||
impl crate::Writable for EVENTS_RXDREADY_SPEC {
|
||||
type Writer = W;
|
||||
}
|
||||
#[doc = "`reset()` method sets EVENTS_RXDREADY to value 0"]
|
||||
impl crate::Resettable for EVENTS_RXDREADY_SPEC {
|
||||
#[inline(always)]
|
||||
fn reset_value() -> Self::Ux {
|
||||
0
|
||||
}
|
||||
}
|
||||
+64
@@ -0,0 +1,64 @@
|
||||
#[doc = "Register `EVENTS_STOPPED` reader"]
|
||||
pub struct R(crate::R<EVENTS_STOPPED_SPEC>);
|
||||
impl core::ops::Deref for R {
|
||||
type Target = crate::R<EVENTS_STOPPED_SPEC>;
|
||||
#[inline(always)]
|
||||
fn deref(&self) -> &Self::Target {
|
||||
&self.0
|
||||
}
|
||||
}
|
||||
impl From<crate::R<EVENTS_STOPPED_SPEC>> for R {
|
||||
#[inline(always)]
|
||||
fn from(reader: crate::R<EVENTS_STOPPED_SPEC>) -> Self {
|
||||
R(reader)
|
||||
}
|
||||
}
|
||||
#[doc = "Register `EVENTS_STOPPED` writer"]
|
||||
pub struct W(crate::W<EVENTS_STOPPED_SPEC>);
|
||||
impl core::ops::Deref for W {
|
||||
type Target = crate::W<EVENTS_STOPPED_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_STOPPED_SPEC>> for W {
|
||||
#[inline(always)]
|
||||
fn from(writer: crate::W<EVENTS_STOPPED_SPEC>) -> Self {
|
||||
W(writer)
|
||||
}
|
||||
}
|
||||
impl W {
|
||||
#[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 = "Two-wire stopped.\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_stopped](index.html) module"]
|
||||
pub struct EVENTS_STOPPED_SPEC;
|
||||
impl crate::RegisterSpec for EVENTS_STOPPED_SPEC {
|
||||
type Ux = u32;
|
||||
}
|
||||
#[doc = "`read()` method returns [events_stopped::R](R) reader structure"]
|
||||
impl crate::Readable for EVENTS_STOPPED_SPEC {
|
||||
type Reader = R;
|
||||
}
|
||||
#[doc = "`write(|w| ..)` method takes [events_stopped::W](W) writer structure"]
|
||||
impl crate::Writable for EVENTS_STOPPED_SPEC {
|
||||
type Writer = W;
|
||||
}
|
||||
#[doc = "`reset()` method sets EVENTS_STOPPED to value 0"]
|
||||
impl crate::Resettable for EVENTS_STOPPED_SPEC {
|
||||
#[inline(always)]
|
||||
fn reset_value() -> Self::Ux {
|
||||
0
|
||||
}
|
||||
}
|
||||
+64
@@ -0,0 +1,64 @@
|
||||
#[doc = "Register `EVENTS_SUSPENDED` reader"]
|
||||
pub struct R(crate::R<EVENTS_SUSPENDED_SPEC>);
|
||||
impl core::ops::Deref for R {
|
||||
type Target = crate::R<EVENTS_SUSPENDED_SPEC>;
|
||||
#[inline(always)]
|
||||
fn deref(&self) -> &Self::Target {
|
||||
&self.0
|
||||
}
|
||||
}
|
||||
impl From<crate::R<EVENTS_SUSPENDED_SPEC>> for R {
|
||||
#[inline(always)]
|
||||
fn from(reader: crate::R<EVENTS_SUSPENDED_SPEC>) -> Self {
|
||||
R(reader)
|
||||
}
|
||||
}
|
||||
#[doc = "Register `EVENTS_SUSPENDED` writer"]
|
||||
pub struct W(crate::W<EVENTS_SUSPENDED_SPEC>);
|
||||
impl core::ops::Deref for W {
|
||||
type Target = crate::W<EVENTS_SUSPENDED_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_SUSPENDED_SPEC>> for W {
|
||||
#[inline(always)]
|
||||
fn from(writer: crate::W<EVENTS_SUSPENDED_SPEC>) -> Self {
|
||||
W(writer)
|
||||
}
|
||||
}
|
||||
impl W {
|
||||
#[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 = "Two-wire suspended.\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_suspended](index.html) module"]
|
||||
pub struct EVENTS_SUSPENDED_SPEC;
|
||||
impl crate::RegisterSpec for EVENTS_SUSPENDED_SPEC {
|
||||
type Ux = u32;
|
||||
}
|
||||
#[doc = "`read()` method returns [events_suspended::R](R) reader structure"]
|
||||
impl crate::Readable for EVENTS_SUSPENDED_SPEC {
|
||||
type Reader = R;
|
||||
}
|
||||
#[doc = "`write(|w| ..)` method takes [events_suspended::W](W) writer structure"]
|
||||
impl crate::Writable for EVENTS_SUSPENDED_SPEC {
|
||||
type Writer = W;
|
||||
}
|
||||
#[doc = "`reset()` method sets EVENTS_SUSPENDED to value 0"]
|
||||
impl crate::Resettable for EVENTS_SUSPENDED_SPEC {
|
||||
#[inline(always)]
|
||||
fn reset_value() -> Self::Ux {
|
||||
0
|
||||
}
|
||||
}
|
||||
+64
@@ -0,0 +1,64 @@
|
||||
#[doc = "Register `EVENTS_TXDSENT` reader"]
|
||||
pub struct R(crate::R<EVENTS_TXDSENT_SPEC>);
|
||||
impl core::ops::Deref for R {
|
||||
type Target = crate::R<EVENTS_TXDSENT_SPEC>;
|
||||
#[inline(always)]
|
||||
fn deref(&self) -> &Self::Target {
|
||||
&self.0
|
||||
}
|
||||
}
|
||||
impl From<crate::R<EVENTS_TXDSENT_SPEC>> for R {
|
||||
#[inline(always)]
|
||||
fn from(reader: crate::R<EVENTS_TXDSENT_SPEC>) -> Self {
|
||||
R(reader)
|
||||
}
|
||||
}
|
||||
#[doc = "Register `EVENTS_TXDSENT` writer"]
|
||||
pub struct W(crate::W<EVENTS_TXDSENT_SPEC>);
|
||||
impl core::ops::Deref for W {
|
||||
type Target = crate::W<EVENTS_TXDSENT_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_TXDSENT_SPEC>> for W {
|
||||
#[inline(always)]
|
||||
fn from(writer: crate::W<EVENTS_TXDSENT_SPEC>) -> Self {
|
||||
W(writer)
|
||||
}
|
||||
}
|
||||
impl W {
|
||||
#[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 = "Two-wire finished sending last TXD byte.\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_txdsent](index.html) module"]
|
||||
pub struct EVENTS_TXDSENT_SPEC;
|
||||
impl crate::RegisterSpec for EVENTS_TXDSENT_SPEC {
|
||||
type Ux = u32;
|
||||
}
|
||||
#[doc = "`read()` method returns [events_txdsent::R](R) reader structure"]
|
||||
impl crate::Readable for EVENTS_TXDSENT_SPEC {
|
||||
type Reader = R;
|
||||
}
|
||||
#[doc = "`write(|w| ..)` method takes [events_txdsent::W](W) writer structure"]
|
||||
impl crate::Writable for EVENTS_TXDSENT_SPEC {
|
||||
type Writer = W;
|
||||
}
|
||||
#[doc = "`reset()` method sets EVENTS_TXDSENT to value 0"]
|
||||
impl crate::Resettable for EVENTS_TXDSENT_SPEC {
|
||||
#[inline(always)]
|
||||
fn reset_value() -> Self::Ux {
|
||||
0
|
||||
}
|
||||
}
|
||||
+142
@@ -0,0 +1,142 @@
|
||||
#[doc = "Register `FREQUENCY` reader"]
|
||||
pub struct R(crate::R<FREQUENCY_SPEC>);
|
||||
impl core::ops::Deref for R {
|
||||
type Target = crate::R<FREQUENCY_SPEC>;
|
||||
#[inline(always)]
|
||||
fn deref(&self) -> &Self::Target {
|
||||
&self.0
|
||||
}
|
||||
}
|
||||
impl From<crate::R<FREQUENCY_SPEC>> for R {
|
||||
#[inline(always)]
|
||||
fn from(reader: crate::R<FREQUENCY_SPEC>) -> Self {
|
||||
R(reader)
|
||||
}
|
||||
}
|
||||
#[doc = "Register `FREQUENCY` writer"]
|
||||
pub struct W(crate::W<FREQUENCY_SPEC>);
|
||||
impl core::ops::Deref for W {
|
||||
type Target = crate::W<FREQUENCY_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<FREQUENCY_SPEC>> for W {
|
||||
#[inline(always)]
|
||||
fn from(writer: crate::W<FREQUENCY_SPEC>) -> Self {
|
||||
W(writer)
|
||||
}
|
||||
}
|
||||
#[doc = "Field `FREQUENCY` reader - Two-wire master clock frequency."]
|
||||
pub type FREQUENCY_R = crate::FieldReader<u32, FREQUENCY_A>;
|
||||
#[doc = "Two-wire master clock frequency.\n\nValue on reset: 67108864"]
|
||||
#[derive(Clone, Copy, Debug, PartialEq)]
|
||||
#[repr(u32)]
|
||||
pub enum FREQUENCY_A {
|
||||
#[doc = "26738688: 100 kbps."]
|
||||
K100 = 26738688,
|
||||
#[doc = "67108864: 250 kbps."]
|
||||
K250 = 67108864,
|
||||
#[doc = "107479040: 400 kbps (actual rate 410.256 kbps)."]
|
||||
K400 = 107479040,
|
||||
}
|
||||
impl From<FREQUENCY_A> for u32 {
|
||||
#[inline(always)]
|
||||
fn from(variant: FREQUENCY_A) -> Self {
|
||||
variant as _
|
||||
}
|
||||
}
|
||||
impl FREQUENCY_R {
|
||||
#[doc = "Get enumerated values variant"]
|
||||
#[inline(always)]
|
||||
pub fn variant(&self) -> Option<FREQUENCY_A> {
|
||||
match self.bits {
|
||||
26738688 => Some(FREQUENCY_A::K100),
|
||||
67108864 => Some(FREQUENCY_A::K250),
|
||||
107479040 => Some(FREQUENCY_A::K400),
|
||||
_ => None,
|
||||
}
|
||||
}
|
||||
#[doc = "Checks if the value of the field is `K100`"]
|
||||
#[inline(always)]
|
||||
pub fn is_k100(&self) -> bool {
|
||||
*self == FREQUENCY_A::K100
|
||||
}
|
||||
#[doc = "Checks if the value of the field is `K250`"]
|
||||
#[inline(always)]
|
||||
pub fn is_k250(&self) -> bool {
|
||||
*self == FREQUENCY_A::K250
|
||||
}
|
||||
#[doc = "Checks if the value of the field is `K400`"]
|
||||
#[inline(always)]
|
||||
pub fn is_k400(&self) -> bool {
|
||||
*self == FREQUENCY_A::K400
|
||||
}
|
||||
}
|
||||
#[doc = "Field `FREQUENCY` writer - Two-wire master clock frequency."]
|
||||
pub type FREQUENCY_W<'a, const O: u8> =
|
||||
crate::FieldWriter<'a, u32, FREQUENCY_SPEC, u32, FREQUENCY_A, 32, O>;
|
||||
impl<'a, const O: u8> FREQUENCY_W<'a, O> {
|
||||
#[doc = "100 kbps."]
|
||||
#[inline(always)]
|
||||
pub fn k100(self) -> &'a mut W {
|
||||
self.variant(FREQUENCY_A::K100)
|
||||
}
|
||||
#[doc = "250 kbps."]
|
||||
#[inline(always)]
|
||||
pub fn k250(self) -> &'a mut W {
|
||||
self.variant(FREQUENCY_A::K250)
|
||||
}
|
||||
#[doc = "400 kbps (actual rate 410.256 kbps)."]
|
||||
#[inline(always)]
|
||||
pub fn k400(self) -> &'a mut W {
|
||||
self.variant(FREQUENCY_A::K400)
|
||||
}
|
||||
}
|
||||
impl R {
|
||||
#[doc = "Bits 0:31 - Two-wire master clock frequency."]
|
||||
#[inline(always)]
|
||||
pub fn frequency(&self) -> FREQUENCY_R {
|
||||
FREQUENCY_R::new(self.bits)
|
||||
}
|
||||
}
|
||||
impl W {
|
||||
#[doc = "Bits 0:31 - Two-wire master clock frequency."]
|
||||
#[inline(always)]
|
||||
pub fn frequency(&mut self) -> FREQUENCY_W<0> {
|
||||
FREQUENCY_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 = "Two-wire frequency.\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 [frequency](index.html) module"]
|
||||
pub struct FREQUENCY_SPEC;
|
||||
impl crate::RegisterSpec for FREQUENCY_SPEC {
|
||||
type Ux = u32;
|
||||
}
|
||||
#[doc = "`read()` method returns [frequency::R](R) reader structure"]
|
||||
impl crate::Readable for FREQUENCY_SPEC {
|
||||
type Reader = R;
|
||||
}
|
||||
#[doc = "`write(|w| ..)` method takes [frequency::W](W) writer structure"]
|
||||
impl crate::Writable for FREQUENCY_SPEC {
|
||||
type Writer = W;
|
||||
}
|
||||
#[doc = "`reset()` method sets FREQUENCY to value 0x0400_0000"]
|
||||
impl crate::Resettable for FREQUENCY_SPEC {
|
||||
#[inline(always)]
|
||||
fn reset_value() -> Self::Ux {
|
||||
0x0400_0000
|
||||
}
|
||||
}
|
||||
+468
@@ -0,0 +1,468 @@
|
||||
#[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 `STOPPED` reader - Disable interrupt on STOPPED event."]
|
||||
pub type STOPPED_R = crate::BitReader<STOPPED_A>;
|
||||
#[doc = "Disable interrupt on STOPPED event.\n\nValue on reset: 0"]
|
||||
#[derive(Clone, Copy, Debug, PartialEq)]
|
||||
pub enum STOPPED_A {
|
||||
#[doc = "0: Interrupt disabled."]
|
||||
DISABLED = 0,
|
||||
#[doc = "1: Interrupt enabled."]
|
||||
ENABLED = 1,
|
||||
}
|
||||
impl From<STOPPED_A> for bool {
|
||||
#[inline(always)]
|
||||
fn from(variant: STOPPED_A) -> Self {
|
||||
variant as u8 != 0
|
||||
}
|
||||
}
|
||||
impl STOPPED_R {
|
||||
#[doc = "Get enumerated values variant"]
|
||||
#[inline(always)]
|
||||
pub fn variant(&self) -> STOPPED_A {
|
||||
match self.bits {
|
||||
false => STOPPED_A::DISABLED,
|
||||
true => STOPPED_A::ENABLED,
|
||||
}
|
||||
}
|
||||
#[doc = "Checks if the value of the field is `DISABLED`"]
|
||||
#[inline(always)]
|
||||
pub fn is_disabled(&self) -> bool {
|
||||
*self == STOPPED_A::DISABLED
|
||||
}
|
||||
#[doc = "Checks if the value of the field is `ENABLED`"]
|
||||
#[inline(always)]
|
||||
pub fn is_enabled(&self) -> bool {
|
||||
*self == STOPPED_A::ENABLED
|
||||
}
|
||||
}
|
||||
#[doc = "Disable interrupt on STOPPED event.\n\nValue on reset: 0"]
|
||||
#[derive(Clone, Copy, Debug, PartialEq)]
|
||||
pub enum STOPPED_AW {
|
||||
#[doc = "1: Disable interrupt on write."]
|
||||
CLEAR = 1,
|
||||
}
|
||||
impl From<STOPPED_AW> for bool {
|
||||
#[inline(always)]
|
||||
fn from(variant: STOPPED_AW) -> Self {
|
||||
variant as u8 != 0
|
||||
}
|
||||
}
|
||||
#[doc = "Field `STOPPED` writer - Disable interrupt on STOPPED event."]
|
||||
pub type STOPPED_W<'a, const O: u8> = crate::BitWriter<'a, u32, INTENCLR_SPEC, STOPPED_AW, O>;
|
||||
impl<'a, const O: u8> STOPPED_W<'a, O> {
|
||||
#[doc = "Disable interrupt on write."]
|
||||
#[inline(always)]
|
||||
pub fn clear(self) -> &'a mut W {
|
||||
self.variant(STOPPED_AW::CLEAR)
|
||||
}
|
||||
}
|
||||
#[doc = "Field `RXDREADY` reader - Disable interrupt on RXDREADY event."]
|
||||
pub type RXDREADY_R = crate::BitReader<RXDREADY_A>;
|
||||
#[doc = "Disable interrupt on RXDREADY event.\n\nValue on reset: 0"]
|
||||
#[derive(Clone, Copy, Debug, PartialEq)]
|
||||
pub enum RXDREADY_A {
|
||||
#[doc = "0: Interrupt disabled."]
|
||||
DISABLED = 0,
|
||||
#[doc = "1: Interrupt enabled."]
|
||||
ENABLED = 1,
|
||||
}
|
||||
impl From<RXDREADY_A> for bool {
|
||||
#[inline(always)]
|
||||
fn from(variant: RXDREADY_A) -> Self {
|
||||
variant as u8 != 0
|
||||
}
|
||||
}
|
||||
impl RXDREADY_R {
|
||||
#[doc = "Get enumerated values variant"]
|
||||
#[inline(always)]
|
||||
pub fn variant(&self) -> RXDREADY_A {
|
||||
match self.bits {
|
||||
false => RXDREADY_A::DISABLED,
|
||||
true => RXDREADY_A::ENABLED,
|
||||
}
|
||||
}
|
||||
#[doc = "Checks if the value of the field is `DISABLED`"]
|
||||
#[inline(always)]
|
||||
pub fn is_disabled(&self) -> bool {
|
||||
*self == RXDREADY_A::DISABLED
|
||||
}
|
||||
#[doc = "Checks if the value of the field is `ENABLED`"]
|
||||
#[inline(always)]
|
||||
pub fn is_enabled(&self) -> bool {
|
||||
*self == RXDREADY_A::ENABLED
|
||||
}
|
||||
}
|
||||
#[doc = "Disable interrupt on RXDREADY event.\n\nValue on reset: 0"]
|
||||
#[derive(Clone, Copy, Debug, PartialEq)]
|
||||
pub enum RXDREADY_AW {
|
||||
#[doc = "1: Disable interrupt on write."]
|
||||
CLEAR = 1,
|
||||
}
|
||||
impl From<RXDREADY_AW> for bool {
|
||||
#[inline(always)]
|
||||
fn from(variant: RXDREADY_AW) -> Self {
|
||||
variant as u8 != 0
|
||||
}
|
||||
}
|
||||
#[doc = "Field `RXDREADY` writer - Disable interrupt on RXDREADY event."]
|
||||
pub type RXDREADY_W<'a, const O: u8> = crate::BitWriter<'a, u32, INTENCLR_SPEC, RXDREADY_AW, O>;
|
||||
impl<'a, const O: u8> RXDREADY_W<'a, O> {
|
||||
#[doc = "Disable interrupt on write."]
|
||||
#[inline(always)]
|
||||
pub fn clear(self) -> &'a mut W {
|
||||
self.variant(RXDREADY_AW::CLEAR)
|
||||
}
|
||||
}
|
||||
#[doc = "Field `TXDSENT` reader - Disable interrupt on TXDSENT event."]
|
||||
pub type TXDSENT_R = crate::BitReader<TXDSENT_A>;
|
||||
#[doc = "Disable interrupt on TXDSENT event.\n\nValue on reset: 0"]
|
||||
#[derive(Clone, Copy, Debug, PartialEq)]
|
||||
pub enum TXDSENT_A {
|
||||
#[doc = "0: Interrupt disabled."]
|
||||
DISABLED = 0,
|
||||
#[doc = "1: Interrupt enabled."]
|
||||
ENABLED = 1,
|
||||
}
|
||||
impl From<TXDSENT_A> for bool {
|
||||
#[inline(always)]
|
||||
fn from(variant: TXDSENT_A) -> Self {
|
||||
variant as u8 != 0
|
||||
}
|
||||
}
|
||||
impl TXDSENT_R {
|
||||
#[doc = "Get enumerated values variant"]
|
||||
#[inline(always)]
|
||||
pub fn variant(&self) -> TXDSENT_A {
|
||||
match self.bits {
|
||||
false => TXDSENT_A::DISABLED,
|
||||
true => TXDSENT_A::ENABLED,
|
||||
}
|
||||
}
|
||||
#[doc = "Checks if the value of the field is `DISABLED`"]
|
||||
#[inline(always)]
|
||||
pub fn is_disabled(&self) -> bool {
|
||||
*self == TXDSENT_A::DISABLED
|
||||
}
|
||||
#[doc = "Checks if the value of the field is `ENABLED`"]
|
||||
#[inline(always)]
|
||||
pub fn is_enabled(&self) -> bool {
|
||||
*self == TXDSENT_A::ENABLED
|
||||
}
|
||||
}
|
||||
#[doc = "Disable interrupt on TXDSENT event.\n\nValue on reset: 0"]
|
||||
#[derive(Clone, Copy, Debug, PartialEq)]
|
||||
pub enum TXDSENT_AW {
|
||||
#[doc = "1: Disable interrupt on write."]
|
||||
CLEAR = 1,
|
||||
}
|
||||
impl From<TXDSENT_AW> for bool {
|
||||
#[inline(always)]
|
||||
fn from(variant: TXDSENT_AW) -> Self {
|
||||
variant as u8 != 0
|
||||
}
|
||||
}
|
||||
#[doc = "Field `TXDSENT` writer - Disable interrupt on TXDSENT event."]
|
||||
pub type TXDSENT_W<'a, const O: u8> = crate::BitWriter<'a, u32, INTENCLR_SPEC, TXDSENT_AW, O>;
|
||||
impl<'a, const O: u8> TXDSENT_W<'a, O> {
|
||||
#[doc = "Disable interrupt on write."]
|
||||
#[inline(always)]
|
||||
pub fn clear(self) -> &'a mut W {
|
||||
self.variant(TXDSENT_AW::CLEAR)
|
||||
}
|
||||
}
|
||||
#[doc = "Field `ERROR` reader - Disable interrupt on ERROR event."]
|
||||
pub type ERROR_R = crate::BitReader<ERROR_A>;
|
||||
#[doc = "Disable interrupt on ERROR event.\n\nValue on reset: 0"]
|
||||
#[derive(Clone, Copy, Debug, PartialEq)]
|
||||
pub enum ERROR_A {
|
||||
#[doc = "0: Interrupt disabled."]
|
||||
DISABLED = 0,
|
||||
#[doc = "1: Interrupt enabled."]
|
||||
ENABLED = 1,
|
||||
}
|
||||
impl From<ERROR_A> for bool {
|
||||
#[inline(always)]
|
||||
fn from(variant: ERROR_A) -> Self {
|
||||
variant as u8 != 0
|
||||
}
|
||||
}
|
||||
impl ERROR_R {
|
||||
#[doc = "Get enumerated values variant"]
|
||||
#[inline(always)]
|
||||
pub fn variant(&self) -> ERROR_A {
|
||||
match self.bits {
|
||||
false => ERROR_A::DISABLED,
|
||||
true => ERROR_A::ENABLED,
|
||||
}
|
||||
}
|
||||
#[doc = "Checks if the value of the field is `DISABLED`"]
|
||||
#[inline(always)]
|
||||
pub fn is_disabled(&self) -> bool {
|
||||
*self == ERROR_A::DISABLED
|
||||
}
|
||||
#[doc = "Checks if the value of the field is `ENABLED`"]
|
||||
#[inline(always)]
|
||||
pub fn is_enabled(&self) -> bool {
|
||||
*self == ERROR_A::ENABLED
|
||||
}
|
||||
}
|
||||
#[doc = "Disable interrupt on ERROR event.\n\nValue on reset: 0"]
|
||||
#[derive(Clone, Copy, Debug, PartialEq)]
|
||||
pub enum ERROR_AW {
|
||||
#[doc = "1: Disable interrupt on write."]
|
||||
CLEAR = 1,
|
||||
}
|
||||
impl From<ERROR_AW> for bool {
|
||||
#[inline(always)]
|
||||
fn from(variant: ERROR_AW) -> Self {
|
||||
variant as u8 != 0
|
||||
}
|
||||
}
|
||||
#[doc = "Field `ERROR` writer - Disable interrupt on ERROR event."]
|
||||
pub type ERROR_W<'a, const O: u8> = crate::BitWriter<'a, u32, INTENCLR_SPEC, ERROR_AW, O>;
|
||||
impl<'a, const O: u8> ERROR_W<'a, O> {
|
||||
#[doc = "Disable interrupt on write."]
|
||||
#[inline(always)]
|
||||
pub fn clear(self) -> &'a mut W {
|
||||
self.variant(ERROR_AW::CLEAR)
|
||||
}
|
||||
}
|
||||
#[doc = "Field `BB` reader - Disable interrupt on BB event."]
|
||||
pub type BB_R = crate::BitReader<BB_A>;
|
||||
#[doc = "Disable interrupt on BB event.\n\nValue on reset: 0"]
|
||||
#[derive(Clone, Copy, Debug, PartialEq)]
|
||||
pub enum BB_A {
|
||||
#[doc = "0: Interrupt disabled."]
|
||||
DISABLED = 0,
|
||||
#[doc = "1: Interrupt enabled."]
|
||||
ENABLED = 1,
|
||||
}
|
||||
impl From<BB_A> for bool {
|
||||
#[inline(always)]
|
||||
fn from(variant: BB_A) -> Self {
|
||||
variant as u8 != 0
|
||||
}
|
||||
}
|
||||
impl BB_R {
|
||||
#[doc = "Get enumerated values variant"]
|
||||
#[inline(always)]
|
||||
pub fn variant(&self) -> BB_A {
|
||||
match self.bits {
|
||||
false => BB_A::DISABLED,
|
||||
true => BB_A::ENABLED,
|
||||
}
|
||||
}
|
||||
#[doc = "Checks if the value of the field is `DISABLED`"]
|
||||
#[inline(always)]
|
||||
pub fn is_disabled(&self) -> bool {
|
||||
*self == BB_A::DISABLED
|
||||
}
|
||||
#[doc = "Checks if the value of the field is `ENABLED`"]
|
||||
#[inline(always)]
|
||||
pub fn is_enabled(&self) -> bool {
|
||||
*self == BB_A::ENABLED
|
||||
}
|
||||
}
|
||||
#[doc = "Disable interrupt on BB event.\n\nValue on reset: 0"]
|
||||
#[derive(Clone, Copy, Debug, PartialEq)]
|
||||
pub enum BB_AW {
|
||||
#[doc = "1: Disable interrupt on write."]
|
||||
CLEAR = 1,
|
||||
}
|
||||
impl From<BB_AW> for bool {
|
||||
#[inline(always)]
|
||||
fn from(variant: BB_AW) -> Self {
|
||||
variant as u8 != 0
|
||||
}
|
||||
}
|
||||
#[doc = "Field `BB` writer - Disable interrupt on BB event."]
|
||||
pub type BB_W<'a, const O: u8> = crate::BitWriter<'a, u32, INTENCLR_SPEC, BB_AW, O>;
|
||||
impl<'a, const O: u8> BB_W<'a, O> {
|
||||
#[doc = "Disable interrupt on write."]
|
||||
#[inline(always)]
|
||||
pub fn clear(self) -> &'a mut W {
|
||||
self.variant(BB_AW::CLEAR)
|
||||
}
|
||||
}
|
||||
#[doc = "Field `SUSPENDED` reader - Disable interrupt on SUSPENDED event."]
|
||||
pub type SUSPENDED_R = crate::BitReader<SUSPENDED_A>;
|
||||
#[doc = "Disable interrupt on SUSPENDED event.\n\nValue on reset: 0"]
|
||||
#[derive(Clone, Copy, Debug, PartialEq)]
|
||||
pub enum SUSPENDED_A {
|
||||
#[doc = "0: Interrupt disabled."]
|
||||
DISABLED = 0,
|
||||
#[doc = "1: Interrupt enabled."]
|
||||
ENABLED = 1,
|
||||
}
|
||||
impl From<SUSPENDED_A> for bool {
|
||||
#[inline(always)]
|
||||
fn from(variant: SUSPENDED_A) -> Self {
|
||||
variant as u8 != 0
|
||||
}
|
||||
}
|
||||
impl SUSPENDED_R {
|
||||
#[doc = "Get enumerated values variant"]
|
||||
#[inline(always)]
|
||||
pub fn variant(&self) -> SUSPENDED_A {
|
||||
match self.bits {
|
||||
false => SUSPENDED_A::DISABLED,
|
||||
true => SUSPENDED_A::ENABLED,
|
||||
}
|
||||
}
|
||||
#[doc = "Checks if the value of the field is `DISABLED`"]
|
||||
#[inline(always)]
|
||||
pub fn is_disabled(&self) -> bool {
|
||||
*self == SUSPENDED_A::DISABLED
|
||||
}
|
||||
#[doc = "Checks if the value of the field is `ENABLED`"]
|
||||
#[inline(always)]
|
||||
pub fn is_enabled(&self) -> bool {
|
||||
*self == SUSPENDED_A::ENABLED
|
||||
}
|
||||
}
|
||||
#[doc = "Disable interrupt on SUSPENDED event.\n\nValue on reset: 0"]
|
||||
#[derive(Clone, Copy, Debug, PartialEq)]
|
||||
pub enum SUSPENDED_AW {
|
||||
#[doc = "1: Disable interrupt on write."]
|
||||
CLEAR = 1,
|
||||
}
|
||||
impl From<SUSPENDED_AW> for bool {
|
||||
#[inline(always)]
|
||||
fn from(variant: SUSPENDED_AW) -> Self {
|
||||
variant as u8 != 0
|
||||
}
|
||||
}
|
||||
#[doc = "Field `SUSPENDED` writer - Disable interrupt on SUSPENDED event."]
|
||||
pub type SUSPENDED_W<'a, const O: u8> = crate::BitWriter<'a, u32, INTENCLR_SPEC, SUSPENDED_AW, O>;
|
||||
impl<'a, const O: u8> SUSPENDED_W<'a, O> {
|
||||
#[doc = "Disable interrupt on write."]
|
||||
#[inline(always)]
|
||||
pub fn clear(self) -> &'a mut W {
|
||||
self.variant(SUSPENDED_AW::CLEAR)
|
||||
}
|
||||
}
|
||||
impl R {
|
||||
#[doc = "Bit 1 - Disable interrupt on STOPPED event."]
|
||||
#[inline(always)]
|
||||
pub fn stopped(&self) -> STOPPED_R {
|
||||
STOPPED_R::new(((self.bits >> 1) & 1) != 0)
|
||||
}
|
||||
#[doc = "Bit 2 - Disable interrupt on RXDREADY event."]
|
||||
#[inline(always)]
|
||||
pub fn rxdready(&self) -> RXDREADY_R {
|
||||
RXDREADY_R::new(((self.bits >> 2) & 1) != 0)
|
||||
}
|
||||
#[doc = "Bit 7 - Disable interrupt on TXDSENT event."]
|
||||
#[inline(always)]
|
||||
pub fn txdsent(&self) -> TXDSENT_R {
|
||||
TXDSENT_R::new(((self.bits >> 7) & 1) != 0)
|
||||
}
|
||||
#[doc = "Bit 9 - Disable interrupt on ERROR event."]
|
||||
#[inline(always)]
|
||||
pub fn error(&self) -> ERROR_R {
|
||||
ERROR_R::new(((self.bits >> 9) & 1) != 0)
|
||||
}
|
||||
#[doc = "Bit 14 - Disable interrupt on BB event."]
|
||||
#[inline(always)]
|
||||
pub fn bb(&self) -> BB_R {
|
||||
BB_R::new(((self.bits >> 14) & 1) != 0)
|
||||
}
|
||||
#[doc = "Bit 18 - Disable interrupt on SUSPENDED event."]
|
||||
#[inline(always)]
|
||||
pub fn suspended(&self) -> SUSPENDED_R {
|
||||
SUSPENDED_R::new(((self.bits >> 18) & 1) != 0)
|
||||
}
|
||||
}
|
||||
impl W {
|
||||
#[doc = "Bit 1 - Disable interrupt on STOPPED event."]
|
||||
#[inline(always)]
|
||||
pub fn stopped(&mut self) -> STOPPED_W<1> {
|
||||
STOPPED_W::new(self)
|
||||
}
|
||||
#[doc = "Bit 2 - Disable interrupt on RXDREADY event."]
|
||||
#[inline(always)]
|
||||
pub fn rxdready(&mut self) -> RXDREADY_W<2> {
|
||||
RXDREADY_W::new(self)
|
||||
}
|
||||
#[doc = "Bit 7 - Disable interrupt on TXDSENT event."]
|
||||
#[inline(always)]
|
||||
pub fn txdsent(&mut self) -> TXDSENT_W<7> {
|
||||
TXDSENT_W::new(self)
|
||||
}
|
||||
#[doc = "Bit 9 - Disable interrupt on ERROR event."]
|
||||
#[inline(always)]
|
||||
pub fn error(&mut self) -> ERROR_W<9> {
|
||||
ERROR_W::new(self)
|
||||
}
|
||||
#[doc = "Bit 14 - Disable interrupt on BB event."]
|
||||
#[inline(always)]
|
||||
pub fn bb(&mut self) -> BB_W<14> {
|
||||
BB_W::new(self)
|
||||
}
|
||||
#[doc = "Bit 18 - Disable interrupt on SUSPENDED event."]
|
||||
#[inline(always)]
|
||||
pub fn suspended(&mut self) -> SUSPENDED_W<18> {
|
||||
SUSPENDED_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 = "Interrupt enable clear register.\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
|
||||
}
|
||||
}
|
||||
+468
@@ -0,0 +1,468 @@
|
||||
#[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 `STOPPED` reader - Enable interrupt on STOPPED event."]
|
||||
pub type STOPPED_R = crate::BitReader<STOPPED_A>;
|
||||
#[doc = "Enable interrupt on STOPPED event.\n\nValue on reset: 0"]
|
||||
#[derive(Clone, Copy, Debug, PartialEq)]
|
||||
pub enum STOPPED_A {
|
||||
#[doc = "0: Interrupt disabled."]
|
||||
DISABLED = 0,
|
||||
#[doc = "1: Interrupt enabled."]
|
||||
ENABLED = 1,
|
||||
}
|
||||
impl From<STOPPED_A> for bool {
|
||||
#[inline(always)]
|
||||
fn from(variant: STOPPED_A) -> Self {
|
||||
variant as u8 != 0
|
||||
}
|
||||
}
|
||||
impl STOPPED_R {
|
||||
#[doc = "Get enumerated values variant"]
|
||||
#[inline(always)]
|
||||
pub fn variant(&self) -> STOPPED_A {
|
||||
match self.bits {
|
||||
false => STOPPED_A::DISABLED,
|
||||
true => STOPPED_A::ENABLED,
|
||||
}
|
||||
}
|
||||
#[doc = "Checks if the value of the field is `DISABLED`"]
|
||||
#[inline(always)]
|
||||
pub fn is_disabled(&self) -> bool {
|
||||
*self == STOPPED_A::DISABLED
|
||||
}
|
||||
#[doc = "Checks if the value of the field is `ENABLED`"]
|
||||
#[inline(always)]
|
||||
pub fn is_enabled(&self) -> bool {
|
||||
*self == STOPPED_A::ENABLED
|
||||
}
|
||||
}
|
||||
#[doc = "Enable interrupt on STOPPED event.\n\nValue on reset: 0"]
|
||||
#[derive(Clone, Copy, Debug, PartialEq)]
|
||||
pub enum STOPPED_AW {
|
||||
#[doc = "1: Enable interrupt on write."]
|
||||
SET = 1,
|
||||
}
|
||||
impl From<STOPPED_AW> for bool {
|
||||
#[inline(always)]
|
||||
fn from(variant: STOPPED_AW) -> Self {
|
||||
variant as u8 != 0
|
||||
}
|
||||
}
|
||||
#[doc = "Field `STOPPED` writer - Enable interrupt on STOPPED event."]
|
||||
pub type STOPPED_W<'a, const O: u8> = crate::BitWriter<'a, u32, INTENSET_SPEC, STOPPED_AW, O>;
|
||||
impl<'a, const O: u8> STOPPED_W<'a, O> {
|
||||
#[doc = "Enable interrupt on write."]
|
||||
#[inline(always)]
|
||||
pub fn set(self) -> &'a mut W {
|
||||
self.variant(STOPPED_AW::SET)
|
||||
}
|
||||
}
|
||||
#[doc = "Field `RXDREADY` reader - Enable interrupt on READY event."]
|
||||
pub type RXDREADY_R = crate::BitReader<RXDREADY_A>;
|
||||
#[doc = "Enable interrupt on READY event.\n\nValue on reset: 0"]
|
||||
#[derive(Clone, Copy, Debug, PartialEq)]
|
||||
pub enum RXDREADY_A {
|
||||
#[doc = "0: Interrupt disabled."]
|
||||
DISABLED = 0,
|
||||
#[doc = "1: Interrupt enabled."]
|
||||
ENABLED = 1,
|
||||
}
|
||||
impl From<RXDREADY_A> for bool {
|
||||
#[inline(always)]
|
||||
fn from(variant: RXDREADY_A) -> Self {
|
||||
variant as u8 != 0
|
||||
}
|
||||
}
|
||||
impl RXDREADY_R {
|
||||
#[doc = "Get enumerated values variant"]
|
||||
#[inline(always)]
|
||||
pub fn variant(&self) -> RXDREADY_A {
|
||||
match self.bits {
|
||||
false => RXDREADY_A::DISABLED,
|
||||
true => RXDREADY_A::ENABLED,
|
||||
}
|
||||
}
|
||||
#[doc = "Checks if the value of the field is `DISABLED`"]
|
||||
#[inline(always)]
|
||||
pub fn is_disabled(&self) -> bool {
|
||||
*self == RXDREADY_A::DISABLED
|
||||
}
|
||||
#[doc = "Checks if the value of the field is `ENABLED`"]
|
||||
#[inline(always)]
|
||||
pub fn is_enabled(&self) -> bool {
|
||||
*self == RXDREADY_A::ENABLED
|
||||
}
|
||||
}
|
||||
#[doc = "Enable interrupt on READY event.\n\nValue on reset: 0"]
|
||||
#[derive(Clone, Copy, Debug, PartialEq)]
|
||||
pub enum RXDREADY_AW {
|
||||
#[doc = "1: Enable interrupt on write."]
|
||||
SET = 1,
|
||||
}
|
||||
impl From<RXDREADY_AW> for bool {
|
||||
#[inline(always)]
|
||||
fn from(variant: RXDREADY_AW) -> Self {
|
||||
variant as u8 != 0
|
||||
}
|
||||
}
|
||||
#[doc = "Field `RXDREADY` writer - Enable interrupt on READY event."]
|
||||
pub type RXDREADY_W<'a, const O: u8> = crate::BitWriter<'a, u32, INTENSET_SPEC, RXDREADY_AW, O>;
|
||||
impl<'a, const O: u8> RXDREADY_W<'a, O> {
|
||||
#[doc = "Enable interrupt on write."]
|
||||
#[inline(always)]
|
||||
pub fn set(self) -> &'a mut W {
|
||||
self.variant(RXDREADY_AW::SET)
|
||||
}
|
||||
}
|
||||
#[doc = "Field `TXDSENT` reader - Enable interrupt on TXDSENT event."]
|
||||
pub type TXDSENT_R = crate::BitReader<TXDSENT_A>;
|
||||
#[doc = "Enable interrupt on TXDSENT event.\n\nValue on reset: 0"]
|
||||
#[derive(Clone, Copy, Debug, PartialEq)]
|
||||
pub enum TXDSENT_A {
|
||||
#[doc = "0: Interrupt disabled."]
|
||||
DISABLED = 0,
|
||||
#[doc = "1: Interrupt enabled."]
|
||||
ENABLED = 1,
|
||||
}
|
||||
impl From<TXDSENT_A> for bool {
|
||||
#[inline(always)]
|
||||
fn from(variant: TXDSENT_A) -> Self {
|
||||
variant as u8 != 0
|
||||
}
|
||||
}
|
||||
impl TXDSENT_R {
|
||||
#[doc = "Get enumerated values variant"]
|
||||
#[inline(always)]
|
||||
pub fn variant(&self) -> TXDSENT_A {
|
||||
match self.bits {
|
||||
false => TXDSENT_A::DISABLED,
|
||||
true => TXDSENT_A::ENABLED,
|
||||
}
|
||||
}
|
||||
#[doc = "Checks if the value of the field is `DISABLED`"]
|
||||
#[inline(always)]
|
||||
pub fn is_disabled(&self) -> bool {
|
||||
*self == TXDSENT_A::DISABLED
|
||||
}
|
||||
#[doc = "Checks if the value of the field is `ENABLED`"]
|
||||
#[inline(always)]
|
||||
pub fn is_enabled(&self) -> bool {
|
||||
*self == TXDSENT_A::ENABLED
|
||||
}
|
||||
}
|
||||
#[doc = "Enable interrupt on TXDSENT event.\n\nValue on reset: 0"]
|
||||
#[derive(Clone, Copy, Debug, PartialEq)]
|
||||
pub enum TXDSENT_AW {
|
||||
#[doc = "1: Enable interrupt on write."]
|
||||
SET = 1,
|
||||
}
|
||||
impl From<TXDSENT_AW> for bool {
|
||||
#[inline(always)]
|
||||
fn from(variant: TXDSENT_AW) -> Self {
|
||||
variant as u8 != 0
|
||||
}
|
||||
}
|
||||
#[doc = "Field `TXDSENT` writer - Enable interrupt on TXDSENT event."]
|
||||
pub type TXDSENT_W<'a, const O: u8> = crate::BitWriter<'a, u32, INTENSET_SPEC, TXDSENT_AW, O>;
|
||||
impl<'a, const O: u8> TXDSENT_W<'a, O> {
|
||||
#[doc = "Enable interrupt on write."]
|
||||
#[inline(always)]
|
||||
pub fn set(self) -> &'a mut W {
|
||||
self.variant(TXDSENT_AW::SET)
|
||||
}
|
||||
}
|
||||
#[doc = "Field `ERROR` reader - Enable interrupt on ERROR event."]
|
||||
pub type ERROR_R = crate::BitReader<ERROR_A>;
|
||||
#[doc = "Enable interrupt on ERROR event.\n\nValue on reset: 0"]
|
||||
#[derive(Clone, Copy, Debug, PartialEq)]
|
||||
pub enum ERROR_A {
|
||||
#[doc = "0: Interrupt disabled."]
|
||||
DISABLED = 0,
|
||||
#[doc = "1: Interrupt enabled."]
|
||||
ENABLED = 1,
|
||||
}
|
||||
impl From<ERROR_A> for bool {
|
||||
#[inline(always)]
|
||||
fn from(variant: ERROR_A) -> Self {
|
||||
variant as u8 != 0
|
||||
}
|
||||
}
|
||||
impl ERROR_R {
|
||||
#[doc = "Get enumerated values variant"]
|
||||
#[inline(always)]
|
||||
pub fn variant(&self) -> ERROR_A {
|
||||
match self.bits {
|
||||
false => ERROR_A::DISABLED,
|
||||
true => ERROR_A::ENABLED,
|
||||
}
|
||||
}
|
||||
#[doc = "Checks if the value of the field is `DISABLED`"]
|
||||
#[inline(always)]
|
||||
pub fn is_disabled(&self) -> bool {
|
||||
*self == ERROR_A::DISABLED
|
||||
}
|
||||
#[doc = "Checks if the value of the field is `ENABLED`"]
|
||||
#[inline(always)]
|
||||
pub fn is_enabled(&self) -> bool {
|
||||
*self == ERROR_A::ENABLED
|
||||
}
|
||||
}
|
||||
#[doc = "Enable interrupt on ERROR event.\n\nValue on reset: 0"]
|
||||
#[derive(Clone, Copy, Debug, PartialEq)]
|
||||
pub enum ERROR_AW {
|
||||
#[doc = "1: Enable interrupt on write."]
|
||||
SET = 1,
|
||||
}
|
||||
impl From<ERROR_AW> for bool {
|
||||
#[inline(always)]
|
||||
fn from(variant: ERROR_AW) -> Self {
|
||||
variant as u8 != 0
|
||||
}
|
||||
}
|
||||
#[doc = "Field `ERROR` writer - Enable interrupt on ERROR event."]
|
||||
pub type ERROR_W<'a, const O: u8> = crate::BitWriter<'a, u32, INTENSET_SPEC, ERROR_AW, O>;
|
||||
impl<'a, const O: u8> ERROR_W<'a, O> {
|
||||
#[doc = "Enable interrupt on write."]
|
||||
#[inline(always)]
|
||||
pub fn set(self) -> &'a mut W {
|
||||
self.variant(ERROR_AW::SET)
|
||||
}
|
||||
}
|
||||
#[doc = "Field `BB` reader - Enable interrupt on BB event."]
|
||||
pub type BB_R = crate::BitReader<BB_A>;
|
||||
#[doc = "Enable interrupt on BB event.\n\nValue on reset: 0"]
|
||||
#[derive(Clone, Copy, Debug, PartialEq)]
|
||||
pub enum BB_A {
|
||||
#[doc = "0: Interrupt disabled."]
|
||||
DISABLED = 0,
|
||||
#[doc = "1: Interrupt enabled."]
|
||||
ENABLED = 1,
|
||||
}
|
||||
impl From<BB_A> for bool {
|
||||
#[inline(always)]
|
||||
fn from(variant: BB_A) -> Self {
|
||||
variant as u8 != 0
|
||||
}
|
||||
}
|
||||
impl BB_R {
|
||||
#[doc = "Get enumerated values variant"]
|
||||
#[inline(always)]
|
||||
pub fn variant(&self) -> BB_A {
|
||||
match self.bits {
|
||||
false => BB_A::DISABLED,
|
||||
true => BB_A::ENABLED,
|
||||
}
|
||||
}
|
||||
#[doc = "Checks if the value of the field is `DISABLED`"]
|
||||
#[inline(always)]
|
||||
pub fn is_disabled(&self) -> bool {
|
||||
*self == BB_A::DISABLED
|
||||
}
|
||||
#[doc = "Checks if the value of the field is `ENABLED`"]
|
||||
#[inline(always)]
|
||||
pub fn is_enabled(&self) -> bool {
|
||||
*self == BB_A::ENABLED
|
||||
}
|
||||
}
|
||||
#[doc = "Enable interrupt on BB event.\n\nValue on reset: 0"]
|
||||
#[derive(Clone, Copy, Debug, PartialEq)]
|
||||
pub enum BB_AW {
|
||||
#[doc = "1: Enable interrupt on write."]
|
||||
SET = 1,
|
||||
}
|
||||
impl From<BB_AW> for bool {
|
||||
#[inline(always)]
|
||||
fn from(variant: BB_AW) -> Self {
|
||||
variant as u8 != 0
|
||||
}
|
||||
}
|
||||
#[doc = "Field `BB` writer - Enable interrupt on BB event."]
|
||||
pub type BB_W<'a, const O: u8> = crate::BitWriter<'a, u32, INTENSET_SPEC, BB_AW, O>;
|
||||
impl<'a, const O: u8> BB_W<'a, O> {
|
||||
#[doc = "Enable interrupt on write."]
|
||||
#[inline(always)]
|
||||
pub fn set(self) -> &'a mut W {
|
||||
self.variant(BB_AW::SET)
|
||||
}
|
||||
}
|
||||
#[doc = "Field `SUSPENDED` reader - Enable interrupt on SUSPENDED event."]
|
||||
pub type SUSPENDED_R = crate::BitReader<SUSPENDED_A>;
|
||||
#[doc = "Enable interrupt on SUSPENDED event.\n\nValue on reset: 0"]
|
||||
#[derive(Clone, Copy, Debug, PartialEq)]
|
||||
pub enum SUSPENDED_A {
|
||||
#[doc = "0: Interrupt disabled."]
|
||||
DISABLED = 0,
|
||||
#[doc = "1: Interrupt enabled."]
|
||||
ENABLED = 1,
|
||||
}
|
||||
impl From<SUSPENDED_A> for bool {
|
||||
#[inline(always)]
|
||||
fn from(variant: SUSPENDED_A) -> Self {
|
||||
variant as u8 != 0
|
||||
}
|
||||
}
|
||||
impl SUSPENDED_R {
|
||||
#[doc = "Get enumerated values variant"]
|
||||
#[inline(always)]
|
||||
pub fn variant(&self) -> SUSPENDED_A {
|
||||
match self.bits {
|
||||
false => SUSPENDED_A::DISABLED,
|
||||
true => SUSPENDED_A::ENABLED,
|
||||
}
|
||||
}
|
||||
#[doc = "Checks if the value of the field is `DISABLED`"]
|
||||
#[inline(always)]
|
||||
pub fn is_disabled(&self) -> bool {
|
||||
*self == SUSPENDED_A::DISABLED
|
||||
}
|
||||
#[doc = "Checks if the value of the field is `ENABLED`"]
|
||||
#[inline(always)]
|
||||
pub fn is_enabled(&self) -> bool {
|
||||
*self == SUSPENDED_A::ENABLED
|
||||
}
|
||||
}
|
||||
#[doc = "Enable interrupt on SUSPENDED event.\n\nValue on reset: 0"]
|
||||
#[derive(Clone, Copy, Debug, PartialEq)]
|
||||
pub enum SUSPENDED_AW {
|
||||
#[doc = "1: Enable interrupt on write."]
|
||||
SET = 1,
|
||||
}
|
||||
impl From<SUSPENDED_AW> for bool {
|
||||
#[inline(always)]
|
||||
fn from(variant: SUSPENDED_AW) -> Self {
|
||||
variant as u8 != 0
|
||||
}
|
||||
}
|
||||
#[doc = "Field `SUSPENDED` writer - Enable interrupt on SUSPENDED event."]
|
||||
pub type SUSPENDED_W<'a, const O: u8> = crate::BitWriter<'a, u32, INTENSET_SPEC, SUSPENDED_AW, O>;
|
||||
impl<'a, const O: u8> SUSPENDED_W<'a, O> {
|
||||
#[doc = "Enable interrupt on write."]
|
||||
#[inline(always)]
|
||||
pub fn set(self) -> &'a mut W {
|
||||
self.variant(SUSPENDED_AW::SET)
|
||||
}
|
||||
}
|
||||
impl R {
|
||||
#[doc = "Bit 1 - Enable interrupt on STOPPED event."]
|
||||
#[inline(always)]
|
||||
pub fn stopped(&self) -> STOPPED_R {
|
||||
STOPPED_R::new(((self.bits >> 1) & 1) != 0)
|
||||
}
|
||||
#[doc = "Bit 2 - Enable interrupt on READY event."]
|
||||
#[inline(always)]
|
||||
pub fn rxdready(&self) -> RXDREADY_R {
|
||||
RXDREADY_R::new(((self.bits >> 2) & 1) != 0)
|
||||
}
|
||||
#[doc = "Bit 7 - Enable interrupt on TXDSENT event."]
|
||||
#[inline(always)]
|
||||
pub fn txdsent(&self) -> TXDSENT_R {
|
||||
TXDSENT_R::new(((self.bits >> 7) & 1) != 0)
|
||||
}
|
||||
#[doc = "Bit 9 - Enable interrupt on ERROR event."]
|
||||
#[inline(always)]
|
||||
pub fn error(&self) -> ERROR_R {
|
||||
ERROR_R::new(((self.bits >> 9) & 1) != 0)
|
||||
}
|
||||
#[doc = "Bit 14 - Enable interrupt on BB event."]
|
||||
#[inline(always)]
|
||||
pub fn bb(&self) -> BB_R {
|
||||
BB_R::new(((self.bits >> 14) & 1) != 0)
|
||||
}
|
||||
#[doc = "Bit 18 - Enable interrupt on SUSPENDED event."]
|
||||
#[inline(always)]
|
||||
pub fn suspended(&self) -> SUSPENDED_R {
|
||||
SUSPENDED_R::new(((self.bits >> 18) & 1) != 0)
|
||||
}
|
||||
}
|
||||
impl W {
|
||||
#[doc = "Bit 1 - Enable interrupt on STOPPED event."]
|
||||
#[inline(always)]
|
||||
pub fn stopped(&mut self) -> STOPPED_W<1> {
|
||||
STOPPED_W::new(self)
|
||||
}
|
||||
#[doc = "Bit 2 - Enable interrupt on READY event."]
|
||||
#[inline(always)]
|
||||
pub fn rxdready(&mut self) -> RXDREADY_W<2> {
|
||||
RXDREADY_W::new(self)
|
||||
}
|
||||
#[doc = "Bit 7 - Enable interrupt on TXDSENT event."]
|
||||
#[inline(always)]
|
||||
pub fn txdsent(&mut self) -> TXDSENT_W<7> {
|
||||
TXDSENT_W::new(self)
|
||||
}
|
||||
#[doc = "Bit 9 - Enable interrupt on ERROR event."]
|
||||
#[inline(always)]
|
||||
pub fn error(&mut self) -> ERROR_W<9> {
|
||||
ERROR_W::new(self)
|
||||
}
|
||||
#[doc = "Bit 14 - Enable interrupt on BB event."]
|
||||
#[inline(always)]
|
||||
pub fn bb(&mut self) -> BB_W<14> {
|
||||
BB_W::new(self)
|
||||
}
|
||||
#[doc = "Bit 18 - Enable interrupt on SUSPENDED event."]
|
||||
#[inline(always)]
|
||||
pub fn suspended(&mut self) -> SUSPENDED_W<18> {
|
||||
SUSPENDED_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 = "Interrupt enable set register.\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
|
||||
}
|
||||
}
|
||||
Vendored
+126
@@ -0,0 +1,126 @@
|
||||
#[doc = "Register `POWER` reader"]
|
||||
pub struct R(crate::R<POWER_SPEC>);
|
||||
impl core::ops::Deref for R {
|
||||
type Target = crate::R<POWER_SPEC>;
|
||||
#[inline(always)]
|
||||
fn deref(&self) -> &Self::Target {
|
||||
&self.0
|
||||
}
|
||||
}
|
||||
impl From<crate::R<POWER_SPEC>> for R {
|
||||
#[inline(always)]
|
||||
fn from(reader: crate::R<POWER_SPEC>) -> Self {
|
||||
R(reader)
|
||||
}
|
||||
}
|
||||
#[doc = "Register `POWER` writer"]
|
||||
pub struct W(crate::W<POWER_SPEC>);
|
||||
impl core::ops::Deref for W {
|
||||
type Target = crate::W<POWER_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<POWER_SPEC>> for W {
|
||||
#[inline(always)]
|
||||
fn from(writer: crate::W<POWER_SPEC>) -> Self {
|
||||
W(writer)
|
||||
}
|
||||
}
|
||||
#[doc = "Field `POWER` reader - Peripheral power control."]
|
||||
pub type POWER_R = crate::BitReader<POWER_A>;
|
||||
#[doc = "Peripheral power control.\n\nValue on reset: 0"]
|
||||
#[derive(Clone, Copy, Debug, PartialEq)]
|
||||
pub enum POWER_A {
|
||||
#[doc = "0: Module power disabled."]
|
||||
DISABLED = 0,
|
||||
#[doc = "1: Module power enabled."]
|
||||
ENABLED = 1,
|
||||
}
|
||||
impl From<POWER_A> for bool {
|
||||
#[inline(always)]
|
||||
fn from(variant: POWER_A) -> Self {
|
||||
variant as u8 != 0
|
||||
}
|
||||
}
|
||||
impl POWER_R {
|
||||
#[doc = "Get enumerated values variant"]
|
||||
#[inline(always)]
|
||||
pub fn variant(&self) -> POWER_A {
|
||||
match self.bits {
|
||||
false => POWER_A::DISABLED,
|
||||
true => POWER_A::ENABLED,
|
||||
}
|
||||
}
|
||||
#[doc = "Checks if the value of the field is `DISABLED`"]
|
||||
#[inline(always)]
|
||||
pub fn is_disabled(&self) -> bool {
|
||||
*self == POWER_A::DISABLED
|
||||
}
|
||||
#[doc = "Checks if the value of the field is `ENABLED`"]
|
||||
#[inline(always)]
|
||||
pub fn is_enabled(&self) -> bool {
|
||||
*self == POWER_A::ENABLED
|
||||
}
|
||||
}
|
||||
#[doc = "Field `POWER` writer - Peripheral power control."]
|
||||
pub type POWER_W<'a, const O: u8> = crate::BitWriter<'a, u32, POWER_SPEC, POWER_A, O>;
|
||||
impl<'a, const O: u8> POWER_W<'a, O> {
|
||||
#[doc = "Module power disabled."]
|
||||
#[inline(always)]
|
||||
pub fn disabled(self) -> &'a mut W {
|
||||
self.variant(POWER_A::DISABLED)
|
||||
}
|
||||
#[doc = "Module power enabled."]
|
||||
#[inline(always)]
|
||||
pub fn enabled(self) -> &'a mut W {
|
||||
self.variant(POWER_A::ENABLED)
|
||||
}
|
||||
}
|
||||
impl R {
|
||||
#[doc = "Bit 0 - Peripheral power control."]
|
||||
#[inline(always)]
|
||||
pub fn power(&self) -> POWER_R {
|
||||
POWER_R::new((self.bits & 1) != 0)
|
||||
}
|
||||
}
|
||||
impl W {
|
||||
#[doc = "Bit 0 - Peripheral power control."]
|
||||
#[inline(always)]
|
||||
pub fn power(&mut self) -> POWER_W<0> {
|
||||
POWER_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 = "Peripheral power control.\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 [power](index.html) module"]
|
||||
pub struct POWER_SPEC;
|
||||
impl crate::RegisterSpec for POWER_SPEC {
|
||||
type Ux = u32;
|
||||
}
|
||||
#[doc = "`read()` method returns [power::R](R) reader structure"]
|
||||
impl crate::Readable for POWER_SPEC {
|
||||
type Reader = R;
|
||||
}
|
||||
#[doc = "`write(|w| ..)` method takes [power::W](W) writer structure"]
|
||||
impl crate::Writable for POWER_SPEC {
|
||||
type Writer = W;
|
||||
}
|
||||
#[doc = "`reset()` method sets POWER to value 0"]
|
||||
impl crate::Resettable for POWER_SPEC {
|
||||
#[inline(always)]
|
||||
fn reset_value() -> Self::Ux {
|
||||
0
|
||||
}
|
||||
}
|
||||
Vendored
+64
@@ -0,0 +1,64 @@
|
||||
#[doc = "Register `PSELSCL` reader"]
|
||||
pub struct R(crate::R<PSELSCL_SPEC>);
|
||||
impl core::ops::Deref for R {
|
||||
type Target = crate::R<PSELSCL_SPEC>;
|
||||
#[inline(always)]
|
||||
fn deref(&self) -> &Self::Target {
|
||||
&self.0
|
||||
}
|
||||
}
|
||||
impl From<crate::R<PSELSCL_SPEC>> for R {
|
||||
#[inline(always)]
|
||||
fn from(reader: crate::R<PSELSCL_SPEC>) -> Self {
|
||||
R(reader)
|
||||
}
|
||||
}
|
||||
#[doc = "Register `PSELSCL` writer"]
|
||||
pub struct W(crate::W<PSELSCL_SPEC>);
|
||||
impl core::ops::Deref for W {
|
||||
type Target = crate::W<PSELSCL_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<PSELSCL_SPEC>> for W {
|
||||
#[inline(always)]
|
||||
fn from(writer: crate::W<PSELSCL_SPEC>) -> Self {
|
||||
W(writer)
|
||||
}
|
||||
}
|
||||
impl W {
|
||||
#[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 = "Pin select for SCL.\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 [pselscl](index.html) module"]
|
||||
pub struct PSELSCL_SPEC;
|
||||
impl crate::RegisterSpec for PSELSCL_SPEC {
|
||||
type Ux = u32;
|
||||
}
|
||||
#[doc = "`read()` method returns [pselscl::R](R) reader structure"]
|
||||
impl crate::Readable for PSELSCL_SPEC {
|
||||
type Reader = R;
|
||||
}
|
||||
#[doc = "`write(|w| ..)` method takes [pselscl::W](W) writer structure"]
|
||||
impl crate::Writable for PSELSCL_SPEC {
|
||||
type Writer = W;
|
||||
}
|
||||
#[doc = "`reset()` method sets PSELSCL to value 0xffff_ffff"]
|
||||
impl crate::Resettable for PSELSCL_SPEC {
|
||||
#[inline(always)]
|
||||
fn reset_value() -> Self::Ux {
|
||||
0xffff_ffff
|
||||
}
|
||||
}
|
||||
Vendored
+64
@@ -0,0 +1,64 @@
|
||||
#[doc = "Register `PSELSDA` reader"]
|
||||
pub struct R(crate::R<PSELSDA_SPEC>);
|
||||
impl core::ops::Deref for R {
|
||||
type Target = crate::R<PSELSDA_SPEC>;
|
||||
#[inline(always)]
|
||||
fn deref(&self) -> &Self::Target {
|
||||
&self.0
|
||||
}
|
||||
}
|
||||
impl From<crate::R<PSELSDA_SPEC>> for R {
|
||||
#[inline(always)]
|
||||
fn from(reader: crate::R<PSELSDA_SPEC>) -> Self {
|
||||
R(reader)
|
||||
}
|
||||
}
|
||||
#[doc = "Register `PSELSDA` writer"]
|
||||
pub struct W(crate::W<PSELSDA_SPEC>);
|
||||
impl core::ops::Deref for W {
|
||||
type Target = crate::W<PSELSDA_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<PSELSDA_SPEC>> for W {
|
||||
#[inline(always)]
|
||||
fn from(writer: crate::W<PSELSDA_SPEC>) -> Self {
|
||||
W(writer)
|
||||
}
|
||||
}
|
||||
impl W {
|
||||
#[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 = "Pin select for SDA.\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 [pselsda](index.html) module"]
|
||||
pub struct PSELSDA_SPEC;
|
||||
impl crate::RegisterSpec for PSELSDA_SPEC {
|
||||
type Ux = u32;
|
||||
}
|
||||
#[doc = "`read()` method returns [pselsda::R](R) reader structure"]
|
||||
impl crate::Readable for PSELSDA_SPEC {
|
||||
type Reader = R;
|
||||
}
|
||||
#[doc = "`write(|w| ..)` method takes [pselsda::W](W) writer structure"]
|
||||
impl crate::Writable for PSELSDA_SPEC {
|
||||
type Writer = W;
|
||||
}
|
||||
#[doc = "`reset()` method sets PSELSDA to value 0xffff_ffff"]
|
||||
impl crate::Resettable for PSELSDA_SPEC {
|
||||
#[inline(always)]
|
||||
fn reset_value() -> Self::Ux {
|
||||
0xffff_ffff
|
||||
}
|
||||
}
|
||||
Vendored
+40
@@ -0,0 +1,40 @@
|
||||
#[doc = "Register `RXD` reader"]
|
||||
pub struct R(crate::R<RXD_SPEC>);
|
||||
impl core::ops::Deref for R {
|
||||
type Target = crate::R<RXD_SPEC>;
|
||||
#[inline(always)]
|
||||
fn deref(&self) -> &Self::Target {
|
||||
&self.0
|
||||
}
|
||||
}
|
||||
impl From<crate::R<RXD_SPEC>> for R {
|
||||
#[inline(always)]
|
||||
fn from(reader: crate::R<RXD_SPEC>) -> Self {
|
||||
R(reader)
|
||||
}
|
||||
}
|
||||
#[doc = "Field `RXD` reader - RX data from last transfer."]
|
||||
pub type RXD_R = crate::FieldReader<u8, u8>;
|
||||
impl R {
|
||||
#[doc = "Bits 0:7 - RX data from last transfer."]
|
||||
#[inline(always)]
|
||||
pub fn rxd(&self) -> RXD_R {
|
||||
RXD_R::new((self.bits & 0xff) as u8)
|
||||
}
|
||||
}
|
||||
#[doc = "RX data register.\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 [rxd](index.html) module\n\nOne or more dependent resources other than the current register are immediately affected by a read operation."]
|
||||
pub struct RXD_SPEC;
|
||||
impl crate::RegisterSpec for RXD_SPEC {
|
||||
type Ux = u32;
|
||||
}
|
||||
#[doc = "`read()` method returns [rxd::R](R) reader structure"]
|
||||
impl crate::Readable for RXD_SPEC {
|
||||
type Reader = R;
|
||||
}
|
||||
#[doc = "`reset()` method sets RXD to value 0"]
|
||||
impl crate::Resettable for RXD_SPEC {
|
||||
#[inline(always)]
|
||||
fn reset_value() -> Self::Ux {
|
||||
0
|
||||
}
|
||||
}
|
||||
Vendored
+186
@@ -0,0 +1,186 @@
|
||||
#[doc = "Register `SHORTS` reader"]
|
||||
pub struct R(crate::R<SHORTS_SPEC>);
|
||||
impl core::ops::Deref for R {
|
||||
type Target = crate::R<SHORTS_SPEC>;
|
||||
#[inline(always)]
|
||||
fn deref(&self) -> &Self::Target {
|
||||
&self.0
|
||||
}
|
||||
}
|
||||
impl From<crate::R<SHORTS_SPEC>> for R {
|
||||
#[inline(always)]
|
||||
fn from(reader: crate::R<SHORTS_SPEC>) -> Self {
|
||||
R(reader)
|
||||
}
|
||||
}
|
||||
#[doc = "Register `SHORTS` writer"]
|
||||
pub struct W(crate::W<SHORTS_SPEC>);
|
||||
impl core::ops::Deref for W {
|
||||
type Target = crate::W<SHORTS_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<SHORTS_SPEC>> for W {
|
||||
#[inline(always)]
|
||||
fn from(writer: crate::W<SHORTS_SPEC>) -> Self {
|
||||
W(writer)
|
||||
}
|
||||
}
|
||||
#[doc = "Field `BB_SUSPEND` reader - Shortcut between BB event and the SUSPEND task."]
|
||||
pub type BB_SUSPEND_R = crate::BitReader<BB_SUSPEND_A>;
|
||||
#[doc = "Shortcut between BB event and the SUSPEND task.\n\nValue on reset: 0"]
|
||||
#[derive(Clone, Copy, Debug, PartialEq)]
|
||||
pub enum BB_SUSPEND_A {
|
||||
#[doc = "0: Shortcut disabled."]
|
||||
DISABLED = 0,
|
||||
#[doc = "1: Shortcut enabled."]
|
||||
ENABLED = 1,
|
||||
}
|
||||
impl From<BB_SUSPEND_A> for bool {
|
||||
#[inline(always)]
|
||||
fn from(variant: BB_SUSPEND_A) -> Self {
|
||||
variant as u8 != 0
|
||||
}
|
||||
}
|
||||
impl BB_SUSPEND_R {
|
||||
#[doc = "Get enumerated values variant"]
|
||||
#[inline(always)]
|
||||
pub fn variant(&self) -> BB_SUSPEND_A {
|
||||
match self.bits {
|
||||
false => BB_SUSPEND_A::DISABLED,
|
||||
true => BB_SUSPEND_A::ENABLED,
|
||||
}
|
||||
}
|
||||
#[doc = "Checks if the value of the field is `DISABLED`"]
|
||||
#[inline(always)]
|
||||
pub fn is_disabled(&self) -> bool {
|
||||
*self == BB_SUSPEND_A::DISABLED
|
||||
}
|
||||
#[doc = "Checks if the value of the field is `ENABLED`"]
|
||||
#[inline(always)]
|
||||
pub fn is_enabled(&self) -> bool {
|
||||
*self == BB_SUSPEND_A::ENABLED
|
||||
}
|
||||
}
|
||||
#[doc = "Field `BB_SUSPEND` writer - Shortcut between BB event and the SUSPEND task."]
|
||||
pub type BB_SUSPEND_W<'a, const O: u8> = crate::BitWriter<'a, u32, SHORTS_SPEC, BB_SUSPEND_A, O>;
|
||||
impl<'a, const O: u8> BB_SUSPEND_W<'a, O> {
|
||||
#[doc = "Shortcut disabled."]
|
||||
#[inline(always)]
|
||||
pub fn disabled(self) -> &'a mut W {
|
||||
self.variant(BB_SUSPEND_A::DISABLED)
|
||||
}
|
||||
#[doc = "Shortcut enabled."]
|
||||
#[inline(always)]
|
||||
pub fn enabled(self) -> &'a mut W {
|
||||
self.variant(BB_SUSPEND_A::ENABLED)
|
||||
}
|
||||
}
|
||||
#[doc = "Field `BB_STOP` reader - Shortcut between BB event and the STOP task."]
|
||||
pub type BB_STOP_R = crate::BitReader<BB_STOP_A>;
|
||||
#[doc = "Shortcut between BB event and the STOP task.\n\nValue on reset: 0"]
|
||||
#[derive(Clone, Copy, Debug, PartialEq)]
|
||||
pub enum BB_STOP_A {
|
||||
#[doc = "0: Shortcut disabled."]
|
||||
DISABLED = 0,
|
||||
#[doc = "1: Shortcut enabled."]
|
||||
ENABLED = 1,
|
||||
}
|
||||
impl From<BB_STOP_A> for bool {
|
||||
#[inline(always)]
|
||||
fn from(variant: BB_STOP_A) -> Self {
|
||||
variant as u8 != 0
|
||||
}
|
||||
}
|
||||
impl BB_STOP_R {
|
||||
#[doc = "Get enumerated values variant"]
|
||||
#[inline(always)]
|
||||
pub fn variant(&self) -> BB_STOP_A {
|
||||
match self.bits {
|
||||
false => BB_STOP_A::DISABLED,
|
||||
true => BB_STOP_A::ENABLED,
|
||||
}
|
||||
}
|
||||
#[doc = "Checks if the value of the field is `DISABLED`"]
|
||||
#[inline(always)]
|
||||
pub fn is_disabled(&self) -> bool {
|
||||
*self == BB_STOP_A::DISABLED
|
||||
}
|
||||
#[doc = "Checks if the value of the field is `ENABLED`"]
|
||||
#[inline(always)]
|
||||
pub fn is_enabled(&self) -> bool {
|
||||
*self == BB_STOP_A::ENABLED
|
||||
}
|
||||
}
|
||||
#[doc = "Field `BB_STOP` writer - Shortcut between BB event and the STOP task."]
|
||||
pub type BB_STOP_W<'a, const O: u8> = crate::BitWriter<'a, u32, SHORTS_SPEC, BB_STOP_A, O>;
|
||||
impl<'a, const O: u8> BB_STOP_W<'a, O> {
|
||||
#[doc = "Shortcut disabled."]
|
||||
#[inline(always)]
|
||||
pub fn disabled(self) -> &'a mut W {
|
||||
self.variant(BB_STOP_A::DISABLED)
|
||||
}
|
||||
#[doc = "Shortcut enabled."]
|
||||
#[inline(always)]
|
||||
pub fn enabled(self) -> &'a mut W {
|
||||
self.variant(BB_STOP_A::ENABLED)
|
||||
}
|
||||
}
|
||||
impl R {
|
||||
#[doc = "Bit 0 - Shortcut between BB event and the SUSPEND task."]
|
||||
#[inline(always)]
|
||||
pub fn bb_suspend(&self) -> BB_SUSPEND_R {
|
||||
BB_SUSPEND_R::new((self.bits & 1) != 0)
|
||||
}
|
||||
#[doc = "Bit 1 - Shortcut between BB event and the STOP task."]
|
||||
#[inline(always)]
|
||||
pub fn bb_stop(&self) -> BB_STOP_R {
|
||||
BB_STOP_R::new(((self.bits >> 1) & 1) != 0)
|
||||
}
|
||||
}
|
||||
impl W {
|
||||
#[doc = "Bit 0 - Shortcut between BB event and the SUSPEND task."]
|
||||
#[inline(always)]
|
||||
pub fn bb_suspend(&mut self) -> BB_SUSPEND_W<0> {
|
||||
BB_SUSPEND_W::new(self)
|
||||
}
|
||||
#[doc = "Bit 1 - Shortcut between BB event and the STOP task."]
|
||||
#[inline(always)]
|
||||
pub fn bb_stop(&mut self) -> BB_STOP_W<1> {
|
||||
BB_STOP_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 = "Shortcuts for TWI.\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 [shorts](index.html) module"]
|
||||
pub struct SHORTS_SPEC;
|
||||
impl crate::RegisterSpec for SHORTS_SPEC {
|
||||
type Ux = u32;
|
||||
}
|
||||
#[doc = "`read()` method returns [shorts::R](R) reader structure"]
|
||||
impl crate::Readable for SHORTS_SPEC {
|
||||
type Reader = R;
|
||||
}
|
||||
#[doc = "`write(|w| ..)` method takes [shorts::W](W) writer structure"]
|
||||
impl crate::Writable for SHORTS_SPEC {
|
||||
type Writer = W;
|
||||
}
|
||||
#[doc = "`reset()` method sets SHORTS to value 0"]
|
||||
impl crate::Resettable for SHORTS_SPEC {
|
||||
#[inline(always)]
|
||||
fn reset_value() -> Self::Ux {
|
||||
0
|
||||
}
|
||||
}
|
||||
+45
@@ -0,0 +1,45 @@
|
||||
#[doc = "Register `TASKS_RESUME` writer"]
|
||||
pub struct W(crate::W<TASKS_RESUME_SPEC>);
|
||||
impl core::ops::Deref for W {
|
||||
type Target = crate::W<TASKS_RESUME_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_RESUME_SPEC>> for W {
|
||||
#[inline(always)]
|
||||
fn from(writer: crate::W<TASKS_RESUME_SPEC>) -> Self {
|
||||
W(writer)
|
||||
}
|
||||
}
|
||||
impl W {
|
||||
#[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 = "Resume 2-Wire transaction.\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_resume](index.html) module"]
|
||||
pub struct TASKS_RESUME_SPEC;
|
||||
impl crate::RegisterSpec for TASKS_RESUME_SPEC {
|
||||
type Ux = u32;
|
||||
}
|
||||
#[doc = "`write(|w| ..)` method takes [tasks_resume::W](W) writer structure"]
|
||||
impl crate::Writable for TASKS_RESUME_SPEC {
|
||||
type Writer = W;
|
||||
}
|
||||
#[doc = "`reset()` method sets TASKS_RESUME to value 0"]
|
||||
impl crate::Resettable for TASKS_RESUME_SPEC {
|
||||
#[inline(always)]
|
||||
fn reset_value() -> Self::Ux {
|
||||
0
|
||||
}
|
||||
}
|
||||
+45
@@ -0,0 +1,45 @@
|
||||
#[doc = "Register `TASKS_STARTRX` writer"]
|
||||
pub struct W(crate::W<TASKS_STARTRX_SPEC>);
|
||||
impl core::ops::Deref for W {
|
||||
type Target = crate::W<TASKS_STARTRX_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_STARTRX_SPEC>> for W {
|
||||
#[inline(always)]
|
||||
fn from(writer: crate::W<TASKS_STARTRX_SPEC>) -> Self {
|
||||
W(writer)
|
||||
}
|
||||
}
|
||||
impl W {
|
||||
#[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 = "Start 2-Wire master receive sequence.\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_startrx](index.html) module"]
|
||||
pub struct TASKS_STARTRX_SPEC;
|
||||
impl crate::RegisterSpec for TASKS_STARTRX_SPEC {
|
||||
type Ux = u32;
|
||||
}
|
||||
#[doc = "`write(|w| ..)` method takes [tasks_startrx::W](W) writer structure"]
|
||||
impl crate::Writable for TASKS_STARTRX_SPEC {
|
||||
type Writer = W;
|
||||
}
|
||||
#[doc = "`reset()` method sets TASKS_STARTRX to value 0"]
|
||||
impl crate::Resettable for TASKS_STARTRX_SPEC {
|
||||
#[inline(always)]
|
||||
fn reset_value() -> Self::Ux {
|
||||
0
|
||||
}
|
||||
}
|
||||
+45
@@ -0,0 +1,45 @@
|
||||
#[doc = "Register `TASKS_STARTTX` writer"]
|
||||
pub struct W(crate::W<TASKS_STARTTX_SPEC>);
|
||||
impl core::ops::Deref for W {
|
||||
type Target = crate::W<TASKS_STARTTX_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_STARTTX_SPEC>> for W {
|
||||
#[inline(always)]
|
||||
fn from(writer: crate::W<TASKS_STARTTX_SPEC>) -> Self {
|
||||
W(writer)
|
||||
}
|
||||
}
|
||||
impl W {
|
||||
#[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 = "Start 2-Wire master transmit sequence.\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_starttx](index.html) module"]
|
||||
pub struct TASKS_STARTTX_SPEC;
|
||||
impl crate::RegisterSpec for TASKS_STARTTX_SPEC {
|
||||
type Ux = u32;
|
||||
}
|
||||
#[doc = "`write(|w| ..)` method takes [tasks_starttx::W](W) writer structure"]
|
||||
impl crate::Writable for TASKS_STARTTX_SPEC {
|
||||
type Writer = W;
|
||||
}
|
||||
#[doc = "`reset()` method sets TASKS_STARTTX to value 0"]
|
||||
impl crate::Resettable for TASKS_STARTTX_SPEC {
|
||||
#[inline(always)]
|
||||
fn reset_value() -> Self::Ux {
|
||||
0
|
||||
}
|
||||
}
|
||||
+45
@@ -0,0 +1,45 @@
|
||||
#[doc = "Register `TASKS_STOP` writer"]
|
||||
pub struct W(crate::W<TASKS_STOP_SPEC>);
|
||||
impl core::ops::Deref for W {
|
||||
type Target = crate::W<TASKS_STOP_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_STOP_SPEC>> for W {
|
||||
#[inline(always)]
|
||||
fn from(writer: crate::W<TASKS_STOP_SPEC>) -> Self {
|
||||
W(writer)
|
||||
}
|
||||
}
|
||||
impl W {
|
||||
#[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 = "Stop 2-Wire transaction.\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_stop](index.html) module"]
|
||||
pub struct TASKS_STOP_SPEC;
|
||||
impl crate::RegisterSpec for TASKS_STOP_SPEC {
|
||||
type Ux = u32;
|
||||
}
|
||||
#[doc = "`write(|w| ..)` method takes [tasks_stop::W](W) writer structure"]
|
||||
impl crate::Writable for TASKS_STOP_SPEC {
|
||||
type Writer = W;
|
||||
}
|
||||
#[doc = "`reset()` method sets TASKS_STOP to value 0"]
|
||||
impl crate::Resettable for TASKS_STOP_SPEC {
|
||||
#[inline(always)]
|
||||
fn reset_value() -> Self::Ux {
|
||||
0
|
||||
}
|
||||
}
|
||||
+45
@@ -0,0 +1,45 @@
|
||||
#[doc = "Register `TASKS_SUSPEND` writer"]
|
||||
pub struct W(crate::W<TASKS_SUSPEND_SPEC>);
|
||||
impl core::ops::Deref for W {
|
||||
type Target = crate::W<TASKS_SUSPEND_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_SUSPEND_SPEC>> for W {
|
||||
#[inline(always)]
|
||||
fn from(writer: crate::W<TASKS_SUSPEND_SPEC>) -> Self {
|
||||
W(writer)
|
||||
}
|
||||
}
|
||||
impl W {
|
||||
#[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 = "Suspend 2-Wire transaction.\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_suspend](index.html) module"]
|
||||
pub struct TASKS_SUSPEND_SPEC;
|
||||
impl crate::RegisterSpec for TASKS_SUSPEND_SPEC {
|
||||
type Ux = u32;
|
||||
}
|
||||
#[doc = "`write(|w| ..)` method takes [tasks_suspend::W](W) writer structure"]
|
||||
impl crate::Writable for TASKS_SUSPEND_SPEC {
|
||||
type Writer = W;
|
||||
}
|
||||
#[doc = "`reset()` method sets TASKS_SUSPEND to value 0"]
|
||||
impl crate::Resettable for TASKS_SUSPEND_SPEC {
|
||||
#[inline(always)]
|
||||
fn reset_value() -> Self::Ux {
|
||||
0
|
||||
}
|
||||
}
|
||||
Vendored
+80
@@ -0,0 +1,80 @@
|
||||
#[doc = "Register `TXD` reader"]
|
||||
pub struct R(crate::R<TXD_SPEC>);
|
||||
impl core::ops::Deref for R {
|
||||
type Target = crate::R<TXD_SPEC>;
|
||||
#[inline(always)]
|
||||
fn deref(&self) -> &Self::Target {
|
||||
&self.0
|
||||
}
|
||||
}
|
||||
impl From<crate::R<TXD_SPEC>> for R {
|
||||
#[inline(always)]
|
||||
fn from(reader: crate::R<TXD_SPEC>) -> Self {
|
||||
R(reader)
|
||||
}
|
||||
}
|
||||
#[doc = "Register `TXD` writer"]
|
||||
pub struct W(crate::W<TXD_SPEC>);
|
||||
impl core::ops::Deref for W {
|
||||
type Target = crate::W<TXD_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<TXD_SPEC>> for W {
|
||||
#[inline(always)]
|
||||
fn from(writer: crate::W<TXD_SPEC>) -> Self {
|
||||
W(writer)
|
||||
}
|
||||
}
|
||||
#[doc = "Field `TXD` reader - TX data for next transfer."]
|
||||
pub type TXD_R = crate::FieldReader<u8, u8>;
|
||||
#[doc = "Field `TXD` writer - TX data for next transfer."]
|
||||
pub type TXD_W<'a, const O: u8> = crate::FieldWriter<'a, u32, TXD_SPEC, u8, u8, 8, O>;
|
||||
impl R {
|
||||
#[doc = "Bits 0:7 - TX data for next transfer."]
|
||||
#[inline(always)]
|
||||
pub fn txd(&self) -> TXD_R {
|
||||
TXD_R::new((self.bits & 0xff) as u8)
|
||||
}
|
||||
}
|
||||
impl W {
|
||||
#[doc = "Bits 0:7 - TX data for next transfer."]
|
||||
#[inline(always)]
|
||||
pub fn txd(&mut self) -> TXD_W<0> {
|
||||
TXD_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 = "TX data register.\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 [txd](index.html) module"]
|
||||
pub struct TXD_SPEC;
|
||||
impl crate::RegisterSpec for TXD_SPEC {
|
||||
type Ux = u32;
|
||||
}
|
||||
#[doc = "`read()` method returns [txd::R](R) reader structure"]
|
||||
impl crate::Readable for TXD_SPEC {
|
||||
type Reader = R;
|
||||
}
|
||||
#[doc = "`write(|w| ..)` method takes [txd::W](W) writer structure"]
|
||||
impl crate::Writable for TXD_SPEC {
|
||||
type Writer = W;
|
||||
}
|
||||
#[doc = "`reset()` method sets TXD to value 0"]
|
||||
impl crate::Resettable for TXD_SPEC {
|
||||
#[inline(always)]
|
||||
fn reset_value() -> Self::Ux {
|
||||
0
|
||||
}
|
||||
}
|
||||
Reference in new issue
Block a user