esp32c6/dma/ch/
out_pri.rs

1#[doc = "Register `OUT_PRI` reader"]
2pub type R = crate::R<OUT_PRI_SPEC>;
3#[doc = "Register `OUT_PRI` writer"]
4pub type W = crate::W<OUT_PRI_SPEC>;
5#[doc = "Field `TX_PRI` reader - The priority of Tx channel 0. The larger of the value the higher of the priority."]
6pub type TX_PRI_R = crate::FieldReader;
7#[doc = "Field `TX_PRI` writer - The priority of Tx channel 0. The larger of the value the higher of the priority."]
8pub type TX_PRI_W<'a, REG> = crate::FieldWriter<'a, REG, 4>;
9impl R {
10    #[doc = "Bits 0:3 - The priority of Tx channel 0. The larger of the value the higher of the priority."]
11    #[inline(always)]
12    pub fn tx_pri(&self) -> TX_PRI_R {
13        TX_PRI_R::new((self.bits & 0x0f) as u8)
14    }
15}
16#[cfg(feature = "impl-register-debug")]
17impl core::fmt::Debug for R {
18    fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
19        f.debug_struct("OUT_PRI")
20            .field("tx_pri", &self.tx_pri())
21            .finish()
22    }
23}
24impl W {
25    #[doc = "Bits 0:3 - The priority of Tx channel 0. The larger of the value the higher of the priority."]
26    #[inline(always)]
27    pub fn tx_pri(&mut self) -> TX_PRI_W<OUT_PRI_SPEC> {
28        TX_PRI_W::new(self, 0)
29    }
30}
31#[doc = "Priority register of Tx channel 0.\n\nYou can [`read`](crate::Reg::read) this register and get [`out_pri::R`](R). You can [`reset`](crate::Reg::reset), [`write`](crate::Reg::write), [`write_with_zero`](crate::Reg::write_with_zero) this register using [`out_pri::W`](W). You can also [`modify`](crate::Reg::modify) this register. See [API](https://docs.rs/svd2rust/#read--modify--write-api)."]
32pub struct OUT_PRI_SPEC;
33impl crate::RegisterSpec for OUT_PRI_SPEC {
34    type Ux = u32;
35}
36#[doc = "`read()` method returns [`out_pri::R`](R) reader structure"]
37impl crate::Readable for OUT_PRI_SPEC {}
38#[doc = "`write(|w| ..)` method takes [`out_pri::W`](W) writer structure"]
39impl crate::Writable for OUT_PRI_SPEC {
40    type Safety = crate::Unsafe;
41}
42#[doc = "`reset()` method sets OUT_PRI to value 0"]
43impl crate::Resettable for OUT_PRI_SPEC {}