xmc4300/scu_general/
idmanuf.rs

1#[doc = "Register `IDMANUF` reader"]
2pub type R = crate::R<IDMANUF_SPEC>;
3#[doc = "Field `DEPT` reader - Department Identification Number"]
4pub type DEPT_R = crate::FieldReader;
5#[doc = "Field `MANUF` reader - Manufacturer Identification Number"]
6pub type MANUF_R = crate::FieldReader<u16>;
7impl R {
8    #[doc = "Bits 0:4 - Department Identification Number"]
9    #[inline(always)]
10    pub fn dept(&self) -> DEPT_R {
11        DEPT_R::new((self.bits & 0x1f) as u8)
12    }
13    #[doc = "Bits 5:15 - Manufacturer Identification Number"]
14    #[inline(always)]
15    pub fn manuf(&self) -> MANUF_R {
16        MANUF_R::new(((self.bits >> 5) & 0x07ff) as u16)
17    }
18}
19#[doc = "Manufactory ID Register\n\nYou can [`read`](crate::Reg::read) this register and get [`idmanuf::R`](R). See [API](https://docs.rs/svd2rust/#read--modify--write-api)."]
20pub struct IDMANUF_SPEC;
21impl crate::RegisterSpec for IDMANUF_SPEC {
22    type Ux = u32;
23}
24#[doc = "`read()` method returns [`idmanuf::R`](R) reader structure"]
25impl crate::Readable for IDMANUF_SPEC {}
26#[doc = "`reset()` method sets IDMANUF to value 0x1820"]
27impl crate::Resettable for IDMANUF_SPEC {
28    const RESET_VALUE: u32 = 0x1820;
29}