atsamd51g/system_control/
shpr2.rs
1#[doc = "Register `SHPR2` reader"]
2pub type R = crate::R<Shpr2Spec>;
3#[doc = "Register `SHPR2` writer"]
4pub type W = crate::W<Shpr2Spec>;
5#[doc = "Field `PRI_11` reader - Priority of system handler 11, SVCall"]
6pub type Pri11R = crate::FieldReader;
7#[doc = "Field `PRI_11` writer - Priority of system handler 11, SVCall"]
8pub type Pri11W<'a, REG> = crate::FieldWriter<'a, REG, 8>;
9impl R {
10 #[doc = "Bits 24:31 - Priority of system handler 11, SVCall"]
11 #[inline(always)]
12 pub fn pri_11(&self) -> Pri11R {
13 Pri11R::new(((self.bits >> 24) & 0xff) as u8)
14 }
15}
16impl W {
17 #[doc = "Bits 24:31 - Priority of system handler 11, SVCall"]
18 #[inline(always)]
19 #[must_use]
20 pub fn pri_11(&mut self) -> Pri11W<Shpr2Spec> {
21 Pri11W::new(self, 24)
22 }
23}
24#[doc = "System Handler Priority Register 2\n\nYou can [`read`](crate::Reg::read) this register and get [`shpr2::R`](R). You can [`reset`](crate::Reg::reset), [`write`](crate::Reg::write), [`write_with_zero`](crate::Reg::write_with_zero) this register using [`shpr2::W`](W). You can also [`modify`](crate::Reg::modify) this register. See [API](https://docs.rs/svd2rust/#read--modify--write-api)."]
25pub struct Shpr2Spec;
26impl crate::RegisterSpec for Shpr2Spec {
27 type Ux = u32;
28}
29#[doc = "`read()` method returns [`shpr2::R`](R) reader structure"]
30impl crate::Readable for Shpr2Spec {}
31#[doc = "`write(|w| ..)` method takes [`shpr2::W`](W) writer structure"]
32impl crate::Writable for Shpr2Spec {
33 type Safety = crate::Unsafe;
34 const ZERO_TO_MODIFY_FIELDS_BITMAP: u32 = 0;
35 const ONE_TO_MODIFY_FIELDS_BITMAP: u32 = 0;
36}
37#[doc = "`reset()` method sets SHPR2 to value 0"]
38impl crate::Resettable for Shpr2Spec {
39 const RESET_VALUE: u32 = 0;
40}