Skip to main content

ra2a2_pac/
sci0.rs

1/*
2DISCLAIMER
3This software is supplied by Renesas Electronics Corporation and is only intended for use with Renesas products.
4No other uses are authorized. This software is owned by Renesas Electronics Corporation and is protected under all
5applicable laws, including copyright laws.
6THIS SOFTWARE IS PROVIDED "AS IS" AND RENESAS MAKES NO WARRANTIES REGARDING THIS SOFTWARE, WHETHER EXPRESS, IMPLIED
7OR STATUTORY, INCLUDING BUT NOT LIMITED TO WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
8NON-INFRINGEMENT.  ALL SUCH WARRANTIES ARE EXPRESSLY DISCLAIMED.TO THE MAXIMUM EXTENT PERMITTED NOT PROHIBITED BY
9LAW, NEITHER RENESAS ELECTRONICS CORPORATION NOR ANY OF ITS AFFILIATED COMPANIES SHALL BE LIABLE FOR ANY DIRECT,
10INDIRECT, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES FOR ANY REASON RELATED TO THIS SOFTWARE, EVEN IF RENESAS OR
11ITS AFFILIATES HAVE BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGES.
12Renesas reserves the right, without notice, to make changes to this software and to discontinue the availability
13of this software. By using this software, you agree to the additional terms and conditions found by accessing the
14following link:
15http://www.renesas.com/disclaimer
16
17*/
18// Generated from SVD 1.20.02, with svd2pac 0.6.1 on Sun, 15 Mar 2026 07:01:00 +0000
19
20#![allow(clippy::identity_op)]
21#![allow(clippy::module_inception)]
22#![allow(clippy::derivable_impls)]
23#[allow(unused_imports)]
24use crate::common::sealed;
25#[allow(unused_imports)]
26use crate::common::*;
27#[doc = r"Serial Communication Interface 0"]
28unsafe impl ::core::marker::Send for super::Sci0 {}
29unsafe impl ::core::marker::Sync for super::Sci0 {}
30impl super::Sci0 {
31    #[allow(unused)]
32    #[inline(always)]
33    pub(crate) const fn _svd2pac_as_ptr(&self) -> *mut u8 {
34        self.ptr
35    }
36
37    #[doc = "Serial Mode Register for Non-Smart Card Interface Mode (SCMR.SMIF = 0)"]
38    #[inline(always)]
39    pub const fn smr(&self) -> &'static crate::common::Reg<self::Smr_SPEC, crate::common::RW> {
40        unsafe {
41            crate::common::Reg::<self::Smr_SPEC, crate::common::RW>::from_ptr(
42                self._svd2pac_as_ptr().add(0usize),
43            )
44        }
45    }
46
47    #[doc = "Serial Mode Register for Smart Card Interface Mode (SCMR.SMIF = 1)"]
48    #[inline(always)]
49    pub const fn smr_smci(
50        &self,
51    ) -> &'static crate::common::Reg<self::SmrSmci_SPEC, crate::common::RW> {
52        unsafe {
53            crate::common::Reg::<self::SmrSmci_SPEC, crate::common::RW>::from_ptr(
54                self._svd2pac_as_ptr().add(0usize),
55            )
56        }
57    }
58
59    #[doc = "Bit Rate Register"]
60    #[inline(always)]
61    pub const fn brr(&self) -> &'static crate::common::Reg<self::Brr_SPEC, crate::common::RW> {
62        unsafe {
63            crate::common::Reg::<self::Brr_SPEC, crate::common::RW>::from_ptr(
64                self._svd2pac_as_ptr().add(1usize),
65            )
66        }
67    }
68
69    #[doc = "Serial Control Register for Non-Smart Card Interface Mode (SCMR.SMIF = 0)"]
70    #[inline(always)]
71    pub const fn scr(&self) -> &'static crate::common::Reg<self::Scr_SPEC, crate::common::RW> {
72        unsafe {
73            crate::common::Reg::<self::Scr_SPEC, crate::common::RW>::from_ptr(
74                self._svd2pac_as_ptr().add(2usize),
75            )
76        }
77    }
78
79    #[doc = "Serial Control Register for Smart Card Interface Mode (SCMR.SMIF = 1)"]
80    #[inline(always)]
81    pub const fn scr_smci(
82        &self,
83    ) -> &'static crate::common::Reg<self::ScrSmci_SPEC, crate::common::RW> {
84        unsafe {
85            crate::common::Reg::<self::ScrSmci_SPEC, crate::common::RW>::from_ptr(
86                self._svd2pac_as_ptr().add(2usize),
87            )
88        }
89    }
90
91    #[doc = "Transmit Data Register"]
92    #[inline(always)]
93    pub const fn tdr(&self) -> &'static crate::common::Reg<self::Tdr_SPEC, crate::common::RW> {
94        unsafe {
95            crate::common::Reg::<self::Tdr_SPEC, crate::common::RW>::from_ptr(
96                self._svd2pac_as_ptr().add(3usize),
97            )
98        }
99    }
100
101    #[doc = "Serial Status Register for Non-Smart Card Interface and Non-FIFO Mode (SCMR.SMIF = 0, FCR.FM = 0)"]
102    #[inline(always)]
103    pub const fn ssr(&self) -> &'static crate::common::Reg<self::Ssr_SPEC, crate::common::RW> {
104        unsafe {
105            crate::common::Reg::<self::Ssr_SPEC, crate::common::RW>::from_ptr(
106                self._svd2pac_as_ptr().add(4usize),
107            )
108        }
109    }
110
111    #[doc = "Serial Status Register for Non-Smart Card Interface and FIFO Mode (SCMR.SMIF = 0, FCR.FM = 1)"]
112    #[inline(always)]
113    pub const fn ssr_fifo(
114        &self,
115    ) -> &'static crate::common::Reg<self::SsrFifo_SPEC, crate::common::RW> {
116        unsafe {
117            crate::common::Reg::<self::SsrFifo_SPEC, crate::common::RW>::from_ptr(
118                self._svd2pac_as_ptr().add(4usize),
119            )
120        }
121    }
122
123    #[doc = "Serial Status Register for Smart Card Interface Mode (SCMR.SMIF = 1)"]
124    #[inline(always)]
125    pub const fn ssr_smci(
126        &self,
127    ) -> &'static crate::common::Reg<self::SsrSmci_SPEC, crate::common::RW> {
128        unsafe {
129            crate::common::Reg::<self::SsrSmci_SPEC, crate::common::RW>::from_ptr(
130                self._svd2pac_as_ptr().add(4usize),
131            )
132        }
133    }
134
135    #[doc = "Receive Data Register"]
136    #[inline(always)]
137    pub const fn rdr(&self) -> &'static crate::common::Reg<self::Rdr_SPEC, crate::common::RW> {
138        unsafe {
139            crate::common::Reg::<self::Rdr_SPEC, crate::common::RW>::from_ptr(
140                self._svd2pac_as_ptr().add(5usize),
141            )
142        }
143    }
144
145    #[doc = "Smart Card Mode Register"]
146    #[inline(always)]
147    pub const fn scmr(&self) -> &'static crate::common::Reg<self::Scmr_SPEC, crate::common::RW> {
148        unsafe {
149            crate::common::Reg::<self::Scmr_SPEC, crate::common::RW>::from_ptr(
150                self._svd2pac_as_ptr().add(6usize),
151            )
152        }
153    }
154
155    #[doc = "Serial Extended Mode Register"]
156    #[inline(always)]
157    pub const fn semr(&self) -> &'static crate::common::Reg<self::Semr_SPEC, crate::common::RW> {
158        unsafe {
159            crate::common::Reg::<self::Semr_SPEC, crate::common::RW>::from_ptr(
160                self._svd2pac_as_ptr().add(7usize),
161            )
162        }
163    }
164
165    #[doc = "Noise Filter Setting Register"]
166    #[inline(always)]
167    pub const fn snfr(&self) -> &'static crate::common::Reg<self::Snfr_SPEC, crate::common::RW> {
168        unsafe {
169            crate::common::Reg::<self::Snfr_SPEC, crate::common::RW>::from_ptr(
170                self._svd2pac_as_ptr().add(8usize),
171            )
172        }
173    }
174
175    #[doc = "IIC Mode Register 1"]
176    #[inline(always)]
177    pub const fn simr1(&self) -> &'static crate::common::Reg<self::Simr1_SPEC, crate::common::RW> {
178        unsafe {
179            crate::common::Reg::<self::Simr1_SPEC, crate::common::RW>::from_ptr(
180                self._svd2pac_as_ptr().add(9usize),
181            )
182        }
183    }
184
185    #[doc = "IIC Mode Register 2"]
186    #[inline(always)]
187    pub const fn simr2(&self) -> &'static crate::common::Reg<self::Simr2_SPEC, crate::common::RW> {
188        unsafe {
189            crate::common::Reg::<self::Simr2_SPEC, crate::common::RW>::from_ptr(
190                self._svd2pac_as_ptr().add(10usize),
191            )
192        }
193    }
194
195    #[doc = "IIC Mode Register 3"]
196    #[inline(always)]
197    pub const fn simr3(&self) -> &'static crate::common::Reg<self::Simr3_SPEC, crate::common::RW> {
198        unsafe {
199            crate::common::Reg::<self::Simr3_SPEC, crate::common::RW>::from_ptr(
200                self._svd2pac_as_ptr().add(11usize),
201            )
202        }
203    }
204
205    #[doc = "IIC Status Register"]
206    #[inline(always)]
207    pub const fn sisr(&self) -> &'static crate::common::Reg<self::Sisr_SPEC, crate::common::R> {
208        unsafe {
209            crate::common::Reg::<self::Sisr_SPEC, crate::common::R>::from_ptr(
210                self._svd2pac_as_ptr().add(12usize),
211            )
212        }
213    }
214
215    #[doc = "SPI Mode Register"]
216    #[inline(always)]
217    pub const fn spmr(&self) -> &'static crate::common::Reg<self::Spmr_SPEC, crate::common::RW> {
218        unsafe {
219            crate::common::Reg::<self::Spmr_SPEC, crate::common::RW>::from_ptr(
220                self._svd2pac_as_ptr().add(13usize),
221            )
222        }
223    }
224
225    #[doc = "Transmit FIFO Data Register"]
226    #[inline(always)]
227    pub const fn ftdrhl(&self) -> &'static crate::common::Reg<self::Ftdrhl_SPEC, crate::common::W> {
228        unsafe {
229            crate::common::Reg::<self::Ftdrhl_SPEC, crate::common::W>::from_ptr(
230                self._svd2pac_as_ptr().add(14usize),
231            )
232        }
233    }
234
235    #[doc = "Transmit Data Register"]
236    #[inline(always)]
237    pub const fn tdrhl(&self) -> &'static crate::common::Reg<self::Tdrhl_SPEC, crate::common::RW> {
238        unsafe {
239            crate::common::Reg::<self::Tdrhl_SPEC, crate::common::RW>::from_ptr(
240                self._svd2pac_as_ptr().add(14usize),
241            )
242        }
243    }
244
245    #[doc = "Transmit FIFO Data Register"]
246    #[inline(always)]
247    pub const fn ftdrh(&self) -> &'static crate::common::Reg<self::Ftdrh_SPEC, crate::common::W> {
248        unsafe {
249            crate::common::Reg::<self::Ftdrh_SPEC, crate::common::W>::from_ptr(
250                self._svd2pac_as_ptr().add(14usize),
251            )
252        }
253    }
254
255    #[doc = "Transmit FIFO Data Register"]
256    #[inline(always)]
257    pub const fn ftdrl(&self) -> &'static crate::common::Reg<self::Ftdrl_SPEC, crate::common::W> {
258        unsafe {
259            crate::common::Reg::<self::Ftdrl_SPEC, crate::common::W>::from_ptr(
260                self._svd2pac_as_ptr().add(15usize),
261            )
262        }
263    }
264
265    #[doc = "Receive FIFO Data Register"]
266    #[inline(always)]
267    pub const fn frdrhl(&self) -> &'static crate::common::Reg<self::Frdrhl_SPEC, crate::common::R> {
268        unsafe {
269            crate::common::Reg::<self::Frdrhl_SPEC, crate::common::R>::from_ptr(
270                self._svd2pac_as_ptr().add(16usize),
271            )
272        }
273    }
274
275    #[doc = "Receive Data Register"]
276    #[inline(always)]
277    pub const fn rdrhl(&self) -> &'static crate::common::Reg<self::Rdrhl_SPEC, crate::common::R> {
278        unsafe {
279            crate::common::Reg::<self::Rdrhl_SPEC, crate::common::R>::from_ptr(
280                self._svd2pac_as_ptr().add(16usize),
281            )
282        }
283    }
284
285    #[doc = "Receive FIFO Data Register"]
286    #[inline(always)]
287    pub const fn frdrh(&self) -> &'static crate::common::Reg<self::Frdrh_SPEC, crate::common::R> {
288        unsafe {
289            crate::common::Reg::<self::Frdrh_SPEC, crate::common::R>::from_ptr(
290                self._svd2pac_as_ptr().add(16usize),
291            )
292        }
293    }
294
295    #[doc = "Receive FIFO Data Register"]
296    #[inline(always)]
297    pub const fn frdrl(&self) -> &'static crate::common::Reg<self::Frdrl_SPEC, crate::common::R> {
298        unsafe {
299            crate::common::Reg::<self::Frdrl_SPEC, crate::common::R>::from_ptr(
300                self._svd2pac_as_ptr().add(17usize),
301            )
302        }
303    }
304
305    #[doc = "Modulation Duty Register"]
306    #[inline(always)]
307    pub const fn mddr(&self) -> &'static crate::common::Reg<self::Mddr_SPEC, crate::common::RW> {
308        unsafe {
309            crate::common::Reg::<self::Mddr_SPEC, crate::common::RW>::from_ptr(
310                self._svd2pac_as_ptr().add(18usize),
311            )
312        }
313    }
314
315    #[doc = "Data Compare Match Control Register"]
316    #[inline(always)]
317    pub const fn dccr(&self) -> &'static crate::common::Reg<self::Dccr_SPEC, crate::common::RW> {
318        unsafe {
319            crate::common::Reg::<self::Dccr_SPEC, crate::common::RW>::from_ptr(
320                self._svd2pac_as_ptr().add(19usize),
321            )
322        }
323    }
324
325    #[doc = "FIFO Control Register"]
326    #[inline(always)]
327    pub const fn fcr(&self) -> &'static crate::common::Reg<self::Fcr_SPEC, crate::common::RW> {
328        unsafe {
329            crate::common::Reg::<self::Fcr_SPEC, crate::common::RW>::from_ptr(
330                self._svd2pac_as_ptr().add(20usize),
331            )
332        }
333    }
334
335    #[doc = "FIFO Data Count Register"]
336    #[inline(always)]
337    pub const fn fdr(&self) -> &'static crate::common::Reg<self::Fdr_SPEC, crate::common::R> {
338        unsafe {
339            crate::common::Reg::<self::Fdr_SPEC, crate::common::R>::from_ptr(
340                self._svd2pac_as_ptr().add(22usize),
341            )
342        }
343    }
344
345    #[doc = "Line Status Register"]
346    #[inline(always)]
347    pub const fn lsr(&self) -> &'static crate::common::Reg<self::Lsr_SPEC, crate::common::R> {
348        unsafe {
349            crate::common::Reg::<self::Lsr_SPEC, crate::common::R>::from_ptr(
350                self._svd2pac_as_ptr().add(24usize),
351            )
352        }
353    }
354
355    #[doc = "Compare Match Data Register"]
356    #[inline(always)]
357    pub const fn cdr(&self) -> &'static crate::common::Reg<self::Cdr_SPEC, crate::common::RW> {
358        unsafe {
359            crate::common::Reg::<self::Cdr_SPEC, crate::common::RW>::from_ptr(
360                self._svd2pac_as_ptr().add(26usize),
361            )
362        }
363    }
364
365    #[doc = "Serial Port Register"]
366    #[inline(always)]
367    pub const fn sptr(&self) -> &'static crate::common::Reg<self::Sptr_SPEC, crate::common::RW> {
368        unsafe {
369            crate::common::Reg::<self::Sptr_SPEC, crate::common::RW>::from_ptr(
370                self._svd2pac_as_ptr().add(28usize),
371            )
372        }
373    }
374}
375#[doc(hidden)]
376#[derive(Copy, Clone, Eq, PartialEq)]
377pub struct Smr_SPEC;
378impl crate::sealed::RegSpec for Smr_SPEC {
379    type DataType = u8;
380}
381
382#[doc = "Serial Mode Register for Non-Smart Card Interface Mode (SCMR.SMIF = 0)"]
383pub type Smr = crate::RegValueT<Smr_SPEC>;
384
385impl Smr {
386    #[doc = "Clock Select"]
387    #[inline(always)]
388    pub fn cks(
389        self,
390    ) -> crate::common::RegisterField<0, 0x3, 1, 0, smr::Cks, smr::Cks, Smr_SPEC, crate::common::RW>
391    {
392        crate::common::RegisterField::<0,0x3,1,0,smr::Cks,smr::Cks,Smr_SPEC,crate::common::RW>::from_register(self,0)
393    }
394
395    #[doc = "Multi-Processor Mode"]
396    #[inline(always)]
397    pub fn mp(
398        self,
399    ) -> crate::common::RegisterField<2, 0x1, 1, 0, smr::Mp, smr::Mp, Smr_SPEC, crate::common::RW>
400    {
401        crate::common::RegisterField::<2,0x1,1,0,smr::Mp,smr::Mp,Smr_SPEC,crate::common::RW>::from_register(self,0)
402    }
403
404    #[doc = "Stop Bit Length"]
405    #[inline(always)]
406    pub fn stop(
407        self,
408    ) -> crate::common::RegisterField<3, 0x1, 1, 0, smr::Stop, smr::Stop, Smr_SPEC, crate::common::RW>
409    {
410        crate::common::RegisterField::<
411            3,
412            0x1,
413            1,
414            0,
415            smr::Stop,
416            smr::Stop,
417            Smr_SPEC,
418            crate::common::RW,
419        >::from_register(self, 0)
420    }
421
422    #[doc = "Parity Mode"]
423    #[inline(always)]
424    pub fn pm(
425        self,
426    ) -> crate::common::RegisterField<4, 0x1, 1, 0, smr::Pm, smr::Pm, Smr_SPEC, crate::common::RW>
427    {
428        crate::common::RegisterField::<4,0x1,1,0,smr::Pm,smr::Pm,Smr_SPEC,crate::common::RW>::from_register(self,0)
429    }
430
431    #[doc = "Parity Enable"]
432    #[inline(always)]
433    pub fn pe(
434        self,
435    ) -> crate::common::RegisterField<5, 0x1, 1, 0, smr::Pe, smr::Pe, Smr_SPEC, crate::common::RW>
436    {
437        crate::common::RegisterField::<5,0x1,1,0,smr::Pe,smr::Pe,Smr_SPEC,crate::common::RW>::from_register(self,0)
438    }
439
440    #[doc = "Character Length"]
441    #[inline(always)]
442    pub fn chr(
443        self,
444    ) -> crate::common::RegisterField<6, 0x1, 1, 0, smr::Chr, smr::Chr, Smr_SPEC, crate::common::RW>
445    {
446        crate::common::RegisterField::<6,0x1,1,0,smr::Chr,smr::Chr,Smr_SPEC,crate::common::RW>::from_register(self,0)
447    }
448
449    #[doc = "Communication Mode"]
450    #[inline(always)]
451    pub fn cm(
452        self,
453    ) -> crate::common::RegisterField<7, 0x1, 1, 0, smr::Cm, smr::Cm, Smr_SPEC, crate::common::RW>
454    {
455        crate::common::RegisterField::<7,0x1,1,0,smr::Cm,smr::Cm,Smr_SPEC,crate::common::RW>::from_register(self,0)
456    }
457}
458impl ::core::default::Default for Smr {
459    #[inline(always)]
460    fn default() -> Smr {
461        <crate::RegValueT<Smr_SPEC> as RegisterValue<_>>::new(0)
462    }
463}
464pub mod smr {
465
466    #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
467    pub struct Cks_SPEC;
468    pub type Cks = crate::EnumBitfieldStruct<u8, Cks_SPEC>;
469    impl Cks {
470        #[doc = "PCLK clock (n = 0)"]
471        pub const _00: Self = Self::new(0);
472
473        #[doc = "PCLK/4 clock (n = 1)"]
474        pub const _01: Self = Self::new(1);
475
476        #[doc = "PCLK/16 clock (n = 2)"]
477        pub const _10: Self = Self::new(2);
478
479        #[doc = "PCLK/64 clock (n = 3)"]
480        pub const _11: Self = Self::new(3);
481    }
482    #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
483    pub struct Mp_SPEC;
484    pub type Mp = crate::EnumBitfieldStruct<u8, Mp_SPEC>;
485    impl Mp {
486        #[doc = "Disable multi-processor communications function"]
487        pub const _0: Self = Self::new(0);
488
489        #[doc = "Enable multi-processor communications function"]
490        pub const _1: Self = Self::new(1);
491    }
492    #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
493    pub struct Stop_SPEC;
494    pub type Stop = crate::EnumBitfieldStruct<u8, Stop_SPEC>;
495    impl Stop {
496        #[doc = "1 stop bit"]
497        pub const _0: Self = Self::new(0);
498
499        #[doc = "2 stop bits"]
500        pub const _1: Self = Self::new(1);
501    }
502    #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
503    pub struct Pm_SPEC;
504    pub type Pm = crate::EnumBitfieldStruct<u8, Pm_SPEC>;
505    impl Pm {
506        #[doc = "Even parity"]
507        pub const _0: Self = Self::new(0);
508
509        #[doc = "Odd parity"]
510        pub const _1: Self = Self::new(1);
511    }
512    #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
513    pub struct Pe_SPEC;
514    pub type Pe = crate::EnumBitfieldStruct<u8, Pe_SPEC>;
515    impl Pe {
516        #[doc = "When transmitting: Do not add parity bit When receiving: Do not check parity bit"]
517        pub const _0: Self = Self::new(0);
518
519        #[doc = "When transmitting: Add parity bit When receiving: Check parity bit"]
520        pub const _1: Self = Self::new(1);
521    }
522    #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
523    pub struct Chr_SPEC;
524    pub type Chr = crate::EnumBitfieldStruct<u8, Chr_SPEC>;
525    impl Chr {
526        #[doc = "SCMR.CHR1 = 0: Transmit/receive in 9-bit data length SCMR.CHR1 = 1: Transmit/receive in 8-bit data length (initial value)"]
527        pub const _0: Self = Self::new(0);
528
529        #[doc = "SCMR.CHR1 = 0: Transmit/receive in 9-bit data length SCMR.CHR1 = 1: Transmit/receive in 7-bit data length"]
530        pub const _1: Self = Self::new(1);
531    }
532    #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
533    pub struct Cm_SPEC;
534    pub type Cm = crate::EnumBitfieldStruct<u8, Cm_SPEC>;
535    impl Cm {
536        #[doc = "Asynchronous mode or simple IIC mode"]
537        pub const _0: Self = Self::new(0);
538
539        #[doc = "Clock synchronous mode or simple SPI mode"]
540        pub const _1: Self = Self::new(1);
541    }
542}
543#[doc(hidden)]
544#[derive(Copy, Clone, Eq, PartialEq)]
545pub struct SmrSmci_SPEC;
546impl crate::sealed::RegSpec for SmrSmci_SPEC {
547    type DataType = u8;
548}
549
550#[doc = "Serial Mode Register for Smart Card Interface Mode (SCMR.SMIF = 1)"]
551pub type SmrSmci = crate::RegValueT<SmrSmci_SPEC>;
552
553impl SmrSmci {
554    #[doc = "Clock Select"]
555    #[inline(always)]
556    pub fn cks(
557        self,
558    ) -> crate::common::RegisterField<
559        0,
560        0x3,
561        1,
562        0,
563        smr_smci::Cks,
564        smr_smci::Cks,
565        SmrSmci_SPEC,
566        crate::common::RW,
567    > {
568        crate::common::RegisterField::<
569            0,
570            0x3,
571            1,
572            0,
573            smr_smci::Cks,
574            smr_smci::Cks,
575            SmrSmci_SPEC,
576            crate::common::RW,
577        >::from_register(self, 0)
578    }
579
580    #[doc = "Base Clock Pulse"]
581    #[inline(always)]
582    pub fn bcp(
583        self,
584    ) -> crate::common::RegisterField<2, 0x3, 1, 0, u8, u8, SmrSmci_SPEC, crate::common::RW> {
585        crate::common::RegisterField::<2,0x3,1,0,u8,u8,SmrSmci_SPEC,crate::common::RW>::from_register(self,0)
586    }
587
588    #[doc = "Parity Mode"]
589    #[inline(always)]
590    pub fn pm(
591        self,
592    ) -> crate::common::RegisterField<
593        4,
594        0x1,
595        1,
596        0,
597        smr_smci::Pm,
598        smr_smci::Pm,
599        SmrSmci_SPEC,
600        crate::common::RW,
601    > {
602        crate::common::RegisterField::<
603            4,
604            0x1,
605            1,
606            0,
607            smr_smci::Pm,
608            smr_smci::Pm,
609            SmrSmci_SPEC,
610            crate::common::RW,
611        >::from_register(self, 0)
612    }
613
614    #[doc = "Parity Enable"]
615    #[inline(always)]
616    pub fn pe(self) -> crate::common::RegisterFieldBool<5, 1, 0, SmrSmci_SPEC, crate::common::RW> {
617        crate::common::RegisterFieldBool::<5, 1, 0, SmrSmci_SPEC, crate::common::RW>::from_register(
618            self, 0,
619        )
620    }
621
622    #[doc = "Block Transfer Mode"]
623    #[inline(always)]
624    pub fn blk(
625        self,
626    ) -> crate::common::RegisterField<
627        6,
628        0x1,
629        1,
630        0,
631        smr_smci::Blk,
632        smr_smci::Blk,
633        SmrSmci_SPEC,
634        crate::common::RW,
635    > {
636        crate::common::RegisterField::<
637            6,
638            0x1,
639            1,
640            0,
641            smr_smci::Blk,
642            smr_smci::Blk,
643            SmrSmci_SPEC,
644            crate::common::RW,
645        >::from_register(self, 0)
646    }
647
648    #[doc = "GSM Mode"]
649    #[inline(always)]
650    pub fn gm(
651        self,
652    ) -> crate::common::RegisterField<
653        7,
654        0x1,
655        1,
656        0,
657        smr_smci::Gm,
658        smr_smci::Gm,
659        SmrSmci_SPEC,
660        crate::common::RW,
661    > {
662        crate::common::RegisterField::<
663            7,
664            0x1,
665            1,
666            0,
667            smr_smci::Gm,
668            smr_smci::Gm,
669            SmrSmci_SPEC,
670            crate::common::RW,
671        >::from_register(self, 0)
672    }
673}
674impl ::core::default::Default for SmrSmci {
675    #[inline(always)]
676    fn default() -> SmrSmci {
677        <crate::RegValueT<SmrSmci_SPEC> as RegisterValue<_>>::new(0)
678    }
679}
680pub mod smr_smci {
681
682    #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
683    pub struct Cks_SPEC;
684    pub type Cks = crate::EnumBitfieldStruct<u8, Cks_SPEC>;
685    impl Cks {
686        #[doc = "PCLK clock (n = 0)"]
687        pub const _00: Self = Self::new(0);
688
689        #[doc = "PCLK/4 clock (n = 1)"]
690        pub const _01: Self = Self::new(1);
691
692        #[doc = "PCLK/16 clock (n = 2)"]
693        pub const _10: Self = Self::new(2);
694
695        #[doc = "PCLK/64 clock (n = 3)"]
696        pub const _11: Self = Self::new(3);
697    }
698    #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
699    pub struct Pm_SPEC;
700    pub type Pm = crate::EnumBitfieldStruct<u8, Pm_SPEC>;
701    impl Pm {
702        #[doc = "Even parity"]
703        pub const _0: Self = Self::new(0);
704
705        #[doc = "Odd parity"]
706        pub const _1: Self = Self::new(1);
707    }
708    #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
709    pub struct Blk_SPEC;
710    pub type Blk = crate::EnumBitfieldStruct<u8, Blk_SPEC>;
711    impl Blk {
712        #[doc = "Normal mode operation"]
713        pub const _0: Self = Self::new(0);
714
715        #[doc = "Block transfer mode operation"]
716        pub const _1: Self = Self::new(1);
717    }
718    #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
719    pub struct Gm_SPEC;
720    pub type Gm = crate::EnumBitfieldStruct<u8, Gm_SPEC>;
721    impl Gm {
722        #[doc = "Normal mode operation"]
723        pub const _0: Self = Self::new(0);
724
725        #[doc = "GSM mode operation"]
726        pub const _1: Self = Self::new(1);
727    }
728}
729#[doc(hidden)]
730#[derive(Copy, Clone, Eq, PartialEq)]
731pub struct Brr_SPEC;
732impl crate::sealed::RegSpec for Brr_SPEC {
733    type DataType = u8;
734}
735
736#[doc = "Bit Rate Register"]
737pub type Brr = crate::RegValueT<Brr_SPEC>;
738
739impl NoBitfieldReg<Brr_SPEC> for Brr {}
740impl ::core::default::Default for Brr {
741    #[inline(always)]
742    fn default() -> Brr {
743        <crate::RegValueT<Brr_SPEC> as RegisterValue<_>>::new(255)
744    }
745}
746
747#[doc(hidden)]
748#[derive(Copy, Clone, Eq, PartialEq)]
749pub struct Scr_SPEC;
750impl crate::sealed::RegSpec for Scr_SPEC {
751    type DataType = u8;
752}
753
754#[doc = "Serial Control Register for Non-Smart Card Interface Mode (SCMR.SMIF = 0)"]
755pub type Scr = crate::RegValueT<Scr_SPEC>;
756
757impl Scr {
758    #[doc = "Clock Enable"]
759    #[inline(always)]
760    pub fn cke(
761        self,
762    ) -> crate::common::RegisterField<0, 0x3, 1, 0, scr::Cke, scr::Cke, Scr_SPEC, crate::common::RW>
763    {
764        crate::common::RegisterField::<0,0x3,1,0,scr::Cke,scr::Cke,Scr_SPEC,crate::common::RW>::from_register(self,0)
765    }
766
767    #[doc = "Transmit End Interrupt Enable"]
768    #[inline(always)]
769    pub fn teie(
770        self,
771    ) -> crate::common::RegisterField<2, 0x1, 1, 0, scr::Teie, scr::Teie, Scr_SPEC, crate::common::RW>
772    {
773        crate::common::RegisterField::<
774            2,
775            0x1,
776            1,
777            0,
778            scr::Teie,
779            scr::Teie,
780            Scr_SPEC,
781            crate::common::RW,
782        >::from_register(self, 0)
783    }
784
785    #[doc = "Multi-Processor Interrupt Enable"]
786    #[inline(always)]
787    pub fn mpie(
788        self,
789    ) -> crate::common::RegisterField<3, 0x1, 1, 0, scr::Mpie, scr::Mpie, Scr_SPEC, crate::common::RW>
790    {
791        crate::common::RegisterField::<
792            3,
793            0x1,
794            1,
795            0,
796            scr::Mpie,
797            scr::Mpie,
798            Scr_SPEC,
799            crate::common::RW,
800        >::from_register(self, 0)
801    }
802
803    #[doc = "Receive Enable"]
804    #[inline(always)]
805    pub fn re(
806        self,
807    ) -> crate::common::RegisterField<4, 0x1, 1, 0, scr::Re, scr::Re, Scr_SPEC, crate::common::RW>
808    {
809        crate::common::RegisterField::<4,0x1,1,0,scr::Re,scr::Re,Scr_SPEC,crate::common::RW>::from_register(self,0)
810    }
811
812    #[doc = "Transmit Enable"]
813    #[inline(always)]
814    pub fn te(
815        self,
816    ) -> crate::common::RegisterField<5, 0x1, 1, 0, scr::Te, scr::Te, Scr_SPEC, crate::common::RW>
817    {
818        crate::common::RegisterField::<5,0x1,1,0,scr::Te,scr::Te,Scr_SPEC,crate::common::RW>::from_register(self,0)
819    }
820
821    #[doc = "Receive Interrupt Enable"]
822    #[inline(always)]
823    pub fn rie(
824        self,
825    ) -> crate::common::RegisterField<6, 0x1, 1, 0, scr::Rie, scr::Rie, Scr_SPEC, crate::common::RW>
826    {
827        crate::common::RegisterField::<6,0x1,1,0,scr::Rie,scr::Rie,Scr_SPEC,crate::common::RW>::from_register(self,0)
828    }
829
830    #[doc = "Transmit Interrupt Enable"]
831    #[inline(always)]
832    pub fn tie(
833        self,
834    ) -> crate::common::RegisterField<7, 0x1, 1, 0, scr::Tie, scr::Tie, Scr_SPEC, crate::common::RW>
835    {
836        crate::common::RegisterField::<7,0x1,1,0,scr::Tie,scr::Tie,Scr_SPEC,crate::common::RW>::from_register(self,0)
837    }
838}
839impl ::core::default::Default for Scr {
840    #[inline(always)]
841    fn default() -> Scr {
842        <crate::RegValueT<Scr_SPEC> as RegisterValue<_>>::new(0)
843    }
844}
845pub mod scr {
846
847    #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
848    pub struct Cke_SPEC;
849    pub type Cke = crate::EnumBitfieldStruct<u8, Cke_SPEC>;
850    impl Cke {
851        #[doc = "In asynchronous mode, the SCKn pin is available for use as an I/O port based on the I/O port settings. In clock synchronous mode, the SCKn pin functions as the clock output pin."]
852        pub const _00: Self = Self::new(0);
853
854        #[doc = "In asynchronous mode, a clock with the same frequency as the bit rate is output from the SCKn pin. In clock synchronous mode, the SCKn pin functions as the clock output pin."]
855        pub const _01: Self = Self::new(1);
856    }
857    #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
858    pub struct Teie_SPEC;
859    pub type Teie = crate::EnumBitfieldStruct<u8, Teie_SPEC>;
860    impl Teie {
861        #[doc = "Disable SCIn_TEI interrupt requests"]
862        pub const _0: Self = Self::new(0);
863
864        #[doc = "Enable SCIn_TEI interrupt requests"]
865        pub const _1: Self = Self::new(1);
866    }
867    #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
868    pub struct Mpie_SPEC;
869    pub type Mpie = crate::EnumBitfieldStruct<u8, Mpie_SPEC>;
870    impl Mpie {
871        #[doc = "Normal reception"]
872        pub const _0: Self = Self::new(0);
873
874        #[doc = "When data with the multi-processor bit set to 0 is received, the data is not read, and setting the status flags RDRF, ORER, and FER in SSR to 1 is disabled. When data with the multi-processor bit set to 1 is received, the MPIE bit is automatically set to 0, and normal reception is resumed."]
875        pub const _1: Self = Self::new(1);
876    }
877    #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
878    pub struct Re_SPEC;
879    pub type Re = crate::EnumBitfieldStruct<u8, Re_SPEC>;
880    impl Re {
881        #[doc = "Disable serial reception"]
882        pub const _0: Self = Self::new(0);
883
884        #[doc = "Enable serial reception"]
885        pub const _1: Self = Self::new(1);
886    }
887    #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
888    pub struct Te_SPEC;
889    pub type Te = crate::EnumBitfieldStruct<u8, Te_SPEC>;
890    impl Te {
891        #[doc = "Disable serial transmission"]
892        pub const _0: Self = Self::new(0);
893
894        #[doc = "Enable serial transmission"]
895        pub const _1: Self = Self::new(1);
896    }
897    #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
898    pub struct Rie_SPEC;
899    pub type Rie = crate::EnumBitfieldStruct<u8, Rie_SPEC>;
900    impl Rie {
901        #[doc = "Disable SCIn_RXI and SCIn_ERI interrupt requests"]
902        pub const _0: Self = Self::new(0);
903
904        #[doc = "Enable SCIn_RXI and SCIn_ERI interrupt requests"]
905        pub const _1: Self = Self::new(1);
906    }
907    #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
908    pub struct Tie_SPEC;
909    pub type Tie = crate::EnumBitfieldStruct<u8, Tie_SPEC>;
910    impl Tie {
911        #[doc = "Disable SCIn_TXI interrupt requests"]
912        pub const _0: Self = Self::new(0);
913
914        #[doc = "Enable SCIn_TXI interrupt requests"]
915        pub const _1: Self = Self::new(1);
916    }
917}
918#[doc(hidden)]
919#[derive(Copy, Clone, Eq, PartialEq)]
920pub struct ScrSmci_SPEC;
921impl crate::sealed::RegSpec for ScrSmci_SPEC {
922    type DataType = u8;
923}
924
925#[doc = "Serial Control Register for Smart Card Interface Mode (SCMR.SMIF = 1)"]
926pub type ScrSmci = crate::RegValueT<ScrSmci_SPEC>;
927
928impl ScrSmci {
929    #[doc = "Clock Enable"]
930    #[inline(always)]
931    pub fn cke(
932        self,
933    ) -> crate::common::RegisterField<
934        0,
935        0x3,
936        1,
937        0,
938        scr_smci::Cke,
939        scr_smci::Cke,
940        ScrSmci_SPEC,
941        crate::common::RW,
942    > {
943        crate::common::RegisterField::<
944            0,
945            0x3,
946            1,
947            0,
948            scr_smci::Cke,
949            scr_smci::Cke,
950            ScrSmci_SPEC,
951            crate::common::RW,
952        >::from_register(self, 0)
953    }
954
955    #[doc = "Transmit End Interrupt Enable"]
956    #[inline(always)]
957    pub fn teie(
958        self,
959    ) -> crate::common::RegisterFieldBool<2, 1, 0, ScrSmci_SPEC, crate::common::RW> {
960        crate::common::RegisterFieldBool::<2, 1, 0, ScrSmci_SPEC, crate::common::RW>::from_register(
961            self, 0,
962        )
963    }
964
965    #[doc = "Multi-Processor Interrupt Enable"]
966    #[inline(always)]
967    pub fn mpie(
968        self,
969    ) -> crate::common::RegisterFieldBool<3, 1, 0, ScrSmci_SPEC, crate::common::RW> {
970        crate::common::RegisterFieldBool::<3, 1, 0, ScrSmci_SPEC, crate::common::RW>::from_register(
971            self, 0,
972        )
973    }
974
975    #[doc = "Receive Enable"]
976    #[inline(always)]
977    pub fn re(
978        self,
979    ) -> crate::common::RegisterField<
980        4,
981        0x1,
982        1,
983        0,
984        scr_smci::Re,
985        scr_smci::Re,
986        ScrSmci_SPEC,
987        crate::common::RW,
988    > {
989        crate::common::RegisterField::<
990            4,
991            0x1,
992            1,
993            0,
994            scr_smci::Re,
995            scr_smci::Re,
996            ScrSmci_SPEC,
997            crate::common::RW,
998        >::from_register(self, 0)
999    }
1000
1001    #[doc = "Transmit Enable"]
1002    #[inline(always)]
1003    pub fn te(
1004        self,
1005    ) -> crate::common::RegisterField<
1006        5,
1007        0x1,
1008        1,
1009        0,
1010        scr_smci::Te,
1011        scr_smci::Te,
1012        ScrSmci_SPEC,
1013        crate::common::RW,
1014    > {
1015        crate::common::RegisterField::<
1016            5,
1017            0x1,
1018            1,
1019            0,
1020            scr_smci::Te,
1021            scr_smci::Te,
1022            ScrSmci_SPEC,
1023            crate::common::RW,
1024        >::from_register(self, 0)
1025    }
1026
1027    #[doc = "Receive Interrupt Enable"]
1028    #[inline(always)]
1029    pub fn rie(
1030        self,
1031    ) -> crate::common::RegisterField<
1032        6,
1033        0x1,
1034        1,
1035        0,
1036        scr_smci::Rie,
1037        scr_smci::Rie,
1038        ScrSmci_SPEC,
1039        crate::common::RW,
1040    > {
1041        crate::common::RegisterField::<
1042            6,
1043            0x1,
1044            1,
1045            0,
1046            scr_smci::Rie,
1047            scr_smci::Rie,
1048            ScrSmci_SPEC,
1049            crate::common::RW,
1050        >::from_register(self, 0)
1051    }
1052
1053    #[doc = "Transmit Interrupt Enable"]
1054    #[inline(always)]
1055    pub fn tie(
1056        self,
1057    ) -> crate::common::RegisterField<
1058        7,
1059        0x1,
1060        1,
1061        0,
1062        scr_smci::Tie,
1063        scr_smci::Tie,
1064        ScrSmci_SPEC,
1065        crate::common::RW,
1066    > {
1067        crate::common::RegisterField::<
1068            7,
1069            0x1,
1070            1,
1071            0,
1072            scr_smci::Tie,
1073            scr_smci::Tie,
1074            ScrSmci_SPEC,
1075            crate::common::RW,
1076        >::from_register(self, 0)
1077    }
1078}
1079impl ::core::default::Default for ScrSmci {
1080    #[inline(always)]
1081    fn default() -> ScrSmci {
1082        <crate::RegValueT<ScrSmci_SPEC> as RegisterValue<_>>::new(0)
1083    }
1084}
1085pub mod scr_smci {
1086
1087    #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
1088    pub struct Cke_SPEC;
1089    pub type Cke = crate::EnumBitfieldStruct<u8, Cke_SPEC>;
1090    impl Cke {
1091        #[doc = "When SMR_SMCI.GM = 0: Disable output The SCKn pin is available for use as an I/O port if set up in the I/O port settings When SMR_SMCI.GM = 1: Fix output low"]
1092        pub const _00: Self = Self::new(0);
1093
1094        #[doc = "When SMR_SMCI.GM = 0: Output clock When SMR_SMCI.GM = 1: Output clock"]
1095        pub const _01: Self = Self::new(1);
1096
1097        #[doc = "When SMR_SMCI.GM = 0: Setting prohibited When SMR_SMCI.GM = 1: Fix output high"]
1098        pub const _10: Self = Self::new(2);
1099
1100        #[doc = "When SMR_SMCI.GM = 0: Setting prohibited When SMR_SMCI.GM = 1: Output clock"]
1101        pub const _11: Self = Self::new(3);
1102    }
1103    #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
1104    pub struct Re_SPEC;
1105    pub type Re = crate::EnumBitfieldStruct<u8, Re_SPEC>;
1106    impl Re {
1107        #[doc = "Disable serial reception"]
1108        pub const _0: Self = Self::new(0);
1109
1110        #[doc = "Enable serial reception"]
1111        pub const _1: Self = Self::new(1);
1112    }
1113    #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
1114    pub struct Te_SPEC;
1115    pub type Te = crate::EnumBitfieldStruct<u8, Te_SPEC>;
1116    impl Te {
1117        #[doc = "Disable serial transmission"]
1118        pub const _0: Self = Self::new(0);
1119
1120        #[doc = "Enable serial transmission"]
1121        pub const _1: Self = Self::new(1);
1122    }
1123    #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
1124    pub struct Rie_SPEC;
1125    pub type Rie = crate::EnumBitfieldStruct<u8, Rie_SPEC>;
1126    impl Rie {
1127        #[doc = "Disable SCIn_RXI and SCIn_ERI interrupt requests"]
1128        pub const _0: Self = Self::new(0);
1129
1130        #[doc = "Enable SCIn_RXI and SCIn_ERI interrupt requests"]
1131        pub const _1: Self = Self::new(1);
1132    }
1133    #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
1134    pub struct Tie_SPEC;
1135    pub type Tie = crate::EnumBitfieldStruct<u8, Tie_SPEC>;
1136    impl Tie {
1137        #[doc = "Disable SCIn_TXI interrupt requests"]
1138        pub const _0: Self = Self::new(0);
1139
1140        #[doc = "Enable SCIn_TXI interrupt requests"]
1141        pub const _1: Self = Self::new(1);
1142    }
1143}
1144#[doc(hidden)]
1145#[derive(Copy, Clone, Eq, PartialEq)]
1146pub struct Tdr_SPEC;
1147impl crate::sealed::RegSpec for Tdr_SPEC {
1148    type DataType = u8;
1149}
1150
1151#[doc = "Transmit Data Register"]
1152pub type Tdr = crate::RegValueT<Tdr_SPEC>;
1153
1154impl NoBitfieldReg<Tdr_SPEC> for Tdr {}
1155impl ::core::default::Default for Tdr {
1156    #[inline(always)]
1157    fn default() -> Tdr {
1158        <crate::RegValueT<Tdr_SPEC> as RegisterValue<_>>::new(255)
1159    }
1160}
1161
1162#[doc(hidden)]
1163#[derive(Copy, Clone, Eq, PartialEq)]
1164pub struct Ssr_SPEC;
1165impl crate::sealed::RegSpec for Ssr_SPEC {
1166    type DataType = u8;
1167}
1168
1169#[doc = "Serial Status Register for Non-Smart Card Interface and Non-FIFO Mode (SCMR.SMIF = 0, FCR.FM = 0)"]
1170pub type Ssr = crate::RegValueT<Ssr_SPEC>;
1171
1172impl Ssr {
1173    #[doc = "Multi-Processor Bit Transfer"]
1174    #[inline(always)]
1175    pub fn mpbt(
1176        self,
1177    ) -> crate::common::RegisterField<0, 0x1, 1, 0, ssr::Mpbt, ssr::Mpbt, Ssr_SPEC, crate::common::RW>
1178    {
1179        crate::common::RegisterField::<
1180            0,
1181            0x1,
1182            1,
1183            0,
1184            ssr::Mpbt,
1185            ssr::Mpbt,
1186            Ssr_SPEC,
1187            crate::common::RW,
1188        >::from_register(self, 0)
1189    }
1190
1191    #[doc = "Multi-Processor"]
1192    #[inline(always)]
1193    pub fn mpb(
1194        self,
1195    ) -> crate::common::RegisterField<1, 0x1, 1, 0, ssr::Mpb, ssr::Mpb, Ssr_SPEC, crate::common::R>
1196    {
1197        crate::common::RegisterField::<1,0x1,1,0,ssr::Mpb,ssr::Mpb,Ssr_SPEC,crate::common::R>::from_register(self,0)
1198    }
1199
1200    #[doc = "Transmit End Flag"]
1201    #[inline(always)]
1202    pub fn tend(
1203        self,
1204    ) -> crate::common::RegisterField<2, 0x1, 1, 0, ssr::Tend, ssr::Tend, Ssr_SPEC, crate::common::R>
1205    {
1206        crate::common::RegisterField::<2,0x1,1,0,ssr::Tend,ssr::Tend,Ssr_SPEC,crate::common::R>::from_register(self,0)
1207    }
1208
1209    #[doc = "Parity Error Flag"]
1210    #[inline(always)]
1211    pub fn per(
1212        self,
1213    ) -> crate::common::RegisterField<3, 0x1, 1, 0, ssr::Per, ssr::Per, Ssr_SPEC, crate::common::RW>
1214    {
1215        crate::common::RegisterField::<3,0x1,1,0,ssr::Per,ssr::Per,Ssr_SPEC,crate::common::RW>::from_register(self,0)
1216    }
1217
1218    #[doc = "Framing Error Flag"]
1219    #[inline(always)]
1220    pub fn fer(
1221        self,
1222    ) -> crate::common::RegisterField<4, 0x1, 1, 0, ssr::Fer, ssr::Fer, Ssr_SPEC, crate::common::RW>
1223    {
1224        crate::common::RegisterField::<4,0x1,1,0,ssr::Fer,ssr::Fer,Ssr_SPEC,crate::common::RW>::from_register(self,0)
1225    }
1226
1227    #[doc = "Overrun Error Flag"]
1228    #[inline(always)]
1229    pub fn orer(
1230        self,
1231    ) -> crate::common::RegisterField<5, 0x1, 1, 0, ssr::Orer, ssr::Orer, Ssr_SPEC, crate::common::RW>
1232    {
1233        crate::common::RegisterField::<
1234            5,
1235            0x1,
1236            1,
1237            0,
1238            ssr::Orer,
1239            ssr::Orer,
1240            Ssr_SPEC,
1241            crate::common::RW,
1242        >::from_register(self, 0)
1243    }
1244
1245    #[doc = "Receive Data Full Flag"]
1246    #[inline(always)]
1247    pub fn rdrf(
1248        self,
1249    ) -> crate::common::RegisterField<6, 0x1, 1, 0, ssr::Rdrf, ssr::Rdrf, Ssr_SPEC, crate::common::RW>
1250    {
1251        crate::common::RegisterField::<
1252            6,
1253            0x1,
1254            1,
1255            0,
1256            ssr::Rdrf,
1257            ssr::Rdrf,
1258            Ssr_SPEC,
1259            crate::common::RW,
1260        >::from_register(self, 0)
1261    }
1262
1263    #[doc = "Transmit Data Empty Flag"]
1264    #[inline(always)]
1265    pub fn tdre(
1266        self,
1267    ) -> crate::common::RegisterField<7, 0x1, 1, 0, ssr::Tdre, ssr::Tdre, Ssr_SPEC, crate::common::RW>
1268    {
1269        crate::common::RegisterField::<
1270            7,
1271            0x1,
1272            1,
1273            0,
1274            ssr::Tdre,
1275            ssr::Tdre,
1276            Ssr_SPEC,
1277            crate::common::RW,
1278        >::from_register(self, 0)
1279    }
1280}
1281impl ::core::default::Default for Ssr {
1282    #[inline(always)]
1283    fn default() -> Ssr {
1284        <crate::RegValueT<Ssr_SPEC> as RegisterValue<_>>::new(132)
1285    }
1286}
1287pub mod ssr {
1288
1289    #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
1290    pub struct Mpbt_SPEC;
1291    pub type Mpbt = crate::EnumBitfieldStruct<u8, Mpbt_SPEC>;
1292    impl Mpbt {
1293        #[doc = "Data transmission cycle"]
1294        pub const _0: Self = Self::new(0);
1295
1296        #[doc = "ID transmission cycle"]
1297        pub const _1: Self = Self::new(1);
1298    }
1299    #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
1300    pub struct Mpb_SPEC;
1301    pub type Mpb = crate::EnumBitfieldStruct<u8, Mpb_SPEC>;
1302    impl Mpb {
1303        #[doc = "Data transmission cycle"]
1304        pub const _0: Self = Self::new(0);
1305
1306        #[doc = "ID transmission cycle"]
1307        pub const _1: Self = Self::new(1);
1308    }
1309    #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
1310    pub struct Tend_SPEC;
1311    pub type Tend = crate::EnumBitfieldStruct<u8, Tend_SPEC>;
1312    impl Tend {
1313        #[doc = "A character is being transmitted"]
1314        pub const _0: Self = Self::new(0);
1315
1316        #[doc = "Character transfer is complete"]
1317        pub const _1: Self = Self::new(1);
1318    }
1319    #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
1320    pub struct Per_SPEC;
1321    pub type Per = crate::EnumBitfieldStruct<u8, Per_SPEC>;
1322    impl Per {
1323        #[doc = "No parity error occurred"]
1324        pub const _0: Self = Self::new(0);
1325
1326        #[doc = "Parity error occurred"]
1327        pub const _1: Self = Self::new(1);
1328    }
1329    #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
1330    pub struct Fer_SPEC;
1331    pub type Fer = crate::EnumBitfieldStruct<u8, Fer_SPEC>;
1332    impl Fer {
1333        #[doc = "No framing error occurred"]
1334        pub const _0: Self = Self::new(0);
1335
1336        #[doc = "Framing error occurred"]
1337        pub const _1: Self = Self::new(1);
1338    }
1339    #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
1340    pub struct Orer_SPEC;
1341    pub type Orer = crate::EnumBitfieldStruct<u8, Orer_SPEC>;
1342    impl Orer {
1343        #[doc = "No overrun error occurred"]
1344        pub const _0: Self = Self::new(0);
1345
1346        #[doc = "Overrun error occurred"]
1347        pub const _1: Self = Self::new(1);
1348    }
1349    #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
1350    pub struct Rdrf_SPEC;
1351    pub type Rdrf = crate::EnumBitfieldStruct<u8, Rdrf_SPEC>;
1352    impl Rdrf {
1353        #[doc = "No received data in RDR register"]
1354        pub const _0: Self = Self::new(0);
1355
1356        #[doc = "Received data in RDR register"]
1357        pub const _1: Self = Self::new(1);
1358    }
1359    #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
1360    pub struct Tdre_SPEC;
1361    pub type Tdre = crate::EnumBitfieldStruct<u8, Tdre_SPEC>;
1362    impl Tdre {
1363        #[doc = "Transmit data in TDR register"]
1364        pub const _0: Self = Self::new(0);
1365
1366        #[doc = "No transmit data in TDR register"]
1367        pub const _1: Self = Self::new(1);
1368    }
1369}
1370#[doc(hidden)]
1371#[derive(Copy, Clone, Eq, PartialEq)]
1372pub struct SsrFifo_SPEC;
1373impl crate::sealed::RegSpec for SsrFifo_SPEC {
1374    type DataType = u8;
1375}
1376
1377#[doc = "Serial Status Register for Non-Smart Card Interface and FIFO Mode (SCMR.SMIF = 0, FCR.FM = 1)"]
1378pub type SsrFifo = crate::RegValueT<SsrFifo_SPEC>;
1379
1380impl SsrFifo {
1381    #[doc = "Receive Data Ready Flag"]
1382    #[inline(always)]
1383    pub fn dr(
1384        self,
1385    ) -> crate::common::RegisterField<
1386        0,
1387        0x1,
1388        1,
1389        0,
1390        ssr_fifo::Dr,
1391        ssr_fifo::Dr,
1392        SsrFifo_SPEC,
1393        crate::common::RW,
1394    > {
1395        crate::common::RegisterField::<
1396            0,
1397            0x1,
1398            1,
1399            0,
1400            ssr_fifo::Dr,
1401            ssr_fifo::Dr,
1402            SsrFifo_SPEC,
1403            crate::common::RW,
1404        >::from_register(self, 0)
1405    }
1406
1407    #[doc = "Transmit End Flag"]
1408    #[inline(always)]
1409    pub fn tend(
1410        self,
1411    ) -> crate::common::RegisterField<
1412        2,
1413        0x1,
1414        1,
1415        0,
1416        ssr_fifo::Tend,
1417        ssr_fifo::Tend,
1418        SsrFifo_SPEC,
1419        crate::common::RW,
1420    > {
1421        crate::common::RegisterField::<
1422            2,
1423            0x1,
1424            1,
1425            0,
1426            ssr_fifo::Tend,
1427            ssr_fifo::Tend,
1428            SsrFifo_SPEC,
1429            crate::common::RW,
1430        >::from_register(self, 0)
1431    }
1432
1433    #[doc = "Parity Error Flag"]
1434    #[inline(always)]
1435    pub fn per(
1436        self,
1437    ) -> crate::common::RegisterField<
1438        3,
1439        0x1,
1440        1,
1441        0,
1442        ssr_fifo::Per,
1443        ssr_fifo::Per,
1444        SsrFifo_SPEC,
1445        crate::common::RW,
1446    > {
1447        crate::common::RegisterField::<
1448            3,
1449            0x1,
1450            1,
1451            0,
1452            ssr_fifo::Per,
1453            ssr_fifo::Per,
1454            SsrFifo_SPEC,
1455            crate::common::RW,
1456        >::from_register(self, 0)
1457    }
1458
1459    #[doc = "Framing Error Flag"]
1460    #[inline(always)]
1461    pub fn fer(
1462        self,
1463    ) -> crate::common::RegisterField<
1464        4,
1465        0x1,
1466        1,
1467        0,
1468        ssr_fifo::Fer,
1469        ssr_fifo::Fer,
1470        SsrFifo_SPEC,
1471        crate::common::RW,
1472    > {
1473        crate::common::RegisterField::<
1474            4,
1475            0x1,
1476            1,
1477            0,
1478            ssr_fifo::Fer,
1479            ssr_fifo::Fer,
1480            SsrFifo_SPEC,
1481            crate::common::RW,
1482        >::from_register(self, 0)
1483    }
1484
1485    #[doc = "Overrun Error Flag"]
1486    #[inline(always)]
1487    pub fn orer(
1488        self,
1489    ) -> crate::common::RegisterField<
1490        5,
1491        0x1,
1492        1,
1493        0,
1494        ssr_fifo::Orer,
1495        ssr_fifo::Orer,
1496        SsrFifo_SPEC,
1497        crate::common::RW,
1498    > {
1499        crate::common::RegisterField::<
1500            5,
1501            0x1,
1502            1,
1503            0,
1504            ssr_fifo::Orer,
1505            ssr_fifo::Orer,
1506            SsrFifo_SPEC,
1507            crate::common::RW,
1508        >::from_register(self, 0)
1509    }
1510
1511    #[doc = "Receive FIFO Data Full Flag"]
1512    #[inline(always)]
1513    pub fn rdf(
1514        self,
1515    ) -> crate::common::RegisterField<
1516        6,
1517        0x1,
1518        1,
1519        0,
1520        ssr_fifo::Rdf,
1521        ssr_fifo::Rdf,
1522        SsrFifo_SPEC,
1523        crate::common::RW,
1524    > {
1525        crate::common::RegisterField::<
1526            6,
1527            0x1,
1528            1,
1529            0,
1530            ssr_fifo::Rdf,
1531            ssr_fifo::Rdf,
1532            SsrFifo_SPEC,
1533            crate::common::RW,
1534        >::from_register(self, 0)
1535    }
1536
1537    #[doc = "Transmit FIFO Data Empty Flag"]
1538    #[inline(always)]
1539    pub fn tdfe(
1540        self,
1541    ) -> crate::common::RegisterField<
1542        7,
1543        0x1,
1544        1,
1545        0,
1546        ssr_fifo::Tdfe,
1547        ssr_fifo::Tdfe,
1548        SsrFifo_SPEC,
1549        crate::common::RW,
1550    > {
1551        crate::common::RegisterField::<
1552            7,
1553            0x1,
1554            1,
1555            0,
1556            ssr_fifo::Tdfe,
1557            ssr_fifo::Tdfe,
1558            SsrFifo_SPEC,
1559            crate::common::RW,
1560        >::from_register(self, 0)
1561    }
1562}
1563impl ::core::default::Default for SsrFifo {
1564    #[inline(always)]
1565    fn default() -> SsrFifo {
1566        <crate::RegValueT<SsrFifo_SPEC> as RegisterValue<_>>::new(128)
1567    }
1568}
1569pub mod ssr_fifo {
1570
1571    #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
1572    pub struct Dr_SPEC;
1573    pub type Dr = crate::EnumBitfieldStruct<u8, Dr_SPEC>;
1574    impl Dr {
1575        #[doc = "Receiving is in progress, or no received data remains in FRDRHL after successfully completed reception (receive FIFO empty)"]
1576        pub const _0: Self = Self::new(0);
1577
1578        #[doc = "Next receive data is not received for a period after normal receiving is complete, when the amount of data stored in the FIFO is equal to or less than the receive triggering number"]
1579        pub const _1: Self = Self::new(1);
1580    }
1581    #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
1582    pub struct Tend_SPEC;
1583    pub type Tend = crate::EnumBitfieldStruct<u8, Tend_SPEC>;
1584    impl Tend {
1585        #[doc = "A character is being transmitted"]
1586        pub const _0: Self = Self::new(0);
1587
1588        #[doc = "Character transfer is complete"]
1589        pub const _1: Self = Self::new(1);
1590    }
1591    #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
1592    pub struct Per_SPEC;
1593    pub type Per = crate::EnumBitfieldStruct<u8, Per_SPEC>;
1594    impl Per {
1595        #[doc = "No parity error occurred"]
1596        pub const _0: Self = Self::new(0);
1597
1598        #[doc = "Parity error occurred"]
1599        pub const _1: Self = Self::new(1);
1600    }
1601    #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
1602    pub struct Fer_SPEC;
1603    pub type Fer = crate::EnumBitfieldStruct<u8, Fer_SPEC>;
1604    impl Fer {
1605        #[doc = "No framing error occurred"]
1606        pub const _0: Self = Self::new(0);
1607
1608        #[doc = "Framing error occurred"]
1609        pub const _1: Self = Self::new(1);
1610    }
1611    #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
1612    pub struct Orer_SPEC;
1613    pub type Orer = crate::EnumBitfieldStruct<u8, Orer_SPEC>;
1614    impl Orer {
1615        #[doc = "No overrun error occurred"]
1616        pub const _0: Self = Self::new(0);
1617
1618        #[doc = "Overrun error occurred"]
1619        pub const _1: Self = Self::new(1);
1620    }
1621    #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
1622    pub struct Rdf_SPEC;
1623    pub type Rdf = crate::EnumBitfieldStruct<u8, Rdf_SPEC>;
1624    impl Rdf {
1625        #[doc = "The amount of receive data written in FRDRHL is less than the specified receive triggering number"]
1626        pub const _0: Self = Self::new(0);
1627
1628        #[doc = "The amount of receive data written in FRDRHL is equal to or greater than the specified receive triggering number"]
1629        pub const _1: Self = Self::new(1);
1630    }
1631    #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
1632    pub struct Tdfe_SPEC;
1633    pub type Tdfe = crate::EnumBitfieldStruct<u8, Tdfe_SPEC>;
1634    impl Tdfe {
1635        #[doc = "The amount of transmit data written in FTDRHL exceeds the specified transmit triggering number"]
1636        pub const _0: Self = Self::new(0);
1637
1638        #[doc = "The amount of transmit data written in FTDRHL is equal to or less than the specified transmit triggering number"]
1639        pub const _1: Self = Self::new(1);
1640    }
1641}
1642#[doc(hidden)]
1643#[derive(Copy, Clone, Eq, PartialEq)]
1644pub struct SsrSmci_SPEC;
1645impl crate::sealed::RegSpec for SsrSmci_SPEC {
1646    type DataType = u8;
1647}
1648
1649#[doc = "Serial Status Register for Smart Card Interface Mode (SCMR.SMIF = 1)"]
1650pub type SsrSmci = crate::RegValueT<SsrSmci_SPEC>;
1651
1652impl SsrSmci {
1653    #[doc = "Multi-Processor Bit Transfer"]
1654    #[inline(always)]
1655    pub fn mpbt(
1656        self,
1657    ) -> crate::common::RegisterFieldBool<0, 1, 0, SsrSmci_SPEC, crate::common::RW> {
1658        crate::common::RegisterFieldBool::<0, 1, 0, SsrSmci_SPEC, crate::common::RW>::from_register(
1659            self, 0,
1660        )
1661    }
1662
1663    #[doc = "Multi-Processor"]
1664    #[inline(always)]
1665    pub fn mpb(self) -> crate::common::RegisterFieldBool<1, 1, 0, SsrSmci_SPEC, crate::common::R> {
1666        crate::common::RegisterFieldBool::<1, 1, 0, SsrSmci_SPEC, crate::common::R>::from_register(
1667            self, 0,
1668        )
1669    }
1670
1671    #[doc = "Transmit End Flag"]
1672    #[inline(always)]
1673    pub fn tend(
1674        self,
1675    ) -> crate::common::RegisterField<
1676        2,
1677        0x1,
1678        1,
1679        0,
1680        ssr_smci::Tend,
1681        ssr_smci::Tend,
1682        SsrSmci_SPEC,
1683        crate::common::R,
1684    > {
1685        crate::common::RegisterField::<
1686            2,
1687            0x1,
1688            1,
1689            0,
1690            ssr_smci::Tend,
1691            ssr_smci::Tend,
1692            SsrSmci_SPEC,
1693            crate::common::R,
1694        >::from_register(self, 0)
1695    }
1696
1697    #[doc = "Parity Error Flag"]
1698    #[inline(always)]
1699    pub fn per(
1700        self,
1701    ) -> crate::common::RegisterField<
1702        3,
1703        0x1,
1704        1,
1705        0,
1706        ssr_smci::Per,
1707        ssr_smci::Per,
1708        SsrSmci_SPEC,
1709        crate::common::RW,
1710    > {
1711        crate::common::RegisterField::<
1712            3,
1713            0x1,
1714            1,
1715            0,
1716            ssr_smci::Per,
1717            ssr_smci::Per,
1718            SsrSmci_SPEC,
1719            crate::common::RW,
1720        >::from_register(self, 0)
1721    }
1722
1723    #[doc = "Error Signal Status Flag"]
1724    #[inline(always)]
1725    pub fn ers(
1726        self,
1727    ) -> crate::common::RegisterField<
1728        4,
1729        0x1,
1730        1,
1731        0,
1732        ssr_smci::Ers,
1733        ssr_smci::Ers,
1734        SsrSmci_SPEC,
1735        crate::common::RW,
1736    > {
1737        crate::common::RegisterField::<
1738            4,
1739            0x1,
1740            1,
1741            0,
1742            ssr_smci::Ers,
1743            ssr_smci::Ers,
1744            SsrSmci_SPEC,
1745            crate::common::RW,
1746        >::from_register(self, 0)
1747    }
1748
1749    #[doc = "Overrun Error Flag"]
1750    #[inline(always)]
1751    pub fn orer(
1752        self,
1753    ) -> crate::common::RegisterField<
1754        5,
1755        0x1,
1756        1,
1757        0,
1758        ssr_smci::Orer,
1759        ssr_smci::Orer,
1760        SsrSmci_SPEC,
1761        crate::common::RW,
1762    > {
1763        crate::common::RegisterField::<
1764            5,
1765            0x1,
1766            1,
1767            0,
1768            ssr_smci::Orer,
1769            ssr_smci::Orer,
1770            SsrSmci_SPEC,
1771            crate::common::RW,
1772        >::from_register(self, 0)
1773    }
1774
1775    #[doc = "Receive Data Full Flag"]
1776    #[inline(always)]
1777    pub fn rdrf(
1778        self,
1779    ) -> crate::common::RegisterField<
1780        6,
1781        0x1,
1782        1,
1783        0,
1784        ssr_smci::Rdrf,
1785        ssr_smci::Rdrf,
1786        SsrSmci_SPEC,
1787        crate::common::RW,
1788    > {
1789        crate::common::RegisterField::<
1790            6,
1791            0x1,
1792            1,
1793            0,
1794            ssr_smci::Rdrf,
1795            ssr_smci::Rdrf,
1796            SsrSmci_SPEC,
1797            crate::common::RW,
1798        >::from_register(self, 0)
1799    }
1800
1801    #[doc = "Transmit Data Empty Flag"]
1802    #[inline(always)]
1803    pub fn tdre(
1804        self,
1805    ) -> crate::common::RegisterField<
1806        7,
1807        0x1,
1808        1,
1809        0,
1810        ssr_smci::Tdre,
1811        ssr_smci::Tdre,
1812        SsrSmci_SPEC,
1813        crate::common::RW,
1814    > {
1815        crate::common::RegisterField::<
1816            7,
1817            0x1,
1818            1,
1819            0,
1820            ssr_smci::Tdre,
1821            ssr_smci::Tdre,
1822            SsrSmci_SPEC,
1823            crate::common::RW,
1824        >::from_register(self, 0)
1825    }
1826}
1827impl ::core::default::Default for SsrSmci {
1828    #[inline(always)]
1829    fn default() -> SsrSmci {
1830        <crate::RegValueT<SsrSmci_SPEC> as RegisterValue<_>>::new(132)
1831    }
1832}
1833pub mod ssr_smci {
1834
1835    #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
1836    pub struct Tend_SPEC;
1837    pub type Tend = crate::EnumBitfieldStruct<u8, Tend_SPEC>;
1838    impl Tend {
1839        #[doc = "A character is being transmitted"]
1840        pub const _0: Self = Self::new(0);
1841
1842        #[doc = "Character transfer is complete"]
1843        pub const _1: Self = Self::new(1);
1844    }
1845    #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
1846    pub struct Per_SPEC;
1847    pub type Per = crate::EnumBitfieldStruct<u8, Per_SPEC>;
1848    impl Per {
1849        #[doc = "No parity error occurred"]
1850        pub const _0: Self = Self::new(0);
1851
1852        #[doc = "Parity error occurred"]
1853        pub const _1: Self = Self::new(1);
1854    }
1855    #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
1856    pub struct Ers_SPEC;
1857    pub type Ers = crate::EnumBitfieldStruct<u8, Ers_SPEC>;
1858    impl Ers {
1859        #[doc = "No low error signal response"]
1860        pub const _0: Self = Self::new(0);
1861
1862        #[doc = "Low error signal response occurred"]
1863        pub const _1: Self = Self::new(1);
1864    }
1865    #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
1866    pub struct Orer_SPEC;
1867    pub type Orer = crate::EnumBitfieldStruct<u8, Orer_SPEC>;
1868    impl Orer {
1869        #[doc = "No overrun error occurred"]
1870        pub const _0: Self = Self::new(0);
1871
1872        #[doc = "Overrun error occurred"]
1873        pub const _1: Self = Self::new(1);
1874    }
1875    #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
1876    pub struct Rdrf_SPEC;
1877    pub type Rdrf = crate::EnumBitfieldStruct<u8, Rdrf_SPEC>;
1878    impl Rdrf {
1879        #[doc = "No received data in RDR register"]
1880        pub const _0: Self = Self::new(0);
1881
1882        #[doc = "Received data in RDR register"]
1883        pub const _1: Self = Self::new(1);
1884    }
1885    #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
1886    pub struct Tdre_SPEC;
1887    pub type Tdre = crate::EnumBitfieldStruct<u8, Tdre_SPEC>;
1888    impl Tdre {
1889        #[doc = "Transmit data in TDR register"]
1890        pub const _0: Self = Self::new(0);
1891
1892        #[doc = "No transmit data in TDR register"]
1893        pub const _1: Self = Self::new(1);
1894    }
1895}
1896#[doc(hidden)]
1897#[derive(Copy, Clone, Eq, PartialEq)]
1898pub struct Rdr_SPEC;
1899impl crate::sealed::RegSpec for Rdr_SPEC {
1900    type DataType = u8;
1901}
1902
1903#[doc = "Receive Data Register"]
1904pub type Rdr = crate::RegValueT<Rdr_SPEC>;
1905
1906impl NoBitfieldReg<Rdr_SPEC> for Rdr {}
1907impl ::core::default::Default for Rdr {
1908    #[inline(always)]
1909    fn default() -> Rdr {
1910        <crate::RegValueT<Rdr_SPEC> as RegisterValue<_>>::new(0)
1911    }
1912}
1913
1914#[doc(hidden)]
1915#[derive(Copy, Clone, Eq, PartialEq)]
1916pub struct Scmr_SPEC;
1917impl crate::sealed::RegSpec for Scmr_SPEC {
1918    type DataType = u8;
1919}
1920
1921#[doc = "Smart Card Mode Register"]
1922pub type Scmr = crate::RegValueT<Scmr_SPEC>;
1923
1924impl Scmr {
1925    #[doc = "Smart Card Interface Mode Select"]
1926    #[inline(always)]
1927    pub fn smif(
1928        self,
1929    ) -> crate::common::RegisterField<
1930        0,
1931        0x1,
1932        1,
1933        0,
1934        scmr::Smif,
1935        scmr::Smif,
1936        Scmr_SPEC,
1937        crate::common::RW,
1938    > {
1939        crate::common::RegisterField::<
1940            0,
1941            0x1,
1942            1,
1943            0,
1944            scmr::Smif,
1945            scmr::Smif,
1946            Scmr_SPEC,
1947            crate::common::RW,
1948        >::from_register(self, 0)
1949    }
1950
1951    #[doc = "Transmitted/Received Data Invert"]
1952    #[inline(always)]
1953    pub fn sinv(
1954        self,
1955    ) -> crate::common::RegisterField<
1956        2,
1957        0x1,
1958        1,
1959        0,
1960        scmr::Sinv,
1961        scmr::Sinv,
1962        Scmr_SPEC,
1963        crate::common::RW,
1964    > {
1965        crate::common::RegisterField::<
1966            2,
1967            0x1,
1968            1,
1969            0,
1970            scmr::Sinv,
1971            scmr::Sinv,
1972            Scmr_SPEC,
1973            crate::common::RW,
1974        >::from_register(self, 0)
1975    }
1976
1977    #[doc = "Transmitted/Received Data Transfer Direction"]
1978    #[inline(always)]
1979    pub fn sdir(
1980        self,
1981    ) -> crate::common::RegisterField<
1982        3,
1983        0x1,
1984        1,
1985        0,
1986        scmr::Sdir,
1987        scmr::Sdir,
1988        Scmr_SPEC,
1989        crate::common::RW,
1990    > {
1991        crate::common::RegisterField::<
1992            3,
1993            0x1,
1994            1,
1995            0,
1996            scmr::Sdir,
1997            scmr::Sdir,
1998            Scmr_SPEC,
1999            crate::common::RW,
2000        >::from_register(self, 0)
2001    }
2002
2003    #[doc = "Character Length 1"]
2004    #[inline(always)]
2005    pub fn chr1(
2006        self,
2007    ) -> crate::common::RegisterField<
2008        4,
2009        0x1,
2010        1,
2011        0,
2012        scmr::Chr1,
2013        scmr::Chr1,
2014        Scmr_SPEC,
2015        crate::common::RW,
2016    > {
2017        crate::common::RegisterField::<
2018            4,
2019            0x1,
2020            1,
2021            0,
2022            scmr::Chr1,
2023            scmr::Chr1,
2024            Scmr_SPEC,
2025            crate::common::RW,
2026        >::from_register(self, 0)
2027    }
2028
2029    #[doc = "Base Clock Pulse 2"]
2030    #[inline(always)]
2031    pub fn bcp2(self) -> crate::common::RegisterFieldBool<7, 1, 0, Scmr_SPEC, crate::common::RW> {
2032        crate::common::RegisterFieldBool::<7, 1, 0, Scmr_SPEC, crate::common::RW>::from_register(
2033            self, 0,
2034        )
2035    }
2036}
2037impl ::core::default::Default for Scmr {
2038    #[inline(always)]
2039    fn default() -> Scmr {
2040        <crate::RegValueT<Scmr_SPEC> as RegisterValue<_>>::new(242)
2041    }
2042}
2043pub mod scmr {
2044
2045    #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
2046    pub struct Smif_SPEC;
2047    pub type Smif = crate::EnumBitfieldStruct<u8, Smif_SPEC>;
2048    impl Smif {
2049        #[doc = "Non-smart card interface mode (asynchronous mode, clock synchronous mode, simple SPI mode, or simple IIC mode)"]
2050        pub const _0: Self = Self::new(0);
2051
2052        #[doc = "Smart card interface mode"]
2053        pub const _1: Self = Self::new(1);
2054    }
2055    #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
2056    pub struct Sinv_SPEC;
2057    pub type Sinv = crate::EnumBitfieldStruct<u8, Sinv_SPEC>;
2058    impl Sinv {
2059        #[doc = "TDR contents are transmitted as they are. Received data is stored as received in the RDR register."]
2060        pub const _0: Self = Self::new(0);
2061
2062        #[doc = "TDR register contents are inverted before transmission. Receive data is stored in inverted form in the RDR register."]
2063        pub const _1: Self = Self::new(1);
2064    }
2065    #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
2066    pub struct Sdir_SPEC;
2067    pub type Sdir = crate::EnumBitfieldStruct<u8, Sdir_SPEC>;
2068    impl Sdir {
2069        #[doc = "Transfer LSB-first"]
2070        pub const _0: Self = Self::new(0);
2071
2072        #[doc = "Transfer MSB-first"]
2073        pub const _1: Self = Self::new(1);
2074    }
2075    #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
2076    pub struct Chr1_SPEC;
2077    pub type Chr1 = crate::EnumBitfieldStruct<u8, Chr1_SPEC>;
2078    impl Chr1 {
2079        #[doc = "SMR.CHR = 0: Transmit/receive in 9-bit data length SMR.CHR = 1: Transmit/receive in 9-bit data length"]
2080        pub const _0: Self = Self::new(0);
2081
2082        #[doc = "SMR.CHR = 0: Transmit/receive in 8-bit data length (initial value) SMR.CHR = 1: Transmit/receive in 7-bit data length"]
2083        pub const _1: Self = Self::new(1);
2084    }
2085}
2086#[doc(hidden)]
2087#[derive(Copy, Clone, Eq, PartialEq)]
2088pub struct Semr_SPEC;
2089impl crate::sealed::RegSpec for Semr_SPEC {
2090    type DataType = u8;
2091}
2092
2093#[doc = "Serial Extended Mode Register"]
2094pub type Semr = crate::RegValueT<Semr_SPEC>;
2095
2096impl Semr {
2097    #[doc = "Bit Rate Modulation Enable"]
2098    #[inline(always)]
2099    pub fn brme(
2100        self,
2101    ) -> crate::common::RegisterField<
2102        2,
2103        0x1,
2104        1,
2105        0,
2106        semr::Brme,
2107        semr::Brme,
2108        Semr_SPEC,
2109        crate::common::RW,
2110    > {
2111        crate::common::RegisterField::<
2112            2,
2113            0x1,
2114            1,
2115            0,
2116            semr::Brme,
2117            semr::Brme,
2118            Semr_SPEC,
2119            crate::common::RW,
2120        >::from_register(self, 0)
2121    }
2122
2123    #[doc = "Asynchronous Mode Extended Base Clock Select 1"]
2124    #[inline(always)]
2125    pub fn abcse(
2126        self,
2127    ) -> crate::common::RegisterField<
2128        3,
2129        0x1,
2130        1,
2131        0,
2132        semr::Abcse,
2133        semr::Abcse,
2134        Semr_SPEC,
2135        crate::common::RW,
2136    > {
2137        crate::common::RegisterField::<
2138            3,
2139            0x1,
2140            1,
2141            0,
2142            semr::Abcse,
2143            semr::Abcse,
2144            Semr_SPEC,
2145            crate::common::RW,
2146        >::from_register(self, 0)
2147    }
2148
2149    #[doc = "Asynchronous Mode Base Clock Select"]
2150    #[inline(always)]
2151    pub fn abcs(
2152        self,
2153    ) -> crate::common::RegisterField<
2154        4,
2155        0x1,
2156        1,
2157        0,
2158        semr::Abcs,
2159        semr::Abcs,
2160        Semr_SPEC,
2161        crate::common::RW,
2162    > {
2163        crate::common::RegisterField::<
2164            4,
2165            0x1,
2166            1,
2167            0,
2168            semr::Abcs,
2169            semr::Abcs,
2170            Semr_SPEC,
2171            crate::common::RW,
2172        >::from_register(self, 0)
2173    }
2174
2175    #[doc = "Digital Noise Filter Function Enable"]
2176    #[inline(always)]
2177    pub fn nfen(
2178        self,
2179    ) -> crate::common::RegisterField<
2180        5,
2181        0x1,
2182        1,
2183        0,
2184        semr::Nfen,
2185        semr::Nfen,
2186        Semr_SPEC,
2187        crate::common::RW,
2188    > {
2189        crate::common::RegisterField::<
2190            5,
2191            0x1,
2192            1,
2193            0,
2194            semr::Nfen,
2195            semr::Nfen,
2196            Semr_SPEC,
2197            crate::common::RW,
2198        >::from_register(self, 0)
2199    }
2200
2201    #[doc = "Baud Rate Generator Double-Speed Mode Select"]
2202    #[inline(always)]
2203    pub fn bgdm(
2204        self,
2205    ) -> crate::common::RegisterField<
2206        6,
2207        0x1,
2208        1,
2209        0,
2210        semr::Bgdm,
2211        semr::Bgdm,
2212        Semr_SPEC,
2213        crate::common::RW,
2214    > {
2215        crate::common::RegisterField::<
2216            6,
2217            0x1,
2218            1,
2219            0,
2220            semr::Bgdm,
2221            semr::Bgdm,
2222            Semr_SPEC,
2223            crate::common::RW,
2224        >::from_register(self, 0)
2225    }
2226
2227    #[doc = "Asynchronous Start Bit Edge Detection Select"]
2228    #[inline(always)]
2229    pub fn rxdesel(
2230        self,
2231    ) -> crate::common::RegisterField<
2232        7,
2233        0x1,
2234        1,
2235        0,
2236        semr::Rxdesel,
2237        semr::Rxdesel,
2238        Semr_SPEC,
2239        crate::common::RW,
2240    > {
2241        crate::common::RegisterField::<
2242            7,
2243            0x1,
2244            1,
2245            0,
2246            semr::Rxdesel,
2247            semr::Rxdesel,
2248            Semr_SPEC,
2249            crate::common::RW,
2250        >::from_register(self, 0)
2251    }
2252}
2253impl ::core::default::Default for Semr {
2254    #[inline(always)]
2255    fn default() -> Semr {
2256        <crate::RegValueT<Semr_SPEC> as RegisterValue<_>>::new(0)
2257    }
2258}
2259pub mod semr {
2260
2261    #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
2262    pub struct Brme_SPEC;
2263    pub type Brme = crate::EnumBitfieldStruct<u8, Brme_SPEC>;
2264    impl Brme {
2265        #[doc = "Disable bit rate modulation function"]
2266        pub const _0: Self = Self::new(0);
2267
2268        #[doc = "Enable bit rate modulation function"]
2269        pub const _1: Self = Self::new(1);
2270    }
2271    #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
2272    pub struct Abcse_SPEC;
2273    pub type Abcse = crate::EnumBitfieldStruct<u8, Abcse_SPEC>;
2274    impl Abcse {
2275        #[doc = "Clock cycles for 1-bit period determined by combination of the BGDM and ABCS bits in the SEMR register"]
2276        pub const _0: Self = Self::new(0);
2277
2278        #[doc = "Baud rate is 6 base clock cycles for 1-bit period"]
2279        pub const _1: Self = Self::new(1);
2280    }
2281    #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
2282    pub struct Abcs_SPEC;
2283    pub type Abcs = crate::EnumBitfieldStruct<u8, Abcs_SPEC>;
2284    impl Abcs {
2285        #[doc = "Select 16 base clock cycles for 1-bit period"]
2286        pub const _0: Self = Self::new(0);
2287
2288        #[doc = "Select 8 base clock cycles for 1-bit period"]
2289        pub const _1: Self = Self::new(1);
2290    }
2291    #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
2292    pub struct Nfen_SPEC;
2293    pub type Nfen = crate::EnumBitfieldStruct<u8, Nfen_SPEC>;
2294    impl Nfen {
2295        #[doc = "In asynchronous mode: Disable noise cancellation function for RXDn input signal In simple I2C mode: Disable noise cancellation function for SCLn and SDAn input signals"]
2296        pub const _0: Self = Self::new(0);
2297
2298        #[doc = "In asynchronous mode: Enable noise cancellation function for RXDn input signal In simple I2C mode: Enable noise cancellation function for SCLn and SDAn input signals"]
2299        pub const _1: Self = Self::new(1);
2300    }
2301    #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
2302    pub struct Bgdm_SPEC;
2303    pub type Bgdm = crate::EnumBitfieldStruct<u8, Bgdm_SPEC>;
2304    impl Bgdm {
2305        #[doc = "Output clock from baud rate generator with normal frequency"]
2306        pub const _0: Self = Self::new(0);
2307
2308        #[doc = "Output clock from baud rate generator with doubled frequency"]
2309        pub const _1: Self = Self::new(1);
2310    }
2311    #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
2312    pub struct Rxdesel_SPEC;
2313    pub type Rxdesel = crate::EnumBitfieldStruct<u8, Rxdesel_SPEC>;
2314    impl Rxdesel {
2315        #[doc = "Detect low level on RXDn pin as start bit"]
2316        pub const _0: Self = Self::new(0);
2317
2318        #[doc = "Detect falling edge of RXDn pin as start bit"]
2319        pub const _1: Self = Self::new(1);
2320    }
2321}
2322#[doc(hidden)]
2323#[derive(Copy, Clone, Eq, PartialEq)]
2324pub struct Snfr_SPEC;
2325impl crate::sealed::RegSpec for Snfr_SPEC {
2326    type DataType = u8;
2327}
2328
2329#[doc = "Noise Filter Setting Register"]
2330pub type Snfr = crate::RegValueT<Snfr_SPEC>;
2331
2332impl Snfr {
2333    #[doc = "Noise Filter Clock Select"]
2334    #[inline(always)]
2335    pub fn nfcs(
2336        self,
2337    ) -> crate::common::RegisterField<
2338        0,
2339        0x7,
2340        1,
2341        0,
2342        snfr::Nfcs,
2343        snfr::Nfcs,
2344        Snfr_SPEC,
2345        crate::common::RW,
2346    > {
2347        crate::common::RegisterField::<
2348            0,
2349            0x7,
2350            1,
2351            0,
2352            snfr::Nfcs,
2353            snfr::Nfcs,
2354            Snfr_SPEC,
2355            crate::common::RW,
2356        >::from_register(self, 0)
2357    }
2358}
2359impl ::core::default::Default for Snfr {
2360    #[inline(always)]
2361    fn default() -> Snfr {
2362        <crate::RegValueT<Snfr_SPEC> as RegisterValue<_>>::new(0)
2363    }
2364}
2365pub mod snfr {
2366
2367    #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
2368    pub struct Nfcs_SPEC;
2369    pub type Nfcs = crate::EnumBitfieldStruct<u8, Nfcs_SPEC>;
2370    impl Nfcs {
2371        #[doc = "In asynchronous mode: Use clock signal divided by 1 with noise filter In simple I2C mode: Setting prohibited"]
2372        pub const _000: Self = Self::new(0);
2373
2374        #[doc = "In asynchronous mode: Setting prohibited In simple I2C mode: Use clock signal divided by 1 with noise filter"]
2375        pub const _001: Self = Self::new(1);
2376
2377        #[doc = "In asynchronous mode: Setting prohibited In simple I2C mode: Use clock signal divided by 2 with noise filter"]
2378        pub const _010: Self = Self::new(2);
2379
2380        #[doc = "In asynchronous mode: Setting prohibited In simple I2C mode: Use clock signal divided by 4 with noise filter"]
2381        pub const _011: Self = Self::new(3);
2382
2383        #[doc = "In asynchronous mode: Setting prohibited In simple I2C mode: Use clock signal divided by 8 with noise filter"]
2384        pub const _100: Self = Self::new(4);
2385    }
2386}
2387#[doc(hidden)]
2388#[derive(Copy, Clone, Eq, PartialEq)]
2389pub struct Simr1_SPEC;
2390impl crate::sealed::RegSpec for Simr1_SPEC {
2391    type DataType = u8;
2392}
2393
2394#[doc = "IIC Mode Register 1"]
2395pub type Simr1 = crate::RegValueT<Simr1_SPEC>;
2396
2397impl Simr1 {
2398    #[doc = "Simple IIC Mode Select"]
2399    #[inline(always)]
2400    pub fn iicm(
2401        self,
2402    ) -> crate::common::RegisterField<
2403        0,
2404        0x1,
2405        1,
2406        0,
2407        simr1::Iicm,
2408        simr1::Iicm,
2409        Simr1_SPEC,
2410        crate::common::RW,
2411    > {
2412        crate::common::RegisterField::<
2413            0,
2414            0x1,
2415            1,
2416            0,
2417            simr1::Iicm,
2418            simr1::Iicm,
2419            Simr1_SPEC,
2420            crate::common::RW,
2421        >::from_register(self, 0)
2422    }
2423
2424    #[doc = "SDAn Delay Output Select"]
2425    #[inline(always)]
2426    pub fn iicdl(
2427        self,
2428    ) -> crate::common::RegisterField<
2429        3,
2430        0x1f,
2431        1,
2432        0,
2433        simr1::Iicdl,
2434        simr1::Iicdl,
2435        Simr1_SPEC,
2436        crate::common::RW,
2437    > {
2438        crate::common::RegisterField::<
2439            3,
2440            0x1f,
2441            1,
2442            0,
2443            simr1::Iicdl,
2444            simr1::Iicdl,
2445            Simr1_SPEC,
2446            crate::common::RW,
2447        >::from_register(self, 0)
2448    }
2449}
2450impl ::core::default::Default for Simr1 {
2451    #[inline(always)]
2452    fn default() -> Simr1 {
2453        <crate::RegValueT<Simr1_SPEC> as RegisterValue<_>>::new(0)
2454    }
2455}
2456pub mod simr1 {
2457
2458    #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
2459    pub struct Iicm_SPEC;
2460    pub type Iicm = crate::EnumBitfieldStruct<u8, Iicm_SPEC>;
2461    impl Iicm {
2462        #[doc = "SCMR.SMIF = 0: Asynchronous mode (including multi-processor mode), clock synchronous mode, or simple SPI mode SCMR.SMIF = 1: Smart card interface mode"]
2463        pub const _0: Self = Self::new(0);
2464
2465        #[doc = "SCMR.SMIF = 0: Simple IIC mode SCMR.SMIF = 1: Setting prohibited"]
2466        pub const _1: Self = Self::new(1);
2467    }
2468    #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
2469    pub struct Iicdl_SPEC;
2470    pub type Iicdl = crate::EnumBitfieldStruct<u8, Iicdl_SPEC>;
2471    impl Iicdl {
2472        #[doc = "No output delay"]
2473        pub const _0_X_00: Self = Self::new(0);
2474    }
2475}
2476#[doc(hidden)]
2477#[derive(Copy, Clone, Eq, PartialEq)]
2478pub struct Simr2_SPEC;
2479impl crate::sealed::RegSpec for Simr2_SPEC {
2480    type DataType = u8;
2481}
2482
2483#[doc = "IIC Mode Register 2"]
2484pub type Simr2 = crate::RegValueT<Simr2_SPEC>;
2485
2486impl Simr2 {
2487    #[doc = "IIC Interrupt Mode Select"]
2488    #[inline(always)]
2489    pub fn iicintm(
2490        self,
2491    ) -> crate::common::RegisterField<
2492        0,
2493        0x1,
2494        1,
2495        0,
2496        simr2::Iicintm,
2497        simr2::Iicintm,
2498        Simr2_SPEC,
2499        crate::common::RW,
2500    > {
2501        crate::common::RegisterField::<
2502            0,
2503            0x1,
2504            1,
2505            0,
2506            simr2::Iicintm,
2507            simr2::Iicintm,
2508            Simr2_SPEC,
2509            crate::common::RW,
2510        >::from_register(self, 0)
2511    }
2512
2513    #[doc = "Clock Synchronization"]
2514    #[inline(always)]
2515    pub fn iiccsc(
2516        self,
2517    ) -> crate::common::RegisterField<
2518        1,
2519        0x1,
2520        1,
2521        0,
2522        simr2::Iiccsc,
2523        simr2::Iiccsc,
2524        Simr2_SPEC,
2525        crate::common::RW,
2526    > {
2527        crate::common::RegisterField::<
2528            1,
2529            0x1,
2530            1,
2531            0,
2532            simr2::Iiccsc,
2533            simr2::Iiccsc,
2534            Simr2_SPEC,
2535            crate::common::RW,
2536        >::from_register(self, 0)
2537    }
2538
2539    #[doc = "ACK Transmission Data"]
2540    #[inline(always)]
2541    pub fn iicackt(
2542        self,
2543    ) -> crate::common::RegisterField<
2544        5,
2545        0x1,
2546        1,
2547        0,
2548        simr2::Iicackt,
2549        simr2::Iicackt,
2550        Simr2_SPEC,
2551        crate::common::RW,
2552    > {
2553        crate::common::RegisterField::<
2554            5,
2555            0x1,
2556            1,
2557            0,
2558            simr2::Iicackt,
2559            simr2::Iicackt,
2560            Simr2_SPEC,
2561            crate::common::RW,
2562        >::from_register(self, 0)
2563    }
2564}
2565impl ::core::default::Default for Simr2 {
2566    #[inline(always)]
2567    fn default() -> Simr2 {
2568        <crate::RegValueT<Simr2_SPEC> as RegisterValue<_>>::new(0)
2569    }
2570}
2571pub mod simr2 {
2572
2573    #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
2574    pub struct Iicintm_SPEC;
2575    pub type Iicintm = crate::EnumBitfieldStruct<u8, Iicintm_SPEC>;
2576    impl Iicintm {
2577        #[doc = "Use ACK/NACK interrupts"]
2578        pub const _0: Self = Self::new(0);
2579
2580        #[doc = "Use reception and transmission interrupts"]
2581        pub const _1: Self = Self::new(1);
2582    }
2583    #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
2584    pub struct Iiccsc_SPEC;
2585    pub type Iiccsc = crate::EnumBitfieldStruct<u8, Iiccsc_SPEC>;
2586    impl Iiccsc {
2587        #[doc = "Do not synchronize with clock signal"]
2588        pub const _0: Self = Self::new(0);
2589
2590        #[doc = "Synchronize with clock signal"]
2591        pub const _1: Self = Self::new(1);
2592    }
2593    #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
2594    pub struct Iicackt_SPEC;
2595    pub type Iicackt = crate::EnumBitfieldStruct<u8, Iicackt_SPEC>;
2596    impl Iicackt {
2597        #[doc = "ACK transmission"]
2598        pub const _0: Self = Self::new(0);
2599
2600        #[doc = "NACK transmission and ACK/NACK reception"]
2601        pub const _1: Self = Self::new(1);
2602    }
2603}
2604#[doc(hidden)]
2605#[derive(Copy, Clone, Eq, PartialEq)]
2606pub struct Simr3_SPEC;
2607impl crate::sealed::RegSpec for Simr3_SPEC {
2608    type DataType = u8;
2609}
2610
2611#[doc = "IIC Mode Register 3"]
2612pub type Simr3 = crate::RegValueT<Simr3_SPEC>;
2613
2614impl Simr3 {
2615    #[doc = "Start Condition Generation"]
2616    #[inline(always)]
2617    pub fn iicstareq(
2618        self,
2619    ) -> crate::common::RegisterField<
2620        0,
2621        0x1,
2622        1,
2623        0,
2624        simr3::Iicstareq,
2625        simr3::Iicstareq,
2626        Simr3_SPEC,
2627        crate::common::RW,
2628    > {
2629        crate::common::RegisterField::<
2630            0,
2631            0x1,
2632            1,
2633            0,
2634            simr3::Iicstareq,
2635            simr3::Iicstareq,
2636            Simr3_SPEC,
2637            crate::common::RW,
2638        >::from_register(self, 0)
2639    }
2640
2641    #[doc = "Restart Condition Generation"]
2642    #[inline(always)]
2643    pub fn iicrstareq(
2644        self,
2645    ) -> crate::common::RegisterField<
2646        1,
2647        0x1,
2648        1,
2649        0,
2650        simr3::Iicrstareq,
2651        simr3::Iicrstareq,
2652        Simr3_SPEC,
2653        crate::common::RW,
2654    > {
2655        crate::common::RegisterField::<
2656            1,
2657            0x1,
2658            1,
2659            0,
2660            simr3::Iicrstareq,
2661            simr3::Iicrstareq,
2662            Simr3_SPEC,
2663            crate::common::RW,
2664        >::from_register(self, 0)
2665    }
2666
2667    #[doc = "Stop Condition Generation"]
2668    #[inline(always)]
2669    pub fn iicstpreq(
2670        self,
2671    ) -> crate::common::RegisterField<
2672        2,
2673        0x1,
2674        1,
2675        0,
2676        simr3::Iicstpreq,
2677        simr3::Iicstpreq,
2678        Simr3_SPEC,
2679        crate::common::RW,
2680    > {
2681        crate::common::RegisterField::<
2682            2,
2683            0x1,
2684            1,
2685            0,
2686            simr3::Iicstpreq,
2687            simr3::Iicstpreq,
2688            Simr3_SPEC,
2689            crate::common::RW,
2690        >::from_register(self, 0)
2691    }
2692
2693    #[doc = "Issuing of Start, Restart, or Stop Condition Completed Flag"]
2694    #[inline(always)]
2695    pub fn iicstif(
2696        self,
2697    ) -> crate::common::RegisterField<
2698        3,
2699        0x1,
2700        1,
2701        0,
2702        simr3::Iicstif,
2703        simr3::Iicstif,
2704        Simr3_SPEC,
2705        crate::common::RW,
2706    > {
2707        crate::common::RegisterField::<
2708            3,
2709            0x1,
2710            1,
2711            0,
2712            simr3::Iicstif,
2713            simr3::Iicstif,
2714            Simr3_SPEC,
2715            crate::common::RW,
2716        >::from_register(self, 0)
2717    }
2718
2719    #[doc = "SDAn Output Select"]
2720    #[inline(always)]
2721    pub fn iicsdas(
2722        self,
2723    ) -> crate::common::RegisterField<
2724        4,
2725        0x3,
2726        1,
2727        0,
2728        simr3::Iicsdas,
2729        simr3::Iicsdas,
2730        Simr3_SPEC,
2731        crate::common::RW,
2732    > {
2733        crate::common::RegisterField::<
2734            4,
2735            0x3,
2736            1,
2737            0,
2738            simr3::Iicsdas,
2739            simr3::Iicsdas,
2740            Simr3_SPEC,
2741            crate::common::RW,
2742        >::from_register(self, 0)
2743    }
2744
2745    #[doc = "SCLn Output Select"]
2746    #[inline(always)]
2747    pub fn iicscls(
2748        self,
2749    ) -> crate::common::RegisterField<
2750        6,
2751        0x3,
2752        1,
2753        0,
2754        simr3::Iicscls,
2755        simr3::Iicscls,
2756        Simr3_SPEC,
2757        crate::common::RW,
2758    > {
2759        crate::common::RegisterField::<
2760            6,
2761            0x3,
2762            1,
2763            0,
2764            simr3::Iicscls,
2765            simr3::Iicscls,
2766            Simr3_SPEC,
2767            crate::common::RW,
2768        >::from_register(self, 0)
2769    }
2770}
2771impl ::core::default::Default for Simr3 {
2772    #[inline(always)]
2773    fn default() -> Simr3 {
2774        <crate::RegValueT<Simr3_SPEC> as RegisterValue<_>>::new(0)
2775    }
2776}
2777pub mod simr3 {
2778
2779    #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
2780    pub struct Iicstareq_SPEC;
2781    pub type Iicstareq = crate::EnumBitfieldStruct<u8, Iicstareq_SPEC>;
2782    impl Iicstareq {
2783        #[doc = "Do not generate start condition"]
2784        pub const _0: Self = Self::new(0);
2785
2786        #[doc = "Generate start condition"]
2787        pub const _1: Self = Self::new(1);
2788    }
2789    #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
2790    pub struct Iicrstareq_SPEC;
2791    pub type Iicrstareq = crate::EnumBitfieldStruct<u8, Iicrstareq_SPEC>;
2792    impl Iicrstareq {
2793        #[doc = "Do not generate restart condition"]
2794        pub const _0: Self = Self::new(0);
2795
2796        #[doc = "Generate restart condition"]
2797        pub const _1: Self = Self::new(1);
2798    }
2799    #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
2800    pub struct Iicstpreq_SPEC;
2801    pub type Iicstpreq = crate::EnumBitfieldStruct<u8, Iicstpreq_SPEC>;
2802    impl Iicstpreq {
2803        #[doc = "Do not generate stop condition"]
2804        pub const _0: Self = Self::new(0);
2805
2806        #[doc = "Generate stop condition"]
2807        pub const _1: Self = Self::new(1);
2808    }
2809    #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
2810    pub struct Iicstif_SPEC;
2811    pub type Iicstif = crate::EnumBitfieldStruct<u8, Iicstif_SPEC>;
2812    impl Iicstif {
2813        #[doc = "No requests are being made for generating conditions, or a condition is being generated"]
2814        pub const _0: Self = Self::new(0);
2815
2816        #[doc = "Generation of start, restart, or stop condition is complete. When 0 is written to IICSTIF, it is set to 0"]
2817        pub const _1: Self = Self::new(1);
2818    }
2819    #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
2820    pub struct Iicsdas_SPEC;
2821    pub type Iicsdas = crate::EnumBitfieldStruct<u8, Iicsdas_SPEC>;
2822    impl Iicsdas {
2823        #[doc = "Output serial data"]
2824        pub const _00: Self = Self::new(0);
2825
2826        #[doc = "Generate start, restart, or stop condition"]
2827        pub const _01: Self = Self::new(1);
2828
2829        #[doc = "Output low on SDAn pin"]
2830        pub const _10: Self = Self::new(2);
2831
2832        #[doc = "Drive SDAn pin to high-impedance state"]
2833        pub const _11: Self = Self::new(3);
2834    }
2835    #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
2836    pub struct Iicscls_SPEC;
2837    pub type Iicscls = crate::EnumBitfieldStruct<u8, Iicscls_SPEC>;
2838    impl Iicscls {
2839        #[doc = "Output serial clock"]
2840        pub const _00: Self = Self::new(0);
2841
2842        #[doc = "Generate start, restart, or stop condition"]
2843        pub const _01: Self = Self::new(1);
2844
2845        #[doc = "Output low on SCLn pin"]
2846        pub const _10: Self = Self::new(2);
2847
2848        #[doc = "Drive SCLn pin to high-impedance state"]
2849        pub const _11: Self = Self::new(3);
2850    }
2851}
2852#[doc(hidden)]
2853#[derive(Copy, Clone, Eq, PartialEq)]
2854pub struct Sisr_SPEC;
2855impl crate::sealed::RegSpec for Sisr_SPEC {
2856    type DataType = u8;
2857}
2858
2859#[doc = "IIC Status Register"]
2860pub type Sisr = crate::RegValueT<Sisr_SPEC>;
2861
2862impl Sisr {
2863    #[doc = "ACK Reception Data Flag"]
2864    #[inline(always)]
2865    pub fn iicackr(
2866        self,
2867    ) -> crate::common::RegisterField<
2868        0,
2869        0x1,
2870        1,
2871        0,
2872        sisr::Iicackr,
2873        sisr::Iicackr,
2874        Sisr_SPEC,
2875        crate::common::R,
2876    > {
2877        crate::common::RegisterField::<
2878            0,
2879            0x1,
2880            1,
2881            0,
2882            sisr::Iicackr,
2883            sisr::Iicackr,
2884            Sisr_SPEC,
2885            crate::common::R,
2886        >::from_register(self, 0)
2887    }
2888}
2889impl ::core::default::Default for Sisr {
2890    #[inline(always)]
2891    fn default() -> Sisr {
2892        <crate::RegValueT<Sisr_SPEC> as RegisterValue<_>>::new(0)
2893    }
2894}
2895pub mod sisr {
2896
2897    #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
2898    pub struct Iicackr_SPEC;
2899    pub type Iicackr = crate::EnumBitfieldStruct<u8, Iicackr_SPEC>;
2900    impl Iicackr {
2901        #[doc = "ACK received"]
2902        pub const _0: Self = Self::new(0);
2903
2904        #[doc = "NACK received"]
2905        pub const _1: Self = Self::new(1);
2906    }
2907}
2908#[doc(hidden)]
2909#[derive(Copy, Clone, Eq, PartialEq)]
2910pub struct Spmr_SPEC;
2911impl crate::sealed::RegSpec for Spmr_SPEC {
2912    type DataType = u8;
2913}
2914
2915#[doc = "SPI Mode Register"]
2916pub type Spmr = crate::RegValueT<Spmr_SPEC>;
2917
2918impl Spmr {
2919    #[doc = "SSn Pin Function Enable"]
2920    #[inline(always)]
2921    pub fn sse(
2922        self,
2923    ) -> crate::common::RegisterField<
2924        0,
2925        0x1,
2926        1,
2927        0,
2928        spmr::Sse,
2929        spmr::Sse,
2930        Spmr_SPEC,
2931        crate::common::RW,
2932    > {
2933        crate::common::RegisterField::<
2934            0,
2935            0x1,
2936            1,
2937            0,
2938            spmr::Sse,
2939            spmr::Sse,
2940            Spmr_SPEC,
2941            crate::common::RW,
2942        >::from_register(self, 0)
2943    }
2944
2945    #[doc = "CTS Enable"]
2946    #[inline(always)]
2947    pub fn ctse(
2948        self,
2949    ) -> crate::common::RegisterField<
2950        1,
2951        0x1,
2952        1,
2953        0,
2954        spmr::Ctse,
2955        spmr::Ctse,
2956        Spmr_SPEC,
2957        crate::common::RW,
2958    > {
2959        crate::common::RegisterField::<
2960            1,
2961            0x1,
2962            1,
2963            0,
2964            spmr::Ctse,
2965            spmr::Ctse,
2966            Spmr_SPEC,
2967            crate::common::RW,
2968        >::from_register(self, 0)
2969    }
2970
2971    #[doc = "Master Slave Select"]
2972    #[inline(always)]
2973    pub fn mss(
2974        self,
2975    ) -> crate::common::RegisterField<
2976        2,
2977        0x1,
2978        1,
2979        0,
2980        spmr::Mss,
2981        spmr::Mss,
2982        Spmr_SPEC,
2983        crate::common::RW,
2984    > {
2985        crate::common::RegisterField::<
2986            2,
2987            0x1,
2988            1,
2989            0,
2990            spmr::Mss,
2991            spmr::Mss,
2992            Spmr_SPEC,
2993            crate::common::RW,
2994        >::from_register(self, 0)
2995    }
2996
2997    #[doc = "Mode Fault Flag"]
2998    #[inline(always)]
2999    pub fn mff(
3000        self,
3001    ) -> crate::common::RegisterField<
3002        4,
3003        0x1,
3004        1,
3005        0,
3006        spmr::Mff,
3007        spmr::Mff,
3008        Spmr_SPEC,
3009        crate::common::RW,
3010    > {
3011        crate::common::RegisterField::<
3012            4,
3013            0x1,
3014            1,
3015            0,
3016            spmr::Mff,
3017            spmr::Mff,
3018            Spmr_SPEC,
3019            crate::common::RW,
3020        >::from_register(self, 0)
3021    }
3022
3023    #[doc = "Clock Polarity Select"]
3024    #[inline(always)]
3025    pub fn ckpol(
3026        self,
3027    ) -> crate::common::RegisterField<
3028        6,
3029        0x1,
3030        1,
3031        0,
3032        spmr::Ckpol,
3033        spmr::Ckpol,
3034        Spmr_SPEC,
3035        crate::common::RW,
3036    > {
3037        crate::common::RegisterField::<
3038            6,
3039            0x1,
3040            1,
3041            0,
3042            spmr::Ckpol,
3043            spmr::Ckpol,
3044            Spmr_SPEC,
3045            crate::common::RW,
3046        >::from_register(self, 0)
3047    }
3048
3049    #[doc = "Clock Phase Select"]
3050    #[inline(always)]
3051    pub fn ckph(
3052        self,
3053    ) -> crate::common::RegisterField<
3054        7,
3055        0x1,
3056        1,
3057        0,
3058        spmr::Ckph,
3059        spmr::Ckph,
3060        Spmr_SPEC,
3061        crate::common::RW,
3062    > {
3063        crate::common::RegisterField::<
3064            7,
3065            0x1,
3066            1,
3067            0,
3068            spmr::Ckph,
3069            spmr::Ckph,
3070            Spmr_SPEC,
3071            crate::common::RW,
3072        >::from_register(self, 0)
3073    }
3074}
3075impl ::core::default::Default for Spmr {
3076    #[inline(always)]
3077    fn default() -> Spmr {
3078        <crate::RegValueT<Spmr_SPEC> as RegisterValue<_>>::new(0)
3079    }
3080}
3081pub mod spmr {
3082
3083    #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
3084    pub struct Sse_SPEC;
3085    pub type Sse = crate::EnumBitfieldStruct<u8, Sse_SPEC>;
3086    impl Sse {
3087        #[doc = "Disable SSn pin function"]
3088        pub const _0: Self = Self::new(0);
3089
3090        #[doc = "Enable SSn pin function"]
3091        pub const _1: Self = Self::new(1);
3092    }
3093    #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
3094    pub struct Ctse_SPEC;
3095    pub type Ctse = crate::EnumBitfieldStruct<u8, Ctse_SPEC>;
3096    impl Ctse {
3097        #[doc = "Disable CTS function (enable RTS output function)"]
3098        pub const _0: Self = Self::new(0);
3099
3100        #[doc = "Enable CTS function"]
3101        pub const _1: Self = Self::new(1);
3102    }
3103    #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
3104    pub struct Mss_SPEC;
3105    pub type Mss = crate::EnumBitfieldStruct<u8, Mss_SPEC>;
3106    impl Mss {
3107        #[doc = "Transmit through TXDn pin and receive through RXDn pin (master mode)"]
3108        pub const _0: Self = Self::new(0);
3109
3110        #[doc = "Receive through TXDn pin and transmit through RXDn pin (slave mode)"]
3111        pub const _1: Self = Self::new(1);
3112    }
3113    #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
3114    pub struct Mff_SPEC;
3115    pub type Mff = crate::EnumBitfieldStruct<u8, Mff_SPEC>;
3116    impl Mff {
3117        #[doc = "No mode fault error"]
3118        pub const _0: Self = Self::new(0);
3119
3120        #[doc = "Mode fault error"]
3121        pub const _1: Self = Self::new(1);
3122    }
3123    #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
3124    pub struct Ckpol_SPEC;
3125    pub type Ckpol = crate::EnumBitfieldStruct<u8, Ckpol_SPEC>;
3126    impl Ckpol {
3127        #[doc = "Do not invert clock polarity"]
3128        pub const _0: Self = Self::new(0);
3129
3130        #[doc = "Invert clock polarity"]
3131        pub const _1: Self = Self::new(1);
3132    }
3133    #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
3134    pub struct Ckph_SPEC;
3135    pub type Ckph = crate::EnumBitfieldStruct<u8, Ckph_SPEC>;
3136    impl Ckph {
3137        #[doc = "Do not delay clock"]
3138        pub const _0: Self = Self::new(0);
3139
3140        #[doc = "Delay clock"]
3141        pub const _1: Self = Self::new(1);
3142    }
3143}
3144#[doc(hidden)]
3145#[derive(Copy, Clone, Eq, PartialEq)]
3146pub struct Ftdrhl_SPEC;
3147impl crate::sealed::RegSpec for Ftdrhl_SPEC {
3148    type DataType = u16;
3149}
3150
3151#[doc = "Transmit FIFO Data Register"]
3152pub type Ftdrhl = crate::RegValueT<Ftdrhl_SPEC>;
3153
3154impl Ftdrhl {
3155    #[doc = "Serial transmit data"]
3156    #[inline(always)]
3157    pub fn tdat(
3158        self,
3159    ) -> crate::common::RegisterField<0, 0x1ff, 1, 0, u16, u16, Ftdrhl_SPEC, crate::common::W> {
3160        crate::common::RegisterField::<0,0x1ff,1,0,u16,u16,Ftdrhl_SPEC,crate::common::W>::from_register(self,0)
3161    }
3162
3163    #[doc = "Multi-Processor Transfer Bit Flag"]
3164    #[inline(always)]
3165    pub fn mpbt(
3166        self,
3167    ) -> crate::common::RegisterField<
3168        9,
3169        0x1,
3170        1,
3171        0,
3172        ftdrhl::Mpbt,
3173        ftdrhl::Mpbt,
3174        Ftdrhl_SPEC,
3175        crate::common::W,
3176    > {
3177        crate::common::RegisterField::<
3178            9,
3179            0x1,
3180            1,
3181            0,
3182            ftdrhl::Mpbt,
3183            ftdrhl::Mpbt,
3184            Ftdrhl_SPEC,
3185            crate::common::W,
3186        >::from_register(self, 0)
3187    }
3188}
3189impl ::core::default::Default for Ftdrhl {
3190    #[inline(always)]
3191    fn default() -> Ftdrhl {
3192        <crate::RegValueT<Ftdrhl_SPEC> as RegisterValue<_>>::new(65535)
3193    }
3194}
3195pub mod ftdrhl {
3196
3197    #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
3198    pub struct Mpbt_SPEC;
3199    pub type Mpbt = crate::EnumBitfieldStruct<u8, Mpbt_SPEC>;
3200    impl Mpbt {
3201        #[doc = "Data transmission cycle"]
3202        pub const _0: Self = Self::new(0);
3203
3204        #[doc = "ID transmission cycle"]
3205        pub const _1: Self = Self::new(1);
3206    }
3207}
3208#[doc(hidden)]
3209#[derive(Copy, Clone, Eq, PartialEq)]
3210pub struct Tdrhl_SPEC;
3211impl crate::sealed::RegSpec for Tdrhl_SPEC {
3212    type DataType = u16;
3213}
3214
3215#[doc = "Transmit Data Register"]
3216pub type Tdrhl = crate::RegValueT<Tdrhl_SPEC>;
3217
3218impl Tdrhl {
3219    #[doc = "Serial Transmit Data"]
3220    #[inline(always)]
3221    pub fn tdat(
3222        self,
3223    ) -> crate::common::RegisterField<0, 0x1ff, 1, 0, u16, u16, Tdrhl_SPEC, crate::common::RW> {
3224        crate::common::RegisterField::<0,0x1ff,1,0,u16,u16,Tdrhl_SPEC,crate::common::RW>::from_register(self,0)
3225    }
3226}
3227impl ::core::default::Default for Tdrhl {
3228    #[inline(always)]
3229    fn default() -> Tdrhl {
3230        <crate::RegValueT<Tdrhl_SPEC> as RegisterValue<_>>::new(65535)
3231    }
3232}
3233
3234#[doc(hidden)]
3235#[derive(Copy, Clone, Eq, PartialEq)]
3236pub struct Ftdrh_SPEC;
3237impl crate::sealed::RegSpec for Ftdrh_SPEC {
3238    type DataType = u8;
3239}
3240
3241#[doc = "Transmit FIFO Data Register"]
3242pub type Ftdrh = crate::RegValueT<Ftdrh_SPEC>;
3243
3244impl Ftdrh {
3245    #[doc = "Serial transmit data"]
3246    #[inline(always)]
3247    pub fn tdat(self) -> crate::common::RegisterFieldBool<0, 1, 0, Ftdrh_SPEC, crate::common::W> {
3248        crate::common::RegisterFieldBool::<0, 1, 0, Ftdrh_SPEC, crate::common::W>::from_register(
3249            self, 0,
3250        )
3251    }
3252
3253    #[doc = "Multi-Processor Transfer Bit Flag"]
3254    #[inline(always)]
3255    pub fn mpbt(
3256        self,
3257    ) -> crate::common::RegisterField<
3258        1,
3259        0x1,
3260        1,
3261        0,
3262        ftdrh::Mpbt,
3263        ftdrh::Mpbt,
3264        Ftdrh_SPEC,
3265        crate::common::W,
3266    > {
3267        crate::common::RegisterField::<
3268            1,
3269            0x1,
3270            1,
3271            0,
3272            ftdrh::Mpbt,
3273            ftdrh::Mpbt,
3274            Ftdrh_SPEC,
3275            crate::common::W,
3276        >::from_register(self, 0)
3277    }
3278}
3279impl ::core::default::Default for Ftdrh {
3280    #[inline(always)]
3281    fn default() -> Ftdrh {
3282        <crate::RegValueT<Ftdrh_SPEC> as RegisterValue<_>>::new(255)
3283    }
3284}
3285pub mod ftdrh {
3286
3287    #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
3288    pub struct Mpbt_SPEC;
3289    pub type Mpbt = crate::EnumBitfieldStruct<u8, Mpbt_SPEC>;
3290    impl Mpbt {
3291        #[doc = "Data transmission cycle"]
3292        pub const _0: Self = Self::new(0);
3293
3294        #[doc = "ID transmission cycle"]
3295        pub const _1: Self = Self::new(1);
3296    }
3297}
3298#[doc(hidden)]
3299#[derive(Copy, Clone, Eq, PartialEq)]
3300pub struct Ftdrl_SPEC;
3301impl crate::sealed::RegSpec for Ftdrl_SPEC {
3302    type DataType = u8;
3303}
3304
3305#[doc = "Transmit FIFO Data Register"]
3306pub type Ftdrl = crate::RegValueT<Ftdrl_SPEC>;
3307
3308impl Ftdrl {
3309    #[doc = "Serial transmit data"]
3310    #[inline(always)]
3311    pub fn tdat(
3312        self,
3313    ) -> crate::common::RegisterField<0, 0xff, 1, 0, u8, u8, Ftdrl_SPEC, crate::common::W> {
3314        crate::common::RegisterField::<0,0xff,1,0,u8,u8,Ftdrl_SPEC,crate::common::W>::from_register(self,0)
3315    }
3316}
3317impl ::core::default::Default for Ftdrl {
3318    #[inline(always)]
3319    fn default() -> Ftdrl {
3320        <crate::RegValueT<Ftdrl_SPEC> as RegisterValue<_>>::new(255)
3321    }
3322}
3323
3324#[doc(hidden)]
3325#[derive(Copy, Clone, Eq, PartialEq)]
3326pub struct Frdrhl_SPEC;
3327impl crate::sealed::RegSpec for Frdrhl_SPEC {
3328    type DataType = u16;
3329}
3330
3331#[doc = "Receive FIFO Data Register"]
3332pub type Frdrhl = crate::RegValueT<Frdrhl_SPEC>;
3333
3334impl Frdrhl {
3335    #[doc = "Serial receive data"]
3336    #[inline(always)]
3337    pub fn rdat(
3338        self,
3339    ) -> crate::common::RegisterField<0, 0x1ff, 1, 0, u16, u16, Frdrhl_SPEC, crate::common::R> {
3340        crate::common::RegisterField::<0,0x1ff,1,0,u16,u16,Frdrhl_SPEC,crate::common::R>::from_register(self,0)
3341    }
3342
3343    #[doc = "Multi-Processor Bit Flag"]
3344    #[inline(always)]
3345    pub fn mpb(
3346        self,
3347    ) -> crate::common::RegisterField<
3348        9,
3349        0x1,
3350        1,
3351        0,
3352        frdrhl::Mpb,
3353        frdrhl::Mpb,
3354        Frdrhl_SPEC,
3355        crate::common::R,
3356    > {
3357        crate::common::RegisterField::<
3358            9,
3359            0x1,
3360            1,
3361            0,
3362            frdrhl::Mpb,
3363            frdrhl::Mpb,
3364            Frdrhl_SPEC,
3365            crate::common::R,
3366        >::from_register(self, 0)
3367    }
3368
3369    #[doc = "Receive Data Ready Flag"]
3370    #[inline(always)]
3371    pub fn dr(
3372        self,
3373    ) -> crate::common::RegisterField<
3374        10,
3375        0x1,
3376        1,
3377        0,
3378        frdrhl::Dr,
3379        frdrhl::Dr,
3380        Frdrhl_SPEC,
3381        crate::common::R,
3382    > {
3383        crate::common::RegisterField::<
3384            10,
3385            0x1,
3386            1,
3387            0,
3388            frdrhl::Dr,
3389            frdrhl::Dr,
3390            Frdrhl_SPEC,
3391            crate::common::R,
3392        >::from_register(self, 0)
3393    }
3394
3395    #[doc = "Parity Error Flag"]
3396    #[inline(always)]
3397    pub fn per(
3398        self,
3399    ) -> crate::common::RegisterField<
3400        11,
3401        0x1,
3402        1,
3403        0,
3404        frdrhl::Per,
3405        frdrhl::Per,
3406        Frdrhl_SPEC,
3407        crate::common::R,
3408    > {
3409        crate::common::RegisterField::<
3410            11,
3411            0x1,
3412            1,
3413            0,
3414            frdrhl::Per,
3415            frdrhl::Per,
3416            Frdrhl_SPEC,
3417            crate::common::R,
3418        >::from_register(self, 0)
3419    }
3420
3421    #[doc = "Framing Error Flag"]
3422    #[inline(always)]
3423    pub fn fer(
3424        self,
3425    ) -> crate::common::RegisterField<
3426        12,
3427        0x1,
3428        1,
3429        0,
3430        frdrhl::Fer,
3431        frdrhl::Fer,
3432        Frdrhl_SPEC,
3433        crate::common::R,
3434    > {
3435        crate::common::RegisterField::<
3436            12,
3437            0x1,
3438            1,
3439            0,
3440            frdrhl::Fer,
3441            frdrhl::Fer,
3442            Frdrhl_SPEC,
3443            crate::common::R,
3444        >::from_register(self, 0)
3445    }
3446
3447    #[doc = "Overrun Error Flag"]
3448    #[inline(always)]
3449    pub fn orer(
3450        self,
3451    ) -> crate::common::RegisterField<
3452        13,
3453        0x1,
3454        1,
3455        0,
3456        frdrhl::Orer,
3457        frdrhl::Orer,
3458        Frdrhl_SPEC,
3459        crate::common::R,
3460    > {
3461        crate::common::RegisterField::<
3462            13,
3463            0x1,
3464            1,
3465            0,
3466            frdrhl::Orer,
3467            frdrhl::Orer,
3468            Frdrhl_SPEC,
3469            crate::common::R,
3470        >::from_register(self, 0)
3471    }
3472
3473    #[doc = "Receive FIFO Data Full Flag"]
3474    #[inline(always)]
3475    pub fn rdf(
3476        self,
3477    ) -> crate::common::RegisterField<
3478        14,
3479        0x1,
3480        1,
3481        0,
3482        frdrhl::Rdf,
3483        frdrhl::Rdf,
3484        Frdrhl_SPEC,
3485        crate::common::R,
3486    > {
3487        crate::common::RegisterField::<
3488            14,
3489            0x1,
3490            1,
3491            0,
3492            frdrhl::Rdf,
3493            frdrhl::Rdf,
3494            Frdrhl_SPEC,
3495            crate::common::R,
3496        >::from_register(self, 0)
3497    }
3498}
3499impl ::core::default::Default for Frdrhl {
3500    #[inline(always)]
3501    fn default() -> Frdrhl {
3502        <crate::RegValueT<Frdrhl_SPEC> as RegisterValue<_>>::new(0)
3503    }
3504}
3505pub mod frdrhl {
3506
3507    #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
3508    pub struct Mpb_SPEC;
3509    pub type Mpb = crate::EnumBitfieldStruct<u8, Mpb_SPEC>;
3510    impl Mpb {
3511        #[doc = "Data transmission cycle"]
3512        pub const _0: Self = Self::new(0);
3513
3514        #[doc = "ID transmission cycle"]
3515        pub const _1: Self = Self::new(1);
3516    }
3517    #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
3518    pub struct Dr_SPEC;
3519    pub type Dr = crate::EnumBitfieldStruct<u8, Dr_SPEC>;
3520    impl Dr {
3521        #[doc = "Receiving is in progress, or no received data remains in the FRDRH and FRDRL registers after successfully completed reception"]
3522        pub const _0: Self = Self::new(0);
3523
3524        #[doc = "Next receive data is not received for a period after successfully completed reception"]
3525        pub const _1: Self = Self::new(1);
3526    }
3527    #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
3528    pub struct Per_SPEC;
3529    pub type Per = crate::EnumBitfieldStruct<u8, Per_SPEC>;
3530    impl Per {
3531        #[doc = "No parity error occurred in the first data of FRDRH and FRDRL"]
3532        pub const _0: Self = Self::new(0);
3533
3534        #[doc = "Parity error occurred in the first data of FRDRH and FRDRL"]
3535        pub const _1: Self = Self::new(1);
3536    }
3537    #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
3538    pub struct Fer_SPEC;
3539    pub type Fer = crate::EnumBitfieldStruct<u8, Fer_SPEC>;
3540    impl Fer {
3541        #[doc = "No framing error occurred in the first data of FRDRH and FRDRL"]
3542        pub const _0: Self = Self::new(0);
3543
3544        #[doc = "Framing error occurred in the first data of FRDRH and FRDRL"]
3545        pub const _1: Self = Self::new(1);
3546    }
3547    #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
3548    pub struct Orer_SPEC;
3549    pub type Orer = crate::EnumBitfieldStruct<u8, Orer_SPEC>;
3550    impl Orer {
3551        #[doc = "No overrun error occurred"]
3552        pub const _0: Self = Self::new(0);
3553
3554        #[doc = "Overrun error occurred"]
3555        pub const _1: Self = Self::new(1);
3556    }
3557    #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
3558    pub struct Rdf_SPEC;
3559    pub type Rdf = crate::EnumBitfieldStruct<u8, Rdf_SPEC>;
3560    impl Rdf {
3561        #[doc = "The amount of receive data written in FRDRH and FRDRL is less than the specified receive triggering number"]
3562        pub const _0: Self = Self::new(0);
3563
3564        #[doc = "The amount of receive data written in FRDRH and FRDRL is equal to or greater than the specified receive triggering number"]
3565        pub const _1: Self = Self::new(1);
3566    }
3567}
3568#[doc(hidden)]
3569#[derive(Copy, Clone, Eq, PartialEq)]
3570pub struct Rdrhl_SPEC;
3571impl crate::sealed::RegSpec for Rdrhl_SPEC {
3572    type DataType = u16;
3573}
3574
3575#[doc = "Receive Data Register"]
3576pub type Rdrhl = crate::RegValueT<Rdrhl_SPEC>;
3577
3578impl Rdrhl {
3579    #[doc = "Serial Receive Data"]
3580    #[inline(always)]
3581    pub fn rdat(
3582        self,
3583    ) -> crate::common::RegisterField<0, 0x1ff, 1, 0, u16, u16, Rdrhl_SPEC, crate::common::R> {
3584        crate::common::RegisterField::<0,0x1ff,1,0,u16,u16,Rdrhl_SPEC,crate::common::R>::from_register(self,0)
3585    }
3586}
3587impl ::core::default::Default for Rdrhl {
3588    #[inline(always)]
3589    fn default() -> Rdrhl {
3590        <crate::RegValueT<Rdrhl_SPEC> as RegisterValue<_>>::new(0)
3591    }
3592}
3593
3594#[doc(hidden)]
3595#[derive(Copy, Clone, Eq, PartialEq)]
3596pub struct Frdrh_SPEC;
3597impl crate::sealed::RegSpec for Frdrh_SPEC {
3598    type DataType = u8;
3599}
3600
3601#[doc = "Receive FIFO Data Register"]
3602pub type Frdrh = crate::RegValueT<Frdrh_SPEC>;
3603
3604impl Frdrh {
3605    #[doc = "Serial receive data"]
3606    #[inline(always)]
3607    pub fn rdat(self) -> crate::common::RegisterFieldBool<0, 1, 0, Frdrh_SPEC, crate::common::R> {
3608        crate::common::RegisterFieldBool::<0, 1, 0, Frdrh_SPEC, crate::common::R>::from_register(
3609            self, 0,
3610        )
3611    }
3612
3613    #[doc = "Multi-Processor Bit Flag"]
3614    #[inline(always)]
3615    pub fn mpb(
3616        self,
3617    ) -> crate::common::RegisterField<
3618        1,
3619        0x1,
3620        1,
3621        0,
3622        frdrh::Mpb,
3623        frdrh::Mpb,
3624        Frdrh_SPEC,
3625        crate::common::R,
3626    > {
3627        crate::common::RegisterField::<
3628            1,
3629            0x1,
3630            1,
3631            0,
3632            frdrh::Mpb,
3633            frdrh::Mpb,
3634            Frdrh_SPEC,
3635            crate::common::R,
3636        >::from_register(self, 0)
3637    }
3638
3639    #[doc = "Receive Data Ready Flag"]
3640    #[inline(always)]
3641    pub fn dr(
3642        self,
3643    ) -> crate::common::RegisterField<
3644        2,
3645        0x1,
3646        1,
3647        0,
3648        frdrh::Dr,
3649        frdrh::Dr,
3650        Frdrh_SPEC,
3651        crate::common::R,
3652    > {
3653        crate::common::RegisterField::<
3654            2,
3655            0x1,
3656            1,
3657            0,
3658            frdrh::Dr,
3659            frdrh::Dr,
3660            Frdrh_SPEC,
3661            crate::common::R,
3662        >::from_register(self, 0)
3663    }
3664
3665    #[doc = "Parity Error Flag"]
3666    #[inline(always)]
3667    pub fn per(
3668        self,
3669    ) -> crate::common::RegisterField<
3670        3,
3671        0x1,
3672        1,
3673        0,
3674        frdrh::Per,
3675        frdrh::Per,
3676        Frdrh_SPEC,
3677        crate::common::R,
3678    > {
3679        crate::common::RegisterField::<
3680            3,
3681            0x1,
3682            1,
3683            0,
3684            frdrh::Per,
3685            frdrh::Per,
3686            Frdrh_SPEC,
3687            crate::common::R,
3688        >::from_register(self, 0)
3689    }
3690
3691    #[doc = "Framing Error Flag"]
3692    #[inline(always)]
3693    pub fn fer(
3694        self,
3695    ) -> crate::common::RegisterField<
3696        4,
3697        0x1,
3698        1,
3699        0,
3700        frdrh::Fer,
3701        frdrh::Fer,
3702        Frdrh_SPEC,
3703        crate::common::R,
3704    > {
3705        crate::common::RegisterField::<
3706            4,
3707            0x1,
3708            1,
3709            0,
3710            frdrh::Fer,
3711            frdrh::Fer,
3712            Frdrh_SPEC,
3713            crate::common::R,
3714        >::from_register(self, 0)
3715    }
3716
3717    #[doc = "Overrun Error Flag"]
3718    #[inline(always)]
3719    pub fn orer(
3720        self,
3721    ) -> crate::common::RegisterField<
3722        5,
3723        0x1,
3724        1,
3725        0,
3726        frdrh::Orer,
3727        frdrh::Orer,
3728        Frdrh_SPEC,
3729        crate::common::R,
3730    > {
3731        crate::common::RegisterField::<
3732            5,
3733            0x1,
3734            1,
3735            0,
3736            frdrh::Orer,
3737            frdrh::Orer,
3738            Frdrh_SPEC,
3739            crate::common::R,
3740        >::from_register(self, 0)
3741    }
3742
3743    #[doc = "Receive FIFO Data Full Flag"]
3744    #[inline(always)]
3745    pub fn rdf(
3746        self,
3747    ) -> crate::common::RegisterField<
3748        6,
3749        0x1,
3750        1,
3751        0,
3752        frdrh::Rdf,
3753        frdrh::Rdf,
3754        Frdrh_SPEC,
3755        crate::common::R,
3756    > {
3757        crate::common::RegisterField::<
3758            6,
3759            0x1,
3760            1,
3761            0,
3762            frdrh::Rdf,
3763            frdrh::Rdf,
3764            Frdrh_SPEC,
3765            crate::common::R,
3766        >::from_register(self, 0)
3767    }
3768}
3769impl ::core::default::Default for Frdrh {
3770    #[inline(always)]
3771    fn default() -> Frdrh {
3772        <crate::RegValueT<Frdrh_SPEC> as RegisterValue<_>>::new(0)
3773    }
3774}
3775pub mod frdrh {
3776
3777    #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
3778    pub struct Mpb_SPEC;
3779    pub type Mpb = crate::EnumBitfieldStruct<u8, Mpb_SPEC>;
3780    impl Mpb {
3781        #[doc = "Data transmission cycle"]
3782        pub const _0: Self = Self::new(0);
3783
3784        #[doc = "ID transmission cycle"]
3785        pub const _1: Self = Self::new(1);
3786    }
3787    #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
3788    pub struct Dr_SPEC;
3789    pub type Dr = crate::EnumBitfieldStruct<u8, Dr_SPEC>;
3790    impl Dr {
3791        #[doc = "Receiving is in progress, or no received data remains in the FRDRH and FRDRL registers after successfully completed reception"]
3792        pub const _0: Self = Self::new(0);
3793
3794        #[doc = "Next receive data is not received for a period after successfully completed reception"]
3795        pub const _1: Self = Self::new(1);
3796    }
3797    #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
3798    pub struct Per_SPEC;
3799    pub type Per = crate::EnumBitfieldStruct<u8, Per_SPEC>;
3800    impl Per {
3801        #[doc = "No parity error occurred in the first data of FRDRH and FRDRL"]
3802        pub const _0: Self = Self::new(0);
3803
3804        #[doc = "Parity error occurred in the first data of FRDRH and FRDRL"]
3805        pub const _1: Self = Self::new(1);
3806    }
3807    #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
3808    pub struct Fer_SPEC;
3809    pub type Fer = crate::EnumBitfieldStruct<u8, Fer_SPEC>;
3810    impl Fer {
3811        #[doc = "No framing error occurred in the first data of FRDRH and FRDRL"]
3812        pub const _0: Self = Self::new(0);
3813
3814        #[doc = "Framing error occurred in the first data of FRDRH and FRDRL"]
3815        pub const _1: Self = Self::new(1);
3816    }
3817    #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
3818    pub struct Orer_SPEC;
3819    pub type Orer = crate::EnumBitfieldStruct<u8, Orer_SPEC>;
3820    impl Orer {
3821        #[doc = "No overrun error occurred"]
3822        pub const _0: Self = Self::new(0);
3823
3824        #[doc = "Overrun error occurred"]
3825        pub const _1: Self = Self::new(1);
3826    }
3827    #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
3828    pub struct Rdf_SPEC;
3829    pub type Rdf = crate::EnumBitfieldStruct<u8, Rdf_SPEC>;
3830    impl Rdf {
3831        #[doc = "The amount of receive data written in FRDRH and FRDRL is less than the specified receive triggering number"]
3832        pub const _0: Self = Self::new(0);
3833
3834        #[doc = "The amount of receive data written in FRDRH and FRDRL is equal to or greater than the specified receive triggering number"]
3835        pub const _1: Self = Self::new(1);
3836    }
3837}
3838#[doc(hidden)]
3839#[derive(Copy, Clone, Eq, PartialEq)]
3840pub struct Frdrl_SPEC;
3841impl crate::sealed::RegSpec for Frdrl_SPEC {
3842    type DataType = u8;
3843}
3844
3845#[doc = "Receive FIFO Data Register"]
3846pub type Frdrl = crate::RegValueT<Frdrl_SPEC>;
3847
3848impl Frdrl {
3849    #[doc = "Serial receive data"]
3850    #[inline(always)]
3851    pub fn rdat(
3852        self,
3853    ) -> crate::common::RegisterField<0, 0xff, 1, 0, u8, u8, Frdrl_SPEC, crate::common::R> {
3854        crate::common::RegisterField::<0,0xff,1,0,u8,u8,Frdrl_SPEC,crate::common::R>::from_register(self,0)
3855    }
3856}
3857impl ::core::default::Default for Frdrl {
3858    #[inline(always)]
3859    fn default() -> Frdrl {
3860        <crate::RegValueT<Frdrl_SPEC> as RegisterValue<_>>::new(0)
3861    }
3862}
3863
3864#[doc(hidden)]
3865#[derive(Copy, Clone, Eq, PartialEq)]
3866pub struct Mddr_SPEC;
3867impl crate::sealed::RegSpec for Mddr_SPEC {
3868    type DataType = u8;
3869}
3870
3871#[doc = "Modulation Duty Register"]
3872pub type Mddr = crate::RegValueT<Mddr_SPEC>;
3873
3874impl NoBitfieldReg<Mddr_SPEC> for Mddr {}
3875impl ::core::default::Default for Mddr {
3876    #[inline(always)]
3877    fn default() -> Mddr {
3878        <crate::RegValueT<Mddr_SPEC> as RegisterValue<_>>::new(255)
3879    }
3880}
3881
3882#[doc(hidden)]
3883#[derive(Copy, Clone, Eq, PartialEq)]
3884pub struct Dccr_SPEC;
3885impl crate::sealed::RegSpec for Dccr_SPEC {
3886    type DataType = u8;
3887}
3888
3889#[doc = "Data Compare Match Control Register"]
3890pub type Dccr = crate::RegValueT<Dccr_SPEC>;
3891
3892impl Dccr {
3893    #[doc = "Data Compare Match Flag"]
3894    #[inline(always)]
3895    pub fn dcmf(
3896        self,
3897    ) -> crate::common::RegisterField<
3898        0,
3899        0x1,
3900        1,
3901        0,
3902        dccr::Dcmf,
3903        dccr::Dcmf,
3904        Dccr_SPEC,
3905        crate::common::RW,
3906    > {
3907        crate::common::RegisterField::<
3908            0,
3909            0x1,
3910            1,
3911            0,
3912            dccr::Dcmf,
3913            dccr::Dcmf,
3914            Dccr_SPEC,
3915            crate::common::RW,
3916        >::from_register(self, 0)
3917    }
3918
3919    #[doc = "Data Compare Match Parity Error Flag"]
3920    #[inline(always)]
3921    pub fn dper(
3922        self,
3923    ) -> crate::common::RegisterField<
3924        3,
3925        0x1,
3926        1,
3927        0,
3928        dccr::Dper,
3929        dccr::Dper,
3930        Dccr_SPEC,
3931        crate::common::RW,
3932    > {
3933        crate::common::RegisterField::<
3934            3,
3935            0x1,
3936            1,
3937            0,
3938            dccr::Dper,
3939            dccr::Dper,
3940            Dccr_SPEC,
3941            crate::common::RW,
3942        >::from_register(self, 0)
3943    }
3944
3945    #[doc = "Data Compare Match Framing Error Flag"]
3946    #[inline(always)]
3947    pub fn dfer(
3948        self,
3949    ) -> crate::common::RegisterField<
3950        4,
3951        0x1,
3952        1,
3953        0,
3954        dccr::Dfer,
3955        dccr::Dfer,
3956        Dccr_SPEC,
3957        crate::common::RW,
3958    > {
3959        crate::common::RegisterField::<
3960            4,
3961            0x1,
3962            1,
3963            0,
3964            dccr::Dfer,
3965            dccr::Dfer,
3966            Dccr_SPEC,
3967            crate::common::RW,
3968        >::from_register(self, 0)
3969    }
3970
3971    #[doc = "ID Frame Select"]
3972    #[inline(always)]
3973    pub fn idsel(
3974        self,
3975    ) -> crate::common::RegisterField<
3976        6,
3977        0x1,
3978        1,
3979        0,
3980        dccr::Idsel,
3981        dccr::Idsel,
3982        Dccr_SPEC,
3983        crate::common::RW,
3984    > {
3985        crate::common::RegisterField::<
3986            6,
3987            0x1,
3988            1,
3989            0,
3990            dccr::Idsel,
3991            dccr::Idsel,
3992            Dccr_SPEC,
3993            crate::common::RW,
3994        >::from_register(self, 0)
3995    }
3996
3997    #[doc = "Data Compare Match Enable"]
3998    #[inline(always)]
3999    pub fn dcme(
4000        self,
4001    ) -> crate::common::RegisterField<
4002        7,
4003        0x1,
4004        1,
4005        0,
4006        dccr::Dcme,
4007        dccr::Dcme,
4008        Dccr_SPEC,
4009        crate::common::RW,
4010    > {
4011        crate::common::RegisterField::<
4012            7,
4013            0x1,
4014            1,
4015            0,
4016            dccr::Dcme,
4017            dccr::Dcme,
4018            Dccr_SPEC,
4019            crate::common::RW,
4020        >::from_register(self, 0)
4021    }
4022}
4023impl ::core::default::Default for Dccr {
4024    #[inline(always)]
4025    fn default() -> Dccr {
4026        <crate::RegValueT<Dccr_SPEC> as RegisterValue<_>>::new(64)
4027    }
4028}
4029pub mod dccr {
4030
4031    #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
4032    pub struct Dcmf_SPEC;
4033    pub type Dcmf = crate::EnumBitfieldStruct<u8, Dcmf_SPEC>;
4034    impl Dcmf {
4035        #[doc = "Not matched"]
4036        pub const _0: Self = Self::new(0);
4037
4038        #[doc = "Matched"]
4039        pub const _1: Self = Self::new(1);
4040    }
4041    #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
4042    pub struct Dper_SPEC;
4043    pub type Dper = crate::EnumBitfieldStruct<u8, Dper_SPEC>;
4044    impl Dper {
4045        #[doc = "No parity error occurred"]
4046        pub const _0: Self = Self::new(0);
4047
4048        #[doc = "Parity error occurred"]
4049        pub const _1: Self = Self::new(1);
4050    }
4051    #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
4052    pub struct Dfer_SPEC;
4053    pub type Dfer = crate::EnumBitfieldStruct<u8, Dfer_SPEC>;
4054    impl Dfer {
4055        #[doc = "No framing error occurred"]
4056        pub const _0: Self = Self::new(0);
4057
4058        #[doc = "Framing error occurred"]
4059        pub const _1: Self = Self::new(1);
4060    }
4061    #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
4062    pub struct Idsel_SPEC;
4063    pub type Idsel = crate::EnumBitfieldStruct<u8, Idsel_SPEC>;
4064    impl Idsel {
4065        #[doc = "Always compare data regardless of the MPB bit value"]
4066        pub const _0: Self = Self::new(0);
4067
4068        #[doc = "Only compare data when MPB bit = 1 (ID frame)"]
4069        pub const _1: Self = Self::new(1);
4070    }
4071    #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
4072    pub struct Dcme_SPEC;
4073    pub type Dcme = crate::EnumBitfieldStruct<u8, Dcme_SPEC>;
4074    impl Dcme {
4075        #[doc = "Disable address match function"]
4076        pub const _0: Self = Self::new(0);
4077
4078        #[doc = "Enable address match function"]
4079        pub const _1: Self = Self::new(1);
4080    }
4081}
4082#[doc(hidden)]
4083#[derive(Copy, Clone, Eq, PartialEq)]
4084pub struct Fcr_SPEC;
4085impl crate::sealed::RegSpec for Fcr_SPEC {
4086    type DataType = u16;
4087}
4088
4089#[doc = "FIFO Control Register"]
4090pub type Fcr = crate::RegValueT<Fcr_SPEC>;
4091
4092impl Fcr {
4093    #[doc = "FIFO Mode Select"]
4094    #[inline(always)]
4095    pub fn fm(
4096        self,
4097    ) -> crate::common::RegisterField<0, 0x1, 1, 0, fcr::Fm, fcr::Fm, Fcr_SPEC, crate::common::RW>
4098    {
4099        crate::common::RegisterField::<0,0x1,1,0,fcr::Fm,fcr::Fm,Fcr_SPEC,crate::common::RW>::from_register(self,0)
4100    }
4101
4102    #[doc = "Receive FIFO Data Register Reset"]
4103    #[inline(always)]
4104    pub fn rfrst(
4105        self,
4106    ) -> crate::common::RegisterField<
4107        1,
4108        0x1,
4109        1,
4110        0,
4111        fcr::Rfrst,
4112        fcr::Rfrst,
4113        Fcr_SPEC,
4114        crate::common::RW,
4115    > {
4116        crate::common::RegisterField::<
4117            1,
4118            0x1,
4119            1,
4120            0,
4121            fcr::Rfrst,
4122            fcr::Rfrst,
4123            Fcr_SPEC,
4124            crate::common::RW,
4125        >::from_register(self, 0)
4126    }
4127
4128    #[doc = "Transmit FIFO Data Register Reset"]
4129    #[inline(always)]
4130    pub fn tfrst(
4131        self,
4132    ) -> crate::common::RegisterField<
4133        2,
4134        0x1,
4135        1,
4136        0,
4137        fcr::Tfrst,
4138        fcr::Tfrst,
4139        Fcr_SPEC,
4140        crate::common::RW,
4141    > {
4142        crate::common::RegisterField::<
4143            2,
4144            0x1,
4145            1,
4146            0,
4147            fcr::Tfrst,
4148            fcr::Tfrst,
4149            Fcr_SPEC,
4150            crate::common::RW,
4151        >::from_register(self, 0)
4152    }
4153
4154    #[doc = "Receive Data Ready Error Select"]
4155    #[inline(always)]
4156    pub fn dres(
4157        self,
4158    ) -> crate::common::RegisterField<3, 0x1, 1, 0, fcr::Dres, fcr::Dres, Fcr_SPEC, crate::common::RW>
4159    {
4160        crate::common::RegisterField::<
4161            3,
4162            0x1,
4163            1,
4164            0,
4165            fcr::Dres,
4166            fcr::Dres,
4167            Fcr_SPEC,
4168            crate::common::RW,
4169        >::from_register(self, 0)
4170    }
4171
4172    #[doc = "Transmit FIFO Data Trigger Number"]
4173    #[inline(always)]
4174    pub fn ttrg(
4175        self,
4176    ) -> crate::common::RegisterField<4, 0xf, 1, 0, u8, u8, Fcr_SPEC, crate::common::RW> {
4177        crate::common::RegisterField::<4,0xf,1,0,u8,u8,Fcr_SPEC,crate::common::RW>::from_register(self,0)
4178    }
4179
4180    #[doc = "Receive FIFO Data Trigger Number"]
4181    #[inline(always)]
4182    pub fn rtrg(
4183        self,
4184    ) -> crate::common::RegisterField<8, 0xf, 1, 0, u8, u8, Fcr_SPEC, crate::common::RW> {
4185        crate::common::RegisterField::<8,0xf,1,0,u8,u8,Fcr_SPEC,crate::common::RW>::from_register(self,0)
4186    }
4187
4188    #[doc = "RTS Output Active Trigger Number Select"]
4189    #[inline(always)]
4190    pub fn rstrg(
4191        self,
4192    ) -> crate::common::RegisterField<12, 0xf, 1, 0, u8, u8, Fcr_SPEC, crate::common::RW> {
4193        crate::common::RegisterField::<12,0xf,1,0,u8,u8,Fcr_SPEC,crate::common::RW>::from_register(self,0)
4194    }
4195}
4196impl ::core::default::Default for Fcr {
4197    #[inline(always)]
4198    fn default() -> Fcr {
4199        <crate::RegValueT<Fcr_SPEC> as RegisterValue<_>>::new(63488)
4200    }
4201}
4202pub mod fcr {
4203
4204    #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
4205    pub struct Fm_SPEC;
4206    pub type Fm = crate::EnumBitfieldStruct<u8, Fm_SPEC>;
4207    impl Fm {
4208        #[doc = "Non-FIFO mode. Selects TDR/RDR or TDRHL/RDRHL for communication."]
4209        pub const _0: Self = Self::new(0);
4210
4211        #[doc = "FIFO mode. Selects FTDRHL/FRDRHL for communication."]
4212        pub const _1: Self = Self::new(1);
4213    }
4214    #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
4215    pub struct Rfrst_SPEC;
4216    pub type Rfrst = crate::EnumBitfieldStruct<u8, Rfrst_SPEC>;
4217    impl Rfrst {
4218        #[doc = "Do not reset FRDRHL"]
4219        pub const _0: Self = Self::new(0);
4220
4221        #[doc = "Reset FRDRHL"]
4222        pub const _1: Self = Self::new(1);
4223    }
4224    #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
4225    pub struct Tfrst_SPEC;
4226    pub type Tfrst = crate::EnumBitfieldStruct<u8, Tfrst_SPEC>;
4227    impl Tfrst {
4228        #[doc = "Do not reset FTDRHL"]
4229        pub const _0: Self = Self::new(0);
4230
4231        #[doc = "Reset FTDRHL"]
4232        pub const _1: Self = Self::new(1);
4233    }
4234    #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
4235    pub struct Dres_SPEC;
4236    pub type Dres = crate::EnumBitfieldStruct<u8, Dres_SPEC>;
4237    impl Dres {
4238        #[doc = "Receive data full interrupt (SCIn_RXI)"]
4239        pub const _0: Self = Self::new(0);
4240
4241        #[doc = "Receive error interrupt (SCIn_ERI)"]
4242        pub const _1: Self = Self::new(1);
4243    }
4244}
4245#[doc(hidden)]
4246#[derive(Copy, Clone, Eq, PartialEq)]
4247pub struct Fdr_SPEC;
4248impl crate::sealed::RegSpec for Fdr_SPEC {
4249    type DataType = u16;
4250}
4251
4252#[doc = "FIFO Data Count Register"]
4253pub type Fdr = crate::RegValueT<Fdr_SPEC>;
4254
4255impl Fdr {
4256    #[doc = "Receive FIFO Data Count"]
4257    #[inline(always)]
4258    pub fn r(
4259        self,
4260    ) -> crate::common::RegisterField<0, 0x1f, 1, 0, u8, u8, Fdr_SPEC, crate::common::R> {
4261        crate::common::RegisterField::<0,0x1f,1,0,u8,u8,Fdr_SPEC,crate::common::R>::from_register(self,0)
4262    }
4263
4264    #[doc = "Transmit FIFO Data Count"]
4265    #[inline(always)]
4266    pub fn t(
4267        self,
4268    ) -> crate::common::RegisterField<8, 0x1f, 1, 0, u8, u8, Fdr_SPEC, crate::common::R> {
4269        crate::common::RegisterField::<8,0x1f,1,0,u8,u8,Fdr_SPEC,crate::common::R>::from_register(self,0)
4270    }
4271}
4272impl ::core::default::Default for Fdr {
4273    #[inline(always)]
4274    fn default() -> Fdr {
4275        <crate::RegValueT<Fdr_SPEC> as RegisterValue<_>>::new(0)
4276    }
4277}
4278
4279#[doc(hidden)]
4280#[derive(Copy, Clone, Eq, PartialEq)]
4281pub struct Lsr_SPEC;
4282impl crate::sealed::RegSpec for Lsr_SPEC {
4283    type DataType = u16;
4284}
4285
4286#[doc = "Line Status Register"]
4287pub type Lsr = crate::RegValueT<Lsr_SPEC>;
4288
4289impl Lsr {
4290    #[doc = "Overrun Error Flag"]
4291    #[inline(always)]
4292    pub fn orer(
4293        self,
4294    ) -> crate::common::RegisterField<0, 0x1, 1, 0, lsr::Orer, lsr::Orer, Lsr_SPEC, crate::common::R>
4295    {
4296        crate::common::RegisterField::<0,0x1,1,0,lsr::Orer,lsr::Orer,Lsr_SPEC,crate::common::R>::from_register(self,0)
4297    }
4298
4299    #[doc = "Framing Error Count"]
4300    #[inline(always)]
4301    pub fn fnum(
4302        self,
4303    ) -> crate::common::RegisterField<2, 0x1f, 1, 0, u8, u8, Lsr_SPEC, crate::common::R> {
4304        crate::common::RegisterField::<2,0x1f,1,0,u8,u8,Lsr_SPEC,crate::common::R>::from_register(self,0)
4305    }
4306
4307    #[doc = "Parity Error Count"]
4308    #[inline(always)]
4309    pub fn pnum(
4310        self,
4311    ) -> crate::common::RegisterField<8, 0x1f, 1, 0, u8, u8, Lsr_SPEC, crate::common::R> {
4312        crate::common::RegisterField::<8,0x1f,1,0,u8,u8,Lsr_SPEC,crate::common::R>::from_register(self,0)
4313    }
4314}
4315impl ::core::default::Default for Lsr {
4316    #[inline(always)]
4317    fn default() -> Lsr {
4318        <crate::RegValueT<Lsr_SPEC> as RegisterValue<_>>::new(0)
4319    }
4320}
4321pub mod lsr {
4322
4323    #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
4324    pub struct Orer_SPEC;
4325    pub type Orer = crate::EnumBitfieldStruct<u8, Orer_SPEC>;
4326    impl Orer {
4327        #[doc = "No overrun error occurred"]
4328        pub const _0: Self = Self::new(0);
4329
4330        #[doc = "Overrun error occurred"]
4331        pub const _1: Self = Self::new(1);
4332    }
4333}
4334#[doc(hidden)]
4335#[derive(Copy, Clone, Eq, PartialEq)]
4336pub struct Cdr_SPEC;
4337impl crate::sealed::RegSpec for Cdr_SPEC {
4338    type DataType = u16;
4339}
4340
4341#[doc = "Compare Match Data Register"]
4342pub type Cdr = crate::RegValueT<Cdr_SPEC>;
4343
4344impl Cdr {
4345    #[doc = "Compare Match Data"]
4346    #[inline(always)]
4347    pub fn cmpd(
4348        self,
4349    ) -> crate::common::RegisterField<0, 0x1ff, 1, 0, u16, u16, Cdr_SPEC, crate::common::RW> {
4350        crate::common::RegisterField::<0,0x1ff,1,0,u16,u16,Cdr_SPEC,crate::common::RW>::from_register(self,0)
4351    }
4352}
4353impl ::core::default::Default for Cdr {
4354    #[inline(always)]
4355    fn default() -> Cdr {
4356        <crate::RegValueT<Cdr_SPEC> as RegisterValue<_>>::new(0)
4357    }
4358}
4359
4360#[doc(hidden)]
4361#[derive(Copy, Clone, Eq, PartialEq)]
4362pub struct Sptr_SPEC;
4363impl crate::sealed::RegSpec for Sptr_SPEC {
4364    type DataType = u8;
4365}
4366
4367#[doc = "Serial Port Register"]
4368pub type Sptr = crate::RegValueT<Sptr_SPEC>;
4369
4370impl Sptr {
4371    #[doc = "Serial Input Data Monitor"]
4372    #[inline(always)]
4373    pub fn rxdmon(
4374        self,
4375    ) -> crate::common::RegisterField<
4376        0,
4377        0x1,
4378        1,
4379        0,
4380        sptr::Rxdmon,
4381        sptr::Rxdmon,
4382        Sptr_SPEC,
4383        crate::common::R,
4384    > {
4385        crate::common::RegisterField::<
4386            0,
4387            0x1,
4388            1,
4389            0,
4390            sptr::Rxdmon,
4391            sptr::Rxdmon,
4392            Sptr_SPEC,
4393            crate::common::R,
4394        >::from_register(self, 0)
4395    }
4396
4397    #[doc = "Serial Port Break Data Select"]
4398    #[inline(always)]
4399    pub fn spb2dt(
4400        self,
4401    ) -> crate::common::RegisterField<
4402        1,
4403        0x1,
4404        1,
4405        0,
4406        sptr::Spb2Dt,
4407        sptr::Spb2Dt,
4408        Sptr_SPEC,
4409        crate::common::RW,
4410    > {
4411        crate::common::RegisterField::<
4412            1,
4413            0x1,
4414            1,
4415            0,
4416            sptr::Spb2Dt,
4417            sptr::Spb2Dt,
4418            Sptr_SPEC,
4419            crate::common::RW,
4420        >::from_register(self, 0)
4421    }
4422
4423    #[doc = "Serial Port Break I/O"]
4424    #[inline(always)]
4425    pub fn spb2io(
4426        self,
4427    ) -> crate::common::RegisterField<
4428        2,
4429        0x1,
4430        1,
4431        0,
4432        sptr::Spb2Io,
4433        sptr::Spb2Io,
4434        Sptr_SPEC,
4435        crate::common::RW,
4436    > {
4437        crate::common::RegisterField::<
4438            2,
4439            0x1,
4440            1,
4441            0,
4442            sptr::Spb2Io,
4443            sptr::Spb2Io,
4444            Sptr_SPEC,
4445            crate::common::RW,
4446        >::from_register(self, 0)
4447    }
4448}
4449impl ::core::default::Default for Sptr {
4450    #[inline(always)]
4451    fn default() -> Sptr {
4452        <crate::RegValueT<Sptr_SPEC> as RegisterValue<_>>::new(3)
4453    }
4454}
4455pub mod sptr {
4456
4457    #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
4458    pub struct Rxdmon_SPEC;
4459    pub type Rxdmon = crate::EnumBitfieldStruct<u8, Rxdmon_SPEC>;
4460    impl Rxdmon {
4461        #[doc = "RXDn terminal is the low level"]
4462        pub const _0: Self = Self::new(0);
4463
4464        #[doc = "RXDn terminal is the high level"]
4465        pub const _1: Self = Self::new(1);
4466    }
4467    #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
4468    pub struct Spb2Dt_SPEC;
4469    pub type Spb2Dt = crate::EnumBitfieldStruct<u8, Spb2Dt_SPEC>;
4470    impl Spb2Dt {
4471        #[doc = "Low level is output in TXDn terminal"]
4472        pub const _0: Self = Self::new(0);
4473
4474        #[doc = "High level is output in TXDn terminal"]
4475        pub const _1: Self = Self::new(1);
4476    }
4477    #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
4478    pub struct Spb2Io_SPEC;
4479    pub type Spb2Io = crate::EnumBitfieldStruct<u8, Spb2Io_SPEC>;
4480    impl Spb2Io {
4481        #[doc = "Do not output value of SPB2DT bit on TXDn pin"]
4482        pub const _0: Self = Self::new(0);
4483
4484        #[doc = "Output value of SPB2DT bit on TXDn pin"]
4485        pub const _1: Self = Self::new(1);
4486    }
4487}