bl602_pac/aon/
gpadc_reg_result.rs1#[doc = "Register `gpadc_reg_result` reader"]
2pub struct R(crate::R<GPADC_REG_RESULT_SPEC>);
3impl core::ops::Deref for R {
4 type Target = crate::R<GPADC_REG_RESULT_SPEC>;
5 #[inline(always)]
6 fn deref(&self) -> &Self::Target {
7 &self.0
8 }
9}
10impl From<crate::R<GPADC_REG_RESULT_SPEC>> for R {
11 #[inline(always)]
12 fn from(reader: crate::R<GPADC_REG_RESULT_SPEC>) -> Self {
13 R(reader)
14 }
15}
16#[doc = "Register `gpadc_reg_result` writer"]
17pub struct W(crate::W<GPADC_REG_RESULT_SPEC>);
18impl core::ops::Deref for W {
19 type Target = crate::W<GPADC_REG_RESULT_SPEC>;
20 #[inline(always)]
21 fn deref(&self) -> &Self::Target {
22 &self.0
23 }
24}
25impl core::ops::DerefMut for W {
26 #[inline(always)]
27 fn deref_mut(&mut self) -> &mut Self::Target {
28 &mut self.0
29 }
30}
31impl From<crate::W<GPADC_REG_RESULT_SPEC>> for W {
32 #[inline(always)]
33 fn from(writer: crate::W<GPADC_REG_RESULT_SPEC>) -> Self {
34 W(writer)
35 }
36}
37#[doc = "Field `gpadc_data_out` reader - "]
38pub type GPADC_DATA_OUT_R = crate::FieldReader<u32, u32>;
39impl R {
40 #[doc = "Bits 0:25"]
41 #[inline(always)]
42 pub fn gpadc_data_out(&self) -> GPADC_DATA_OUT_R {
43 GPADC_DATA_OUT_R::new(self.bits & 0x03ff_ffff)
44 }
45}
46impl W {
47 #[doc = "Writes raw bits to the register."]
48 #[inline(always)]
49 pub unsafe fn bits(&mut self, bits: u32) -> &mut Self {
50 self.0.bits(bits);
51 self
52 }
53}
54#[doc = "gpadc_reg_result.\n\nThis register you can [`read`](crate::generic::Reg::read), [`write_with_zero`](crate::generic::Reg::write_with_zero), [`reset`](crate::generic::Reg::reset), [`write`](crate::generic::Reg::write), [`modify`](crate::generic::Reg::modify). See [API](https://docs.rs/svd2rust/#read--modify--write-api).\n\nFor information about available fields see [gpadc_reg_result](index.html) module"]
55pub struct GPADC_REG_RESULT_SPEC;
56impl crate::RegisterSpec for GPADC_REG_RESULT_SPEC {
57 type Ux = u32;
58}
59#[doc = "`read()` method returns [gpadc_reg_result::R](R) reader structure"]
60impl crate::Readable for GPADC_REG_RESULT_SPEC {
61 type Reader = R;
62}
63#[doc = "`write(|w| ..)` method takes [gpadc_reg_result::W](W) writer structure"]
64impl crate::Writable for GPADC_REG_RESULT_SPEC {
65 type Writer = W;
66 const ZERO_TO_MODIFY_FIELDS_BITMAP: Self::Ux = 0;
67 const ONE_TO_MODIFY_FIELDS_BITMAP: Self::Ux = 0;
68}
69#[doc = "`reset()` method sets gpadc_reg_result to value 0x01ef_0000"]
70impl crate::Resettable for GPADC_REG_RESULT_SPEC {
71 const RESET_VALUE: Self::Ux = 0x01ef_0000;
72}