stm32l4x6/pwr/
pucrd.rs

1#[doc = r" Value read from the register"]
2pub struct R {
3    bits: u32,
4}
5#[doc = r" Value to write to the register"]
6pub struct W {
7    bits: u32,
8}
9impl super::PUCRD {
10    #[doc = r" Modifies the contents of the register"]
11    #[inline]
12    pub fn modify<F>(&self, f: F)
13    where
14        for<'w> F: FnOnce(&R, &'w mut W) -> &'w mut W,
15    {
16        let bits = self.register.get();
17        let r = R { bits: bits };
18        let mut w = W { bits: bits };
19        f(&r, &mut w);
20        self.register.set(w.bits);
21    }
22    #[doc = r" Reads the contents of the register"]
23    #[inline]
24    pub fn read(&self) -> R {
25        R {
26            bits: self.register.get(),
27        }
28    }
29    #[doc = r" Writes to the register"]
30    #[inline]
31    pub fn write<F>(&self, f: F)
32    where
33        F: FnOnce(&mut W) -> &mut W,
34    {
35        let mut w = W::reset_value();
36        f(&mut w);
37        self.register.set(w.bits);
38    }
39    #[doc = r" Writes the reset value to the register"]
40    #[inline]
41    pub fn reset(&self) {
42        self.write(|w| w)
43    }
44}
45#[doc = r" Value of the field"]
46pub struct PU15R {
47    bits: bool,
48}
49impl PU15R {
50    #[doc = r" Value of the field as raw bits"]
51    #[inline]
52    pub fn bit(&self) -> bool {
53        self.bits
54    }
55    #[doc = r" Returns `true` if the bit is clear (0)"]
56    #[inline]
57    pub fn bit_is_clear(&self) -> bool {
58        !self.bit()
59    }
60    #[doc = r" Returns `true` if the bit is set (1)"]
61    #[inline]
62    pub fn bit_is_set(&self) -> bool {
63        self.bit()
64    }
65}
66#[doc = r" Value of the field"]
67pub struct PU14R {
68    bits: bool,
69}
70impl PU14R {
71    #[doc = r" Value of the field as raw bits"]
72    #[inline]
73    pub fn bit(&self) -> bool {
74        self.bits
75    }
76    #[doc = r" Returns `true` if the bit is clear (0)"]
77    #[inline]
78    pub fn bit_is_clear(&self) -> bool {
79        !self.bit()
80    }
81    #[doc = r" Returns `true` if the bit is set (1)"]
82    #[inline]
83    pub fn bit_is_set(&self) -> bool {
84        self.bit()
85    }
86}
87#[doc = r" Value of the field"]
88pub struct PU13R {
89    bits: bool,
90}
91impl PU13R {
92    #[doc = r" Value of the field as raw bits"]
93    #[inline]
94    pub fn bit(&self) -> bool {
95        self.bits
96    }
97    #[doc = r" Returns `true` if the bit is clear (0)"]
98    #[inline]
99    pub fn bit_is_clear(&self) -> bool {
100        !self.bit()
101    }
102    #[doc = r" Returns `true` if the bit is set (1)"]
103    #[inline]
104    pub fn bit_is_set(&self) -> bool {
105        self.bit()
106    }
107}
108#[doc = r" Value of the field"]
109pub struct PU12R {
110    bits: bool,
111}
112impl PU12R {
113    #[doc = r" Value of the field as raw bits"]
114    #[inline]
115    pub fn bit(&self) -> bool {
116        self.bits
117    }
118    #[doc = r" Returns `true` if the bit is clear (0)"]
119    #[inline]
120    pub fn bit_is_clear(&self) -> bool {
121        !self.bit()
122    }
123    #[doc = r" Returns `true` if the bit is set (1)"]
124    #[inline]
125    pub fn bit_is_set(&self) -> bool {
126        self.bit()
127    }
128}
129#[doc = r" Value of the field"]
130pub struct PU11R {
131    bits: bool,
132}
133impl PU11R {
134    #[doc = r" Value of the field as raw bits"]
135    #[inline]
136    pub fn bit(&self) -> bool {
137        self.bits
138    }
139    #[doc = r" Returns `true` if the bit is clear (0)"]
140    #[inline]
141    pub fn bit_is_clear(&self) -> bool {
142        !self.bit()
143    }
144    #[doc = r" Returns `true` if the bit is set (1)"]
145    #[inline]
146    pub fn bit_is_set(&self) -> bool {
147        self.bit()
148    }
149}
150#[doc = r" Value of the field"]
151pub struct PU10R {
152    bits: bool,
153}
154impl PU10R {
155    #[doc = r" Value of the field as raw bits"]
156    #[inline]
157    pub fn bit(&self) -> bool {
158        self.bits
159    }
160    #[doc = r" Returns `true` if the bit is clear (0)"]
161    #[inline]
162    pub fn bit_is_clear(&self) -> bool {
163        !self.bit()
164    }
165    #[doc = r" Returns `true` if the bit is set (1)"]
166    #[inline]
167    pub fn bit_is_set(&self) -> bool {
168        self.bit()
169    }
170}
171#[doc = r" Value of the field"]
172pub struct PU9R {
173    bits: bool,
174}
175impl PU9R {
176    #[doc = r" Value of the field as raw bits"]
177    #[inline]
178    pub fn bit(&self) -> bool {
179        self.bits
180    }
181    #[doc = r" Returns `true` if the bit is clear (0)"]
182    #[inline]
183    pub fn bit_is_clear(&self) -> bool {
184        !self.bit()
185    }
186    #[doc = r" Returns `true` if the bit is set (1)"]
187    #[inline]
188    pub fn bit_is_set(&self) -> bool {
189        self.bit()
190    }
191}
192#[doc = r" Value of the field"]
193pub struct PU8R {
194    bits: bool,
195}
196impl PU8R {
197    #[doc = r" Value of the field as raw bits"]
198    #[inline]
199    pub fn bit(&self) -> bool {
200        self.bits
201    }
202    #[doc = r" Returns `true` if the bit is clear (0)"]
203    #[inline]
204    pub fn bit_is_clear(&self) -> bool {
205        !self.bit()
206    }
207    #[doc = r" Returns `true` if the bit is set (1)"]
208    #[inline]
209    pub fn bit_is_set(&self) -> bool {
210        self.bit()
211    }
212}
213#[doc = r" Value of the field"]
214pub struct PU7R {
215    bits: bool,
216}
217impl PU7R {
218    #[doc = r" Value of the field as raw bits"]
219    #[inline]
220    pub fn bit(&self) -> bool {
221        self.bits
222    }
223    #[doc = r" Returns `true` if the bit is clear (0)"]
224    #[inline]
225    pub fn bit_is_clear(&self) -> bool {
226        !self.bit()
227    }
228    #[doc = r" Returns `true` if the bit is set (1)"]
229    #[inline]
230    pub fn bit_is_set(&self) -> bool {
231        self.bit()
232    }
233}
234#[doc = r" Value of the field"]
235pub struct PU6R {
236    bits: bool,
237}
238impl PU6R {
239    #[doc = r" Value of the field as raw bits"]
240    #[inline]
241    pub fn bit(&self) -> bool {
242        self.bits
243    }
244    #[doc = r" Returns `true` if the bit is clear (0)"]
245    #[inline]
246    pub fn bit_is_clear(&self) -> bool {
247        !self.bit()
248    }
249    #[doc = r" Returns `true` if the bit is set (1)"]
250    #[inline]
251    pub fn bit_is_set(&self) -> bool {
252        self.bit()
253    }
254}
255#[doc = r" Value of the field"]
256pub struct PU5R {
257    bits: bool,
258}
259impl PU5R {
260    #[doc = r" Value of the field as raw bits"]
261    #[inline]
262    pub fn bit(&self) -> bool {
263        self.bits
264    }
265    #[doc = r" Returns `true` if the bit is clear (0)"]
266    #[inline]
267    pub fn bit_is_clear(&self) -> bool {
268        !self.bit()
269    }
270    #[doc = r" Returns `true` if the bit is set (1)"]
271    #[inline]
272    pub fn bit_is_set(&self) -> bool {
273        self.bit()
274    }
275}
276#[doc = r" Value of the field"]
277pub struct PU4R {
278    bits: bool,
279}
280impl PU4R {
281    #[doc = r" Value of the field as raw bits"]
282    #[inline]
283    pub fn bit(&self) -> bool {
284        self.bits
285    }
286    #[doc = r" Returns `true` if the bit is clear (0)"]
287    #[inline]
288    pub fn bit_is_clear(&self) -> bool {
289        !self.bit()
290    }
291    #[doc = r" Returns `true` if the bit is set (1)"]
292    #[inline]
293    pub fn bit_is_set(&self) -> bool {
294        self.bit()
295    }
296}
297#[doc = r" Value of the field"]
298pub struct PU3R {
299    bits: bool,
300}
301impl PU3R {
302    #[doc = r" Value of the field as raw bits"]
303    #[inline]
304    pub fn bit(&self) -> bool {
305        self.bits
306    }
307    #[doc = r" Returns `true` if the bit is clear (0)"]
308    #[inline]
309    pub fn bit_is_clear(&self) -> bool {
310        !self.bit()
311    }
312    #[doc = r" Returns `true` if the bit is set (1)"]
313    #[inline]
314    pub fn bit_is_set(&self) -> bool {
315        self.bit()
316    }
317}
318#[doc = r" Value of the field"]
319pub struct PU2R {
320    bits: bool,
321}
322impl PU2R {
323    #[doc = r" Value of the field as raw bits"]
324    #[inline]
325    pub fn bit(&self) -> bool {
326        self.bits
327    }
328    #[doc = r" Returns `true` if the bit is clear (0)"]
329    #[inline]
330    pub fn bit_is_clear(&self) -> bool {
331        !self.bit()
332    }
333    #[doc = r" Returns `true` if the bit is set (1)"]
334    #[inline]
335    pub fn bit_is_set(&self) -> bool {
336        self.bit()
337    }
338}
339#[doc = r" Value of the field"]
340pub struct PU1R {
341    bits: bool,
342}
343impl PU1R {
344    #[doc = r" Value of the field as raw bits"]
345    #[inline]
346    pub fn bit(&self) -> bool {
347        self.bits
348    }
349    #[doc = r" Returns `true` if the bit is clear (0)"]
350    #[inline]
351    pub fn bit_is_clear(&self) -> bool {
352        !self.bit()
353    }
354    #[doc = r" Returns `true` if the bit is set (1)"]
355    #[inline]
356    pub fn bit_is_set(&self) -> bool {
357        self.bit()
358    }
359}
360#[doc = r" Value of the field"]
361pub struct PU0R {
362    bits: bool,
363}
364impl PU0R {
365    #[doc = r" Value of the field as raw bits"]
366    #[inline]
367    pub fn bit(&self) -> bool {
368        self.bits
369    }
370    #[doc = r" Returns `true` if the bit is clear (0)"]
371    #[inline]
372    pub fn bit_is_clear(&self) -> bool {
373        !self.bit()
374    }
375    #[doc = r" Returns `true` if the bit is set (1)"]
376    #[inline]
377    pub fn bit_is_set(&self) -> bool {
378        self.bit()
379    }
380}
381#[doc = r" Proxy"]
382pub struct _PU15W<'a> {
383    w: &'a mut W,
384}
385impl<'a> _PU15W<'a> {
386    #[doc = r" Sets the field bit"]
387    pub fn set_bit(self) -> &'a mut W {
388        self.bit(true)
389    }
390    #[doc = r" Clears the field bit"]
391    pub fn clear_bit(self) -> &'a mut W {
392        self.bit(false)
393    }
394    #[doc = r" Writes raw bits to the field"]
395    #[inline]
396    pub fn bit(self, value: bool) -> &'a mut W {
397        const MASK: bool = true;
398        const OFFSET: u8 = 15;
399        self.w.bits &= !((MASK as u32) << OFFSET);
400        self.w.bits |= ((value & MASK) as u32) << OFFSET;
401        self.w
402    }
403}
404#[doc = r" Proxy"]
405pub struct _PU14W<'a> {
406    w: &'a mut W,
407}
408impl<'a> _PU14W<'a> {
409    #[doc = r" Sets the field bit"]
410    pub fn set_bit(self) -> &'a mut W {
411        self.bit(true)
412    }
413    #[doc = r" Clears the field bit"]
414    pub fn clear_bit(self) -> &'a mut W {
415        self.bit(false)
416    }
417    #[doc = r" Writes raw bits to the field"]
418    #[inline]
419    pub fn bit(self, value: bool) -> &'a mut W {
420        const MASK: bool = true;
421        const OFFSET: u8 = 14;
422        self.w.bits &= !((MASK as u32) << OFFSET);
423        self.w.bits |= ((value & MASK) as u32) << OFFSET;
424        self.w
425    }
426}
427#[doc = r" Proxy"]
428pub struct _PU13W<'a> {
429    w: &'a mut W,
430}
431impl<'a> _PU13W<'a> {
432    #[doc = r" Sets the field bit"]
433    pub fn set_bit(self) -> &'a mut W {
434        self.bit(true)
435    }
436    #[doc = r" Clears the field bit"]
437    pub fn clear_bit(self) -> &'a mut W {
438        self.bit(false)
439    }
440    #[doc = r" Writes raw bits to the field"]
441    #[inline]
442    pub fn bit(self, value: bool) -> &'a mut W {
443        const MASK: bool = true;
444        const OFFSET: u8 = 13;
445        self.w.bits &= !((MASK as u32) << OFFSET);
446        self.w.bits |= ((value & MASK) as u32) << OFFSET;
447        self.w
448    }
449}
450#[doc = r" Proxy"]
451pub struct _PU12W<'a> {
452    w: &'a mut W,
453}
454impl<'a> _PU12W<'a> {
455    #[doc = r" Sets the field bit"]
456    pub fn set_bit(self) -> &'a mut W {
457        self.bit(true)
458    }
459    #[doc = r" Clears the field bit"]
460    pub fn clear_bit(self) -> &'a mut W {
461        self.bit(false)
462    }
463    #[doc = r" Writes raw bits to the field"]
464    #[inline]
465    pub fn bit(self, value: bool) -> &'a mut W {
466        const MASK: bool = true;
467        const OFFSET: u8 = 12;
468        self.w.bits &= !((MASK as u32) << OFFSET);
469        self.w.bits |= ((value & MASK) as u32) << OFFSET;
470        self.w
471    }
472}
473#[doc = r" Proxy"]
474pub struct _PU11W<'a> {
475    w: &'a mut W,
476}
477impl<'a> _PU11W<'a> {
478    #[doc = r" Sets the field bit"]
479    pub fn set_bit(self) -> &'a mut W {
480        self.bit(true)
481    }
482    #[doc = r" Clears the field bit"]
483    pub fn clear_bit(self) -> &'a mut W {
484        self.bit(false)
485    }
486    #[doc = r" Writes raw bits to the field"]
487    #[inline]
488    pub fn bit(self, value: bool) -> &'a mut W {
489        const MASK: bool = true;
490        const OFFSET: u8 = 11;
491        self.w.bits &= !((MASK as u32) << OFFSET);
492        self.w.bits |= ((value & MASK) as u32) << OFFSET;
493        self.w
494    }
495}
496#[doc = r" Proxy"]
497pub struct _PU10W<'a> {
498    w: &'a mut W,
499}
500impl<'a> _PU10W<'a> {
501    #[doc = r" Sets the field bit"]
502    pub fn set_bit(self) -> &'a mut W {
503        self.bit(true)
504    }
505    #[doc = r" Clears the field bit"]
506    pub fn clear_bit(self) -> &'a mut W {
507        self.bit(false)
508    }
509    #[doc = r" Writes raw bits to the field"]
510    #[inline]
511    pub fn bit(self, value: bool) -> &'a mut W {
512        const MASK: bool = true;
513        const OFFSET: u8 = 10;
514        self.w.bits &= !((MASK as u32) << OFFSET);
515        self.w.bits |= ((value & MASK) as u32) << OFFSET;
516        self.w
517    }
518}
519#[doc = r" Proxy"]
520pub struct _PU9W<'a> {
521    w: &'a mut W,
522}
523impl<'a> _PU9W<'a> {
524    #[doc = r" Sets the field bit"]
525    pub fn set_bit(self) -> &'a mut W {
526        self.bit(true)
527    }
528    #[doc = r" Clears the field bit"]
529    pub fn clear_bit(self) -> &'a mut W {
530        self.bit(false)
531    }
532    #[doc = r" Writes raw bits to the field"]
533    #[inline]
534    pub fn bit(self, value: bool) -> &'a mut W {
535        const MASK: bool = true;
536        const OFFSET: u8 = 9;
537        self.w.bits &= !((MASK as u32) << OFFSET);
538        self.w.bits |= ((value & MASK) as u32) << OFFSET;
539        self.w
540    }
541}
542#[doc = r" Proxy"]
543pub struct _PU8W<'a> {
544    w: &'a mut W,
545}
546impl<'a> _PU8W<'a> {
547    #[doc = r" Sets the field bit"]
548    pub fn set_bit(self) -> &'a mut W {
549        self.bit(true)
550    }
551    #[doc = r" Clears the field bit"]
552    pub fn clear_bit(self) -> &'a mut W {
553        self.bit(false)
554    }
555    #[doc = r" Writes raw bits to the field"]
556    #[inline]
557    pub fn bit(self, value: bool) -> &'a mut W {
558        const MASK: bool = true;
559        const OFFSET: u8 = 8;
560        self.w.bits &= !((MASK as u32) << OFFSET);
561        self.w.bits |= ((value & MASK) as u32) << OFFSET;
562        self.w
563    }
564}
565#[doc = r" Proxy"]
566pub struct _PU7W<'a> {
567    w: &'a mut W,
568}
569impl<'a> _PU7W<'a> {
570    #[doc = r" Sets the field bit"]
571    pub fn set_bit(self) -> &'a mut W {
572        self.bit(true)
573    }
574    #[doc = r" Clears the field bit"]
575    pub fn clear_bit(self) -> &'a mut W {
576        self.bit(false)
577    }
578    #[doc = r" Writes raw bits to the field"]
579    #[inline]
580    pub fn bit(self, value: bool) -> &'a mut W {
581        const MASK: bool = true;
582        const OFFSET: u8 = 7;
583        self.w.bits &= !((MASK as u32) << OFFSET);
584        self.w.bits |= ((value & MASK) as u32) << OFFSET;
585        self.w
586    }
587}
588#[doc = r" Proxy"]
589pub struct _PU6W<'a> {
590    w: &'a mut W,
591}
592impl<'a> _PU6W<'a> {
593    #[doc = r" Sets the field bit"]
594    pub fn set_bit(self) -> &'a mut W {
595        self.bit(true)
596    }
597    #[doc = r" Clears the field bit"]
598    pub fn clear_bit(self) -> &'a mut W {
599        self.bit(false)
600    }
601    #[doc = r" Writes raw bits to the field"]
602    #[inline]
603    pub fn bit(self, value: bool) -> &'a mut W {
604        const MASK: bool = true;
605        const OFFSET: u8 = 6;
606        self.w.bits &= !((MASK as u32) << OFFSET);
607        self.w.bits |= ((value & MASK) as u32) << OFFSET;
608        self.w
609    }
610}
611#[doc = r" Proxy"]
612pub struct _PU5W<'a> {
613    w: &'a mut W,
614}
615impl<'a> _PU5W<'a> {
616    #[doc = r" Sets the field bit"]
617    pub fn set_bit(self) -> &'a mut W {
618        self.bit(true)
619    }
620    #[doc = r" Clears the field bit"]
621    pub fn clear_bit(self) -> &'a mut W {
622        self.bit(false)
623    }
624    #[doc = r" Writes raw bits to the field"]
625    #[inline]
626    pub fn bit(self, value: bool) -> &'a mut W {
627        const MASK: bool = true;
628        const OFFSET: u8 = 5;
629        self.w.bits &= !((MASK as u32) << OFFSET);
630        self.w.bits |= ((value & MASK) as u32) << OFFSET;
631        self.w
632    }
633}
634#[doc = r" Proxy"]
635pub struct _PU4W<'a> {
636    w: &'a mut W,
637}
638impl<'a> _PU4W<'a> {
639    #[doc = r" Sets the field bit"]
640    pub fn set_bit(self) -> &'a mut W {
641        self.bit(true)
642    }
643    #[doc = r" Clears the field bit"]
644    pub fn clear_bit(self) -> &'a mut W {
645        self.bit(false)
646    }
647    #[doc = r" Writes raw bits to the field"]
648    #[inline]
649    pub fn bit(self, value: bool) -> &'a mut W {
650        const MASK: bool = true;
651        const OFFSET: u8 = 4;
652        self.w.bits &= !((MASK as u32) << OFFSET);
653        self.w.bits |= ((value & MASK) as u32) << OFFSET;
654        self.w
655    }
656}
657#[doc = r" Proxy"]
658pub struct _PU3W<'a> {
659    w: &'a mut W,
660}
661impl<'a> _PU3W<'a> {
662    #[doc = r" Sets the field bit"]
663    pub fn set_bit(self) -> &'a mut W {
664        self.bit(true)
665    }
666    #[doc = r" Clears the field bit"]
667    pub fn clear_bit(self) -> &'a mut W {
668        self.bit(false)
669    }
670    #[doc = r" Writes raw bits to the field"]
671    #[inline]
672    pub fn bit(self, value: bool) -> &'a mut W {
673        const MASK: bool = true;
674        const OFFSET: u8 = 3;
675        self.w.bits &= !((MASK as u32) << OFFSET);
676        self.w.bits |= ((value & MASK) as u32) << OFFSET;
677        self.w
678    }
679}
680#[doc = r" Proxy"]
681pub struct _PU2W<'a> {
682    w: &'a mut W,
683}
684impl<'a> _PU2W<'a> {
685    #[doc = r" Sets the field bit"]
686    pub fn set_bit(self) -> &'a mut W {
687        self.bit(true)
688    }
689    #[doc = r" Clears the field bit"]
690    pub fn clear_bit(self) -> &'a mut W {
691        self.bit(false)
692    }
693    #[doc = r" Writes raw bits to the field"]
694    #[inline]
695    pub fn bit(self, value: bool) -> &'a mut W {
696        const MASK: bool = true;
697        const OFFSET: u8 = 2;
698        self.w.bits &= !((MASK as u32) << OFFSET);
699        self.w.bits |= ((value & MASK) as u32) << OFFSET;
700        self.w
701    }
702}
703#[doc = r" Proxy"]
704pub struct _PU1W<'a> {
705    w: &'a mut W,
706}
707impl<'a> _PU1W<'a> {
708    #[doc = r" Sets the field bit"]
709    pub fn set_bit(self) -> &'a mut W {
710        self.bit(true)
711    }
712    #[doc = r" Clears the field bit"]
713    pub fn clear_bit(self) -> &'a mut W {
714        self.bit(false)
715    }
716    #[doc = r" Writes raw bits to the field"]
717    #[inline]
718    pub fn bit(self, value: bool) -> &'a mut W {
719        const MASK: bool = true;
720        const OFFSET: u8 = 1;
721        self.w.bits &= !((MASK as u32) << OFFSET);
722        self.w.bits |= ((value & MASK) as u32) << OFFSET;
723        self.w
724    }
725}
726#[doc = r" Proxy"]
727pub struct _PU0W<'a> {
728    w: &'a mut W,
729}
730impl<'a> _PU0W<'a> {
731    #[doc = r" Sets the field bit"]
732    pub fn set_bit(self) -> &'a mut W {
733        self.bit(true)
734    }
735    #[doc = r" Clears the field bit"]
736    pub fn clear_bit(self) -> &'a mut W {
737        self.bit(false)
738    }
739    #[doc = r" Writes raw bits to the field"]
740    #[inline]
741    pub fn bit(self, value: bool) -> &'a mut W {
742        const MASK: bool = true;
743        const OFFSET: u8 = 0;
744        self.w.bits &= !((MASK as u32) << OFFSET);
745        self.w.bits |= ((value & MASK) as u32) << OFFSET;
746        self.w
747    }
748}
749impl R {
750    #[doc = r" Value of the register as raw bits"]
751    #[inline]
752    pub fn bits(&self) -> u32 {
753        self.bits
754    }
755    #[doc = "Bit 15 - Port D pull-up bit y (y=0..15)"]
756    #[inline]
757    pub fn pu15(&self) -> PU15R {
758        let bits = {
759            const MASK: bool = true;
760            const OFFSET: u8 = 15;
761            ((self.bits >> OFFSET) & MASK as u32) != 0
762        };
763        PU15R { bits }
764    }
765    #[doc = "Bit 14 - Port D pull-up bit y (y=0..15)"]
766    #[inline]
767    pub fn pu14(&self) -> PU14R {
768        let bits = {
769            const MASK: bool = true;
770            const OFFSET: u8 = 14;
771            ((self.bits >> OFFSET) & MASK as u32) != 0
772        };
773        PU14R { bits }
774    }
775    #[doc = "Bit 13 - Port D pull-up bit y (y=0..15)"]
776    #[inline]
777    pub fn pu13(&self) -> PU13R {
778        let bits = {
779            const MASK: bool = true;
780            const OFFSET: u8 = 13;
781            ((self.bits >> OFFSET) & MASK as u32) != 0
782        };
783        PU13R { bits }
784    }
785    #[doc = "Bit 12 - Port D pull-up bit y (y=0..15)"]
786    #[inline]
787    pub fn pu12(&self) -> PU12R {
788        let bits = {
789            const MASK: bool = true;
790            const OFFSET: u8 = 12;
791            ((self.bits >> OFFSET) & MASK as u32) != 0
792        };
793        PU12R { bits }
794    }
795    #[doc = "Bit 11 - Port D pull-up bit y (y=0..15)"]
796    #[inline]
797    pub fn pu11(&self) -> PU11R {
798        let bits = {
799            const MASK: bool = true;
800            const OFFSET: u8 = 11;
801            ((self.bits >> OFFSET) & MASK as u32) != 0
802        };
803        PU11R { bits }
804    }
805    #[doc = "Bit 10 - Port D pull-up bit y (y=0..15)"]
806    #[inline]
807    pub fn pu10(&self) -> PU10R {
808        let bits = {
809            const MASK: bool = true;
810            const OFFSET: u8 = 10;
811            ((self.bits >> OFFSET) & MASK as u32) != 0
812        };
813        PU10R { bits }
814    }
815    #[doc = "Bit 9 - Port D pull-up bit y (y=0..15)"]
816    #[inline]
817    pub fn pu9(&self) -> PU9R {
818        let bits = {
819            const MASK: bool = true;
820            const OFFSET: u8 = 9;
821            ((self.bits >> OFFSET) & MASK as u32) != 0
822        };
823        PU9R { bits }
824    }
825    #[doc = "Bit 8 - Port D pull-up bit y (y=0..15)"]
826    #[inline]
827    pub fn pu8(&self) -> PU8R {
828        let bits = {
829            const MASK: bool = true;
830            const OFFSET: u8 = 8;
831            ((self.bits >> OFFSET) & MASK as u32) != 0
832        };
833        PU8R { bits }
834    }
835    #[doc = "Bit 7 - Port D pull-up bit y (y=0..15)"]
836    #[inline]
837    pub fn pu7(&self) -> PU7R {
838        let bits = {
839            const MASK: bool = true;
840            const OFFSET: u8 = 7;
841            ((self.bits >> OFFSET) & MASK as u32) != 0
842        };
843        PU7R { bits }
844    }
845    #[doc = "Bit 6 - Port D pull-up bit y (y=0..15)"]
846    #[inline]
847    pub fn pu6(&self) -> PU6R {
848        let bits = {
849            const MASK: bool = true;
850            const OFFSET: u8 = 6;
851            ((self.bits >> OFFSET) & MASK as u32) != 0
852        };
853        PU6R { bits }
854    }
855    #[doc = "Bit 5 - Port D pull-up bit y (y=0..15)"]
856    #[inline]
857    pub fn pu5(&self) -> PU5R {
858        let bits = {
859            const MASK: bool = true;
860            const OFFSET: u8 = 5;
861            ((self.bits >> OFFSET) & MASK as u32) != 0
862        };
863        PU5R { bits }
864    }
865    #[doc = "Bit 4 - Port D pull-up bit y (y=0..15)"]
866    #[inline]
867    pub fn pu4(&self) -> PU4R {
868        let bits = {
869            const MASK: bool = true;
870            const OFFSET: u8 = 4;
871            ((self.bits >> OFFSET) & MASK as u32) != 0
872        };
873        PU4R { bits }
874    }
875    #[doc = "Bit 3 - Port D pull-up bit y (y=0..15)"]
876    #[inline]
877    pub fn pu3(&self) -> PU3R {
878        let bits = {
879            const MASK: bool = true;
880            const OFFSET: u8 = 3;
881            ((self.bits >> OFFSET) & MASK as u32) != 0
882        };
883        PU3R { bits }
884    }
885    #[doc = "Bit 2 - Port D pull-up bit y (y=0..15)"]
886    #[inline]
887    pub fn pu2(&self) -> PU2R {
888        let bits = {
889            const MASK: bool = true;
890            const OFFSET: u8 = 2;
891            ((self.bits >> OFFSET) & MASK as u32) != 0
892        };
893        PU2R { bits }
894    }
895    #[doc = "Bit 1 - Port D pull-up bit y (y=0..15)"]
896    #[inline]
897    pub fn pu1(&self) -> PU1R {
898        let bits = {
899            const MASK: bool = true;
900            const OFFSET: u8 = 1;
901            ((self.bits >> OFFSET) & MASK as u32) != 0
902        };
903        PU1R { bits }
904    }
905    #[doc = "Bit 0 - Port D pull-up bit y (y=0..15)"]
906    #[inline]
907    pub fn pu0(&self) -> PU0R {
908        let bits = {
909            const MASK: bool = true;
910            const OFFSET: u8 = 0;
911            ((self.bits >> OFFSET) & MASK as u32) != 0
912        };
913        PU0R { bits }
914    }
915}
916impl W {
917    #[doc = r" Reset value of the register"]
918    #[inline]
919    pub fn reset_value() -> W {
920        W { bits: 0 }
921    }
922    #[doc = r" Writes raw bits to the register"]
923    #[inline]
924    pub unsafe fn bits(&mut self, bits: u32) -> &mut Self {
925        self.bits = bits;
926        self
927    }
928    #[doc = "Bit 15 - Port D pull-up bit y (y=0..15)"]
929    #[inline]
930    pub fn pu15(&mut self) -> _PU15W {
931        _PU15W { w: self }
932    }
933    #[doc = "Bit 14 - Port D pull-up bit y (y=0..15)"]
934    #[inline]
935    pub fn pu14(&mut self) -> _PU14W {
936        _PU14W { w: self }
937    }
938    #[doc = "Bit 13 - Port D pull-up bit y (y=0..15)"]
939    #[inline]
940    pub fn pu13(&mut self) -> _PU13W {
941        _PU13W { w: self }
942    }
943    #[doc = "Bit 12 - Port D pull-up bit y (y=0..15)"]
944    #[inline]
945    pub fn pu12(&mut self) -> _PU12W {
946        _PU12W { w: self }
947    }
948    #[doc = "Bit 11 - Port D pull-up bit y (y=0..15)"]
949    #[inline]
950    pub fn pu11(&mut self) -> _PU11W {
951        _PU11W { w: self }
952    }
953    #[doc = "Bit 10 - Port D pull-up bit y (y=0..15)"]
954    #[inline]
955    pub fn pu10(&mut self) -> _PU10W {
956        _PU10W { w: self }
957    }
958    #[doc = "Bit 9 - Port D pull-up bit y (y=0..15)"]
959    #[inline]
960    pub fn pu9(&mut self) -> _PU9W {
961        _PU9W { w: self }
962    }
963    #[doc = "Bit 8 - Port D pull-up bit y (y=0..15)"]
964    #[inline]
965    pub fn pu8(&mut self) -> _PU8W {
966        _PU8W { w: self }
967    }
968    #[doc = "Bit 7 - Port D pull-up bit y (y=0..15)"]
969    #[inline]
970    pub fn pu7(&mut self) -> _PU7W {
971        _PU7W { w: self }
972    }
973    #[doc = "Bit 6 - Port D pull-up bit y (y=0..15)"]
974    #[inline]
975    pub fn pu6(&mut self) -> _PU6W {
976        _PU6W { w: self }
977    }
978    #[doc = "Bit 5 - Port D pull-up bit y (y=0..15)"]
979    #[inline]
980    pub fn pu5(&mut self) -> _PU5W {
981        _PU5W { w: self }
982    }
983    #[doc = "Bit 4 - Port D pull-up bit y (y=0..15)"]
984    #[inline]
985    pub fn pu4(&mut self) -> _PU4W {
986        _PU4W { w: self }
987    }
988    #[doc = "Bit 3 - Port D pull-up bit y (y=0..15)"]
989    #[inline]
990    pub fn pu3(&mut self) -> _PU3W {
991        _PU3W { w: self }
992    }
993    #[doc = "Bit 2 - Port D pull-up bit y (y=0..15)"]
994    #[inline]
995    pub fn pu2(&mut self) -> _PU2W {
996        _PU2W { w: self }
997    }
998    #[doc = "Bit 1 - Port D pull-up bit y (y=0..15)"]
999    #[inline]
1000    pub fn pu1(&mut self) -> _PU1W {
1001        _PU1W { w: self }
1002    }
1003    #[doc = "Bit 0 - Port D pull-up bit y (y=0..15)"]
1004    #[inline]
1005    pub fn pu0(&mut self) -> _PU0W {
1006        _PU0W { w: self }
1007    }
1008}