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