atsamd51g/
ccl.rs

1#[repr(C)]
2#[doc = "Register block"]
3pub struct RegisterBlock {
4    ctrl: Ctrl,
5    _reserved1: [u8; 0x03],
6    seqctrl: [Seqctrl; 2],
7    _reserved2: [u8; 0x02],
8    lutctrl: [Lutctrl; 4],
9}
10impl RegisterBlock {
11    #[doc = "0x00 - Control"]
12    #[inline(always)]
13    pub const fn ctrl(&self) -> &Ctrl {
14        &self.ctrl
15    }
16    #[doc = "0x04 - SEQ Control x"]
17    #[inline(always)]
18    pub const fn seqctrl(&self, n: usize) -> &Seqctrl {
19        &self.seqctrl[n]
20    }
21    #[doc = "Iterator for array of:"]
22    #[doc = "0x04 - SEQ Control x"]
23    #[inline(always)]
24    pub fn seqctrl_iter(&self) -> impl Iterator<Item = &Seqctrl> {
25        self.seqctrl.iter()
26    }
27    #[doc = "0x08..0x18 - LUT Control x"]
28    #[inline(always)]
29    pub const fn lutctrl(&self, n: usize) -> &Lutctrl {
30        &self.lutctrl[n]
31    }
32    #[doc = "Iterator for array of:"]
33    #[doc = "0x08..0x18 - LUT Control x"]
34    #[inline(always)]
35    pub fn lutctrl_iter(&self) -> impl Iterator<Item = &Lutctrl> {
36        self.lutctrl.iter()
37    }
38}
39#[doc = "CTRL (rw) register accessor: Control\n\nYou can [`read`](crate::Reg::read) this register and get [`ctrl::R`]. You can [`reset`](crate::Reg::reset), [`write`](crate::Reg::write), [`write_with_zero`](crate::Reg::write_with_zero) this register using [`ctrl::W`]. You can also [`modify`](crate::Reg::modify) this register. See [API](https://docs.rs/svd2rust/#read--modify--write-api).\n\nFor information about available fields see [`mod@ctrl`]
40module"]
41#[doc(alias = "CTRL")]
42pub type Ctrl = crate::Reg<ctrl::CtrlSpec>;
43#[doc = "Control"]
44pub mod ctrl;
45#[doc = "SEQCTRL (rw) register accessor: SEQ Control x\n\nYou can [`read`](crate::Reg::read) this register and get [`seqctrl::R`]. You can [`reset`](crate::Reg::reset), [`write`](crate::Reg::write), [`write_with_zero`](crate::Reg::write_with_zero) this register using [`seqctrl::W`]. You can also [`modify`](crate::Reg::modify) this register. See [API](https://docs.rs/svd2rust/#read--modify--write-api).\n\nFor information about available fields see [`mod@seqctrl`]
46module"]
47#[doc(alias = "SEQCTRL")]
48pub type Seqctrl = crate::Reg<seqctrl::SeqctrlSpec>;
49#[doc = "SEQ Control x"]
50pub mod seqctrl;
51#[doc = "LUTCTRL (rw) register accessor: LUT Control x\n\nYou can [`read`](crate::Reg::read) this register and get [`lutctrl::R`]. You can [`reset`](crate::Reg::reset), [`write`](crate::Reg::write), [`write_with_zero`](crate::Reg::write_with_zero) this register using [`lutctrl::W`]. You can also [`modify`](crate::Reg::modify) this register. See [API](https://docs.rs/svd2rust/#read--modify--write-api).\n\nFor information about available fields see [`mod@lutctrl`]
52module"]
53#[doc(alias = "LUTCTRL")]
54pub type Lutctrl = crate::Reg<lutctrl::LutctrlSpec>;
55#[doc = "LUT Control x"]
56pub mod lutctrl;