stm32f1_staging/stm32f101/afio/
mapr2.rs1pub type R = crate::R<MAPR2rs>;
3pub type W = crate::W<MAPR2rs>;
5pub type TIM9_REMAP_R = crate::BitReader;
7pub type TIM9_REMAP_W<'a, REG> = crate::BitWriter<'a, REG>;
9pub type TIM10_REMAP_R = crate::BitReader;
11pub type TIM10_REMAP_W<'a, REG> = crate::BitWriter<'a, REG>;
13pub type TIM11_REMAP_R = crate::BitReader;
15pub type TIM11_REMAP_W<'a, REG> = crate::BitWriter<'a, REG>;
17pub type TIM13_REMAP_R = crate::BitReader;
19pub type TIM13_REMAP_W<'a, REG> = crate::BitWriter<'a, REG>;
21pub type TIM14_REMAP_R = crate::BitReader;
23pub type TIM14_REMAP_W<'a, REG> = crate::BitWriter<'a, REG>;
25pub type FSMC_NADV_R = crate::BitReader;
27pub type FSMC_NADV_W<'a, REG> = crate::BitWriter<'a, REG>;
29impl R {
30 #[inline(always)]
32 pub fn tim9_remap(&self) -> TIM9_REMAP_R {
33 TIM9_REMAP_R::new(((self.bits >> 5) & 1) != 0)
34 }
35 #[inline(always)]
37 pub fn tim10_remap(&self) -> TIM10_REMAP_R {
38 TIM10_REMAP_R::new(((self.bits >> 6) & 1) != 0)
39 }
40 #[inline(always)]
42 pub fn tim11_remap(&self) -> TIM11_REMAP_R {
43 TIM11_REMAP_R::new(((self.bits >> 7) & 1) != 0)
44 }
45 #[inline(always)]
47 pub fn tim13_remap(&self) -> TIM13_REMAP_R {
48 TIM13_REMAP_R::new(((self.bits >> 8) & 1) != 0)
49 }
50 #[inline(always)]
52 pub fn tim14_remap(&self) -> TIM14_REMAP_R {
53 TIM14_REMAP_R::new(((self.bits >> 9) & 1) != 0)
54 }
55 #[inline(always)]
57 pub fn fsmc_nadv(&self) -> FSMC_NADV_R {
58 FSMC_NADV_R::new(((self.bits >> 10) & 1) != 0)
59 }
60}
61impl core::fmt::Debug for R {
62 fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
63 f.debug_struct("MAPR2")
64 .field("tim9_remap", &self.tim9_remap())
65 .field("tim10_remap", &self.tim10_remap())
66 .field("tim11_remap", &self.tim11_remap())
67 .field("tim13_remap", &self.tim13_remap())
68 .field("tim14_remap", &self.tim14_remap())
69 .field("fsmc_nadv", &self.fsmc_nadv())
70 .finish()
71 }
72}
73impl W {
74 #[inline(always)]
76 pub fn tim9_remap(&mut self) -> TIM9_REMAP_W<MAPR2rs> {
77 TIM9_REMAP_W::new(self, 5)
78 }
79 #[inline(always)]
81 pub fn tim10_remap(&mut self) -> TIM10_REMAP_W<MAPR2rs> {
82 TIM10_REMAP_W::new(self, 6)
83 }
84 #[inline(always)]
86 pub fn tim11_remap(&mut self) -> TIM11_REMAP_W<MAPR2rs> {
87 TIM11_REMAP_W::new(self, 7)
88 }
89 #[inline(always)]
91 pub fn tim13_remap(&mut self) -> TIM13_REMAP_W<MAPR2rs> {
92 TIM13_REMAP_W::new(self, 8)
93 }
94 #[inline(always)]
96 pub fn tim14_remap(&mut self) -> TIM14_REMAP_W<MAPR2rs> {
97 TIM14_REMAP_W::new(self, 9)
98 }
99 #[inline(always)]
101 pub fn fsmc_nadv(&mut self) -> FSMC_NADV_W<MAPR2rs> {
102 FSMC_NADV_W::new(self, 10)
103 }
104}
105pub struct MAPR2rs;
111impl crate::RegisterSpec for MAPR2rs {
112 type Ux = u32;
113}
114impl crate::Readable for MAPR2rs {}
116impl crate::Writable for MAPR2rs {
118 type Safety = crate::Unsafe;
119}
120impl crate::Resettable for MAPR2rs {}