stm32f7_staging/stm32f779/dsi/
ghcr.rs1pub type R = crate::R<GHCRrs>;
3pub type W = crate::W<GHCRrs>;
5pub type DT_R = crate::FieldReader;
7pub type DT_W<'a, REG> = crate::FieldWriter<'a, REG, 6>;
9pub type VCID_R = crate::FieldReader;
11pub type VCID_W<'a, REG> = crate::FieldWriter<'a, REG, 2>;
13pub type WCLSB_R = crate::FieldReader;
15pub type WCLSB_W<'a, REG> = crate::FieldWriter<'a, REG, 8>;
17pub type WCMSB_R = crate::FieldReader;
19pub type WCMSB_W<'a, REG> = crate::FieldWriter<'a, REG, 8>;
21impl R {
22 #[inline(always)]
24 pub fn dt(&self) -> DT_R {
25 DT_R::new((self.bits & 0x3f) as u8)
26 }
27 #[inline(always)]
29 pub fn vcid(&self) -> VCID_R {
30 VCID_R::new(((self.bits >> 6) & 3) as u8)
31 }
32 #[inline(always)]
34 pub fn wclsb(&self) -> WCLSB_R {
35 WCLSB_R::new(((self.bits >> 8) & 0xff) as u8)
36 }
37 #[inline(always)]
39 pub fn wcmsb(&self) -> WCMSB_R {
40 WCMSB_R::new(((self.bits >> 16) & 0xff) as u8)
41 }
42}
43impl core::fmt::Debug for R {
44 fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
45 f.debug_struct("GHCR")
46 .field("dt", &self.dt())
47 .field("vcid", &self.vcid())
48 .field("wclsb", &self.wclsb())
49 .field("wcmsb", &self.wcmsb())
50 .finish()
51 }
52}
53impl W {
54 #[inline(always)]
56 pub fn dt(&mut self) -> DT_W<GHCRrs> {
57 DT_W::new(self, 0)
58 }
59 #[inline(always)]
61 pub fn vcid(&mut self) -> VCID_W<GHCRrs> {
62 VCID_W::new(self, 6)
63 }
64 #[inline(always)]
66 pub fn wclsb(&mut self) -> WCLSB_W<GHCRrs> {
67 WCLSB_W::new(self, 8)
68 }
69 #[inline(always)]
71 pub fn wcmsb(&mut self) -> WCMSB_W<GHCRrs> {
72 WCMSB_W::new(self, 16)
73 }
74}
75pub struct GHCRrs;
81impl crate::RegisterSpec for GHCRrs {
82 type Ux = u32;
83}
84impl crate::Readable for GHCRrs {}
86impl crate::Writable for GHCRrs {
88 type Safety = crate::Unsafe;
89}
90impl crate::Resettable for GHCRrs {}