nuc1xx/gcr/
gpc_mfp.rs

1#[doc = "Reader of register GPC_MFP"]
2pub type R = crate::R<u32, super::GPC_MFP>;
3#[doc = "Writer for register GPC_MFP"]
4pub type W = crate::W<u32, super::GPC_MFP>;
5#[doc = "Register GPC_MFP `reset()`'s with value 0"]
6impl crate::ResetValue for super::GPC_MFP {
7    type Type = u32;
8    #[inline(always)]
9    fn reset_value() -> Self::Type {
10        0
11    }
12}
13#[doc = "Reader of field `SPI0_SS0_I2SLRCLK`"]
14pub type SPI0_SS0_I2SLRCLK_R = crate::R<bool, bool>;
15#[doc = "Write proxy for field `SPI0_SS0_I2SLRCLK`"]
16pub struct SPI0_SS0_I2SLRCLK_W<'a> {
17    w: &'a mut W,
18}
19impl<'a> SPI0_SS0_I2SLRCLK_W<'a> {
20    #[doc = r"Sets the field bit"]
21    #[inline(always)]
22    pub fn set_bit(self) -> &'a mut W {
23        self.bit(true)
24    }
25    #[doc = r"Clears the field bit"]
26    #[inline(always)]
27    pub fn clear_bit(self) -> &'a mut W {
28        self.bit(false)
29    }
30    #[doc = r"Writes raw bits to the field"]
31    #[inline(always)]
32    pub fn bit(self, value: bool) -> &'a mut W {
33        self.w.bits = (self.w.bits & !0x01) | ((value as u32) & 0x01);
34        self.w
35    }
36}
37#[doc = "Reader of field `SPI0_CLK_I2SBCLK`"]
38pub type SPI0_CLK_I2SBCLK_R = crate::R<bool, bool>;
39#[doc = "Write proxy for field `SPI0_CLK_I2SBCLK`"]
40pub struct SPI0_CLK_I2SBCLK_W<'a> {
41    w: &'a mut W,
42}
43impl<'a> SPI0_CLK_I2SBCLK_W<'a> {
44    #[doc = r"Sets the field bit"]
45    #[inline(always)]
46    pub fn set_bit(self) -> &'a mut W {
47        self.bit(true)
48    }
49    #[doc = r"Clears the field bit"]
50    #[inline(always)]
51    pub fn clear_bit(self) -> &'a mut W {
52        self.bit(false)
53    }
54    #[doc = r"Writes raw bits to the field"]
55    #[inline(always)]
56    pub fn bit(self, value: bool) -> &'a mut W {
57        self.w.bits = (self.w.bits & !(0x01 << 1)) | (((value as u32) & 0x01) << 1);
58        self.w
59    }
60}
61#[doc = "Reader of field `SPI0_MISO0_I2SDI`"]
62pub type SPI0_MISO0_I2SDI_R = crate::R<bool, bool>;
63#[doc = "Write proxy for field `SPI0_MISO0_I2SDI`"]
64pub struct SPI0_MISO0_I2SDI_W<'a> {
65    w: &'a mut W,
66}
67impl<'a> SPI0_MISO0_I2SDI_W<'a> {
68    #[doc = r"Sets the field bit"]
69    #[inline(always)]
70    pub fn set_bit(self) -> &'a mut W {
71        self.bit(true)
72    }
73    #[doc = r"Clears the field bit"]
74    #[inline(always)]
75    pub fn clear_bit(self) -> &'a mut W {
76        self.bit(false)
77    }
78    #[doc = r"Writes raw bits to the field"]
79    #[inline(always)]
80    pub fn bit(self, value: bool) -> &'a mut W {
81        self.w.bits = (self.w.bits & !(0x01 << 2)) | (((value as u32) & 0x01) << 2);
82        self.w
83    }
84}
85#[doc = "Reader of field `SPI0_MOSI0_I2SDO`"]
86pub type SPI0_MOSI0_I2SDO_R = crate::R<bool, bool>;
87#[doc = "Write proxy for field `SPI0_MOSI0_I2SDO`"]
88pub struct SPI0_MOSI0_I2SDO_W<'a> {
89    w: &'a mut W,
90}
91impl<'a> SPI0_MOSI0_I2SDO_W<'a> {
92    #[doc = r"Sets the field bit"]
93    #[inline(always)]
94    pub fn set_bit(self) -> &'a mut W {
95        self.bit(true)
96    }
97    #[doc = r"Clears the field bit"]
98    #[inline(always)]
99    pub fn clear_bit(self) -> &'a mut W {
100        self.bit(false)
101    }
102    #[doc = r"Writes raw bits to the field"]
103    #[inline(always)]
104    pub fn bit(self, value: bool) -> &'a mut W {
105        self.w.bits = (self.w.bits & !(0x01 << 3)) | (((value as u32) & 0x01) << 3);
106        self.w
107    }
108}
109#[doc = "Reader of field `SPI0_MISO1`"]
110pub type SPI0_MISO1_R = crate::R<bool, bool>;
111#[doc = "Write proxy for field `SPI0_MISO1`"]
112pub struct SPI0_MISO1_W<'a> {
113    w: &'a mut W,
114}
115impl<'a> SPI0_MISO1_W<'a> {
116    #[doc = r"Sets the field bit"]
117    #[inline(always)]
118    pub fn set_bit(self) -> &'a mut W {
119        self.bit(true)
120    }
121    #[doc = r"Clears the field bit"]
122    #[inline(always)]
123    pub fn clear_bit(self) -> &'a mut W {
124        self.bit(false)
125    }
126    #[doc = r"Writes raw bits to the field"]
127    #[inline(always)]
128    pub fn bit(self, value: bool) -> &'a mut W {
129        self.w.bits = (self.w.bits & !(0x01 << 4)) | (((value as u32) & 0x01) << 4);
130        self.w
131    }
132}
133#[doc = "Reader of field `SPI0_MOSI1`"]
134pub type SPI0_MOSI1_R = crate::R<bool, bool>;
135#[doc = "Write proxy for field `SPI0_MOSI1`"]
136pub struct SPI0_MOSI1_W<'a> {
137    w: &'a mut W,
138}
139impl<'a> SPI0_MOSI1_W<'a> {
140    #[doc = r"Sets the field bit"]
141    #[inline(always)]
142    pub fn set_bit(self) -> &'a mut W {
143        self.bit(true)
144    }
145    #[doc = r"Clears the field bit"]
146    #[inline(always)]
147    pub fn clear_bit(self) -> &'a mut W {
148        self.bit(false)
149    }
150    #[doc = r"Writes raw bits to the field"]
151    #[inline(always)]
152    pub fn bit(self, value: bool) -> &'a mut W {
153        self.w.bits = (self.w.bits & !(0x01 << 5)) | (((value as u32) & 0x01) << 5);
154        self.w
155    }
156}
157#[doc = "Reader of field `CPP0_AD4`"]
158pub type CPP0_AD4_R = crate::R<bool, bool>;
159#[doc = "Write proxy for field `CPP0_AD4`"]
160pub struct CPP0_AD4_W<'a> {
161    w: &'a mut W,
162}
163impl<'a> CPP0_AD4_W<'a> {
164    #[doc = r"Sets the field bit"]
165    #[inline(always)]
166    pub fn set_bit(self) -> &'a mut W {
167        self.bit(true)
168    }
169    #[doc = r"Clears the field bit"]
170    #[inline(always)]
171    pub fn clear_bit(self) -> &'a mut W {
172        self.bit(false)
173    }
174    #[doc = r"Writes raw bits to the field"]
175    #[inline(always)]
176    pub fn bit(self, value: bool) -> &'a mut W {
177        self.w.bits = (self.w.bits & !(0x01 << 6)) | (((value as u32) & 0x01) << 6);
178        self.w
179    }
180}
181#[doc = "Reader of field `CPN0_AD5`"]
182pub type CPN0_AD5_R = crate::R<bool, bool>;
183#[doc = "Write proxy for field `CPN0_AD5`"]
184pub struct CPN0_AD5_W<'a> {
185    w: &'a mut W,
186}
187impl<'a> CPN0_AD5_W<'a> {
188    #[doc = r"Sets the field bit"]
189    #[inline(always)]
190    pub fn set_bit(self) -> &'a mut W {
191        self.bit(true)
192    }
193    #[doc = r"Clears the field bit"]
194    #[inline(always)]
195    pub fn clear_bit(self) -> &'a mut W {
196        self.bit(false)
197    }
198    #[doc = r"Writes raw bits to the field"]
199    #[inline(always)]
200    pub fn bit(self, value: bool) -> &'a mut W {
201        self.w.bits = (self.w.bits & !(0x01 << 7)) | (((value as u32) & 0x01) << 7);
202        self.w
203    }
204}
205#[doc = "Reader of field `SPI1_SS0_MCLK`"]
206pub type SPI1_SS0_MCLK_R = crate::R<bool, bool>;
207#[doc = "Write proxy for field `SPI1_SS0_MCLK`"]
208pub struct SPI1_SS0_MCLK_W<'a> {
209    w: &'a mut W,
210}
211impl<'a> SPI1_SS0_MCLK_W<'a> {
212    #[doc = r"Sets the field bit"]
213    #[inline(always)]
214    pub fn set_bit(self) -> &'a mut W {
215        self.bit(true)
216    }
217    #[doc = r"Clears the field bit"]
218    #[inline(always)]
219    pub fn clear_bit(self) -> &'a mut W {
220        self.bit(false)
221    }
222    #[doc = r"Writes raw bits to the field"]
223    #[inline(always)]
224    pub fn bit(self, value: bool) -> &'a mut W {
225        self.w.bits = (self.w.bits & !(0x01 << 8)) | (((value as u32) & 0x01) << 8);
226        self.w
227    }
228}
229#[doc = "Reader of field `SPI1_CLK`"]
230pub type SPI1_CLK_R = crate::R<bool, bool>;
231#[doc = "Write proxy for field `SPI1_CLK`"]
232pub struct SPI1_CLK_W<'a> {
233    w: &'a mut W,
234}
235impl<'a> SPI1_CLK_W<'a> {
236    #[doc = r"Sets the field bit"]
237    #[inline(always)]
238    pub fn set_bit(self) -> &'a mut W {
239        self.bit(true)
240    }
241    #[doc = r"Clears the field bit"]
242    #[inline(always)]
243    pub fn clear_bit(self) -> &'a mut W {
244        self.bit(false)
245    }
246    #[doc = r"Writes raw bits to the field"]
247    #[inline(always)]
248    pub fn bit(self, value: bool) -> &'a mut W {
249        self.w.bits = (self.w.bits & !(0x01 << 9)) | (((value as u32) & 0x01) << 9);
250        self.w
251    }
252}
253#[doc = "Reader of field `SPI1_MISO0`"]
254pub type SPI1_MISO0_R = crate::R<bool, bool>;
255#[doc = "Write proxy for field `SPI1_MISO0`"]
256pub struct SPI1_MISO0_W<'a> {
257    w: &'a mut W,
258}
259impl<'a> SPI1_MISO0_W<'a> {
260    #[doc = r"Sets the field bit"]
261    #[inline(always)]
262    pub fn set_bit(self) -> &'a mut W {
263        self.bit(true)
264    }
265    #[doc = r"Clears the field bit"]
266    #[inline(always)]
267    pub fn clear_bit(self) -> &'a mut W {
268        self.bit(false)
269    }
270    #[doc = r"Writes raw bits to the field"]
271    #[inline(always)]
272    pub fn bit(self, value: bool) -> &'a mut W {
273        self.w.bits = (self.w.bits & !(0x01 << 10)) | (((value as u32) & 0x01) << 10);
274        self.w
275    }
276}
277#[doc = "Reader of field `SPI1_MOSI0`"]
278pub type SPI1_MOSI0_R = crate::R<bool, bool>;
279#[doc = "Write proxy for field `SPI1_MOSI0`"]
280pub struct SPI1_MOSI0_W<'a> {
281    w: &'a mut W,
282}
283impl<'a> SPI1_MOSI0_W<'a> {
284    #[doc = r"Sets the field bit"]
285    #[inline(always)]
286    pub fn set_bit(self) -> &'a mut W {
287        self.bit(true)
288    }
289    #[doc = r"Clears the field bit"]
290    #[inline(always)]
291    pub fn clear_bit(self) -> &'a mut W {
292        self.bit(false)
293    }
294    #[doc = r"Writes raw bits to the field"]
295    #[inline(always)]
296    pub fn bit(self, value: bool) -> &'a mut W {
297        self.w.bits = (self.w.bits & !(0x01 << 11)) | (((value as u32) & 0x01) << 11);
298        self.w
299    }
300}
301#[doc = "Reader of field `SPI1_MISO1`"]
302pub type SPI1_MISO1_R = crate::R<bool, bool>;
303#[doc = "Write proxy for field `SPI1_MISO1`"]
304pub struct SPI1_MISO1_W<'a> {
305    w: &'a mut W,
306}
307impl<'a> SPI1_MISO1_W<'a> {
308    #[doc = r"Sets the field bit"]
309    #[inline(always)]
310    pub fn set_bit(self) -> &'a mut W {
311        self.bit(true)
312    }
313    #[doc = r"Clears the field bit"]
314    #[inline(always)]
315    pub fn clear_bit(self) -> &'a mut W {
316        self.bit(false)
317    }
318    #[doc = r"Writes raw bits to the field"]
319    #[inline(always)]
320    pub fn bit(self, value: bool) -> &'a mut W {
321        self.w.bits = (self.w.bits & !(0x01 << 12)) | (((value as u32) & 0x01) << 12);
322        self.w
323    }
324}
325#[doc = "Reader of field `SPI1_MOSI1`"]
326pub type SPI1_MOSI1_R = crate::R<bool, bool>;
327#[doc = "Write proxy for field `SPI1_MOSI1`"]
328pub struct SPI1_MOSI1_W<'a> {
329    w: &'a mut W,
330}
331impl<'a> SPI1_MOSI1_W<'a> {
332    #[doc = r"Sets the field bit"]
333    #[inline(always)]
334    pub fn set_bit(self) -> &'a mut W {
335        self.bit(true)
336    }
337    #[doc = r"Clears the field bit"]
338    #[inline(always)]
339    pub fn clear_bit(self) -> &'a mut W {
340        self.bit(false)
341    }
342    #[doc = r"Writes raw bits to the field"]
343    #[inline(always)]
344    pub fn bit(self, value: bool) -> &'a mut W {
345        self.w.bits = (self.w.bits & !(0x01 << 13)) | (((value as u32) & 0x01) << 13);
346        self.w
347    }
348}
349#[doc = "Reader of field `CPP1_AD2`"]
350pub type CPP1_AD2_R = crate::R<bool, bool>;
351#[doc = "Write proxy for field `CPP1_AD2`"]
352pub struct CPP1_AD2_W<'a> {
353    w: &'a mut W,
354}
355impl<'a> CPP1_AD2_W<'a> {
356    #[doc = r"Sets the field bit"]
357    #[inline(always)]
358    pub fn set_bit(self) -> &'a mut W {
359        self.bit(true)
360    }
361    #[doc = r"Clears the field bit"]
362    #[inline(always)]
363    pub fn clear_bit(self) -> &'a mut W {
364        self.bit(false)
365    }
366    #[doc = r"Writes raw bits to the field"]
367    #[inline(always)]
368    pub fn bit(self, value: bool) -> &'a mut W {
369        self.w.bits = (self.w.bits & !(0x01 << 14)) | (((value as u32) & 0x01) << 14);
370        self.w
371    }
372}
373#[doc = "Reader of field `CPP1_AD3`"]
374pub type CPP1_AD3_R = crate::R<bool, bool>;
375#[doc = "Write proxy for field `CPP1_AD3`"]
376pub struct CPP1_AD3_W<'a> {
377    w: &'a mut W,
378}
379impl<'a> CPP1_AD3_W<'a> {
380    #[doc = r"Sets the field bit"]
381    #[inline(always)]
382    pub fn set_bit(self) -> &'a mut W {
383        self.bit(true)
384    }
385    #[doc = r"Clears the field bit"]
386    #[inline(always)]
387    pub fn clear_bit(self) -> &'a mut W {
388        self.bit(false)
389    }
390    #[doc = r"Writes raw bits to the field"]
391    #[inline(always)]
392    pub fn bit(self, value: bool) -> &'a mut W {
393        self.w.bits = (self.w.bits & !(0x01 << 15)) | (((value as u32) & 0x01) << 15);
394        self.w
395    }
396}
397#[doc = "Reader of field `SCHMITT`"]
398pub type SCHMITT_R = crate::R<u16, u16>;
399#[doc = "Write proxy for field `SCHMITT`"]
400pub struct SCHMITT_W<'a> {
401    w: &'a mut W,
402}
403impl<'a> SCHMITT_W<'a> {
404    #[doc = r"Writes raw bits to the field"]
405    #[inline(always)]
406    pub unsafe fn bits(self, value: u16) -> &'a mut W {
407        self.w.bits = (self.w.bits & !(0xffff << 16)) | (((value as u32) & 0xffff) << 16);
408        self.w
409    }
410}
411impl R {
412    #[doc = "Bit 0 - PC.0 Pin Function Selection Bits PC0_I2SLRCLK (ALT_MFP\\[5\\]) and GPC_MFP\\[0\\]
413determine the PC.0 function. PC0_I2SLRCLK GPC_MFP\\[0\\]
414PC.0 function x 0 GPIO 0 1 SPISS00(SPI0) 1 1 I2SLRCLK (I2S)"]
415    #[inline(always)]
416    pub fn spi0_ss0_i2slrclk(&self) -> SPI0_SS0_I2SLRCLK_R {
417        SPI0_SS0_I2SLRCLK_R::new((self.bits & 0x01) != 0)
418    }
419    #[doc = "Bit 1 - PC.1 Pin Function Selection Bits PC1_I2SBCLK (ALT_MFP\\[6\\]) and GPC_MFP\\[1\\]
420determine the PC.1 function. PC1_I2SBCLK GPC_MFP\\[1\\]
421PC.1 function x 0 GPIO 0 1 SPICLK0 (SPI0) 1 1 I2SBLK (I2S)"]
422    #[inline(always)]
423    pub fn spi0_clk_i2sbclk(&self) -> SPI0_CLK_I2SBCLK_R {
424        SPI0_CLK_I2SBCLK_R::new(((self.bits >> 1) & 0x01) != 0)
425    }
426    #[doc = "Bit 2 - PC.2 Pin Function Selection Bits PC2_I2SDI (ALT_MFP\\[7\\]) and GPC_MFP\\[2\\]
427determine the PC.2 function. PC2_I2SDI GPC_MFP\\[2\\]
428PC.2 function x 0 GPIO 0 1 MISO00 (SPI0) 1 1 I2SDI (I2S)"]
429    #[inline(always)]
430    pub fn spi0_miso0_i2sdi(&self) -> SPI0_MISO0_I2SDI_R {
431        SPI0_MISO0_I2SDI_R::new(((self.bits >> 2) & 0x01) != 0)
432    }
433    #[doc = "Bit 3 - PC.3 Pin Function Selection Bits PC3_I2SDO (ALT_MFP\\[8\\]) and GPC_MFP\\[3\\]
434determine the PC.3 function. PC3_I2SDO GPC_MFP\\[3\\]
435PC.3 function x 0 GPIO 0 1 MOSI00 (SPI0) 1 1 I2SDO (I2S)"]
436    #[inline(always)]
437    pub fn spi0_mosi0_i2sdo(&self) -> SPI0_MOSI0_I2SDO_R {
438        SPI0_MOSI0_I2SDO_R::new(((self.bits >> 3) & 0x01) != 0)
439    }
440    #[doc = "Bit 4 - PC.4 Pin Function Selection 1 = The SPI0 MISO1 (master input, slave output pin-1) function is selected to the pin PC.4 0 = The GPIOC\\[4\\]
441is selected to the pin PC.4"]
442    #[inline(always)]
443    pub fn spi0_miso1(&self) -> SPI0_MISO1_R {
444        SPI0_MISO1_R::new(((self.bits >> 4) & 0x01) != 0)
445    }
446    #[doc = "Bit 5 - PC.5 Pin Function Selection 1 = The SPI0 MOSI1 (master output, slave input pin-1) function is selected to the pin PC.5 0 = The GPIOC\\[5\\]
447is selected to the pin PC.5"]
448    #[inline(always)]
449    pub fn spi0_mosi1(&self) -> SPI0_MOSI1_R {
450        SPI0_MOSI1_R::new(((self.bits >> 5) & 0x01) != 0)
451    }
452    #[doc = "Bit 6 - PC.6 Pin Function Selection The pin function depends on GPC_MFP6 and EBI_EN (ALT_MFP\\[11\\]). EBI_EN GPC_MFP\\[6\\]
453PC.6 function x 0 GPIO 0 1 CPP0 (CMP) 1 1 AD4 (EBI AD bus bit 4)"]
454    #[inline(always)]
455    pub fn cpp0_ad4(&self) -> CPP0_AD4_R {
456        CPP0_AD4_R::new(((self.bits >> 6) & 0x01) != 0)
457    }
458    #[doc = "Bit 7 - PC.7 Pin Function Selection The pin function depends on GPC_MFP7 and EBI_EN (ALT_MFP\\[11\\]). EBI_EN GPC_MFP\\[7\\]
459PC.7 function x 0 GPIO 0 1 CPN0 (CMP) 1 1 AD5 (EBI AD bus bit 5)"]
460    #[inline(always)]
461    pub fn cpn0_ad5(&self) -> CPN0_AD5_R {
462        CPN0_AD5_R::new(((self.bits >> 7) & 0x01) != 0)
463    }
464    #[doc = "Bit 8 - PC.8 Pin Function Selection The pin function depends on GPC_MFP8 and EBI_MCLK_EN (ALT_MFP\\[12\\]) and EBI_EN (ALT_MFP\\[11\\]). EBI_MCLK_EN EBI_EN GPC_MFP\\[8\\]
465PC.8 function x x 0 GPIO x 0 1 SPISS10 (SPI1) 0 1 1 SPISS10 (SPI1) 1 1 1 MCLK (EBI Clock output)"]
466    #[inline(always)]
467    pub fn spi1_ss0_mclk(&self) -> SPI1_SS0_MCLK_R {
468        SPI1_SS0_MCLK_R::new(((self.bits >> 8) & 0x01) != 0)
469    }
470    #[doc = "Bit 9 - PC.9 Pin Function Selection 1 = The SPI1 SPICLK function is selected to the pin PC.9 0 = The GPIOC\\[9\\]
471is selected to the pin PC.9"]
472    #[inline(always)]
473    pub fn spi1_clk(&self) -> SPI1_CLK_R {
474        SPI1_CLK_R::new(((self.bits >> 9) & 0x01) != 0)
475    }
476    #[doc = "Bit 10 - PC.10 Pin Function Selection 1 = The SPI1 MISO0 (master input, slave output pin-0) function is selected to the pin PC.10 0 = The GPIOC\\[10\\]
477is selected to the pin PC.10"]
478    #[inline(always)]
479    pub fn spi1_miso0(&self) -> SPI1_MISO0_R {
480        SPI1_MISO0_R::new(((self.bits >> 10) & 0x01) != 0)
481    }
482    #[doc = "Bit 11 - PC.11 Pin Function Selection 1 = The SPI1 MOSI0 (master output, slave input pin-0) function is selected to the pin PC.11 0 = The GPIOC\\[11\\]
483is selected to the pin PC.11"]
484    #[inline(always)]
485    pub fn spi1_mosi0(&self) -> SPI1_MOSI0_R {
486        SPI1_MOSI0_R::new(((self.bits >> 11) & 0x01) != 0)
487    }
488    #[doc = "Bit 12 - PC.12 Pin Function Selection 1 = The SPI1 MISO1 (master input, slave output pin-1) function is selected to the pin PC.12 0 = The GPIOC\\[12\\]
489is selected to the pin PC.12"]
490    #[inline(always)]
491    pub fn spi1_miso1(&self) -> SPI1_MISO1_R {
492        SPI1_MISO1_R::new(((self.bits >> 12) & 0x01) != 0)
493    }
494    #[doc = "Bit 13 - PC.13 Pin Function Selection 1 = The SPI1 MOSI1 (master output, slave input pin-1) function is selected to the pin PC.13 0 = The GPIOC\\[13\\]
495is selected to the pin PC.13"]
496    #[inline(always)]
497    pub fn spi1_mosi1(&self) -> SPI1_MOSI1_R {
498        SPI1_MOSI1_R::new(((self.bits >> 13) & 0x01) != 0)
499    }
500    #[doc = "Bit 14 - PC.14 Pin Function Selection The pin function depends on GPC_MFP14 and EBI_EN (ALT_MFP\\[11\\]). EBI_EN GPC_MFP\\[14\\]
501PC.14 function x 0 GPIO 0 1 CPP1 (CMP) 1 1 AD2 (EBI AD bus bit 2)"]
502    #[inline(always)]
503    pub fn cpp1_ad2(&self) -> CPP1_AD2_R {
504        CPP1_AD2_R::new(((self.bits >> 14) & 0x01) != 0)
505    }
506    #[doc = "Bit 15 - PC.15 Pin Function Selection The pin function depends on GPC_MFP15 and EBI_EN (ALT_MFP\\[11\\]). EBI_EN GPC_MFP\\[15\\]
507PC.15 function x 0 GPIO 0 1 CPN1 (CMP) 1 1 AD3 (EBI AD bus bit 3)"]
508    #[inline(always)]
509    pub fn cpp1_ad3(&self) -> CPP1_AD3_R {
510        CPP1_AD3_R::new(((self.bits >> 15) & 0x01) != 0)
511    }
512    #[doc = "Bits 16:31 - 1 = Enable GPIOC\\[15:0\\]
513I/O input Schmitt Trigger function 0 = Disable GPIOC\\[15:0\\]
514I/O input Schmitt Trigger function"]
515    #[inline(always)]
516    pub fn schmitt(&self) -> SCHMITT_R {
517        SCHMITT_R::new(((self.bits >> 16) & 0xffff) as u16)
518    }
519}
520impl W {
521    #[doc = "Bit 0 - PC.0 Pin Function Selection Bits PC0_I2SLRCLK (ALT_MFP\\[5\\]) and GPC_MFP\\[0\\]
522determine the PC.0 function. PC0_I2SLRCLK GPC_MFP\\[0\\]
523PC.0 function x 0 GPIO 0 1 SPISS00(SPI0) 1 1 I2SLRCLK (I2S)"]
524    #[inline(always)]
525    pub fn spi0_ss0_i2slrclk(&mut self) -> SPI0_SS0_I2SLRCLK_W {
526        SPI0_SS0_I2SLRCLK_W { w: self }
527    }
528    #[doc = "Bit 1 - PC.1 Pin Function Selection Bits PC1_I2SBCLK (ALT_MFP\\[6\\]) and GPC_MFP\\[1\\]
529determine the PC.1 function. PC1_I2SBCLK GPC_MFP\\[1\\]
530PC.1 function x 0 GPIO 0 1 SPICLK0 (SPI0) 1 1 I2SBLK (I2S)"]
531    #[inline(always)]
532    pub fn spi0_clk_i2sbclk(&mut self) -> SPI0_CLK_I2SBCLK_W {
533        SPI0_CLK_I2SBCLK_W { w: self }
534    }
535    #[doc = "Bit 2 - PC.2 Pin Function Selection Bits PC2_I2SDI (ALT_MFP\\[7\\]) and GPC_MFP\\[2\\]
536determine the PC.2 function. PC2_I2SDI GPC_MFP\\[2\\]
537PC.2 function x 0 GPIO 0 1 MISO00 (SPI0) 1 1 I2SDI (I2S)"]
538    #[inline(always)]
539    pub fn spi0_miso0_i2sdi(&mut self) -> SPI0_MISO0_I2SDI_W {
540        SPI0_MISO0_I2SDI_W { w: self }
541    }
542    #[doc = "Bit 3 - PC.3 Pin Function Selection Bits PC3_I2SDO (ALT_MFP\\[8\\]) and GPC_MFP\\[3\\]
543determine the PC.3 function. PC3_I2SDO GPC_MFP\\[3\\]
544PC.3 function x 0 GPIO 0 1 MOSI00 (SPI0) 1 1 I2SDO (I2S)"]
545    #[inline(always)]
546    pub fn spi0_mosi0_i2sdo(&mut self) -> SPI0_MOSI0_I2SDO_W {
547        SPI0_MOSI0_I2SDO_W { w: self }
548    }
549    #[doc = "Bit 4 - PC.4 Pin Function Selection 1 = The SPI0 MISO1 (master input, slave output pin-1) function is selected to the pin PC.4 0 = The GPIOC\\[4\\]
550is selected to the pin PC.4"]
551    #[inline(always)]
552    pub fn spi0_miso1(&mut self) -> SPI0_MISO1_W {
553        SPI0_MISO1_W { w: self }
554    }
555    #[doc = "Bit 5 - PC.5 Pin Function Selection 1 = The SPI0 MOSI1 (master output, slave input pin-1) function is selected to the pin PC.5 0 = The GPIOC\\[5\\]
556is selected to the pin PC.5"]
557    #[inline(always)]
558    pub fn spi0_mosi1(&mut self) -> SPI0_MOSI1_W {
559        SPI0_MOSI1_W { w: self }
560    }
561    #[doc = "Bit 6 - PC.6 Pin Function Selection The pin function depends on GPC_MFP6 and EBI_EN (ALT_MFP\\[11\\]). EBI_EN GPC_MFP\\[6\\]
562PC.6 function x 0 GPIO 0 1 CPP0 (CMP) 1 1 AD4 (EBI AD bus bit 4)"]
563    #[inline(always)]
564    pub fn cpp0_ad4(&mut self) -> CPP0_AD4_W {
565        CPP0_AD4_W { w: self }
566    }
567    #[doc = "Bit 7 - PC.7 Pin Function Selection The pin function depends on GPC_MFP7 and EBI_EN (ALT_MFP\\[11\\]). EBI_EN GPC_MFP\\[7\\]
568PC.7 function x 0 GPIO 0 1 CPN0 (CMP) 1 1 AD5 (EBI AD bus bit 5)"]
569    #[inline(always)]
570    pub fn cpn0_ad5(&mut self) -> CPN0_AD5_W {
571        CPN0_AD5_W { w: self }
572    }
573    #[doc = "Bit 8 - PC.8 Pin Function Selection The pin function depends on GPC_MFP8 and EBI_MCLK_EN (ALT_MFP\\[12\\]) and EBI_EN (ALT_MFP\\[11\\]). EBI_MCLK_EN EBI_EN GPC_MFP\\[8\\]
574PC.8 function x x 0 GPIO x 0 1 SPISS10 (SPI1) 0 1 1 SPISS10 (SPI1) 1 1 1 MCLK (EBI Clock output)"]
575    #[inline(always)]
576    pub fn spi1_ss0_mclk(&mut self) -> SPI1_SS0_MCLK_W {
577        SPI1_SS0_MCLK_W { w: self }
578    }
579    #[doc = "Bit 9 - PC.9 Pin Function Selection 1 = The SPI1 SPICLK function is selected to the pin PC.9 0 = The GPIOC\\[9\\]
580is selected to the pin PC.9"]
581    #[inline(always)]
582    pub fn spi1_clk(&mut self) -> SPI1_CLK_W {
583        SPI1_CLK_W { w: self }
584    }
585    #[doc = "Bit 10 - PC.10 Pin Function Selection 1 = The SPI1 MISO0 (master input, slave output pin-0) function is selected to the pin PC.10 0 = The GPIOC\\[10\\]
586is selected to the pin PC.10"]
587    #[inline(always)]
588    pub fn spi1_miso0(&mut self) -> SPI1_MISO0_W {
589        SPI1_MISO0_W { w: self }
590    }
591    #[doc = "Bit 11 - PC.11 Pin Function Selection 1 = The SPI1 MOSI0 (master output, slave input pin-0) function is selected to the pin PC.11 0 = The GPIOC\\[11\\]
592is selected to the pin PC.11"]
593    #[inline(always)]
594    pub fn spi1_mosi0(&mut self) -> SPI1_MOSI0_W {
595        SPI1_MOSI0_W { w: self }
596    }
597    #[doc = "Bit 12 - PC.12 Pin Function Selection 1 = The SPI1 MISO1 (master input, slave output pin-1) function is selected to the pin PC.12 0 = The GPIOC\\[12\\]
598is selected to the pin PC.12"]
599    #[inline(always)]
600    pub fn spi1_miso1(&mut self) -> SPI1_MISO1_W {
601        SPI1_MISO1_W { w: self }
602    }
603    #[doc = "Bit 13 - PC.13 Pin Function Selection 1 = The SPI1 MOSI1 (master output, slave input pin-1) function is selected to the pin PC.13 0 = The GPIOC\\[13\\]
604is selected to the pin PC.13"]
605    #[inline(always)]
606    pub fn spi1_mosi1(&mut self) -> SPI1_MOSI1_W {
607        SPI1_MOSI1_W { w: self }
608    }
609    #[doc = "Bit 14 - PC.14 Pin Function Selection The pin function depends on GPC_MFP14 and EBI_EN (ALT_MFP\\[11\\]). EBI_EN GPC_MFP\\[14\\]
610PC.14 function x 0 GPIO 0 1 CPP1 (CMP) 1 1 AD2 (EBI AD bus bit 2)"]
611    #[inline(always)]
612    pub fn cpp1_ad2(&mut self) -> CPP1_AD2_W {
613        CPP1_AD2_W { w: self }
614    }
615    #[doc = "Bit 15 - PC.15 Pin Function Selection The pin function depends on GPC_MFP15 and EBI_EN (ALT_MFP\\[11\\]). EBI_EN GPC_MFP\\[15\\]
616PC.15 function x 0 GPIO 0 1 CPN1 (CMP) 1 1 AD3 (EBI AD bus bit 3)"]
617    #[inline(always)]
618    pub fn cpp1_ad3(&mut self) -> CPP1_AD3_W {
619        CPP1_AD3_W { w: self }
620    }
621    #[doc = "Bits 16:31 - 1 = Enable GPIOC\\[15:0\\]
622I/O input Schmitt Trigger function 0 = Disable GPIOC\\[15:0\\]
623I/O input Schmitt Trigger function"]
624    #[inline(always)]
625    pub fn schmitt(&mut self) -> SCHMITT_W {
626        SCHMITT_W { w: self }
627    }
628}