py32f0/py32f003/adc/
calrr2.rs1pub struct R(crate::R<CALRR2_SPEC>);
3impl core::ops::Deref for R {
4 type Target = crate::R<CALRR2_SPEC>;
5 #[inline(always)]
6 fn deref(&self) -> &Self::Target {
7 &self.0
8 }
9}
10impl From<crate::R<CALRR2_SPEC>> for R {
11 #[inline(always)]
12 fn from(reader: crate::R<CALRR2_SPEC>) -> Self {
13 R(reader)
14 }
15}
16pub type CALC0OUT_R = crate::FieldReader<u8, u8>;
18pub type CALC1OUT_R = crate::FieldReader<u8, u8>;
20pub type CALC2OUT_R = crate::FieldReader<u8, u8>;
22pub type CALC3OUT_R = crate::FieldReader<u8, u8>;
24impl R {
25 #[inline(always)]
27 pub fn calc0out(&self) -> CALC0OUT_R {
28 CALC0OUT_R::new((self.bits & 0xff) as u8)
29 }
30 #[inline(always)]
32 pub fn calc1out(&self) -> CALC1OUT_R {
33 CALC1OUT_R::new(((self.bits >> 8) & 0xff) as u8)
34 }
35 #[inline(always)]
37 pub fn calc2out(&self) -> CALC2OUT_R {
38 CALC2OUT_R::new(((self.bits >> 16) & 0xff) as u8)
39 }
40 #[inline(always)]
42 pub fn calc3out(&self) -> CALC3OUT_R {
43 CALC3OUT_R::new(((self.bits >> 24) & 0xff) as u8)
44 }
45}
46pub struct CALRR2_SPEC;
52impl crate::RegisterSpec for CALRR2_SPEC {
53 type Ux = u32;
54}
55impl crate::Readable for CALRR2_SPEC {
57 type Reader = R;
58}
59impl crate::Resettable for CALRR2_SPEC {
61 const RESET_VALUE: Self::Ux = 0;
62}