w7500x_pac/dma/
chnl_useburst_set.rs1#[doc = "Register `CHNL_USEBURST_SET` reader"]
2pub struct R(crate::R<CHNL_USEBURST_SET_SPEC>);
3impl core::ops::Deref for R {
4 type Target = crate::R<CHNL_USEBURST_SET_SPEC>;
5 #[inline(always)]
6 fn deref(&self) -> &Self::Target {
7 &self.0
8 }
9}
10impl From<crate::R<CHNL_USEBURST_SET_SPEC>> for R {
11 #[inline(always)]
12 fn from(reader: crate::R<CHNL_USEBURST_SET_SPEC>) -> Self {
13 R(reader)
14 }
15}
16#[doc = "Register `CHNL_USEBURST_SET` writer"]
17pub struct W(crate::W<CHNL_USEBURST_SET_SPEC>);
18impl core::ops::Deref for W {
19 type Target = crate::W<CHNL_USEBURST_SET_SPEC>;
20 #[inline(always)]
21 fn deref(&self) -> &Self::Target {
22 &self.0
23 }
24}
25impl core::ops::DerefMut for W {
26 #[inline(always)]
27 fn deref_mut(&mut self) -> &mut Self::Target {
28 &mut self.0
29 }
30}
31impl From<crate::W<CHNL_USEBURST_SET_SPEC>> for W {
32 #[inline(always)]
33 fn from(writer: crate::W<CHNL_USEBURST_SET_SPEC>) -> Self {
34 W(writer)
35 }
36}
37#[doc = "Field `CHNL_USEBURST_SET` reader - CHNL_USEBURST_SET\\[5:0\\]
38bits (Returns the useburst status, or disable dma_sreq\\[Channel-1\\]
39form generating DMA requests)"]
40pub struct CHNL_USEBURST_SET_R(crate::FieldReader<u8>);
41impl CHNL_USEBURST_SET_R {
42 #[inline(always)]
43 pub(crate) fn new(bits: u8) -> Self {
44 CHNL_USEBURST_SET_R(crate::FieldReader::new(bits))
45 }
46}
47impl core::ops::Deref for CHNL_USEBURST_SET_R {
48 type Target = crate::FieldReader<u8>;
49 #[inline(always)]
50 fn deref(&self) -> &Self::Target {
51 &self.0
52 }
53}
54#[doc = "Field `CHNL_USEBURST_SET` writer - CHNL_USEBURST_SET\\[5:0\\]
55bits (Returns the useburst status, or disable dma_sreq\\[Channel-1\\]
56form generating DMA requests)"]
57pub struct CHNL_USEBURST_SET_W<'a> {
58 w: &'a mut W,
59}
60impl<'a> CHNL_USEBURST_SET_W<'a> {
61 #[doc = r"Writes raw bits to the field"]
62 #[inline(always)]
63 pub unsafe fn bits(self, value: u8) -> &'a mut W {
64 self.w.bits = (self.w.bits & !0x3f) | (value as u32 & 0x3f);
65 self.w
66 }
67}
68impl R {
69 #[doc = "Bits 0:5 - CHNL_USEBURST_SET\\[5:0\\]
70bits (Returns the useburst status, or disable dma_sreq\\[Channel-1\\]
71form generating DMA requests)"]
72 #[inline(always)]
73 pub fn chnl_useburst_set(&self) -> CHNL_USEBURST_SET_R {
74 CHNL_USEBURST_SET_R::new((self.bits & 0x3f) as u8)
75 }
76}
77impl W {
78 #[doc = "Bits 0:5 - CHNL_USEBURST_SET\\[5:0\\]
79bits (Returns the useburst status, or disable dma_sreq\\[Channel-1\\]
80form generating DMA requests)"]
81 #[inline(always)]
82 pub fn chnl_useburst_set(&mut self) -> CHNL_USEBURST_SET_W {
83 CHNL_USEBURST_SET_W { w: self }
84 }
85 #[doc = "Writes raw bits to the register."]
86 #[inline(always)]
87 pub unsafe fn bits(&mut self, bits: u32) -> &mut Self {
88 self.0.bits(bits);
89 self
90 }
91}
92#[doc = "Channel UseBurst 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 [chnl_useburst_set](index.html) module"]
93pub struct CHNL_USEBURST_SET_SPEC;
94impl crate::RegisterSpec for CHNL_USEBURST_SET_SPEC {
95 type Ux = u32;
96}
97#[doc = "`read()` method returns [chnl_useburst_set::R](R) reader structure"]
98impl crate::Readable for CHNL_USEBURST_SET_SPEC {
99 type Reader = R;
100}
101#[doc = "`write(|w| ..)` method takes [chnl_useburst_set::W](W) writer structure"]
102impl crate::Writable for CHNL_USEBURST_SET_SPEC {
103 type Writer = W;
104}
105#[doc = "`reset()` method sets CHNL_USEBURST_SET to value 0"]
106impl crate::Resettable for CHNL_USEBURST_SET_SPEC {
107 #[inline(always)]
108 fn reset_value() -> Self::Ux {
109 0
110 }
111}