mimxrt685s_pac/usbhsd/
epliststart.rs

1#[doc = "Register `EPLISTSTART` reader"]
2pub type R = crate::R<EpliststartSpec>;
3#[doc = "Register `EPLISTSTART` writer"]
4pub type W = crate::W<EpliststartSpec>;
5#[doc = "Field `EP_LIST_PRG` reader - Programmable portion of the USB EP Command/Status List address."]
6pub type EpListPrgR = crate::FieldReader<u16>;
7#[doc = "Field `EP_LIST_PRG` writer - Programmable portion of the USB EP Command/Status List address."]
8pub type EpListPrgW<'a, REG> = crate::FieldWriter<'a, REG, 12, u16>;
9#[doc = "Field `EP_LIST_FIXED` reader - Fixed portion of USB EP Command/Status List address."]
10pub type EpListFixedR = crate::FieldReader<u16>;
11impl R {
12    #[doc = "Bits 8:19 - Programmable portion of the USB EP Command/Status List address."]
13    #[inline(always)]
14    pub fn ep_list_prg(&self) -> EpListPrgR {
15        EpListPrgR::new(((self.bits >> 8) & 0x0fff) as u16)
16    }
17    #[doc = "Bits 20:31 - Fixed portion of USB EP Command/Status List address."]
18    #[inline(always)]
19    pub fn ep_list_fixed(&self) -> EpListFixedR {
20        EpListFixedR::new(((self.bits >> 20) & 0x0fff) as u16)
21    }
22}
23#[cfg(feature = "debug")]
24impl core::fmt::Debug for R {
25    fn fmt(&self, f: &mut core::fmt::Formatter) -> core::fmt::Result {
26        f.debug_struct("EPLISTSTART")
27            .field("ep_list_prg", &self.ep_list_prg())
28            .field("ep_list_fixed", &self.ep_list_fixed())
29            .finish()
30    }
31}
32impl W {
33    #[doc = "Bits 8:19 - Programmable portion of the USB EP Command/Status List address."]
34    #[inline(always)]
35    pub fn ep_list_prg(&mut self) -> EpListPrgW<EpliststartSpec> {
36        EpListPrgW::new(self, 8)
37    }
38}
39#[doc = "USB EP Command/Status List start address\n\nYou can [`read`](crate::Reg::read) this register and get [`epliststart::R`](R). You can [`reset`](crate::Reg::reset), [`write`](crate::Reg::write), [`write_with_zero`](crate::Reg::write_with_zero) this register using [`epliststart::W`](W). You can also [`modify`](crate::Reg::modify) this register. See [API](https://docs.rs/svd2rust/#read--modify--write-api)."]
40pub struct EpliststartSpec;
41impl crate::RegisterSpec for EpliststartSpec {
42    type Ux = u32;
43}
44#[doc = "`read()` method returns [`epliststart::R`](R) reader structure"]
45impl crate::Readable for EpliststartSpec {}
46#[doc = "`write(|w| ..)` method takes [`epliststart::W`](W) writer structure"]
47impl crate::Writable for EpliststartSpec {
48    type Safety = crate::Unsafe;
49    const ZERO_TO_MODIFY_FIELDS_BITMAP: u32 = 0;
50    const ONE_TO_MODIFY_FIELDS_BITMAP: u32 = 0;
51}
52#[doc = "`reset()` method sets EPLISTSTART to value 0"]
53impl crate::Resettable for EpliststartSpec {
54    const RESET_VALUE: u32 = 0;
55}