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"Realtime Clock"]
28unsafe impl ::core::marker::Send for super::Rtc {}
29unsafe impl ::core::marker::Sync for super::Rtc {}
30impl super::Rtc {
31 #[allow(unused)]
32 #[inline(always)]
33 pub(crate) const fn _svd2pac_as_ptr(&self) -> *mut u8 {
34 self.ptr
35 }
36
37 #[doc = "64-Hz Counter"]
38 #[inline(always)]
39 pub const fn r64cnt(&self) -> &'static crate::common::Reg<self::R64Cnt_SPEC, crate::common::R> {
40 unsafe {
41 crate::common::Reg::<self::R64Cnt_SPEC, crate::common::R>::from_ptr(
42 self._svd2pac_as_ptr().add(0usize),
43 )
44 }
45 }
46
47 #[doc = "Binary Counter %s"]
48 #[inline(always)]
49 pub const fn bcnt(
50 &self,
51 ) -> &'static crate::common::ClusterRegisterArray<
52 crate::common::Reg<self::Bcnt_SPEC, crate::common::RW>,
53 4,
54 0x2,
55 > {
56 unsafe {
57 crate::common::ClusterRegisterArray::from_ptr(self._svd2pac_as_ptr().add(0x2usize))
58 }
59 }
60 #[inline(always)]
61 pub const fn bcnt0(&self) -> &'static crate::common::Reg<self::Bcnt_SPEC, crate::common::RW> {
62 unsafe {
63 crate::common::Reg::<self::Bcnt_SPEC, crate::common::RW>::from_ptr(
64 self._svd2pac_as_ptr().add(0x2usize),
65 )
66 }
67 }
68 #[inline(always)]
69 pub const fn bcnt1(&self) -> &'static crate::common::Reg<self::Bcnt_SPEC, crate::common::RW> {
70 unsafe {
71 crate::common::Reg::<self::Bcnt_SPEC, crate::common::RW>::from_ptr(
72 self._svd2pac_as_ptr().add(0x4usize),
73 )
74 }
75 }
76 #[inline(always)]
77 pub const fn bcnt2(&self) -> &'static crate::common::Reg<self::Bcnt_SPEC, crate::common::RW> {
78 unsafe {
79 crate::common::Reg::<self::Bcnt_SPEC, crate::common::RW>::from_ptr(
80 self._svd2pac_as_ptr().add(0x6usize),
81 )
82 }
83 }
84 #[inline(always)]
85 pub const fn bcnt3(&self) -> &'static crate::common::Reg<self::Bcnt_SPEC, crate::common::RW> {
86 unsafe {
87 crate::common::Reg::<self::Bcnt_SPEC, crate::common::RW>::from_ptr(
88 self._svd2pac_as_ptr().add(0x8usize),
89 )
90 }
91 }
92
93 #[doc = "Second Counter (in Calendar Count Mode)"]
94 #[inline(always)]
95 pub const fn rseccnt(
96 &self,
97 ) -> &'static crate::common::Reg<self::Rseccnt_SPEC, crate::common::RW> {
98 unsafe {
99 crate::common::Reg::<self::Rseccnt_SPEC, crate::common::RW>::from_ptr(
100 self._svd2pac_as_ptr().add(2usize),
101 )
102 }
103 }
104
105 #[doc = "Minute Counter (in Calendar Count Mode)"]
106 #[inline(always)]
107 pub const fn rmincnt(
108 &self,
109 ) -> &'static crate::common::Reg<self::Rmincnt_SPEC, crate::common::RW> {
110 unsafe {
111 crate::common::Reg::<self::Rmincnt_SPEC, crate::common::RW>::from_ptr(
112 self._svd2pac_as_ptr().add(4usize),
113 )
114 }
115 }
116
117 #[doc = "Hour Counter (in Calendar Count Mode)"]
118 #[inline(always)]
119 pub const fn rhrcnt(
120 &self,
121 ) -> &'static crate::common::Reg<self::Rhrcnt_SPEC, crate::common::RW> {
122 unsafe {
123 crate::common::Reg::<self::Rhrcnt_SPEC, crate::common::RW>::from_ptr(
124 self._svd2pac_as_ptr().add(6usize),
125 )
126 }
127 }
128
129 #[doc = "Day-of-Week Counter (in Calendar Count Mode)"]
130 #[inline(always)]
131 pub const fn rwkcnt(
132 &self,
133 ) -> &'static crate::common::Reg<self::Rwkcnt_SPEC, crate::common::RW> {
134 unsafe {
135 crate::common::Reg::<self::Rwkcnt_SPEC, crate::common::RW>::from_ptr(
136 self._svd2pac_as_ptr().add(8usize),
137 )
138 }
139 }
140
141 #[doc = "Day Counter"]
142 #[inline(always)]
143 pub const fn rdaycnt(
144 &self,
145 ) -> &'static crate::common::Reg<self::Rdaycnt_SPEC, crate::common::RW> {
146 unsafe {
147 crate::common::Reg::<self::Rdaycnt_SPEC, crate::common::RW>::from_ptr(
148 self._svd2pac_as_ptr().add(10usize),
149 )
150 }
151 }
152
153 #[doc = "Month Counter"]
154 #[inline(always)]
155 pub const fn rmoncnt(
156 &self,
157 ) -> &'static crate::common::Reg<self::Rmoncnt_SPEC, crate::common::RW> {
158 unsafe {
159 crate::common::Reg::<self::Rmoncnt_SPEC, crate::common::RW>::from_ptr(
160 self._svd2pac_as_ptr().add(12usize),
161 )
162 }
163 }
164
165 #[doc = "Year Counter"]
166 #[inline(always)]
167 pub const fn ryrcnt(
168 &self,
169 ) -> &'static crate::common::Reg<self::Ryrcnt_SPEC, crate::common::RW> {
170 unsafe {
171 crate::common::Reg::<self::Ryrcnt_SPEC, crate::common::RW>::from_ptr(
172 self._svd2pac_as_ptr().add(14usize),
173 )
174 }
175 }
176
177 #[doc = "Binary Counter %s Alarm Register"]
178 #[inline(always)]
179 pub const fn bcntar(
180 &self,
181 ) -> &'static crate::common::ClusterRegisterArray<
182 crate::common::Reg<self::Bcntar_SPEC, crate::common::RW>,
183 4,
184 0x2,
185 > {
186 unsafe {
187 crate::common::ClusterRegisterArray::from_ptr(self._svd2pac_as_ptr().add(0x10usize))
188 }
189 }
190 #[inline(always)]
191 pub const fn bcnt0ar(
192 &self,
193 ) -> &'static crate::common::Reg<self::Bcntar_SPEC, crate::common::RW> {
194 unsafe {
195 crate::common::Reg::<self::Bcntar_SPEC, crate::common::RW>::from_ptr(
196 self._svd2pac_as_ptr().add(0x10usize),
197 )
198 }
199 }
200 #[inline(always)]
201 pub const fn bcnt1ar(
202 &self,
203 ) -> &'static crate::common::Reg<self::Bcntar_SPEC, crate::common::RW> {
204 unsafe {
205 crate::common::Reg::<self::Bcntar_SPEC, crate::common::RW>::from_ptr(
206 self._svd2pac_as_ptr().add(0x12usize),
207 )
208 }
209 }
210 #[inline(always)]
211 pub const fn bcnt2ar(
212 &self,
213 ) -> &'static crate::common::Reg<self::Bcntar_SPEC, crate::common::RW> {
214 unsafe {
215 crate::common::Reg::<self::Bcntar_SPEC, crate::common::RW>::from_ptr(
216 self._svd2pac_as_ptr().add(0x14usize),
217 )
218 }
219 }
220 #[inline(always)]
221 pub const fn bcnt3ar(
222 &self,
223 ) -> &'static crate::common::Reg<self::Bcntar_SPEC, crate::common::RW> {
224 unsafe {
225 crate::common::Reg::<self::Bcntar_SPEC, crate::common::RW>::from_ptr(
226 self._svd2pac_as_ptr().add(0x16usize),
227 )
228 }
229 }
230
231 #[doc = "Second Alarm Register (in Calendar Count Mode)"]
232 #[inline(always)]
233 pub const fn rsecar(
234 &self,
235 ) -> &'static crate::common::Reg<self::Rsecar_SPEC, crate::common::RW> {
236 unsafe {
237 crate::common::Reg::<self::Rsecar_SPEC, crate::common::RW>::from_ptr(
238 self._svd2pac_as_ptr().add(16usize),
239 )
240 }
241 }
242
243 #[doc = "Minute Alarm Register (in Calendar Count Mode)"]
244 #[inline(always)]
245 pub const fn rminar(
246 &self,
247 ) -> &'static crate::common::Reg<self::Rminar_SPEC, crate::common::RW> {
248 unsafe {
249 crate::common::Reg::<self::Rminar_SPEC, crate::common::RW>::from_ptr(
250 self._svd2pac_as_ptr().add(18usize),
251 )
252 }
253 }
254
255 #[doc = "Hour Alarm Register (in Calendar Count Mode)"]
256 #[inline(always)]
257 pub const fn rhrar(&self) -> &'static crate::common::Reg<self::Rhrar_SPEC, crate::common::RW> {
258 unsafe {
259 crate::common::Reg::<self::Rhrar_SPEC, crate::common::RW>::from_ptr(
260 self._svd2pac_as_ptr().add(20usize),
261 )
262 }
263 }
264
265 #[doc = "Day-of-Week Alarm Register (in Calendar Count Mode)"]
266 #[inline(always)]
267 pub const fn rwkar(&self) -> &'static crate::common::Reg<self::Rwkar_SPEC, crate::common::RW> {
268 unsafe {
269 crate::common::Reg::<self::Rwkar_SPEC, crate::common::RW>::from_ptr(
270 self._svd2pac_as_ptr().add(22usize),
271 )
272 }
273 }
274
275 #[doc = "Binary Counter %s Alarm Enable Register"]
276 #[inline(always)]
277 pub const fn bcntaer(
278 &self,
279 ) -> &'static crate::common::ClusterRegisterArray<
280 crate::common::Reg<self::Bcntaer_SPEC, crate::common::RW>,
281 2,
282 0x2,
283 > {
284 unsafe {
285 crate::common::ClusterRegisterArray::from_ptr(self._svd2pac_as_ptr().add(0x18usize))
286 }
287 }
288 #[inline(always)]
289 pub const fn bcnt0aer(
290 &self,
291 ) -> &'static crate::common::Reg<self::Bcntaer_SPEC, crate::common::RW> {
292 unsafe {
293 crate::common::Reg::<self::Bcntaer_SPEC, crate::common::RW>::from_ptr(
294 self._svd2pac_as_ptr().add(0x18usize),
295 )
296 }
297 }
298 #[inline(always)]
299 pub const fn bcnt1aer(
300 &self,
301 ) -> &'static crate::common::Reg<self::Bcntaer_SPEC, crate::common::RW> {
302 unsafe {
303 crate::common::Reg::<self::Bcntaer_SPEC, crate::common::RW>::from_ptr(
304 self._svd2pac_as_ptr().add(0x1ausize),
305 )
306 }
307 }
308
309 #[doc = "Date Alarm Register (in Calendar Count Mode)"]
310 #[inline(always)]
311 pub const fn rdayar(
312 &self,
313 ) -> &'static crate::common::Reg<self::Rdayar_SPEC, crate::common::RW> {
314 unsafe {
315 crate::common::Reg::<self::Rdayar_SPEC, crate::common::RW>::from_ptr(
316 self._svd2pac_as_ptr().add(24usize),
317 )
318 }
319 }
320
321 #[doc = "Month Alarm Register (in Calendar Count Mode)"]
322 #[inline(always)]
323 pub const fn rmonar(
324 &self,
325 ) -> &'static crate::common::Reg<self::Rmonar_SPEC, crate::common::RW> {
326 unsafe {
327 crate::common::Reg::<self::Rmonar_SPEC, crate::common::RW>::from_ptr(
328 self._svd2pac_as_ptr().add(26usize),
329 )
330 }
331 }
332
333 #[doc = "Binary Counter 2 Alarm Enable Register"]
334 #[inline(always)]
335 pub const fn bcnt2aer(
336 &self,
337 ) -> &'static crate::common::Reg<self::Bcnt2Aer_SPEC, crate::common::RW> {
338 unsafe {
339 crate::common::Reg::<self::Bcnt2Aer_SPEC, crate::common::RW>::from_ptr(
340 self._svd2pac_as_ptr().add(28usize),
341 )
342 }
343 }
344
345 #[doc = "Year Alarm Register (in Calendar Count Mode)"]
346 #[inline(always)]
347 pub const fn ryrar(&self) -> &'static crate::common::Reg<self::Ryrar_SPEC, crate::common::RW> {
348 unsafe {
349 crate::common::Reg::<self::Ryrar_SPEC, crate::common::RW>::from_ptr(
350 self._svd2pac_as_ptr().add(28usize),
351 )
352 }
353 }
354
355 #[doc = "Binary Counter 3 Alarm Enable Register"]
356 #[inline(always)]
357 pub const fn bcnt3aer(
358 &self,
359 ) -> &'static crate::common::Reg<self::Bcnt3Aer_SPEC, crate::common::RW> {
360 unsafe {
361 crate::common::Reg::<self::Bcnt3Aer_SPEC, crate::common::RW>::from_ptr(
362 self._svd2pac_as_ptr().add(30usize),
363 )
364 }
365 }
366
367 #[doc = "Year Alarm Enable Register (in Calendar Count Mode)"]
368 #[inline(always)]
369 pub const fn ryraren(
370 &self,
371 ) -> &'static crate::common::Reg<self::Ryraren_SPEC, crate::common::RW> {
372 unsafe {
373 crate::common::Reg::<self::Ryraren_SPEC, crate::common::RW>::from_ptr(
374 self._svd2pac_as_ptr().add(30usize),
375 )
376 }
377 }
378
379 #[doc = "RTC Control Register 1"]
380 #[inline(always)]
381 pub const fn rcr1(&self) -> &'static crate::common::Reg<self::Rcr1_SPEC, crate::common::RW> {
382 unsafe {
383 crate::common::Reg::<self::Rcr1_SPEC, crate::common::RW>::from_ptr(
384 self._svd2pac_as_ptr().add(34usize),
385 )
386 }
387 }
388
389 #[doc = "RTC Control Register 2 (in Calendar Count Mode)"]
390 #[inline(always)]
391 pub const fn rcr2(&self) -> &'static crate::common::Reg<self::Rcr2_SPEC, crate::common::RW> {
392 unsafe {
393 crate::common::Reg::<self::Rcr2_SPEC, crate::common::RW>::from_ptr(
394 self._svd2pac_as_ptr().add(36usize),
395 )
396 }
397 }
398
399 #[doc = "RTC Control Register 2 (in Binary Count Mode)"]
400 #[inline(always)]
401 pub const fn rcr2_bcnt(
402 &self,
403 ) -> &'static crate::common::Reg<self::Rcr2Bcnt_SPEC, crate::common::RW> {
404 unsafe {
405 crate::common::Reg::<self::Rcr2Bcnt_SPEC, crate::common::RW>::from_ptr(
406 self._svd2pac_as_ptr().add(36usize),
407 )
408 }
409 }
410
411 #[doc = "RTC Control Register 4"]
412 #[inline(always)]
413 pub const fn rcr4(&self) -> &'static crate::common::Reg<self::Rcr4_SPEC, crate::common::RW> {
414 unsafe {
415 crate::common::Reg::<self::Rcr4_SPEC, crate::common::RW>::from_ptr(
416 self._svd2pac_as_ptr().add(40usize),
417 )
418 }
419 }
420
421 #[doc = "Frequency Register H"]
422 #[inline(always)]
423 pub const fn rfrh(&self) -> &'static crate::common::Reg<self::Rfrh_SPEC, crate::common::RW> {
424 unsafe {
425 crate::common::Reg::<self::Rfrh_SPEC, crate::common::RW>::from_ptr(
426 self._svd2pac_as_ptr().add(42usize),
427 )
428 }
429 }
430
431 #[doc = "Frequency Register L"]
432 #[inline(always)]
433 pub const fn rfrl(&self) -> &'static crate::common::Reg<self::Rfrl_SPEC, crate::common::RW> {
434 unsafe {
435 crate::common::Reg::<self::Rfrl_SPEC, crate::common::RW>::from_ptr(
436 self._svd2pac_as_ptr().add(44usize),
437 )
438 }
439 }
440
441 #[doc = "Time Error Adjustment Register"]
442 #[inline(always)]
443 pub const fn radj(&self) -> &'static crate::common::Reg<self::Radj_SPEC, crate::common::RW> {
444 unsafe {
445 crate::common::Reg::<self::Radj_SPEC, crate::common::RW>::from_ptr(
446 self._svd2pac_as_ptr().add(46usize),
447 )
448 }
449 }
450
451 #[doc = "Time Capture Control Register 0"]
452 #[inline(always)]
453 pub const fn rtccr0(
454 &self,
455 ) -> &'static crate::common::Reg<self::Rtccr0_SPEC, crate::common::RW> {
456 unsafe {
457 crate::common::Reg::<self::Rtccr0_SPEC, crate::common::RW>::from_ptr(
458 self._svd2pac_as_ptr().add(64usize),
459 )
460 }
461 }
462
463 #[doc = "BCNT0 Capture Register 0"]
464 #[inline(always)]
465 pub const fn bcnt0cp0(
466 &self,
467 ) -> &'static crate::common::Reg<self::Bcnt0Cp0_SPEC, crate::common::R> {
468 unsafe {
469 crate::common::Reg::<self::Bcnt0Cp0_SPEC, crate::common::R>::from_ptr(
470 self._svd2pac_as_ptr().add(82usize),
471 )
472 }
473 }
474
475 #[doc = "Second Capture Register 0"]
476 #[inline(always)]
477 pub const fn rseccp0(
478 &self,
479 ) -> &'static crate::common::Reg<self::Rseccp0_SPEC, crate::common::R> {
480 unsafe {
481 crate::common::Reg::<self::Rseccp0_SPEC, crate::common::R>::from_ptr(
482 self._svd2pac_as_ptr().add(82usize),
483 )
484 }
485 }
486
487 #[doc = "BCNT1 Capture Register 0"]
488 #[inline(always)]
489 pub const fn bcnt1cp0(
490 &self,
491 ) -> &'static crate::common::Reg<self::Bcnt1Cp0_SPEC, crate::common::R> {
492 unsafe {
493 crate::common::Reg::<self::Bcnt1Cp0_SPEC, crate::common::R>::from_ptr(
494 self._svd2pac_as_ptr().add(84usize),
495 )
496 }
497 }
498
499 #[doc = "Minute Capture Register 0"]
500 #[inline(always)]
501 pub const fn rmincp0(
502 &self,
503 ) -> &'static crate::common::Reg<self::Rmincp0_SPEC, crate::common::R> {
504 unsafe {
505 crate::common::Reg::<self::Rmincp0_SPEC, crate::common::R>::from_ptr(
506 self._svd2pac_as_ptr().add(84usize),
507 )
508 }
509 }
510
511 #[doc = "BCNT2 Capture Register 0"]
512 #[inline(always)]
513 pub const fn bcnt2cp0(
514 &self,
515 ) -> &'static crate::common::Reg<self::Bcnt2Cp0_SPEC, crate::common::R> {
516 unsafe {
517 crate::common::Reg::<self::Bcnt2Cp0_SPEC, crate::common::R>::from_ptr(
518 self._svd2pac_as_ptr().add(86usize),
519 )
520 }
521 }
522
523 #[doc = "Hour Capture Register 0"]
524 #[inline(always)]
525 pub const fn rhrcp0(&self) -> &'static crate::common::Reg<self::Rhrcp0_SPEC, crate::common::R> {
526 unsafe {
527 crate::common::Reg::<self::Rhrcp0_SPEC, crate::common::R>::from_ptr(
528 self._svd2pac_as_ptr().add(86usize),
529 )
530 }
531 }
532
533 #[doc = "BCNT3 Capture Register 0"]
534 #[inline(always)]
535 pub const fn bcnt3cp0(
536 &self,
537 ) -> &'static crate::common::Reg<self::Bcnt3Cp0_SPEC, crate::common::R> {
538 unsafe {
539 crate::common::Reg::<self::Bcnt3Cp0_SPEC, crate::common::R>::from_ptr(
540 self._svd2pac_as_ptr().add(90usize),
541 )
542 }
543 }
544
545 #[doc = "Date Capture Register 0"]
546 #[inline(always)]
547 pub const fn rdaycp0(
548 &self,
549 ) -> &'static crate::common::Reg<self::Rdaycp0_SPEC, crate::common::R> {
550 unsafe {
551 crate::common::Reg::<self::Rdaycp0_SPEC, crate::common::R>::from_ptr(
552 self._svd2pac_as_ptr().add(90usize),
553 )
554 }
555 }
556
557 #[doc = "Month Capture Register 0"]
558 #[inline(always)]
559 pub const fn rmoncp0(
560 &self,
561 ) -> &'static crate::common::Reg<self::Rmoncp0_SPEC, crate::common::R> {
562 unsafe {
563 crate::common::Reg::<self::Rmoncp0_SPEC, crate::common::R>::from_ptr(
564 self._svd2pac_as_ptr().add(92usize),
565 )
566 }
567 }
568}
569#[doc(hidden)]
570#[derive(Copy, Clone, Eq, PartialEq)]
571pub struct R64Cnt_SPEC;
572impl crate::sealed::RegSpec for R64Cnt_SPEC {
573 type DataType = u8;
574}
575
576#[doc = "64-Hz Counter"]
577pub type R64Cnt = crate::RegValueT<R64Cnt_SPEC>;
578
579impl R64Cnt {
580 #[doc = "64-Hz Flag"]
581 #[inline(always)]
582 pub fn f64hz(self) -> crate::common::RegisterFieldBool<0, 1, 0, R64Cnt_SPEC, crate::common::R> {
583 crate::common::RegisterFieldBool::<0, 1, 0, R64Cnt_SPEC, crate::common::R>::from_register(
584 self, 0,
585 )
586 }
587
588 #[doc = "32-Hz Flag"]
589 #[inline(always)]
590 pub fn f32hz(self) -> crate::common::RegisterFieldBool<1, 1, 0, R64Cnt_SPEC, crate::common::R> {
591 crate::common::RegisterFieldBool::<1, 1, 0, R64Cnt_SPEC, crate::common::R>::from_register(
592 self, 0,
593 )
594 }
595
596 #[doc = "16-Hz Flag"]
597 #[inline(always)]
598 pub fn f16hz(self) -> crate::common::RegisterFieldBool<2, 1, 0, R64Cnt_SPEC, crate::common::R> {
599 crate::common::RegisterFieldBool::<2, 1, 0, R64Cnt_SPEC, crate::common::R>::from_register(
600 self, 0,
601 )
602 }
603
604 #[doc = "8-Hz Flag"]
605 #[inline(always)]
606 pub fn f8hz(self) -> crate::common::RegisterFieldBool<3, 1, 0, R64Cnt_SPEC, crate::common::R> {
607 crate::common::RegisterFieldBool::<3, 1, 0, R64Cnt_SPEC, crate::common::R>::from_register(
608 self, 0,
609 )
610 }
611
612 #[doc = "4-Hz Flag"]
613 #[inline(always)]
614 pub fn f4hz(self) -> crate::common::RegisterFieldBool<4, 1, 0, R64Cnt_SPEC, crate::common::R> {
615 crate::common::RegisterFieldBool::<4, 1, 0, R64Cnt_SPEC, crate::common::R>::from_register(
616 self, 0,
617 )
618 }
619
620 #[doc = "2-Hz Flag"]
621 #[inline(always)]
622 pub fn f2hz(self) -> crate::common::RegisterFieldBool<5, 1, 0, R64Cnt_SPEC, crate::common::R> {
623 crate::common::RegisterFieldBool::<5, 1, 0, R64Cnt_SPEC, crate::common::R>::from_register(
624 self, 0,
625 )
626 }
627
628 #[doc = "1-Hz Flag"]
629 #[inline(always)]
630 pub fn f1hz(self) -> crate::common::RegisterFieldBool<6, 1, 0, R64Cnt_SPEC, crate::common::R> {
631 crate::common::RegisterFieldBool::<6, 1, 0, R64Cnt_SPEC, crate::common::R>::from_register(
632 self, 0,
633 )
634 }
635}
636impl ::core::default::Default for R64Cnt {
637 #[inline(always)]
638 fn default() -> R64Cnt {
639 <crate::RegValueT<R64Cnt_SPEC> as RegisterValue<_>>::new(0)
640 }
641}
642
643#[doc(hidden)]
644#[derive(Copy, Clone, Eq, PartialEq)]
645pub struct Bcnt_SPEC;
646impl crate::sealed::RegSpec for Bcnt_SPEC {
647 type DataType = u8;
648}
649
650#[doc = "Binary Counter %s"]
651pub type Bcnt = crate::RegValueT<Bcnt_SPEC>;
652
653impl Bcnt {
654 #[doc = "Binary Counter"]
655 #[inline(always)]
656 pub fn bcnt(
657 self,
658 ) -> crate::common::RegisterField<0, 0xff, 1, 0, u8, u8, Bcnt_SPEC, crate::common::RW> {
659 crate::common::RegisterField::<0,0xff,1,0,u8,u8,Bcnt_SPEC,crate::common::RW>::from_register(self,0)
660 }
661}
662impl ::core::default::Default for Bcnt {
663 #[inline(always)]
664 fn default() -> Bcnt {
665 <crate::RegValueT<Bcnt_SPEC> as RegisterValue<_>>::new(0)
666 }
667}
668
669#[doc(hidden)]
670#[derive(Copy, Clone, Eq, PartialEq)]
671pub struct Rseccnt_SPEC;
672impl crate::sealed::RegSpec for Rseccnt_SPEC {
673 type DataType = u8;
674}
675
676#[doc = "Second Counter (in Calendar Count Mode)"]
677pub type Rseccnt = crate::RegValueT<Rseccnt_SPEC>;
678
679impl Rseccnt {
680 #[doc = "1-Second Count"]
681 #[inline(always)]
682 pub fn sec1(
683 self,
684 ) -> crate::common::RegisterField<0, 0xf, 1, 0, u8, u8, Rseccnt_SPEC, crate::common::RW> {
685 crate::common::RegisterField::<0,0xf,1,0,u8,u8,Rseccnt_SPEC,crate::common::RW>::from_register(self,0)
686 }
687
688 #[doc = "10-Second Count"]
689 #[inline(always)]
690 pub fn sec10(
691 self,
692 ) -> crate::common::RegisterField<4, 0x7, 1, 0, u8, u8, Rseccnt_SPEC, crate::common::RW> {
693 crate::common::RegisterField::<4,0x7,1,0,u8,u8,Rseccnt_SPEC,crate::common::RW>::from_register(self,0)
694 }
695}
696impl ::core::default::Default for Rseccnt {
697 #[inline(always)]
698 fn default() -> Rseccnt {
699 <crate::RegValueT<Rseccnt_SPEC> as RegisterValue<_>>::new(0)
700 }
701}
702
703#[doc(hidden)]
704#[derive(Copy, Clone, Eq, PartialEq)]
705pub struct Rmincnt_SPEC;
706impl crate::sealed::RegSpec for Rmincnt_SPEC {
707 type DataType = u8;
708}
709
710#[doc = "Minute Counter (in Calendar Count Mode)"]
711pub type Rmincnt = crate::RegValueT<Rmincnt_SPEC>;
712
713impl Rmincnt {
714 #[doc = "1-Minute Count"]
715 #[inline(always)]
716 pub fn min1(
717 self,
718 ) -> crate::common::RegisterField<0, 0xf, 1, 0, u8, u8, Rmincnt_SPEC, crate::common::RW> {
719 crate::common::RegisterField::<0,0xf,1,0,u8,u8,Rmincnt_SPEC,crate::common::RW>::from_register(self,0)
720 }
721
722 #[doc = "10-Minute Count"]
723 #[inline(always)]
724 pub fn min10(
725 self,
726 ) -> crate::common::RegisterField<4, 0x7, 1, 0, u8, u8, Rmincnt_SPEC, crate::common::RW> {
727 crate::common::RegisterField::<4,0x7,1,0,u8,u8,Rmincnt_SPEC,crate::common::RW>::from_register(self,0)
728 }
729}
730impl ::core::default::Default for Rmincnt {
731 #[inline(always)]
732 fn default() -> Rmincnt {
733 <crate::RegValueT<Rmincnt_SPEC> as RegisterValue<_>>::new(0)
734 }
735}
736
737#[doc(hidden)]
738#[derive(Copy, Clone, Eq, PartialEq)]
739pub struct Rhrcnt_SPEC;
740impl crate::sealed::RegSpec for Rhrcnt_SPEC {
741 type DataType = u8;
742}
743
744#[doc = "Hour Counter (in Calendar Count Mode)"]
745pub type Rhrcnt = crate::RegValueT<Rhrcnt_SPEC>;
746
747impl Rhrcnt {
748 #[doc = "1-Hour Count"]
749 #[inline(always)]
750 pub fn hr1(
751 self,
752 ) -> crate::common::RegisterField<0, 0xf, 1, 0, u8, u8, Rhrcnt_SPEC, crate::common::RW> {
753 crate::common::RegisterField::<0,0xf,1,0,u8,u8,Rhrcnt_SPEC,crate::common::RW>::from_register(self,0)
754 }
755
756 #[doc = "10-Hour Count"]
757 #[inline(always)]
758 pub fn hr10(
759 self,
760 ) -> crate::common::RegisterField<4, 0x3, 1, 0, u8, u8, Rhrcnt_SPEC, crate::common::RW> {
761 crate::common::RegisterField::<4,0x3,1,0,u8,u8,Rhrcnt_SPEC,crate::common::RW>::from_register(self,0)
762 }
763
764 #[doc = "AM/PM select for time counter setting."]
765 #[inline(always)]
766 pub fn pm(
767 self,
768 ) -> crate::common::RegisterField<
769 6,
770 0x1,
771 1,
772 0,
773 rhrcnt::Pm,
774 rhrcnt::Pm,
775 Rhrcnt_SPEC,
776 crate::common::RW,
777 > {
778 crate::common::RegisterField::<
779 6,
780 0x1,
781 1,
782 0,
783 rhrcnt::Pm,
784 rhrcnt::Pm,
785 Rhrcnt_SPEC,
786 crate::common::RW,
787 >::from_register(self, 0)
788 }
789}
790impl ::core::default::Default for Rhrcnt {
791 #[inline(always)]
792 fn default() -> Rhrcnt {
793 <crate::RegValueT<Rhrcnt_SPEC> as RegisterValue<_>>::new(0)
794 }
795}
796pub mod rhrcnt {
797
798 #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
799 pub struct Pm_SPEC;
800 pub type Pm = crate::EnumBitfieldStruct<u8, Pm_SPEC>;
801 impl Pm {
802 #[doc = "AM"]
803 pub const _0: Self = Self::new(0);
804
805 #[doc = "PM"]
806 pub const _1: Self = Self::new(1);
807 }
808}
809#[doc(hidden)]
810#[derive(Copy, Clone, Eq, PartialEq)]
811pub struct Rwkcnt_SPEC;
812impl crate::sealed::RegSpec for Rwkcnt_SPEC {
813 type DataType = u8;
814}
815
816#[doc = "Day-of-Week Counter (in Calendar Count Mode)"]
817pub type Rwkcnt = crate::RegValueT<Rwkcnt_SPEC>;
818
819impl Rwkcnt {
820 #[doc = "Day-of-Week Counting"]
821 #[inline(always)]
822 pub fn dayw(
823 self,
824 ) -> crate::common::RegisterField<
825 0,
826 0x7,
827 1,
828 0,
829 rwkcnt::Dayw,
830 rwkcnt::Dayw,
831 Rwkcnt_SPEC,
832 crate::common::RW,
833 > {
834 crate::common::RegisterField::<
835 0,
836 0x7,
837 1,
838 0,
839 rwkcnt::Dayw,
840 rwkcnt::Dayw,
841 Rwkcnt_SPEC,
842 crate::common::RW,
843 >::from_register(self, 0)
844 }
845}
846impl ::core::default::Default for Rwkcnt {
847 #[inline(always)]
848 fn default() -> Rwkcnt {
849 <crate::RegValueT<Rwkcnt_SPEC> as RegisterValue<_>>::new(0)
850 }
851}
852pub mod rwkcnt {
853
854 #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
855 pub struct Dayw_SPEC;
856 pub type Dayw = crate::EnumBitfieldStruct<u8, Dayw_SPEC>;
857 impl Dayw {
858 #[doc = "Sunday"]
859 pub const _000: Self = Self::new(0);
860
861 #[doc = "Monday"]
862 pub const _001: Self = Self::new(1);
863
864 #[doc = "Tuesday"]
865 pub const _010: Self = Self::new(2);
866
867 #[doc = "Wednesday"]
868 pub const _011: Self = Self::new(3);
869
870 #[doc = "Thursday"]
871 pub const _100: Self = Self::new(4);
872
873 #[doc = "Friday"]
874 pub const _101: Self = Self::new(5);
875
876 #[doc = "Saturday"]
877 pub const _110: Self = Self::new(6);
878
879 #[doc = "Setting prohibited"]
880 pub const _111: Self = Self::new(7);
881 }
882}
883#[doc(hidden)]
884#[derive(Copy, Clone, Eq, PartialEq)]
885pub struct Rdaycnt_SPEC;
886impl crate::sealed::RegSpec for Rdaycnt_SPEC {
887 type DataType = u8;
888}
889
890#[doc = "Day Counter"]
891pub type Rdaycnt = crate::RegValueT<Rdaycnt_SPEC>;
892
893impl Rdaycnt {
894 #[doc = "1-Day Count"]
895 #[inline(always)]
896 pub fn date1(
897 self,
898 ) -> crate::common::RegisterField<0, 0xf, 1, 0, u8, u8, Rdaycnt_SPEC, crate::common::RW> {
899 crate::common::RegisterField::<0,0xf,1,0,u8,u8,Rdaycnt_SPEC,crate::common::RW>::from_register(self,0)
900 }
901
902 #[doc = "10-Day Count"]
903 #[inline(always)]
904 pub fn date10(
905 self,
906 ) -> crate::common::RegisterField<4, 0x3, 1, 0, u8, u8, Rdaycnt_SPEC, crate::common::RW> {
907 crate::common::RegisterField::<4,0x3,1,0,u8,u8,Rdaycnt_SPEC,crate::common::RW>::from_register(self,0)
908 }
909}
910impl ::core::default::Default for Rdaycnt {
911 #[inline(always)]
912 fn default() -> Rdaycnt {
913 <crate::RegValueT<Rdaycnt_SPEC> as RegisterValue<_>>::new(0)
914 }
915}
916
917#[doc(hidden)]
918#[derive(Copy, Clone, Eq, PartialEq)]
919pub struct Rmoncnt_SPEC;
920impl crate::sealed::RegSpec for Rmoncnt_SPEC {
921 type DataType = u8;
922}
923
924#[doc = "Month Counter"]
925pub type Rmoncnt = crate::RegValueT<Rmoncnt_SPEC>;
926
927impl Rmoncnt {
928 #[doc = "1-Month Count"]
929 #[inline(always)]
930 pub fn mon1(
931 self,
932 ) -> crate::common::RegisterField<0, 0xf, 1, 0, u8, u8, Rmoncnt_SPEC, crate::common::RW> {
933 crate::common::RegisterField::<0,0xf,1,0,u8,u8,Rmoncnt_SPEC,crate::common::RW>::from_register(self,0)
934 }
935
936 #[doc = "10-Month Count"]
937 #[inline(always)]
938 pub fn mon10(
939 self,
940 ) -> crate::common::RegisterFieldBool<4, 1, 0, Rmoncnt_SPEC, crate::common::RW> {
941 crate::common::RegisterFieldBool::<4, 1, 0, Rmoncnt_SPEC, crate::common::RW>::from_register(
942 self, 0,
943 )
944 }
945}
946impl ::core::default::Default for Rmoncnt {
947 #[inline(always)]
948 fn default() -> Rmoncnt {
949 <crate::RegValueT<Rmoncnt_SPEC> as RegisterValue<_>>::new(0)
950 }
951}
952
953#[doc(hidden)]
954#[derive(Copy, Clone, Eq, PartialEq)]
955pub struct Ryrcnt_SPEC;
956impl crate::sealed::RegSpec for Ryrcnt_SPEC {
957 type DataType = u16;
958}
959
960#[doc = "Year Counter"]
961pub type Ryrcnt = crate::RegValueT<Ryrcnt_SPEC>;
962
963impl Ryrcnt {
964 #[doc = "1-Year Count"]
965 #[inline(always)]
966 pub fn yr1(
967 self,
968 ) -> crate::common::RegisterField<0, 0xf, 1, 0, u8, u8, Ryrcnt_SPEC, crate::common::RW> {
969 crate::common::RegisterField::<0,0xf,1,0,u8,u8,Ryrcnt_SPEC,crate::common::RW>::from_register(self,0)
970 }
971
972 #[doc = "10-Year Count"]
973 #[inline(always)]
974 pub fn yr10(
975 self,
976 ) -> crate::common::RegisterField<4, 0xf, 1, 0, u8, u8, Ryrcnt_SPEC, crate::common::RW> {
977 crate::common::RegisterField::<4,0xf,1,0,u8,u8,Ryrcnt_SPEC,crate::common::RW>::from_register(self,0)
978 }
979}
980impl ::core::default::Default for Ryrcnt {
981 #[inline(always)]
982 fn default() -> Ryrcnt {
983 <crate::RegValueT<Ryrcnt_SPEC> as RegisterValue<_>>::new(0)
984 }
985}
986
987#[doc(hidden)]
988#[derive(Copy, Clone, Eq, PartialEq)]
989pub struct Bcntar_SPEC;
990impl crate::sealed::RegSpec for Bcntar_SPEC {
991 type DataType = u8;
992}
993
994#[doc = "Binary Counter %s Alarm Register"]
995pub type Bcntar = crate::RegValueT<Bcntar_SPEC>;
996
997impl Bcntar {
998 #[doc = "Alarm register associated with the 32-bit binary counter"]
999 #[inline(always)]
1000 pub fn bcntar(
1001 self,
1002 ) -> crate::common::RegisterField<0, 0xff, 1, 0, u8, u8, Bcntar_SPEC, crate::common::RW> {
1003 crate::common::RegisterField::<0,0xff,1,0,u8,u8,Bcntar_SPEC,crate::common::RW>::from_register(self,0)
1004 }
1005}
1006impl ::core::default::Default for Bcntar {
1007 #[inline(always)]
1008 fn default() -> Bcntar {
1009 <crate::RegValueT<Bcntar_SPEC> as RegisterValue<_>>::new(0)
1010 }
1011}
1012
1013#[doc(hidden)]
1014#[derive(Copy, Clone, Eq, PartialEq)]
1015pub struct Rsecar_SPEC;
1016impl crate::sealed::RegSpec for Rsecar_SPEC {
1017 type DataType = u8;
1018}
1019
1020#[doc = "Second Alarm Register (in Calendar Count Mode)"]
1021pub type Rsecar = crate::RegValueT<Rsecar_SPEC>;
1022
1023impl Rsecar {
1024 #[doc = "1 Second"]
1025 #[inline(always)]
1026 pub fn sec1(
1027 self,
1028 ) -> crate::common::RegisterField<0, 0xf, 1, 0, u8, u8, Rsecar_SPEC, crate::common::RW> {
1029 crate::common::RegisterField::<0,0xf,1,0,u8,u8,Rsecar_SPEC,crate::common::RW>::from_register(self,0)
1030 }
1031
1032 #[doc = "10 Seconds"]
1033 #[inline(always)]
1034 pub fn sec10(
1035 self,
1036 ) -> crate::common::RegisterField<4, 0x7, 1, 0, u8, u8, Rsecar_SPEC, crate::common::RW> {
1037 crate::common::RegisterField::<4,0x7,1,0,u8,u8,Rsecar_SPEC,crate::common::RW>::from_register(self,0)
1038 }
1039
1040 #[doc = "ENB"]
1041 #[inline(always)]
1042 pub fn enb(
1043 self,
1044 ) -> crate::common::RegisterField<
1045 7,
1046 0x1,
1047 1,
1048 0,
1049 rsecar::Enb,
1050 rsecar::Enb,
1051 Rsecar_SPEC,
1052 crate::common::RW,
1053 > {
1054 crate::common::RegisterField::<
1055 7,
1056 0x1,
1057 1,
1058 0,
1059 rsecar::Enb,
1060 rsecar::Enb,
1061 Rsecar_SPEC,
1062 crate::common::RW,
1063 >::from_register(self, 0)
1064 }
1065}
1066impl ::core::default::Default for Rsecar {
1067 #[inline(always)]
1068 fn default() -> Rsecar {
1069 <crate::RegValueT<Rsecar_SPEC> as RegisterValue<_>>::new(0)
1070 }
1071}
1072pub mod rsecar {
1073
1074 #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
1075 pub struct Enb_SPEC;
1076 pub type Enb = crate::EnumBitfieldStruct<u8, Enb_SPEC>;
1077 impl Enb {
1078 #[doc = "Do not compare register value with RSECCNT counter value"]
1079 pub const _0: Self = Self::new(0);
1080
1081 #[doc = "Compare register value with RSECCNT counter value"]
1082 pub const _1: Self = Self::new(1);
1083 }
1084}
1085#[doc(hidden)]
1086#[derive(Copy, Clone, Eq, PartialEq)]
1087pub struct Rminar_SPEC;
1088impl crate::sealed::RegSpec for Rminar_SPEC {
1089 type DataType = u8;
1090}
1091
1092#[doc = "Minute Alarm Register (in Calendar Count Mode)"]
1093pub type Rminar = crate::RegValueT<Rminar_SPEC>;
1094
1095impl Rminar {
1096 #[doc = "1 Minute"]
1097 #[inline(always)]
1098 pub fn min1(
1099 self,
1100 ) -> crate::common::RegisterField<0, 0xf, 1, 0, u8, u8, Rminar_SPEC, crate::common::RW> {
1101 crate::common::RegisterField::<0,0xf,1,0,u8,u8,Rminar_SPEC,crate::common::RW>::from_register(self,0)
1102 }
1103
1104 #[doc = "10 Minutes"]
1105 #[inline(always)]
1106 pub fn min10(
1107 self,
1108 ) -> crate::common::RegisterField<4, 0x7, 1, 0, u8, u8, Rminar_SPEC, crate::common::RW> {
1109 crate::common::RegisterField::<4,0x7,1,0,u8,u8,Rminar_SPEC,crate::common::RW>::from_register(self,0)
1110 }
1111
1112 #[doc = "ENB"]
1113 #[inline(always)]
1114 pub fn enb(
1115 self,
1116 ) -> crate::common::RegisterField<
1117 7,
1118 0x1,
1119 1,
1120 0,
1121 rminar::Enb,
1122 rminar::Enb,
1123 Rminar_SPEC,
1124 crate::common::RW,
1125 > {
1126 crate::common::RegisterField::<
1127 7,
1128 0x1,
1129 1,
1130 0,
1131 rminar::Enb,
1132 rminar::Enb,
1133 Rminar_SPEC,
1134 crate::common::RW,
1135 >::from_register(self, 0)
1136 }
1137}
1138impl ::core::default::Default for Rminar {
1139 #[inline(always)]
1140 fn default() -> Rminar {
1141 <crate::RegValueT<Rminar_SPEC> as RegisterValue<_>>::new(0)
1142 }
1143}
1144pub mod rminar {
1145
1146 #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
1147 pub struct Enb_SPEC;
1148 pub type Enb = crate::EnumBitfieldStruct<u8, Enb_SPEC>;
1149 impl Enb {
1150 #[doc = "Do not compare register value with RMINCNT counter value"]
1151 pub const _0: Self = Self::new(0);
1152
1153 #[doc = "Compare register value with RMINCNT counter value"]
1154 pub const _1: Self = Self::new(1);
1155 }
1156}
1157#[doc(hidden)]
1158#[derive(Copy, Clone, Eq, PartialEq)]
1159pub struct Rhrar_SPEC;
1160impl crate::sealed::RegSpec for Rhrar_SPEC {
1161 type DataType = u8;
1162}
1163
1164#[doc = "Hour Alarm Register (in Calendar Count Mode)"]
1165pub type Rhrar = crate::RegValueT<Rhrar_SPEC>;
1166
1167impl Rhrar {
1168 #[doc = "1 Hour"]
1169 #[inline(always)]
1170 pub fn hr1(
1171 self,
1172 ) -> crate::common::RegisterField<0, 0xf, 1, 0, u8, u8, Rhrar_SPEC, crate::common::RW> {
1173 crate::common::RegisterField::<0,0xf,1,0,u8,u8,Rhrar_SPEC,crate::common::RW>::from_register(self,0)
1174 }
1175
1176 #[doc = "10 Hours"]
1177 #[inline(always)]
1178 pub fn hr10(
1179 self,
1180 ) -> crate::common::RegisterField<4, 0x3, 1, 0, u8, u8, Rhrar_SPEC, crate::common::RW> {
1181 crate::common::RegisterField::<4,0x3,1,0,u8,u8,Rhrar_SPEC,crate::common::RW>::from_register(self,0)
1182 }
1183
1184 #[doc = "AM/PM select for alarm setting."]
1185 #[inline(always)]
1186 pub fn pm(
1187 self,
1188 ) -> crate::common::RegisterField<
1189 6,
1190 0x1,
1191 1,
1192 0,
1193 rhrar::Pm,
1194 rhrar::Pm,
1195 Rhrar_SPEC,
1196 crate::common::RW,
1197 > {
1198 crate::common::RegisterField::<
1199 6,
1200 0x1,
1201 1,
1202 0,
1203 rhrar::Pm,
1204 rhrar::Pm,
1205 Rhrar_SPEC,
1206 crate::common::RW,
1207 >::from_register(self, 0)
1208 }
1209
1210 #[doc = "ENB"]
1211 #[inline(always)]
1212 pub fn enb(
1213 self,
1214 ) -> crate::common::RegisterField<
1215 7,
1216 0x1,
1217 1,
1218 0,
1219 rhrar::Enb,
1220 rhrar::Enb,
1221 Rhrar_SPEC,
1222 crate::common::RW,
1223 > {
1224 crate::common::RegisterField::<
1225 7,
1226 0x1,
1227 1,
1228 0,
1229 rhrar::Enb,
1230 rhrar::Enb,
1231 Rhrar_SPEC,
1232 crate::common::RW,
1233 >::from_register(self, 0)
1234 }
1235}
1236impl ::core::default::Default for Rhrar {
1237 #[inline(always)]
1238 fn default() -> Rhrar {
1239 <crate::RegValueT<Rhrar_SPEC> as RegisterValue<_>>::new(0)
1240 }
1241}
1242pub mod rhrar {
1243
1244 #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
1245 pub struct Pm_SPEC;
1246 pub type Pm = crate::EnumBitfieldStruct<u8, Pm_SPEC>;
1247 impl Pm {
1248 #[doc = "AM"]
1249 pub const _0: Self = Self::new(0);
1250
1251 #[doc = "PM"]
1252 pub const _1: Self = Self::new(1);
1253 }
1254 #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
1255 pub struct Enb_SPEC;
1256 pub type Enb = crate::EnumBitfieldStruct<u8, Enb_SPEC>;
1257 impl Enb {
1258 #[doc = "Do not compare register value with RHRCNT counter value"]
1259 pub const _0: Self = Self::new(0);
1260
1261 #[doc = "Compare register value with RHRCNT counter value"]
1262 pub const _1: Self = Self::new(1);
1263 }
1264}
1265#[doc(hidden)]
1266#[derive(Copy, Clone, Eq, PartialEq)]
1267pub struct Rwkar_SPEC;
1268impl crate::sealed::RegSpec for Rwkar_SPEC {
1269 type DataType = u8;
1270}
1271
1272#[doc = "Day-of-Week Alarm Register (in Calendar Count Mode)"]
1273pub type Rwkar = crate::RegValueT<Rwkar_SPEC>;
1274
1275impl Rwkar {
1276 #[doc = "Day-of-Week Setting"]
1277 #[inline(always)]
1278 pub fn dayw(
1279 self,
1280 ) -> crate::common::RegisterField<
1281 0,
1282 0x7,
1283 1,
1284 0,
1285 rwkar::Dayw,
1286 rwkar::Dayw,
1287 Rwkar_SPEC,
1288 crate::common::RW,
1289 > {
1290 crate::common::RegisterField::<
1291 0,
1292 0x7,
1293 1,
1294 0,
1295 rwkar::Dayw,
1296 rwkar::Dayw,
1297 Rwkar_SPEC,
1298 crate::common::RW,
1299 >::from_register(self, 0)
1300 }
1301
1302 #[doc = "ENB"]
1303 #[inline(always)]
1304 pub fn enb(
1305 self,
1306 ) -> crate::common::RegisterField<
1307 7,
1308 0x1,
1309 1,
1310 0,
1311 rwkar::Enb,
1312 rwkar::Enb,
1313 Rwkar_SPEC,
1314 crate::common::RW,
1315 > {
1316 crate::common::RegisterField::<
1317 7,
1318 0x1,
1319 1,
1320 0,
1321 rwkar::Enb,
1322 rwkar::Enb,
1323 Rwkar_SPEC,
1324 crate::common::RW,
1325 >::from_register(self, 0)
1326 }
1327}
1328impl ::core::default::Default for Rwkar {
1329 #[inline(always)]
1330 fn default() -> Rwkar {
1331 <crate::RegValueT<Rwkar_SPEC> as RegisterValue<_>>::new(0)
1332 }
1333}
1334pub mod rwkar {
1335
1336 #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
1337 pub struct Dayw_SPEC;
1338 pub type Dayw = crate::EnumBitfieldStruct<u8, Dayw_SPEC>;
1339 impl Dayw {
1340 #[doc = "Sunday"]
1341 pub const _000: Self = Self::new(0);
1342
1343 #[doc = "Monday"]
1344 pub const _001: Self = Self::new(1);
1345
1346 #[doc = "Tuesday"]
1347 pub const _010: Self = Self::new(2);
1348
1349 #[doc = "Wednesday"]
1350 pub const _011: Self = Self::new(3);
1351
1352 #[doc = "Thursday"]
1353 pub const _100: Self = Self::new(4);
1354
1355 #[doc = "Friday"]
1356 pub const _101: Self = Self::new(5);
1357
1358 #[doc = "Saturday"]
1359 pub const _110: Self = Self::new(6);
1360
1361 #[doc = "Setting prohibited"]
1362 pub const _111: Self = Self::new(7);
1363 }
1364 #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
1365 pub struct Enb_SPEC;
1366 pub type Enb = crate::EnumBitfieldStruct<u8, Enb_SPEC>;
1367 impl Enb {
1368 #[doc = "Do not compare register value with RWKCNT counter value"]
1369 pub const _0: Self = Self::new(0);
1370
1371 #[doc = "Compare register value with RWKCNT counter value"]
1372 pub const _1: Self = Self::new(1);
1373 }
1374}
1375#[doc(hidden)]
1376#[derive(Copy, Clone, Eq, PartialEq)]
1377pub struct Bcntaer_SPEC;
1378impl crate::sealed::RegSpec for Bcntaer_SPEC {
1379 type DataType = u8;
1380}
1381
1382#[doc = "Binary Counter %s Alarm Enable Register"]
1383pub type Bcntaer = crate::RegValueT<Bcntaer_SPEC>;
1384
1385impl Bcntaer {
1386 #[doc = "Setting the alarm enable associated with the 32-bit binary counter"]
1387 #[inline(always)]
1388 pub fn enb(
1389 self,
1390 ) -> crate::common::RegisterField<0, 0xff, 1, 0, u8, u8, Bcntaer_SPEC, crate::common::RW> {
1391 crate::common::RegisterField::<0,0xff,1,0,u8,u8,Bcntaer_SPEC,crate::common::RW>::from_register(self,0)
1392 }
1393}
1394impl ::core::default::Default for Bcntaer {
1395 #[inline(always)]
1396 fn default() -> Bcntaer {
1397 <crate::RegValueT<Bcntaer_SPEC> as RegisterValue<_>>::new(0)
1398 }
1399}
1400
1401#[doc(hidden)]
1402#[derive(Copy, Clone, Eq, PartialEq)]
1403pub struct Rdayar_SPEC;
1404impl crate::sealed::RegSpec for Rdayar_SPEC {
1405 type DataType = u8;
1406}
1407
1408#[doc = "Date Alarm Register (in Calendar Count Mode)"]
1409pub type Rdayar = crate::RegValueT<Rdayar_SPEC>;
1410
1411impl Rdayar {
1412 #[doc = "1 Day"]
1413 #[inline(always)]
1414 pub fn date1(
1415 self,
1416 ) -> crate::common::RegisterField<0, 0xf, 1, 0, u8, u8, Rdayar_SPEC, crate::common::RW> {
1417 crate::common::RegisterField::<0,0xf,1,0,u8,u8,Rdayar_SPEC,crate::common::RW>::from_register(self,0)
1418 }
1419
1420 #[doc = "10 Days"]
1421 #[inline(always)]
1422 pub fn date10(
1423 self,
1424 ) -> crate::common::RegisterField<4, 0x3, 1, 0, u8, u8, Rdayar_SPEC, crate::common::RW> {
1425 crate::common::RegisterField::<4,0x3,1,0,u8,u8,Rdayar_SPEC,crate::common::RW>::from_register(self,0)
1426 }
1427
1428 #[doc = "ENB"]
1429 #[inline(always)]
1430 pub fn enb(
1431 self,
1432 ) -> crate::common::RegisterField<
1433 7,
1434 0x1,
1435 1,
1436 0,
1437 rdayar::Enb,
1438 rdayar::Enb,
1439 Rdayar_SPEC,
1440 crate::common::RW,
1441 > {
1442 crate::common::RegisterField::<
1443 7,
1444 0x1,
1445 1,
1446 0,
1447 rdayar::Enb,
1448 rdayar::Enb,
1449 Rdayar_SPEC,
1450 crate::common::RW,
1451 >::from_register(self, 0)
1452 }
1453}
1454impl ::core::default::Default for Rdayar {
1455 #[inline(always)]
1456 fn default() -> Rdayar {
1457 <crate::RegValueT<Rdayar_SPEC> as RegisterValue<_>>::new(0)
1458 }
1459}
1460pub mod rdayar {
1461
1462 #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
1463 pub struct Enb_SPEC;
1464 pub type Enb = crate::EnumBitfieldStruct<u8, Enb_SPEC>;
1465 impl Enb {
1466 #[doc = "Do not compare register value with RDAYCNT counter value"]
1467 pub const _0: Self = Self::new(0);
1468
1469 #[doc = "Compare register value with RDAYCNT counter value"]
1470 pub const _1: Self = Self::new(1);
1471 }
1472}
1473#[doc(hidden)]
1474#[derive(Copy, Clone, Eq, PartialEq)]
1475pub struct Rmonar_SPEC;
1476impl crate::sealed::RegSpec for Rmonar_SPEC {
1477 type DataType = u8;
1478}
1479
1480#[doc = "Month Alarm Register (in Calendar Count Mode)"]
1481pub type Rmonar = crate::RegValueT<Rmonar_SPEC>;
1482
1483impl Rmonar {
1484 #[doc = "1 Month"]
1485 #[inline(always)]
1486 pub fn mon1(
1487 self,
1488 ) -> crate::common::RegisterField<0, 0xf, 1, 0, u8, u8, Rmonar_SPEC, crate::common::RW> {
1489 crate::common::RegisterField::<0,0xf,1,0,u8,u8,Rmonar_SPEC,crate::common::RW>::from_register(self,0)
1490 }
1491
1492 #[doc = "10 Months"]
1493 #[inline(always)]
1494 pub fn mon10(
1495 self,
1496 ) -> crate::common::RegisterFieldBool<4, 1, 0, Rmonar_SPEC, crate::common::RW> {
1497 crate::common::RegisterFieldBool::<4, 1, 0, Rmonar_SPEC, crate::common::RW>::from_register(
1498 self, 0,
1499 )
1500 }
1501
1502 #[doc = "ENB"]
1503 #[inline(always)]
1504 pub fn enb(
1505 self,
1506 ) -> crate::common::RegisterField<
1507 7,
1508 0x1,
1509 1,
1510 0,
1511 rmonar::Enb,
1512 rmonar::Enb,
1513 Rmonar_SPEC,
1514 crate::common::RW,
1515 > {
1516 crate::common::RegisterField::<
1517 7,
1518 0x1,
1519 1,
1520 0,
1521 rmonar::Enb,
1522 rmonar::Enb,
1523 Rmonar_SPEC,
1524 crate::common::RW,
1525 >::from_register(self, 0)
1526 }
1527}
1528impl ::core::default::Default for Rmonar {
1529 #[inline(always)]
1530 fn default() -> Rmonar {
1531 <crate::RegValueT<Rmonar_SPEC> as RegisterValue<_>>::new(0)
1532 }
1533}
1534pub mod rmonar {
1535
1536 #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
1537 pub struct Enb_SPEC;
1538 pub type Enb = crate::EnumBitfieldStruct<u8, Enb_SPEC>;
1539 impl Enb {
1540 #[doc = "Do not compare register value with RMONCNT counter value"]
1541 pub const _0: Self = Self::new(0);
1542
1543 #[doc = "Compare register value with RMONCNT counter value"]
1544 pub const _1: Self = Self::new(1);
1545 }
1546}
1547#[doc(hidden)]
1548#[derive(Copy, Clone, Eq, PartialEq)]
1549pub struct Bcnt2Aer_SPEC;
1550impl crate::sealed::RegSpec for Bcnt2Aer_SPEC {
1551 type DataType = u16;
1552}
1553
1554#[doc = "Binary Counter 2 Alarm Enable Register"]
1555pub type Bcnt2Aer = crate::RegValueT<Bcnt2Aer_SPEC>;
1556
1557impl Bcnt2Aer {
1558 #[doc = "Setting the alarm enable associated with the 32-bit binary counter"]
1559 #[inline(always)]
1560 pub fn enb(
1561 self,
1562 ) -> crate::common::RegisterField<0, 0xff, 1, 0, u8, u8, Bcnt2Aer_SPEC, crate::common::RW> {
1563 crate::common::RegisterField::<0,0xff,1,0,u8,u8,Bcnt2Aer_SPEC,crate::common::RW>::from_register(self,0)
1564 }
1565}
1566impl ::core::default::Default for Bcnt2Aer {
1567 #[inline(always)]
1568 fn default() -> Bcnt2Aer {
1569 <crate::RegValueT<Bcnt2Aer_SPEC> as RegisterValue<_>>::new(0)
1570 }
1571}
1572
1573#[doc(hidden)]
1574#[derive(Copy, Clone, Eq, PartialEq)]
1575pub struct Ryrar_SPEC;
1576impl crate::sealed::RegSpec for Ryrar_SPEC {
1577 type DataType = u16;
1578}
1579
1580#[doc = "Year Alarm Register (in Calendar Count Mode)"]
1581pub type Ryrar = crate::RegValueT<Ryrar_SPEC>;
1582
1583impl Ryrar {
1584 #[doc = "1 Year"]
1585 #[inline(always)]
1586 pub fn yr1(
1587 self,
1588 ) -> crate::common::RegisterField<0, 0xf, 1, 0, u8, u8, Ryrar_SPEC, crate::common::RW> {
1589 crate::common::RegisterField::<0,0xf,1,0,u8,u8,Ryrar_SPEC,crate::common::RW>::from_register(self,0)
1590 }
1591
1592 #[doc = "10 Years"]
1593 #[inline(always)]
1594 pub fn yr10(
1595 self,
1596 ) -> crate::common::RegisterField<4, 0xf, 1, 0, u8, u8, Ryrar_SPEC, crate::common::RW> {
1597 crate::common::RegisterField::<4,0xf,1,0,u8,u8,Ryrar_SPEC,crate::common::RW>::from_register(self,0)
1598 }
1599}
1600impl ::core::default::Default for Ryrar {
1601 #[inline(always)]
1602 fn default() -> Ryrar {
1603 <crate::RegValueT<Ryrar_SPEC> as RegisterValue<_>>::new(0)
1604 }
1605}
1606
1607#[doc(hidden)]
1608#[derive(Copy, Clone, Eq, PartialEq)]
1609pub struct Bcnt3Aer_SPEC;
1610impl crate::sealed::RegSpec for Bcnt3Aer_SPEC {
1611 type DataType = u8;
1612}
1613
1614#[doc = "Binary Counter 3 Alarm Enable Register"]
1615pub type Bcnt3Aer = crate::RegValueT<Bcnt3Aer_SPEC>;
1616
1617impl Bcnt3Aer {
1618 #[doc = "Setting the alarm enable associated with the 32-bit binary counter"]
1619 #[inline(always)]
1620 pub fn enb(
1621 self,
1622 ) -> crate::common::RegisterField<0, 0xff, 1, 0, u8, u8, Bcnt3Aer_SPEC, crate::common::RW> {
1623 crate::common::RegisterField::<0,0xff,1,0,u8,u8,Bcnt3Aer_SPEC,crate::common::RW>::from_register(self,0)
1624 }
1625}
1626impl ::core::default::Default for Bcnt3Aer {
1627 #[inline(always)]
1628 fn default() -> Bcnt3Aer {
1629 <crate::RegValueT<Bcnt3Aer_SPEC> as RegisterValue<_>>::new(0)
1630 }
1631}
1632
1633#[doc(hidden)]
1634#[derive(Copy, Clone, Eq, PartialEq)]
1635pub struct Ryraren_SPEC;
1636impl crate::sealed::RegSpec for Ryraren_SPEC {
1637 type DataType = u8;
1638}
1639
1640#[doc = "Year Alarm Enable Register (in Calendar Count Mode)"]
1641pub type Ryraren = crate::RegValueT<Ryraren_SPEC>;
1642
1643impl Ryraren {
1644 #[doc = "ENB"]
1645 #[inline(always)]
1646 pub fn enb(
1647 self,
1648 ) -> crate::common::RegisterField<
1649 7,
1650 0x1,
1651 1,
1652 0,
1653 ryraren::Enb,
1654 ryraren::Enb,
1655 Ryraren_SPEC,
1656 crate::common::RW,
1657 > {
1658 crate::common::RegisterField::<
1659 7,
1660 0x1,
1661 1,
1662 0,
1663 ryraren::Enb,
1664 ryraren::Enb,
1665 Ryraren_SPEC,
1666 crate::common::RW,
1667 >::from_register(self, 0)
1668 }
1669}
1670impl ::core::default::Default for Ryraren {
1671 #[inline(always)]
1672 fn default() -> Ryraren {
1673 <crate::RegValueT<Ryraren_SPEC> as RegisterValue<_>>::new(0)
1674 }
1675}
1676pub mod ryraren {
1677
1678 #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
1679 pub struct Enb_SPEC;
1680 pub type Enb = crate::EnumBitfieldStruct<u8, Enb_SPEC>;
1681 impl Enb {
1682 #[doc = "Do not compare register value with the RYRCNT counter value"]
1683 pub const _0: Self = Self::new(0);
1684
1685 #[doc = "Compare register value with the RYRCNT counter value"]
1686 pub const _1: Self = Self::new(1);
1687 }
1688}
1689#[doc(hidden)]
1690#[derive(Copy, Clone, Eq, PartialEq)]
1691pub struct Rcr1_SPEC;
1692impl crate::sealed::RegSpec for Rcr1_SPEC {
1693 type DataType = u8;
1694}
1695
1696#[doc = "RTC Control Register 1"]
1697pub type Rcr1 = crate::RegValueT<Rcr1_SPEC>;
1698
1699impl Rcr1 {
1700 #[doc = "Alarm Interrupt Enable"]
1701 #[inline(always)]
1702 pub fn aie(
1703 self,
1704 ) -> crate::common::RegisterField<
1705 0,
1706 0x1,
1707 1,
1708 0,
1709 rcr1::Aie,
1710 rcr1::Aie,
1711 Rcr1_SPEC,
1712 crate::common::RW,
1713 > {
1714 crate::common::RegisterField::<
1715 0,
1716 0x1,
1717 1,
1718 0,
1719 rcr1::Aie,
1720 rcr1::Aie,
1721 Rcr1_SPEC,
1722 crate::common::RW,
1723 >::from_register(self, 0)
1724 }
1725
1726 #[doc = "Carry Interrupt Enable"]
1727 #[inline(always)]
1728 pub fn cie(
1729 self,
1730 ) -> crate::common::RegisterField<
1731 1,
1732 0x1,
1733 1,
1734 0,
1735 rcr1::Cie,
1736 rcr1::Cie,
1737 Rcr1_SPEC,
1738 crate::common::RW,
1739 > {
1740 crate::common::RegisterField::<
1741 1,
1742 0x1,
1743 1,
1744 0,
1745 rcr1::Cie,
1746 rcr1::Cie,
1747 Rcr1_SPEC,
1748 crate::common::RW,
1749 >::from_register(self, 0)
1750 }
1751
1752 #[doc = "Periodic Interrupt Enable"]
1753 #[inline(always)]
1754 pub fn pie(
1755 self,
1756 ) -> crate::common::RegisterField<
1757 2,
1758 0x1,
1759 1,
1760 0,
1761 rcr1::Pie,
1762 rcr1::Pie,
1763 Rcr1_SPEC,
1764 crate::common::RW,
1765 > {
1766 crate::common::RegisterField::<
1767 2,
1768 0x1,
1769 1,
1770 0,
1771 rcr1::Pie,
1772 rcr1::Pie,
1773 Rcr1_SPEC,
1774 crate::common::RW,
1775 >::from_register(self, 0)
1776 }
1777
1778 #[doc = "RTCOUT Output Select"]
1779 #[inline(always)]
1780 pub fn rtcos(
1781 self,
1782 ) -> crate::common::RegisterField<
1783 3,
1784 0x1,
1785 1,
1786 0,
1787 rcr1::Rtcos,
1788 rcr1::Rtcos,
1789 Rcr1_SPEC,
1790 crate::common::RW,
1791 > {
1792 crate::common::RegisterField::<
1793 3,
1794 0x1,
1795 1,
1796 0,
1797 rcr1::Rtcos,
1798 rcr1::Rtcos,
1799 Rcr1_SPEC,
1800 crate::common::RW,
1801 >::from_register(self, 0)
1802 }
1803
1804 #[doc = "Periodic Interrupt Select"]
1805 #[inline(always)]
1806 pub fn pes(
1807 self,
1808 ) -> crate::common::RegisterField<
1809 4,
1810 0xf,
1811 1,
1812 0,
1813 rcr1::Pes,
1814 rcr1::Pes,
1815 Rcr1_SPEC,
1816 crate::common::RW,
1817 > {
1818 crate::common::RegisterField::<
1819 4,
1820 0xf,
1821 1,
1822 0,
1823 rcr1::Pes,
1824 rcr1::Pes,
1825 Rcr1_SPEC,
1826 crate::common::RW,
1827 >::from_register(self, 0)
1828 }
1829}
1830impl ::core::default::Default for Rcr1 {
1831 #[inline(always)]
1832 fn default() -> Rcr1 {
1833 <crate::RegValueT<Rcr1_SPEC> as RegisterValue<_>>::new(0)
1834 }
1835}
1836pub mod rcr1 {
1837
1838 #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
1839 pub struct Aie_SPEC;
1840 pub type Aie = crate::EnumBitfieldStruct<u8, Aie_SPEC>;
1841 impl Aie {
1842 #[doc = "Disable alarm interrupt requests"]
1843 pub const _0: Self = Self::new(0);
1844
1845 #[doc = "Enable alarm interrupt requests"]
1846 pub const _1: Self = Self::new(1);
1847 }
1848 #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
1849 pub struct Cie_SPEC;
1850 pub type Cie = crate::EnumBitfieldStruct<u8, Cie_SPEC>;
1851 impl Cie {
1852 #[doc = "Disable carry interrupt requests"]
1853 pub const _0: Self = Self::new(0);
1854
1855 #[doc = "Enable carry interrupt requests"]
1856 pub const _1: Self = Self::new(1);
1857 }
1858 #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
1859 pub struct Pie_SPEC;
1860 pub type Pie = crate::EnumBitfieldStruct<u8, Pie_SPEC>;
1861 impl Pie {
1862 #[doc = "Disable periodic interrupt requests"]
1863 pub const _0: Self = Self::new(0);
1864
1865 #[doc = "Enable periodic interrupt requests"]
1866 pub const _1: Self = Self::new(1);
1867 }
1868 #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
1869 pub struct Rtcos_SPEC;
1870 pub type Rtcos = crate::EnumBitfieldStruct<u8, Rtcos_SPEC>;
1871 impl Rtcos {
1872 #[doc = "Outputs 1 Hz on RTCOUT"]
1873 pub const _0: Self = Self::new(0);
1874
1875 #[doc = "Outputs 64 Hz RTCOUT"]
1876 pub const _1: Self = Self::new(1);
1877 }
1878 #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
1879 pub struct Pes_SPEC;
1880 pub type Pes = crate::EnumBitfieldStruct<u8, Pes_SPEC>;
1881 impl Pes {
1882 #[doc = "Generate periodic interrupt every 1/256 second"]
1883 pub const _0_X_6: Self = Self::new(6);
1884
1885 #[doc = "Generate periodic interrupt every 1/128 second"]
1886 pub const _0_X_7: Self = Self::new(7);
1887
1888 #[doc = "Generate periodic interrupt every 1/64 second"]
1889 pub const _0_X_8: Self = Self::new(8);
1890
1891 #[doc = "Generate periodic interrupt every 1/32 second"]
1892 pub const _0_X_9: Self = Self::new(9);
1893
1894 #[doc = "Generate periodic interrupt every 1/16 second"]
1895 pub const _0_X_A: Self = Self::new(10);
1896
1897 #[doc = "Generate periodic interrupt every 1/8 second"]
1898 pub const _0_X_B: Self = Self::new(11);
1899
1900 #[doc = "Generate periodic interrupt every 1/4 second"]
1901 pub const _0_X_C: Self = Self::new(12);
1902
1903 #[doc = "Generate periodic interrupt every 1/2 second"]
1904 pub const _0_X_D: Self = Self::new(13);
1905
1906 #[doc = "Generate periodic interrupt every 1 second"]
1907 pub const _0_X_E: Self = Self::new(14);
1908
1909 #[doc = "Generate periodic interrupt every 2 seconds"]
1910 pub const _0_X_F: Self = Self::new(15);
1911 }
1912}
1913#[doc(hidden)]
1914#[derive(Copy, Clone, Eq, PartialEq)]
1915pub struct Rcr2_SPEC;
1916impl crate::sealed::RegSpec for Rcr2_SPEC {
1917 type DataType = u8;
1918}
1919
1920#[doc = "RTC Control Register 2 (in Calendar Count Mode)"]
1921pub type Rcr2 = crate::RegValueT<Rcr2_SPEC>;
1922
1923impl Rcr2 {
1924 #[doc = "Start"]
1925 #[inline(always)]
1926 pub fn start(
1927 self,
1928 ) -> crate::common::RegisterField<
1929 0,
1930 0x1,
1931 1,
1932 0,
1933 rcr2::Start,
1934 rcr2::Start,
1935 Rcr2_SPEC,
1936 crate::common::RW,
1937 > {
1938 crate::common::RegisterField::<
1939 0,
1940 0x1,
1941 1,
1942 0,
1943 rcr2::Start,
1944 rcr2::Start,
1945 Rcr2_SPEC,
1946 crate::common::RW,
1947 >::from_register(self, 0)
1948 }
1949
1950 #[doc = "RTC Software Reset"]
1951 #[inline(always)]
1952 pub fn reset(
1953 self,
1954 ) -> crate::common::RegisterField<
1955 1,
1956 0x1,
1957 1,
1958 0,
1959 rcr2::Reset,
1960 rcr2::Reset,
1961 Rcr2_SPEC,
1962 crate::common::RW,
1963 > {
1964 crate::common::RegisterField::<
1965 1,
1966 0x1,
1967 1,
1968 0,
1969 rcr2::Reset,
1970 rcr2::Reset,
1971 Rcr2_SPEC,
1972 crate::common::RW,
1973 >::from_register(self, 0)
1974 }
1975
1976 #[doc = "30-Second Adjustment"]
1977 #[inline(always)]
1978 pub fn adj30(
1979 self,
1980 ) -> crate::common::RegisterField<
1981 2,
1982 0x1,
1983 1,
1984 0,
1985 rcr2::Adj30,
1986 rcr2::Adj30,
1987 Rcr2_SPEC,
1988 crate::common::RW,
1989 > {
1990 crate::common::RegisterField::<
1991 2,
1992 0x1,
1993 1,
1994 0,
1995 rcr2::Adj30,
1996 rcr2::Adj30,
1997 Rcr2_SPEC,
1998 crate::common::RW,
1999 >::from_register(self, 0)
2000 }
2001
2002 #[doc = "RTCOUT Output Enable"]
2003 #[inline(always)]
2004 pub fn rtcoe(
2005 self,
2006 ) -> crate::common::RegisterField<
2007 3,
2008 0x1,
2009 1,
2010 0,
2011 rcr2::Rtcoe,
2012 rcr2::Rtcoe,
2013 Rcr2_SPEC,
2014 crate::common::RW,
2015 > {
2016 crate::common::RegisterField::<
2017 3,
2018 0x1,
2019 1,
2020 0,
2021 rcr2::Rtcoe,
2022 rcr2::Rtcoe,
2023 Rcr2_SPEC,
2024 crate::common::RW,
2025 >::from_register(self, 0)
2026 }
2027
2028 #[doc = "Automatic Adjustment Enable"]
2029 #[inline(always)]
2030 pub fn aadje(
2031 self,
2032 ) -> crate::common::RegisterField<
2033 4,
2034 0x1,
2035 1,
2036 0,
2037 rcr2::Aadje,
2038 rcr2::Aadje,
2039 Rcr2_SPEC,
2040 crate::common::RW,
2041 > {
2042 crate::common::RegisterField::<
2043 4,
2044 0x1,
2045 1,
2046 0,
2047 rcr2::Aadje,
2048 rcr2::Aadje,
2049 Rcr2_SPEC,
2050 crate::common::RW,
2051 >::from_register(self, 0)
2052 }
2053
2054 #[doc = "Automatic Adjustment Period Select"]
2055 #[inline(always)]
2056 pub fn aadjp(
2057 self,
2058 ) -> crate::common::RegisterField<
2059 5,
2060 0x1,
2061 1,
2062 0,
2063 rcr2::Aadjp,
2064 rcr2::Aadjp,
2065 Rcr2_SPEC,
2066 crate::common::RW,
2067 > {
2068 crate::common::RegisterField::<
2069 5,
2070 0x1,
2071 1,
2072 0,
2073 rcr2::Aadjp,
2074 rcr2::Aadjp,
2075 Rcr2_SPEC,
2076 crate::common::RW,
2077 >::from_register(self, 0)
2078 }
2079
2080 #[doc = "Hours Mode"]
2081 #[inline(always)]
2082 pub fn hr24(
2083 self,
2084 ) -> crate::common::RegisterField<
2085 6,
2086 0x1,
2087 1,
2088 0,
2089 rcr2::Hr24,
2090 rcr2::Hr24,
2091 Rcr2_SPEC,
2092 crate::common::RW,
2093 > {
2094 crate::common::RegisterField::<
2095 6,
2096 0x1,
2097 1,
2098 0,
2099 rcr2::Hr24,
2100 rcr2::Hr24,
2101 Rcr2_SPEC,
2102 crate::common::RW,
2103 >::from_register(self, 0)
2104 }
2105
2106 #[doc = "Count Mode Select"]
2107 #[inline(always)]
2108 pub fn cntmd(
2109 self,
2110 ) -> crate::common::RegisterField<
2111 7,
2112 0x1,
2113 1,
2114 0,
2115 rcr2::Cntmd,
2116 rcr2::Cntmd,
2117 Rcr2_SPEC,
2118 crate::common::RW,
2119 > {
2120 crate::common::RegisterField::<
2121 7,
2122 0x1,
2123 1,
2124 0,
2125 rcr2::Cntmd,
2126 rcr2::Cntmd,
2127 Rcr2_SPEC,
2128 crate::common::RW,
2129 >::from_register(self, 0)
2130 }
2131}
2132impl ::core::default::Default for Rcr2 {
2133 #[inline(always)]
2134 fn default() -> Rcr2 {
2135 <crate::RegValueT<Rcr2_SPEC> as RegisterValue<_>>::new(0)
2136 }
2137}
2138pub mod rcr2 {
2139
2140 #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
2141 pub struct Start_SPEC;
2142 pub type Start = crate::EnumBitfieldStruct<u8, Start_SPEC>;
2143 impl Start {
2144 #[doc = "Stop prescaler and time counter"]
2145 pub const _0: Self = Self::new(0);
2146
2147 #[doc = "Operate prescaler and time counter normally"]
2148 pub const _1: Self = Self::new(1);
2149 }
2150 #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
2151 pub struct Reset_SPEC;
2152 pub type Reset = crate::EnumBitfieldStruct<u8, Reset_SPEC>;
2153 impl Reset {
2154 #[doc = "In writing: Invalid (writing 0 has no effect). In reading: Normal time operation in progress, or an RTC software reset has completed."]
2155 pub const _0: Self = Self::new(0);
2156
2157 #[doc = "In writing: Initialize the prescaler and target registers for RTC software reset. In reading: RTC software reset in progress."]
2158 pub const _1: Self = Self::new(1);
2159 }
2160 #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
2161 pub struct Adj30_SPEC;
2162 pub type Adj30 = crate::EnumBitfieldStruct<u8, Adj30_SPEC>;
2163 impl Adj30 {
2164 #[doc = "In writing: Invalid (writing 0 has no effect). In reading: Normal time operation in progress, or 30-second adjustment has completed."]
2165 pub const _0: Self = Self::new(0);
2166
2167 #[doc = "In writing: Execute 30-second adjustment. In reading: 30-second adjustment in progress."]
2168 pub const _1: Self = Self::new(1);
2169 }
2170 #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
2171 pub struct Rtcoe_SPEC;
2172 pub type Rtcoe = crate::EnumBitfieldStruct<u8, Rtcoe_SPEC>;
2173 impl Rtcoe {
2174 #[doc = "Disable RTCOUT output"]
2175 pub const _0: Self = Self::new(0);
2176
2177 #[doc = "Enable RTCOUT output"]
2178 pub const _1: Self = Self::new(1);
2179 }
2180 #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
2181 pub struct Aadje_SPEC;
2182 pub type Aadje = crate::EnumBitfieldStruct<u8, Aadje_SPEC>;
2183 impl Aadje {
2184 #[doc = "Disable automatic adjustment"]
2185 pub const _0: Self = Self::new(0);
2186
2187 #[doc = "Enable automatic adjustment"]
2188 pub const _1: Self = Self::new(1);
2189 }
2190 #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
2191 pub struct Aadjp_SPEC;
2192 pub type Aadjp = crate::EnumBitfieldStruct<u8, Aadjp_SPEC>;
2193 impl Aadjp {
2194 #[doc = "The RADJ.ADJ\\[5:0\\] setting from the count value of the prescaler every minute."]
2195 pub const _0: Self = Self::new(0);
2196
2197 #[doc = "The RADJ.ADJ\\[5:0\\] setting value is adjusted from the coun tvalue of the prescaler every 10 seconds."]
2198 pub const _1: Self = Self::new(1);
2199 }
2200 #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
2201 pub struct Hr24_SPEC;
2202 pub type Hr24 = crate::EnumBitfieldStruct<u8, Hr24_SPEC>;
2203 impl Hr24 {
2204 #[doc = "Operate RTC in 12-hour mode"]
2205 pub const _0: Self = Self::new(0);
2206
2207 #[doc = "Operate RTC in 24-hour mode"]
2208 pub const _1: Self = Self::new(1);
2209 }
2210 #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
2211 pub struct Cntmd_SPEC;
2212 pub type Cntmd = crate::EnumBitfieldStruct<u8, Cntmd_SPEC>;
2213 impl Cntmd {
2214 #[doc = "Calendar count mode"]
2215 pub const _0: Self = Self::new(0);
2216
2217 #[doc = "Binary count mode"]
2218 pub const _1: Self = Self::new(1);
2219 }
2220}
2221#[doc(hidden)]
2222#[derive(Copy, Clone, Eq, PartialEq)]
2223pub struct Rcr2Bcnt_SPEC;
2224impl crate::sealed::RegSpec for Rcr2Bcnt_SPEC {
2225 type DataType = u8;
2226}
2227
2228#[doc = "RTC Control Register 2 (in Binary Count Mode)"]
2229pub type Rcr2Bcnt = crate::RegValueT<Rcr2Bcnt_SPEC>;
2230
2231impl Rcr2Bcnt {
2232 #[doc = "Start"]
2233 #[inline(always)]
2234 pub fn start(
2235 self,
2236 ) -> crate::common::RegisterField<
2237 0,
2238 0x1,
2239 1,
2240 0,
2241 rcr2_bcnt::Start,
2242 rcr2_bcnt::Start,
2243 Rcr2Bcnt_SPEC,
2244 crate::common::RW,
2245 > {
2246 crate::common::RegisterField::<
2247 0,
2248 0x1,
2249 1,
2250 0,
2251 rcr2_bcnt::Start,
2252 rcr2_bcnt::Start,
2253 Rcr2Bcnt_SPEC,
2254 crate::common::RW,
2255 >::from_register(self, 0)
2256 }
2257
2258 #[doc = "RTC Software Reset"]
2259 #[inline(always)]
2260 pub fn reset(
2261 self,
2262 ) -> crate::common::RegisterField<
2263 1,
2264 0x1,
2265 1,
2266 0,
2267 rcr2_bcnt::Reset,
2268 rcr2_bcnt::Reset,
2269 Rcr2Bcnt_SPEC,
2270 crate::common::RW,
2271 > {
2272 crate::common::RegisterField::<
2273 1,
2274 0x1,
2275 1,
2276 0,
2277 rcr2_bcnt::Reset,
2278 rcr2_bcnt::Reset,
2279 Rcr2Bcnt_SPEC,
2280 crate::common::RW,
2281 >::from_register(self, 0)
2282 }
2283
2284 #[doc = "RTCOUT Output Enable"]
2285 #[inline(always)]
2286 pub fn rtcoe(
2287 self,
2288 ) -> crate::common::RegisterField<
2289 3,
2290 0x1,
2291 1,
2292 0,
2293 rcr2_bcnt::Rtcoe,
2294 rcr2_bcnt::Rtcoe,
2295 Rcr2Bcnt_SPEC,
2296 crate::common::RW,
2297 > {
2298 crate::common::RegisterField::<
2299 3,
2300 0x1,
2301 1,
2302 0,
2303 rcr2_bcnt::Rtcoe,
2304 rcr2_bcnt::Rtcoe,
2305 Rcr2Bcnt_SPEC,
2306 crate::common::RW,
2307 >::from_register(self, 0)
2308 }
2309
2310 #[doc = "Automatic Adjustment Enable"]
2311 #[inline(always)]
2312 pub fn aadje(
2313 self,
2314 ) -> crate::common::RegisterField<
2315 4,
2316 0x1,
2317 1,
2318 0,
2319 rcr2_bcnt::Aadje,
2320 rcr2_bcnt::Aadje,
2321 Rcr2Bcnt_SPEC,
2322 crate::common::RW,
2323 > {
2324 crate::common::RegisterField::<
2325 4,
2326 0x1,
2327 1,
2328 0,
2329 rcr2_bcnt::Aadje,
2330 rcr2_bcnt::Aadje,
2331 Rcr2Bcnt_SPEC,
2332 crate::common::RW,
2333 >::from_register(self, 0)
2334 }
2335
2336 #[doc = "Automatic Adjustment Period Select"]
2337 #[inline(always)]
2338 pub fn aadjp(
2339 self,
2340 ) -> crate::common::RegisterField<
2341 5,
2342 0x1,
2343 1,
2344 0,
2345 rcr2_bcnt::Aadjp,
2346 rcr2_bcnt::Aadjp,
2347 Rcr2Bcnt_SPEC,
2348 crate::common::RW,
2349 > {
2350 crate::common::RegisterField::<
2351 5,
2352 0x1,
2353 1,
2354 0,
2355 rcr2_bcnt::Aadjp,
2356 rcr2_bcnt::Aadjp,
2357 Rcr2Bcnt_SPEC,
2358 crate::common::RW,
2359 >::from_register(self, 0)
2360 }
2361
2362 #[doc = "Count Mode Select"]
2363 #[inline(always)]
2364 pub fn cntmd(
2365 self,
2366 ) -> crate::common::RegisterField<
2367 7,
2368 0x1,
2369 1,
2370 0,
2371 rcr2_bcnt::Cntmd,
2372 rcr2_bcnt::Cntmd,
2373 Rcr2Bcnt_SPEC,
2374 crate::common::RW,
2375 > {
2376 crate::common::RegisterField::<
2377 7,
2378 0x1,
2379 1,
2380 0,
2381 rcr2_bcnt::Cntmd,
2382 rcr2_bcnt::Cntmd,
2383 Rcr2Bcnt_SPEC,
2384 crate::common::RW,
2385 >::from_register(self, 0)
2386 }
2387}
2388impl ::core::default::Default for Rcr2Bcnt {
2389 #[inline(always)]
2390 fn default() -> Rcr2Bcnt {
2391 <crate::RegValueT<Rcr2Bcnt_SPEC> as RegisterValue<_>>::new(0)
2392 }
2393}
2394pub mod rcr2_bcnt {
2395
2396 #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
2397 pub struct Start_SPEC;
2398 pub type Start = crate::EnumBitfieldStruct<u8, Start_SPEC>;
2399 impl Start {
2400 #[doc = "Stop the 32-bit binary counter, 64-Hz counter, and prescaler"]
2401 pub const _0: Self = Self::new(0);
2402
2403 #[doc = "Operate the 32-bit binary counter, 64-Hz counter, and prescaler normally"]
2404 pub const _1: Self = Self::new(1);
2405 }
2406 #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
2407 pub struct Reset_SPEC;
2408 pub type Reset = crate::EnumBitfieldStruct<u8, Reset_SPEC>;
2409 impl Reset {
2410 #[doc = "In writing: Invalid (writing 0 has no effect). In reading: Normal time operation in progress, or an RTC software reset has completed."]
2411 pub const _0: Self = Self::new(0);
2412
2413 #[doc = "In writing: Initialize the prescaler and target registers for RTC software reset. In reading: RTC software reset in progress."]
2414 pub const _1: Self = Self::new(1);
2415 }
2416 #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
2417 pub struct Rtcoe_SPEC;
2418 pub type Rtcoe = crate::EnumBitfieldStruct<u8, Rtcoe_SPEC>;
2419 impl Rtcoe {
2420 #[doc = "Disable RTCOUT output"]
2421 pub const _0: Self = Self::new(0);
2422
2423 #[doc = "Enable RTCOUT output"]
2424 pub const _1: Self = Self::new(1);
2425 }
2426 #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
2427 pub struct Aadje_SPEC;
2428 pub type Aadje = crate::EnumBitfieldStruct<u8, Aadje_SPEC>;
2429 impl Aadje {
2430 #[doc = "Disable automatic adjustment"]
2431 pub const _0: Self = Self::new(0);
2432
2433 #[doc = "Enable automatic adjustment"]
2434 pub const _1: Self = Self::new(1);
2435 }
2436 #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
2437 pub struct Aadjp_SPEC;
2438 pub type Aadjp = crate::EnumBitfieldStruct<u8, Aadjp_SPEC>;
2439 impl Aadjp {
2440 #[doc = "Add or subtract RADJ.ADJ \\[5:0\\] bits from prescaler count value every 32 seconds"]
2441 pub const _0: Self = Self::new(0);
2442
2443 #[doc = "Add or subtract RADJ.ADJ \\[5:0\\] bits from prescaler countvalue every 8 seconds."]
2444 pub const _1: Self = Self::new(1);
2445 }
2446 #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
2447 pub struct Cntmd_SPEC;
2448 pub type Cntmd = crate::EnumBitfieldStruct<u8, Cntmd_SPEC>;
2449 impl Cntmd {
2450 #[doc = "Calendar count mode"]
2451 pub const _0: Self = Self::new(0);
2452
2453 #[doc = "Binary count mode"]
2454 pub const _1: Self = Self::new(1);
2455 }
2456}
2457#[doc(hidden)]
2458#[derive(Copy, Clone, Eq, PartialEq)]
2459pub struct Rcr4_SPEC;
2460impl crate::sealed::RegSpec for Rcr4_SPEC {
2461 type DataType = u8;
2462}
2463
2464#[doc = "RTC Control Register 4"]
2465pub type Rcr4 = crate::RegValueT<Rcr4_SPEC>;
2466
2467impl Rcr4 {
2468 #[doc = "Count Source Select"]
2469 #[inline(always)]
2470 pub fn rcksel(
2471 self,
2472 ) -> crate::common::RegisterField<
2473 0,
2474 0x1,
2475 1,
2476 0,
2477 rcr4::Rcksel,
2478 rcr4::Rcksel,
2479 Rcr4_SPEC,
2480 crate::common::RW,
2481 > {
2482 crate::common::RegisterField::<
2483 0,
2484 0x1,
2485 1,
2486 0,
2487 rcr4::Rcksel,
2488 rcr4::Rcksel,
2489 Rcr4_SPEC,
2490 crate::common::RW,
2491 >::from_register(self, 0)
2492 }
2493}
2494impl ::core::default::Default for Rcr4 {
2495 #[inline(always)]
2496 fn default() -> Rcr4 {
2497 <crate::RegValueT<Rcr4_SPEC> as RegisterValue<_>>::new(0)
2498 }
2499}
2500pub mod rcr4 {
2501
2502 #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
2503 pub struct Rcksel_SPEC;
2504 pub type Rcksel = crate::EnumBitfieldStruct<u8, Rcksel_SPEC>;
2505 impl Rcksel {
2506 #[doc = "Sub-clock oscillator is selected"]
2507 pub const _0: Self = Self::new(0);
2508
2509 #[doc = "LOCO is selected"]
2510 pub const _1: Self = Self::new(1);
2511 }
2512}
2513#[doc(hidden)]
2514#[derive(Copy, Clone, Eq, PartialEq)]
2515pub struct Rfrh_SPEC;
2516impl crate::sealed::RegSpec for Rfrh_SPEC {
2517 type DataType = u16;
2518}
2519
2520#[doc = "Frequency Register H"]
2521pub type Rfrh = crate::RegValueT<Rfrh_SPEC>;
2522
2523impl Rfrh {
2524 #[doc = "Write 0 before writing to the RFRL register after a cold start."]
2525 #[inline(always)]
2526 pub fn rfc16(self) -> crate::common::RegisterFieldBool<0, 1, 0, Rfrh_SPEC, crate::common::RW> {
2527 crate::common::RegisterFieldBool::<0, 1, 0, Rfrh_SPEC, crate::common::RW>::from_register(
2528 self, 0,
2529 )
2530 }
2531}
2532impl ::core::default::Default for Rfrh {
2533 #[inline(always)]
2534 fn default() -> Rfrh {
2535 <crate::RegValueT<Rfrh_SPEC> as RegisterValue<_>>::new(0)
2536 }
2537}
2538
2539#[doc(hidden)]
2540#[derive(Copy, Clone, Eq, PartialEq)]
2541pub struct Rfrl_SPEC;
2542impl crate::sealed::RegSpec for Rfrl_SPEC {
2543 type DataType = u16;
2544}
2545
2546#[doc = "Frequency Register L"]
2547pub type Rfrl = crate::RegValueT<Rfrl_SPEC>;
2548
2549impl Rfrl {
2550 #[doc = "Frequency Comparison Value"]
2551 #[inline(always)]
2552 pub fn rfc(
2553 self,
2554 ) -> crate::common::RegisterField<0, 0xffff, 1, 0, u16, u16, Rfrl_SPEC, crate::common::RW> {
2555 crate::common::RegisterField::<0,0xffff,1,0,u16,u16,Rfrl_SPEC,crate::common::RW>::from_register(self,0)
2556 }
2557}
2558impl ::core::default::Default for Rfrl {
2559 #[inline(always)]
2560 fn default() -> Rfrl {
2561 <crate::RegValueT<Rfrl_SPEC> as RegisterValue<_>>::new(0)
2562 }
2563}
2564
2565#[doc(hidden)]
2566#[derive(Copy, Clone, Eq, PartialEq)]
2567pub struct Radj_SPEC;
2568impl crate::sealed::RegSpec for Radj_SPEC {
2569 type DataType = u8;
2570}
2571
2572#[doc = "Time Error Adjustment Register"]
2573pub type Radj = crate::RegValueT<Radj_SPEC>;
2574
2575impl Radj {
2576 #[doc = "Adjustment Value"]
2577 #[inline(always)]
2578 pub fn adj(
2579 self,
2580 ) -> crate::common::RegisterField<0, 0x3f, 1, 0, u8, u8, Radj_SPEC, crate::common::RW> {
2581 crate::common::RegisterField::<0,0x3f,1,0,u8,u8,Radj_SPEC,crate::common::RW>::from_register(self,0)
2582 }
2583
2584 #[doc = "Plus-Minus"]
2585 #[inline(always)]
2586 pub fn pmadj(
2587 self,
2588 ) -> crate::common::RegisterField<
2589 6,
2590 0x3,
2591 1,
2592 0,
2593 radj::Pmadj,
2594 radj::Pmadj,
2595 Radj_SPEC,
2596 crate::common::RW,
2597 > {
2598 crate::common::RegisterField::<
2599 6,
2600 0x3,
2601 1,
2602 0,
2603 radj::Pmadj,
2604 radj::Pmadj,
2605 Radj_SPEC,
2606 crate::common::RW,
2607 >::from_register(self, 0)
2608 }
2609}
2610impl ::core::default::Default for Radj {
2611 #[inline(always)]
2612 fn default() -> Radj {
2613 <crate::RegValueT<Radj_SPEC> as RegisterValue<_>>::new(0)
2614 }
2615}
2616pub mod radj {
2617
2618 #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
2619 pub struct Pmadj_SPEC;
2620 pub type Pmadj = crate::EnumBitfieldStruct<u8, Pmadj_SPEC>;
2621 impl Pmadj {
2622 #[doc = "Do not perform adjustment."]
2623 pub const _00: Self = Self::new(0);
2624
2625 #[doc = "Adjustment is performed by the addition to the prescaler"]
2626 pub const _01: Self = Self::new(1);
2627
2628 #[doc = "Adjustment is performed by the subtraction from the prescaler"]
2629 pub const _10: Self = Self::new(2);
2630
2631 #[doc = "Setting prohibited."]
2632 pub const _11: Self = Self::new(3);
2633 }
2634}
2635#[doc(hidden)]
2636#[derive(Copy, Clone, Eq, PartialEq)]
2637pub struct Rtccr0_SPEC;
2638impl crate::sealed::RegSpec for Rtccr0_SPEC {
2639 type DataType = u8;
2640}
2641
2642#[doc = "Time Capture Control Register 0"]
2643pub type Rtccr0 = crate::RegValueT<Rtccr0_SPEC>;
2644
2645impl Rtccr0 {
2646 #[doc = "Time Capture Control"]
2647 #[inline(always)]
2648 pub fn tcct(
2649 self,
2650 ) -> crate::common::RegisterField<
2651 0,
2652 0x3,
2653 1,
2654 0,
2655 rtccr0::Tcct,
2656 rtccr0::Tcct,
2657 Rtccr0_SPEC,
2658 crate::common::RW,
2659 > {
2660 crate::common::RegisterField::<
2661 0,
2662 0x3,
2663 1,
2664 0,
2665 rtccr0::Tcct,
2666 rtccr0::Tcct,
2667 Rtccr0_SPEC,
2668 crate::common::RW,
2669 >::from_register(self, 0)
2670 }
2671
2672 #[doc = "Time Capture Status"]
2673 #[inline(always)]
2674 pub fn tcst(
2675 self,
2676 ) -> crate::common::RegisterField<
2677 2,
2678 0x1,
2679 1,
2680 0,
2681 rtccr0::Tcst,
2682 rtccr0::Tcst,
2683 Rtccr0_SPEC,
2684 crate::common::RW,
2685 > {
2686 crate::common::RegisterField::<
2687 2,
2688 0x1,
2689 1,
2690 0,
2691 rtccr0::Tcst,
2692 rtccr0::Tcst,
2693 Rtccr0_SPEC,
2694 crate::common::RW,
2695 >::from_register(self, 0)
2696 }
2697
2698 #[doc = "Time Capture Noise Filter Control"]
2699 #[inline(always)]
2700 pub fn tcnf(
2701 self,
2702 ) -> crate::common::RegisterField<
2703 4,
2704 0x3,
2705 1,
2706 0,
2707 rtccr0::Tcnf,
2708 rtccr0::Tcnf,
2709 Rtccr0_SPEC,
2710 crate::common::RW,
2711 > {
2712 crate::common::RegisterField::<
2713 4,
2714 0x3,
2715 1,
2716 0,
2717 rtccr0::Tcnf,
2718 rtccr0::Tcnf,
2719 Rtccr0_SPEC,
2720 crate::common::RW,
2721 >::from_register(self, 0)
2722 }
2723
2724 #[doc = "Time Capture Event Input Pin Enable"]
2725 #[inline(always)]
2726 pub fn tcen(
2727 self,
2728 ) -> crate::common::RegisterField<
2729 7,
2730 0x1,
2731 1,
2732 0,
2733 rtccr0::Tcen,
2734 rtccr0::Tcen,
2735 Rtccr0_SPEC,
2736 crate::common::RW,
2737 > {
2738 crate::common::RegisterField::<
2739 7,
2740 0x1,
2741 1,
2742 0,
2743 rtccr0::Tcen,
2744 rtccr0::Tcen,
2745 Rtccr0_SPEC,
2746 crate::common::RW,
2747 >::from_register(self, 0)
2748 }
2749}
2750impl ::core::default::Default for Rtccr0 {
2751 #[inline(always)]
2752 fn default() -> Rtccr0 {
2753 <crate::RegValueT<Rtccr0_SPEC> as RegisterValue<_>>::new(0)
2754 }
2755}
2756pub mod rtccr0 {
2757
2758 #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
2759 pub struct Tcct_SPEC;
2760 pub type Tcct = crate::EnumBitfieldStruct<u8, Tcct_SPEC>;
2761 impl Tcct {
2762 #[doc = "Do not detect events"]
2763 pub const _00: Self = Self::new(0);
2764
2765 #[doc = "Detect rising edge"]
2766 pub const _01: Self = Self::new(1);
2767
2768 #[doc = "Detect falling edge"]
2769 pub const _10: Self = Self::new(2);
2770
2771 #[doc = "Detect both edges"]
2772 pub const _11: Self = Self::new(3);
2773 }
2774 #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
2775 pub struct Tcst_SPEC;
2776 pub type Tcst = crate::EnumBitfieldStruct<u8, Tcst_SPEC>;
2777 impl Tcst {
2778 #[doc = "No event detected"]
2779 pub const _0: Self = Self::new(0);
2780
2781 #[doc = "Event detected"]
2782 pub const _1: Self = Self::new(1);
2783 }
2784 #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
2785 pub struct Tcnf_SPEC;
2786 pub type Tcnf = crate::EnumBitfieldStruct<u8, Tcnf_SPEC>;
2787 impl Tcnf {
2788 #[doc = "Turn noise filter off"]
2789 pub const _00: Self = Self::new(0);
2790
2791 #[doc = "Setting prohibited"]
2792 pub const _01: Self = Self::new(1);
2793
2794 #[doc = "Turn noise filter on (count source)"]
2795 pub const _10: Self = Self::new(2);
2796
2797 #[doc = "Turn noise filter on (count source by divided by 32)"]
2798 pub const _11: Self = Self::new(3);
2799 }
2800 #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
2801 pub struct Tcen_SPEC;
2802 pub type Tcen = crate::EnumBitfieldStruct<u8, Tcen_SPEC>;
2803 impl Tcen {
2804 #[doc = "Disable the RTCICn pin as the time capture event input pin"]
2805 pub const _0: Self = Self::new(0);
2806
2807 #[doc = "Enable the RTCICn pin as the time capture event input pin"]
2808 pub const _1: Self = Self::new(1);
2809 }
2810}
2811#[doc(hidden)]
2812#[derive(Copy, Clone, Eq, PartialEq)]
2813pub struct Bcnt0Cp0_SPEC;
2814impl crate::sealed::RegSpec for Bcnt0Cp0_SPEC {
2815 type DataType = u8;
2816}
2817
2818#[doc = "BCNT0 Capture Register 0"]
2819pub type Bcnt0Cp0 = crate::RegValueT<Bcnt0Cp0_SPEC>;
2820
2821impl NoBitfieldReg<Bcnt0Cp0_SPEC> for Bcnt0Cp0 {}
2822impl ::core::default::Default for Bcnt0Cp0 {
2823 #[inline(always)]
2824 fn default() -> Bcnt0Cp0 {
2825 <crate::RegValueT<Bcnt0Cp0_SPEC> as RegisterValue<_>>::new(0)
2826 }
2827}
2828
2829#[doc(hidden)]
2830#[derive(Copy, Clone, Eq, PartialEq)]
2831pub struct Rseccp0_SPEC;
2832impl crate::sealed::RegSpec for Rseccp0_SPEC {
2833 type DataType = u8;
2834}
2835
2836#[doc = "Second Capture Register 0"]
2837pub type Rseccp0 = crate::RegValueT<Rseccp0_SPEC>;
2838
2839impl Rseccp0 {
2840 #[doc = "1-Second Capture"]
2841 #[inline(always)]
2842 pub fn sec1(
2843 self,
2844 ) -> crate::common::RegisterField<0, 0xf, 1, 0, u8, u8, Rseccp0_SPEC, crate::common::R> {
2845 crate::common::RegisterField::<0,0xf,1,0,u8,u8,Rseccp0_SPEC,crate::common::R>::from_register(self,0)
2846 }
2847
2848 #[doc = "10-Second Capture"]
2849 #[inline(always)]
2850 pub fn sec10(
2851 self,
2852 ) -> crate::common::RegisterField<4, 0x7, 1, 0, u8, u8, Rseccp0_SPEC, crate::common::R> {
2853 crate::common::RegisterField::<4,0x7,1,0,u8,u8,Rseccp0_SPEC,crate::common::R>::from_register(self,0)
2854 }
2855}
2856impl ::core::default::Default for Rseccp0 {
2857 #[inline(always)]
2858 fn default() -> Rseccp0 {
2859 <crate::RegValueT<Rseccp0_SPEC> as RegisterValue<_>>::new(0)
2860 }
2861}
2862
2863#[doc(hidden)]
2864#[derive(Copy, Clone, Eq, PartialEq)]
2865pub struct Bcnt1Cp0_SPEC;
2866impl crate::sealed::RegSpec for Bcnt1Cp0_SPEC {
2867 type DataType = u8;
2868}
2869
2870#[doc = "BCNT1 Capture Register 0"]
2871pub type Bcnt1Cp0 = crate::RegValueT<Bcnt1Cp0_SPEC>;
2872
2873impl NoBitfieldReg<Bcnt1Cp0_SPEC> for Bcnt1Cp0 {}
2874impl ::core::default::Default for Bcnt1Cp0 {
2875 #[inline(always)]
2876 fn default() -> Bcnt1Cp0 {
2877 <crate::RegValueT<Bcnt1Cp0_SPEC> as RegisterValue<_>>::new(0)
2878 }
2879}
2880
2881#[doc(hidden)]
2882#[derive(Copy, Clone, Eq, PartialEq)]
2883pub struct Rmincp0_SPEC;
2884impl crate::sealed::RegSpec for Rmincp0_SPEC {
2885 type DataType = u8;
2886}
2887
2888#[doc = "Minute Capture Register 0"]
2889pub type Rmincp0 = crate::RegValueT<Rmincp0_SPEC>;
2890
2891impl Rmincp0 {
2892 #[doc = "1-Minute Capture"]
2893 #[inline(always)]
2894 pub fn min1(
2895 self,
2896 ) -> crate::common::RegisterField<0, 0xf, 1, 0, u8, u8, Rmincp0_SPEC, crate::common::R> {
2897 crate::common::RegisterField::<0,0xf,1,0,u8,u8,Rmincp0_SPEC,crate::common::R>::from_register(self,0)
2898 }
2899
2900 #[doc = "10-Minute Capture"]
2901 #[inline(always)]
2902 pub fn min10(
2903 self,
2904 ) -> crate::common::RegisterField<4, 0x7, 1, 0, u8, u8, Rmincp0_SPEC, crate::common::R> {
2905 crate::common::RegisterField::<4,0x7,1,0,u8,u8,Rmincp0_SPEC,crate::common::R>::from_register(self,0)
2906 }
2907}
2908impl ::core::default::Default for Rmincp0 {
2909 #[inline(always)]
2910 fn default() -> Rmincp0 {
2911 <crate::RegValueT<Rmincp0_SPEC> as RegisterValue<_>>::new(0)
2912 }
2913}
2914
2915#[doc(hidden)]
2916#[derive(Copy, Clone, Eq, PartialEq)]
2917pub struct Bcnt2Cp0_SPEC;
2918impl crate::sealed::RegSpec for Bcnt2Cp0_SPEC {
2919 type DataType = u8;
2920}
2921
2922#[doc = "BCNT2 Capture Register 0"]
2923pub type Bcnt2Cp0 = crate::RegValueT<Bcnt2Cp0_SPEC>;
2924
2925impl NoBitfieldReg<Bcnt2Cp0_SPEC> for Bcnt2Cp0 {}
2926impl ::core::default::Default for Bcnt2Cp0 {
2927 #[inline(always)]
2928 fn default() -> Bcnt2Cp0 {
2929 <crate::RegValueT<Bcnt2Cp0_SPEC> as RegisterValue<_>>::new(0)
2930 }
2931}
2932
2933#[doc(hidden)]
2934#[derive(Copy, Clone, Eq, PartialEq)]
2935pub struct Rhrcp0_SPEC;
2936impl crate::sealed::RegSpec for Rhrcp0_SPEC {
2937 type DataType = u8;
2938}
2939
2940#[doc = "Hour Capture Register 0"]
2941pub type Rhrcp0 = crate::RegValueT<Rhrcp0_SPEC>;
2942
2943impl Rhrcp0 {
2944 #[doc = "1-Hour Capture"]
2945 #[inline(always)]
2946 pub fn hr1(
2947 self,
2948 ) -> crate::common::RegisterField<0, 0xf, 1, 0, u8, u8, Rhrcp0_SPEC, crate::common::R> {
2949 crate::common::RegisterField::<0,0xf,1,0,u8,u8,Rhrcp0_SPEC,crate::common::R>::from_register(self,0)
2950 }
2951
2952 #[doc = "10-Hour Capture"]
2953 #[inline(always)]
2954 pub fn hr10(
2955 self,
2956 ) -> crate::common::RegisterField<4, 0x3, 1, 0, u8, u8, Rhrcp0_SPEC, crate::common::R> {
2957 crate::common::RegisterField::<4,0x3,1,0,u8,u8,Rhrcp0_SPEC,crate::common::R>::from_register(self,0)
2958 }
2959
2960 #[doc = "PM"]
2961 #[inline(always)]
2962 pub fn pm(
2963 self,
2964 ) -> crate::common::RegisterField<
2965 6,
2966 0x1,
2967 1,
2968 0,
2969 rhrcp0::Pm,
2970 rhrcp0::Pm,
2971 Rhrcp0_SPEC,
2972 crate::common::R,
2973 > {
2974 crate::common::RegisterField::<
2975 6,
2976 0x1,
2977 1,
2978 0,
2979 rhrcp0::Pm,
2980 rhrcp0::Pm,
2981 Rhrcp0_SPEC,
2982 crate::common::R,
2983 >::from_register(self, 0)
2984 }
2985}
2986impl ::core::default::Default for Rhrcp0 {
2987 #[inline(always)]
2988 fn default() -> Rhrcp0 {
2989 <crate::RegValueT<Rhrcp0_SPEC> as RegisterValue<_>>::new(0)
2990 }
2991}
2992pub mod rhrcp0 {
2993
2994 #[derive(Clone, Copy, Eq, PartialEq, Ord, PartialOrd)]
2995 pub struct Pm_SPEC;
2996 pub type Pm = crate::EnumBitfieldStruct<u8, Pm_SPEC>;
2997 impl Pm {
2998 #[doc = "AM"]
2999 pub const _0: Self = Self::new(0);
3000
3001 #[doc = "PM"]
3002 pub const _1: Self = Self::new(1);
3003 }
3004}
3005#[doc(hidden)]
3006#[derive(Copy, Clone, Eq, PartialEq)]
3007pub struct Bcnt3Cp0_SPEC;
3008impl crate::sealed::RegSpec for Bcnt3Cp0_SPEC {
3009 type DataType = u8;
3010}
3011
3012#[doc = "BCNT3 Capture Register 0"]
3013pub type Bcnt3Cp0 = crate::RegValueT<Bcnt3Cp0_SPEC>;
3014
3015impl NoBitfieldReg<Bcnt3Cp0_SPEC> for Bcnt3Cp0 {}
3016impl ::core::default::Default for Bcnt3Cp0 {
3017 #[inline(always)]
3018 fn default() -> Bcnt3Cp0 {
3019 <crate::RegValueT<Bcnt3Cp0_SPEC> as RegisterValue<_>>::new(0)
3020 }
3021}
3022
3023#[doc(hidden)]
3024#[derive(Copy, Clone, Eq, PartialEq)]
3025pub struct Rdaycp0_SPEC;
3026impl crate::sealed::RegSpec for Rdaycp0_SPEC {
3027 type DataType = u8;
3028}
3029
3030#[doc = "Date Capture Register 0"]
3031pub type Rdaycp0 = crate::RegValueT<Rdaycp0_SPEC>;
3032
3033impl Rdaycp0 {
3034 #[doc = "1-Day Capture"]
3035 #[inline(always)]
3036 pub fn date1(
3037 self,
3038 ) -> crate::common::RegisterField<0, 0xf, 1, 0, u8, u8, Rdaycp0_SPEC, crate::common::R> {
3039 crate::common::RegisterField::<0,0xf,1,0,u8,u8,Rdaycp0_SPEC,crate::common::R>::from_register(self,0)
3040 }
3041
3042 #[doc = "10-Day Capture"]
3043 #[inline(always)]
3044 pub fn date10(
3045 self,
3046 ) -> crate::common::RegisterField<4, 0x3, 1, 0, u8, u8, Rdaycp0_SPEC, crate::common::R> {
3047 crate::common::RegisterField::<4,0x3,1,0,u8,u8,Rdaycp0_SPEC,crate::common::R>::from_register(self,0)
3048 }
3049}
3050impl ::core::default::Default for Rdaycp0 {
3051 #[inline(always)]
3052 fn default() -> Rdaycp0 {
3053 <crate::RegValueT<Rdaycp0_SPEC> as RegisterValue<_>>::new(0)
3054 }
3055}
3056
3057#[doc(hidden)]
3058#[derive(Copy, Clone, Eq, PartialEq)]
3059pub struct Rmoncp0_SPEC;
3060impl crate::sealed::RegSpec for Rmoncp0_SPEC {
3061 type DataType = u8;
3062}
3063
3064#[doc = "Month Capture Register 0"]
3065pub type Rmoncp0 = crate::RegValueT<Rmoncp0_SPEC>;
3066
3067impl Rmoncp0 {
3068 #[doc = "1-Month Capture"]
3069 #[inline(always)]
3070 pub fn mon1(
3071 self,
3072 ) -> crate::common::RegisterField<0, 0xf, 1, 0, u8, u8, Rmoncp0_SPEC, crate::common::R> {
3073 crate::common::RegisterField::<0,0xf,1,0,u8,u8,Rmoncp0_SPEC,crate::common::R>::from_register(self,0)
3074 }
3075
3076 #[doc = "10-Month Capture"]
3077 #[inline(always)]
3078 pub fn mon10(
3079 self,
3080 ) -> crate::common::RegisterFieldBool<4, 1, 0, Rmoncp0_SPEC, crate::common::R> {
3081 crate::common::RegisterFieldBool::<4, 1, 0, Rmoncp0_SPEC, crate::common::R>::from_register(
3082 self, 0,
3083 )
3084 }
3085}
3086impl ::core::default::Default for Rmoncp0 {
3087 #[inline(always)]
3088 fn default() -> Rmoncp0 {
3089 <crate::RegValueT<Rmoncp0_SPEC> as RegisterValue<_>>::new(0)
3090 }
3091}