atsam3s1a/tc0/
qidr.rs

1#[doc = "Register `QIDR` writer"]
2pub type W = crate::W<QidrSpec>;
3#[doc = "Field `IDX` writer - InDeX"]
4pub type IdxW<'a, REG> = crate::BitWriter<'a, REG>;
5#[doc = "Field `DIRCHG` writer - DIRection CHanGe"]
6pub type DirchgW<'a, REG> = crate::BitWriter<'a, REG>;
7#[doc = "Field `QERR` writer - Quadrature ERRor"]
8pub type QerrW<'a, REG> = crate::BitWriter<'a, REG>;
9impl W {
10    #[doc = "Bit 0 - InDeX"]
11    #[inline(always)]
12    #[must_use]
13    pub fn idx(&mut self) -> IdxW<QidrSpec> {
14        IdxW::new(self, 0)
15    }
16    #[doc = "Bit 1 - DIRection CHanGe"]
17    #[inline(always)]
18    #[must_use]
19    pub fn dirchg(&mut self) -> DirchgW<QidrSpec> {
20        DirchgW::new(self, 1)
21    }
22    #[doc = "Bit 2 - Quadrature ERRor"]
23    #[inline(always)]
24    #[must_use]
25    pub fn qerr(&mut self) -> QerrW<QidrSpec> {
26        QerrW::new(self, 2)
27    }
28}
29#[doc = "QDEC Interrupt Disable Register\n\nYou can [`write_with_zero`](crate::generic::Reg::write_with_zero) this register using [`qidr::W`](W). See [API](https://docs.rs/svd2rust/#read--modify--write-api)."]
30pub struct QidrSpec;
31impl crate::RegisterSpec for QidrSpec {
32    type Ux = u32;
33}
34#[doc = "`write(|w| ..)` method takes [`qidr::W`](W) writer structure"]
35impl crate::Writable for QidrSpec {
36    type Safety = crate::Unsafe;
37    const ZERO_TO_MODIFY_FIELDS_BITMAP: u32 = 0;
38    const ONE_TO_MODIFY_FIELDS_BITMAP: u32 = 0;
39}