esp32p4/isp/
ae_block_mean_0.rs1#[doc = "Register `AE_BLOCK_MEAN_0` reader"]
2pub type R = crate::R<AE_BLOCK_MEAN_0_SPEC>;
3#[doc = "Field `AE_B03_MEAN` reader - this field configures block03 Y mean data"]
4pub type AE_B03_MEAN_R = crate::FieldReader;
5#[doc = "Field `AE_B02_MEAN` reader - this field configures block02 Y mean data"]
6pub type AE_B02_MEAN_R = crate::FieldReader;
7#[doc = "Field `AE_B01_MEAN` reader - this field configures block01 Y mean data"]
8pub type AE_B01_MEAN_R = crate::FieldReader;
9#[doc = "Field `AE_B00_MEAN` reader - this field configures block00 Y mean data"]
10pub type AE_B00_MEAN_R = crate::FieldReader;
11impl R {
12 #[doc = "Bits 0:7 - this field configures block03 Y mean data"]
13 #[inline(always)]
14 pub fn ae_b03_mean(&self) -> AE_B03_MEAN_R {
15 AE_B03_MEAN_R::new((self.bits & 0xff) as u8)
16 }
17 #[doc = "Bits 8:15 - this field configures block02 Y mean data"]
18 #[inline(always)]
19 pub fn ae_b02_mean(&self) -> AE_B02_MEAN_R {
20 AE_B02_MEAN_R::new(((self.bits >> 8) & 0xff) as u8)
21 }
22 #[doc = "Bits 16:23 - this field configures block01 Y mean data"]
23 #[inline(always)]
24 pub fn ae_b01_mean(&self) -> AE_B01_MEAN_R {
25 AE_B01_MEAN_R::new(((self.bits >> 16) & 0xff) as u8)
26 }
27 #[doc = "Bits 24:31 - this field configures block00 Y mean data"]
28 #[inline(always)]
29 pub fn ae_b00_mean(&self) -> AE_B00_MEAN_R {
30 AE_B00_MEAN_R::new(((self.bits >> 24) & 0xff) as u8)
31 }
32}
33#[cfg(feature = "impl-register-debug")]
34impl core::fmt::Debug for R {
35 fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
36 f.debug_struct("AE_BLOCK_MEAN_0")
37 .field(
38 "ae_b03_mean",
39 &format_args!("{}", self.ae_b03_mean().bits()),
40 )
41 .field(
42 "ae_b02_mean",
43 &format_args!("{}", self.ae_b02_mean().bits()),
44 )
45 .field(
46 "ae_b01_mean",
47 &format_args!("{}", self.ae_b01_mean().bits()),
48 )
49 .field(
50 "ae_b00_mean",
51 &format_args!("{}", self.ae_b00_mean().bits()),
52 )
53 .finish()
54 }
55}
56#[cfg(feature = "impl-register-debug")]
57impl core::fmt::Debug for crate::generic::Reg<AE_BLOCK_MEAN_0_SPEC> {
58 fn fmt(&self, f: &mut core::fmt::Formatter<'_>) -> core::fmt::Result {
59 core::fmt::Debug::fmt(&self.read(), f)
60 }
61}
62#[doc = "ae statistic result register 0\n\nYou can [`read`](crate::generic::Reg::read) this register and get [`ae_block_mean_0::R`](R). See [API](https://docs.rs/svd2rust/#read--modify--write-api)."]
63pub struct AE_BLOCK_MEAN_0_SPEC;
64impl crate::RegisterSpec for AE_BLOCK_MEAN_0_SPEC {
65 type Ux = u32;
66}
67#[doc = "`read()` method returns [`ae_block_mean_0::R`](R) reader structure"]
68impl crate::Readable for AE_BLOCK_MEAN_0_SPEC {}
69#[doc = "`reset()` method sets AE_BLOCK_MEAN_0 to value 0"]
70impl crate::Resettable for AE_BLOCK_MEAN_0_SPEC {
71 const RESET_VALUE: u32 = 0;
72}