Hackfix and re-enable strtoull and wcstoull, see bug #3798.
[sdcc.git] / sdcc / device / non-free / include / pic14 / pic16lf18323.h
blob1ccb4d73ec3cff3daea32772b7646599e0c42256
1 /*
2 * This declarations of the PIC16LF18323 MCU.
4 * This file is part of the GNU PIC library for SDCC, originally
5 * created by Molnar Karoly <molnarkaroly@users.sf.net> 2016.
7 * This file is generated automatically by the cinc2h.pl, 2016-04-13 17:23:23 UTC.
9 * SDCC is licensed under the GNU Public license (GPL) v2. Note that
10 * this license covers the code to the compiler and other executables,
11 * but explicitly does not cover any code or objects generated by sdcc.
13 * For pic device libraries and header files which are derived from
14 * Microchip header (.inc) and linker script (.lkr) files Microchip
15 * requires that "The header files should state that they are only to be
16 * used with authentic Microchip devices" which makes them incompatible
17 * with the GPL. Pic device libraries and header files are located at
18 * non-free/lib and non-free/include directories respectively.
19 * Sdcc should be run with the --use-non-free command line option in
20 * order to include non-free header files and libraries.
22 * See http://sdcc.sourceforge.net/ for the latest information on sdcc.
25 #ifndef __PIC16LF18323_H__
26 #define __PIC16LF18323_H__
28 //==============================================================================
30 // Register Addresses
32 //==============================================================================
34 #ifndef NO_ADDR_DEFINES
36 #define INDF0_ADDR 0x0000
37 #define INDF1_ADDR 0x0001
38 #define PCL_ADDR 0x0002
39 #define STATUS_ADDR 0x0003
40 #define FSR0_ADDR 0x0004
41 #define FSR0L_ADDR 0x0004
42 #define FSR0H_ADDR 0x0005
43 #define FSR1_ADDR 0x0006
44 #define FSR1L_ADDR 0x0006
45 #define FSR1H_ADDR 0x0007
46 #define BSR_ADDR 0x0008
47 #define WREG_ADDR 0x0009
48 #define PCLATH_ADDR 0x000A
49 #define INTCON_ADDR 0x000B
50 #define PORTA_ADDR 0x000C
51 #define PORTC_ADDR 0x000E
52 #define PIR0_ADDR 0x0010
53 #define PIR1_ADDR 0x0011
54 #define PIR2_ADDR 0x0012
55 #define PIR3_ADDR 0x0013
56 #define PIR4_ADDR 0x0014
57 #define TMR0L_ADDR 0x0015
58 #define TMR0H_ADDR 0x0016
59 #define T0CON0_ADDR 0x0017
60 #define T0CON1_ADDR 0x0018
61 #define TMR1_ADDR 0x0019
62 #define TMR1L_ADDR 0x0019
63 #define TMR1H_ADDR 0x001A
64 #define T1CON_ADDR 0x001B
65 #define T1GCON_ADDR 0x001C
66 #define TMR2_ADDR 0x001D
67 #define PR2_ADDR 0x001E
68 #define T2CON_ADDR 0x001F
69 #define TRISA_ADDR 0x008C
70 #define TRISC_ADDR 0x008E
71 #define PIE0_ADDR 0x0090
72 #define PIE1_ADDR 0x0091
73 #define PIE2_ADDR 0x0092
74 #define PIE3_ADDR 0x0093
75 #define PIE4_ADDR 0x0094
76 #define WDTCON_ADDR 0x0097
77 #define ADRES_ADDR 0x009B
78 #define ADRESL_ADDR 0x009B
79 #define ADRESH_ADDR 0x009C
80 #define ADCON0_ADDR 0x009D
81 #define ADCON1_ADDR 0x009E
82 #define ADACT_ADDR 0x009F
83 #define LATA_ADDR 0x010C
84 #define LATC_ADDR 0x010E
85 #define CM1CON0_ADDR 0x0111
86 #define CM1CON1_ADDR 0x0112
87 #define CM2CON0_ADDR 0x0113
88 #define CM2CON1_ADDR 0x0114
89 #define CMOUT_ADDR 0x0115
90 #define BORCON_ADDR 0x0116
91 #define FVRCON_ADDR 0x0117
92 #define DACCON0_ADDR 0x0118
93 #define DACCON1_ADDR 0x0119
94 #define ANSELA_ADDR 0x018C
95 #define ANSELC_ADDR 0x018E
96 #define RC1REG_ADDR 0x0199
97 #define RCREG_ADDR 0x0199
98 #define RCREG1_ADDR 0x0199
99 #define TX1REG_ADDR 0x019A
100 #define TXREG_ADDR 0x019A
101 #define TXREG1_ADDR 0x019A
102 #define SP1BRG_ADDR 0x019B
103 #define SP1BRGL_ADDR 0x019B
104 #define SPBRG_ADDR 0x019B
105 #define SPBRG1_ADDR 0x019B
106 #define SPBRGL_ADDR 0x019B
107 #define SP1BRGH_ADDR 0x019C
108 #define SPBRGH_ADDR 0x019C
109 #define SPBRGH1_ADDR 0x019C
110 #define RC1STA_ADDR 0x019D
111 #define RCSTA_ADDR 0x019D
112 #define RCSTA1_ADDR 0x019D
113 #define TX1STA_ADDR 0x019E
114 #define TXSTA_ADDR 0x019E
115 #define TXSTA1_ADDR 0x019E
116 #define BAUD1CON_ADDR 0x019F
117 #define BAUDCON_ADDR 0x019F
118 #define BAUDCON1_ADDR 0x019F
119 #define BAUDCTL_ADDR 0x019F
120 #define BAUDCTL1_ADDR 0x019F
121 #define WPUA_ADDR 0x020C
122 #define WPUC_ADDR 0x020E
123 #define SSP1BUF_ADDR 0x0211
124 #define SSPBUF_ADDR 0x0211
125 #define SSP1ADD_ADDR 0x0212
126 #define SSPADD_ADDR 0x0212
127 #define SSP1MSK_ADDR 0x0213
128 #define SSPMSK_ADDR 0x0213
129 #define SSP1STAT_ADDR 0x0214
130 #define SSPSTAT_ADDR 0x0214
131 #define SSP1CON_ADDR 0x0215
132 #define SSP1CON1_ADDR 0x0215
133 #define SSPCON_ADDR 0x0215
134 #define SSPCON1_ADDR 0x0215
135 #define SSP1CON2_ADDR 0x0216
136 #define SSPCON2_ADDR 0x0216
137 #define SSP1CON3_ADDR 0x0217
138 #define SSPCON3_ADDR 0x0217
139 #define ODCONA_ADDR 0x028C
140 #define ODCONC_ADDR 0x028E
141 #define CCPR1_ADDR 0x0291
142 #define CCPR1L_ADDR 0x0291
143 #define CCPR1H_ADDR 0x0292
144 #define CCP1CON_ADDR 0x0293
145 #define CCP1CAP_ADDR 0x0294
146 #define CCPR2_ADDR 0x0295
147 #define CCPR2L_ADDR 0x0295
148 #define CCPR2H_ADDR 0x0296
149 #define CCP2CON_ADDR 0x0297
150 #define CCP2CAP_ADDR 0x0298
151 #define CCPTMRS_ADDR 0x029F
152 #define SLRCONA_ADDR 0x030C
153 #define SLRCONC_ADDR 0x030E
154 #define INLVLA_ADDR 0x038C
155 #define INLVLC_ADDR 0x038E
156 #define IOCAP_ADDR 0x0391
157 #define IOCAN_ADDR 0x0392
158 #define IOCAF_ADDR 0x0393
159 #define IOCCP_ADDR 0x0397
160 #define IOCCN_ADDR 0x0398
161 #define IOCCF_ADDR 0x0399
162 #define CLKRCON_ADDR 0x039A
163 #define MDCON_ADDR 0x039C
164 #define MDSRC_ADDR 0x039D
165 #define MDCARH_ADDR 0x039E
166 #define MDCARL_ADDR 0x039F
167 #define CCDNA_ADDR 0x040C
168 #define CCDNC_ADDR 0x040E
169 #define CCDCON_ADDR 0x041F
170 #define CCDPA_ADDR 0x048C
171 #define CCDPC_ADDR 0x048E
172 #define NCO1ACC_ADDR 0x0498
173 #define NCO1ACCL_ADDR 0x0498
174 #define NCO1ACCH_ADDR 0x0499
175 #define NCO1ACCU_ADDR 0x049A
176 #define NCO1INC_ADDR 0x049B
177 #define NCO1INCL_ADDR 0x049B
178 #define NCO1INCH_ADDR 0x049C
179 #define NCO1INCU_ADDR 0x049D
180 #define NCO1CON_ADDR 0x049E
181 #define NCO1CLK_ADDR 0x049F
182 #define PWM5DCL_ADDR 0x0617
183 #define PWM5DCH_ADDR 0x0618
184 #define PWM5CON_ADDR 0x0619
185 #define PWM5CON0_ADDR 0x0619
186 #define PWM6DCL_ADDR 0x061A
187 #define PWM6DCH_ADDR 0x061B
188 #define PWM6CON_ADDR 0x061C
189 #define PWM6CON0_ADDR 0x061C
190 #define CWG1CLKCON_ADDR 0x0691
191 #define CWG1DAT_ADDR 0x0692
192 #define CWG1DBR_ADDR 0x0693
193 #define CWG1DBF_ADDR 0x0694
194 #define CWG1CON0_ADDR 0x0695
195 #define CWG1CON1_ADDR 0x0696
196 #define CWG1AS0_ADDR 0x0697
197 #define CWG1AS1_ADDR 0x0698
198 #define CWG1STR_ADDR 0x0699
199 #define NVMADR_ADDR 0x0891
200 #define NVMADRL_ADDR 0x0891
201 #define NVMADRH_ADDR 0x0892
202 #define NVMDAT_ADDR 0x0893
203 #define NVMDATL_ADDR 0x0893
204 #define NVMDATH_ADDR 0x0894
205 #define NVMCON1_ADDR 0x0895
206 #define NVMCON2_ADDR 0x0896
207 #define PCON0_ADDR 0x089B
208 #define PMD0_ADDR 0x0911
209 #define PMD1_ADDR 0x0912
210 #define PMD2_ADDR 0x0913
211 #define PMD3_ADDR 0x0914
212 #define PMD4_ADDR 0x0915
213 #define PMD5_ADDR 0x0916
214 #define CPUDOZE_ADDR 0x0918
215 #define OSCCON1_ADDR 0x0919
216 #define OSCCON2_ADDR 0x091A
217 #define OSCCON3_ADDR 0x091B
218 #define OSCSTAT1_ADDR 0x091C
219 #define OSCEN_ADDR 0x091D
220 #define OSCTUNE_ADDR 0x091E
221 #define OSCFRQ_ADDR 0x091F
222 #define PPSLOCK_ADDR 0x0E0F
223 #define INTPPS_ADDR 0x0E10
224 #define T0CKIPPS_ADDR 0x0E11
225 #define T1CKIPPS_ADDR 0x0E12
226 #define T1GPPS_ADDR 0x0E13
227 #define CCP1PPS_ADDR 0x0E14
228 #define CCP2PPS_ADDR 0x0E15
229 #define CWG1PPS_ADDR 0x0E18
230 #define MDCIN1PPS_ADDR 0x0E1A
231 #define MDCIN2PPS_ADDR 0x0E1B
232 #define MDMINPPS_ADDR 0x0E1C
233 #define SSP1CLKPPS_ADDR 0x0E20
234 #define SSP1DATPPS_ADDR 0x0E21
235 #define SSP1SSPPS_ADDR 0x0E22
236 #define RXPPS_ADDR 0x0E24
237 #define TXPPS_ADDR 0x0E25
238 #define CLCIN0PPS_ADDR 0x0E28
239 #define CLCIN1PPS_ADDR 0x0E29
240 #define CLCIN2PPS_ADDR 0x0E2A
241 #define CLCIN3PPS_ADDR 0x0E2B
242 #define RA0PPS_ADDR 0x0E90
243 #define RA1PPS_ADDR 0x0E91
244 #define RA2PPS_ADDR 0x0E92
245 #define RA4PPS_ADDR 0x0E94
246 #define RA5PPS_ADDR 0x0E95
247 #define RC0PPS_ADDR 0x0EA0
248 #define RC1PPS_ADDR 0x0EA1
249 #define RC2PPS_ADDR 0x0EA2
250 #define RC3PPS_ADDR 0x0EA3
251 #define RC4PPS_ADDR 0x0EA4
252 #define RC5PPS_ADDR 0x0EA5
253 #define CLCDATA_ADDR 0x0F0F
254 #define CLC1CON_ADDR 0x0F10
255 #define CLC1POL_ADDR 0x0F11
256 #define CLC1SEL0_ADDR 0x0F12
257 #define CLC1SEL1_ADDR 0x0F13
258 #define CLC1SEL2_ADDR 0x0F14
259 #define CLC1SEL3_ADDR 0x0F15
260 #define CLC1GLS0_ADDR 0x0F16
261 #define CLC1GLS1_ADDR 0x0F17
262 #define CLC1GLS2_ADDR 0x0F18
263 #define CLC1GLS3_ADDR 0x0F19
264 #define CLC2CON_ADDR 0x0F1A
265 #define CLC2POL_ADDR 0x0F1B
266 #define CLC2SEL0_ADDR 0x0F1C
267 #define CLC2SEL1_ADDR 0x0F1D
268 #define CLC2SEL2_ADDR 0x0F1E
269 #define CLC2SEL3_ADDR 0x0F1F
270 #define CLC2GLS0_ADDR 0x0F20
271 #define CLC2GLS1_ADDR 0x0F21
272 #define CLC2GLS2_ADDR 0x0F22
273 #define CLC2GLS3_ADDR 0x0F23
274 #define STATUS_SHAD_ADDR 0x0FE4
275 #define WREG_SHAD_ADDR 0x0FE5
276 #define BSR_SHAD_ADDR 0x0FE6
277 #define PCLATH_SHAD_ADDR 0x0FE7
278 #define FSR0L_SHAD_ADDR 0x0FE8
279 #define FSR0H_SHAD_ADDR 0x0FE9
280 #define FSR1L_SHAD_ADDR 0x0FEA
281 #define FSR1H_SHAD_ADDR 0x0FEB
282 #define STKPTR_ADDR 0x0FED
283 #define TOSL_ADDR 0x0FEE
284 #define TOSH_ADDR 0x0FEF
286 #endif // #ifndef NO_ADDR_DEFINES
288 //==============================================================================
290 // Register Definitions
292 //==============================================================================
294 extern __at(0x0000) __sfr INDF0;
295 extern __at(0x0001) __sfr INDF1;
296 extern __at(0x0002) __sfr PCL;
298 //==============================================================================
299 // STATUS Bits
301 extern __at(0x0003) __sfr STATUS;
303 typedef struct
305 unsigned C : 1;
306 unsigned DC : 1;
307 unsigned Z : 1;
308 unsigned NOT_PD : 1;
309 unsigned NOT_TO : 1;
310 unsigned : 1;
311 unsigned : 1;
312 unsigned : 1;
313 } __STATUSbits_t;
315 extern __at(0x0003) volatile __STATUSbits_t STATUSbits;
317 #define _C 0x01
318 #define _DC 0x02
319 #define _Z 0x04
320 #define _NOT_PD 0x08
321 #define _NOT_TO 0x10
323 //==============================================================================
325 extern __at(0x0004) __sfr FSR0;
326 extern __at(0x0004) __sfr FSR0L;
327 extern __at(0x0005) __sfr FSR0H;
328 extern __at(0x0006) __sfr FSR1;
329 extern __at(0x0006) __sfr FSR1L;
330 extern __at(0x0007) __sfr FSR1H;
332 //==============================================================================
333 // BSR Bits
335 extern __at(0x0008) __sfr BSR;
337 typedef union
339 struct
341 unsigned BSR0 : 1;
342 unsigned BSR1 : 1;
343 unsigned BSR2 : 1;
344 unsigned BSR3 : 1;
345 unsigned BSR4 : 1;
346 unsigned : 1;
347 unsigned : 1;
348 unsigned : 1;
351 struct
353 unsigned BSR : 5;
354 unsigned : 3;
356 } __BSRbits_t;
358 extern __at(0x0008) volatile __BSRbits_t BSRbits;
360 #define _BSR0 0x01
361 #define _BSR1 0x02
362 #define _BSR2 0x04
363 #define _BSR3 0x08
364 #define _BSR4 0x10
366 //==============================================================================
368 extern __at(0x0009) __sfr WREG;
369 extern __at(0x000A) __sfr PCLATH;
371 //==============================================================================
372 // INTCON Bits
374 extern __at(0x000B) __sfr INTCON;
376 typedef struct
378 unsigned INTEDG : 1;
379 unsigned : 1;
380 unsigned : 1;
381 unsigned : 1;
382 unsigned : 1;
383 unsigned : 1;
384 unsigned PEIE : 1;
385 unsigned GIE : 1;
386 } __INTCONbits_t;
388 extern __at(0x000B) volatile __INTCONbits_t INTCONbits;
390 #define _INTEDG 0x01
391 #define _PEIE 0x40
392 #define _GIE 0x80
394 //==============================================================================
397 //==============================================================================
398 // PORTA Bits
400 extern __at(0x000C) __sfr PORTA;
402 typedef union
404 struct
406 unsigned RA0 : 1;
407 unsigned RA1 : 1;
408 unsigned RA2 : 1;
409 unsigned RA3 : 1;
410 unsigned RA4 : 1;
411 unsigned RA5 : 1;
412 unsigned : 1;
413 unsigned : 1;
416 struct
418 unsigned RA : 6;
419 unsigned : 2;
421 } __PORTAbits_t;
423 extern __at(0x000C) volatile __PORTAbits_t PORTAbits;
425 #define _RA0 0x01
426 #define _RA1 0x02
427 #define _RA2 0x04
428 #define _RA3 0x08
429 #define _RA4 0x10
430 #define _RA5 0x20
432 //==============================================================================
435 //==============================================================================
436 // PORTC Bits
438 extern __at(0x000E) __sfr PORTC;
440 typedef union
442 struct
444 unsigned RC0 : 1;
445 unsigned RC1 : 1;
446 unsigned RC2 : 1;
447 unsigned RC3 : 1;
448 unsigned RC4 : 1;
449 unsigned RC5 : 1;
450 unsigned : 1;
451 unsigned : 1;
454 struct
456 unsigned RC : 6;
457 unsigned : 2;
459 } __PORTCbits_t;
461 extern __at(0x000E) volatile __PORTCbits_t PORTCbits;
463 #define _RC0 0x01
464 #define _RC1 0x02
465 #define _RC2 0x04
466 #define _RC3 0x08
467 #define _RC4 0x10
468 #define _RC5 0x20
470 //==============================================================================
473 //==============================================================================
474 // PIR0 Bits
476 extern __at(0x0010) __sfr PIR0;
478 typedef struct
480 unsigned INTF : 1;
481 unsigned : 1;
482 unsigned : 1;
483 unsigned : 1;
484 unsigned IOCIF : 1;
485 unsigned TMR0IF : 1;
486 unsigned : 1;
487 unsigned : 1;
488 } __PIR0bits_t;
490 extern __at(0x0010) volatile __PIR0bits_t PIR0bits;
492 #define _INTF 0x01
493 #define _IOCIF 0x10
494 #define _TMR0IF 0x20
496 //==============================================================================
499 //==============================================================================
500 // PIR1 Bits
502 extern __at(0x0011) __sfr PIR1;
504 typedef struct
506 unsigned TMR1IF : 1;
507 unsigned TMR2IF : 1;
508 unsigned BCL1IF : 1;
509 unsigned SSP1IF : 1;
510 unsigned TXIF : 1;
511 unsigned RCIF : 1;
512 unsigned ADIF : 1;
513 unsigned TMR1GIF : 1;
514 } __PIR1bits_t;
516 extern __at(0x0011) volatile __PIR1bits_t PIR1bits;
518 #define _TMR1IF 0x01
519 #define _TMR2IF 0x02
520 #define _BCL1IF 0x04
521 #define _SSP1IF 0x08
522 #define _TXIF 0x10
523 #define _RCIF 0x20
524 #define _ADIF 0x40
525 #define _TMR1GIF 0x80
527 //==============================================================================
530 //==============================================================================
531 // PIR2 Bits
533 extern __at(0x0012) __sfr PIR2;
535 typedef struct
537 unsigned NCO1IF : 1;
538 unsigned : 1;
539 unsigned : 1;
540 unsigned : 1;
541 unsigned NVMIF : 1;
542 unsigned C1IF : 1;
543 unsigned C2IF : 1;
544 unsigned : 1;
545 } __PIR2bits_t;
547 extern __at(0x0012) volatile __PIR2bits_t PIR2bits;
549 #define _NCO1IF 0x01
550 #define _NVMIF 0x10
551 #define _C1IF 0x20
552 #define _C2IF 0x40
554 //==============================================================================
557 //==============================================================================
558 // PIR3 Bits
560 extern __at(0x0013) __sfr PIR3;
562 typedef struct
564 unsigned CLC1IF : 1;
565 unsigned CLC2IF : 1;
566 unsigned : 1;
567 unsigned : 1;
568 unsigned : 1;
569 unsigned : 1;
570 unsigned CSWIF : 1;
571 unsigned OSFIF : 1;
572 } __PIR3bits_t;
574 extern __at(0x0013) volatile __PIR3bits_t PIR3bits;
576 #define _CLC1IF 0x01
577 #define _CLC2IF 0x02
578 #define _CSWIF 0x40
579 #define _OSFIF 0x80
581 //==============================================================================
584 //==============================================================================
585 // PIR4 Bits
587 extern __at(0x0014) __sfr PIR4;
589 typedef struct
591 unsigned CCP1IF : 1;
592 unsigned CCP2IF : 1;
593 unsigned : 1;
594 unsigned : 1;
595 unsigned : 1;
596 unsigned : 1;
597 unsigned CWG1IF : 1;
598 unsigned : 1;
599 } __PIR4bits_t;
601 extern __at(0x0014) volatile __PIR4bits_t PIR4bits;
603 #define _CCP1IF 0x01
604 #define _CCP2IF 0x02
605 #define _CWG1IF 0x40
607 //==============================================================================
610 //==============================================================================
611 // TMR0L Bits
613 extern __at(0x0015) __sfr TMR0L;
615 typedef struct
617 unsigned TMR00 : 1;
618 unsigned TMR01 : 1;
619 unsigned TMR02 : 1;
620 unsigned TMR03 : 1;
621 unsigned TMR04 : 1;
622 unsigned TMR05 : 1;
623 unsigned TMR06 : 1;
624 unsigned TMR07 : 1;
625 } __TMR0Lbits_t;
627 extern __at(0x0015) volatile __TMR0Lbits_t TMR0Lbits;
629 #define _TMR00 0x01
630 #define _TMR01 0x02
631 #define _TMR02 0x04
632 #define _TMR03 0x08
633 #define _TMR04 0x10
634 #define _TMR05 0x20
635 #define _TMR06 0x40
636 #define _TMR07 0x80
638 //==============================================================================
641 //==============================================================================
642 // TMR0H Bits
644 extern __at(0x0016) __sfr TMR0H;
646 typedef struct
648 unsigned TMR08 : 1;
649 unsigned TMR09 : 1;
650 unsigned TMR010 : 1;
651 unsigned TMR011 : 1;
652 unsigned TMR012 : 1;
653 unsigned TMR013 : 1;
654 unsigned TMR014 : 1;
655 unsigned TMR015 : 1;
656 } __TMR0Hbits_t;
658 extern __at(0x0016) volatile __TMR0Hbits_t TMR0Hbits;
660 #define _TMR08 0x01
661 #define _TMR09 0x02
662 #define _TMR010 0x04
663 #define _TMR011 0x08
664 #define _TMR012 0x10
665 #define _TMR013 0x20
666 #define _TMR014 0x40
667 #define _TMR015 0x80
669 //==============================================================================
672 //==============================================================================
673 // T0CON0 Bits
675 extern __at(0x0017) __sfr T0CON0;
677 typedef union
679 struct
681 unsigned T0OUTPS0 : 1;
682 unsigned T0OUTPS1 : 1;
683 unsigned T0OUTPS2 : 1;
684 unsigned T0OUTPS3 : 1;
685 unsigned T016BIT : 1;
686 unsigned T0OUT : 1;
687 unsigned : 1;
688 unsigned T0EN : 1;
691 struct
693 unsigned T0OUTPS : 4;
694 unsigned : 4;
696 } __T0CON0bits_t;
698 extern __at(0x0017) volatile __T0CON0bits_t T0CON0bits;
700 #define _T0OUTPS0 0x01
701 #define _T0OUTPS1 0x02
702 #define _T0OUTPS2 0x04
703 #define _T0OUTPS3 0x08
704 #define _T016BIT 0x10
705 #define _T0OUT 0x20
706 #define _T0EN 0x80
708 //==============================================================================
711 //==============================================================================
712 // T0CON1 Bits
714 extern __at(0x0018) __sfr T0CON1;
716 typedef union
718 struct
720 unsigned T0CKPS0 : 1;
721 unsigned T0CKPS1 : 1;
722 unsigned T0CKPS2 : 1;
723 unsigned T0CKPS3 : 1;
724 unsigned T0ASYNC : 1;
725 unsigned T0CS0 : 1;
726 unsigned T0CS1 : 1;
727 unsigned T0CS2 : 1;
730 struct
732 unsigned T0CKPS : 4;
733 unsigned : 4;
736 struct
738 unsigned : 5;
739 unsigned T0CS : 3;
741 } __T0CON1bits_t;
743 extern __at(0x0018) volatile __T0CON1bits_t T0CON1bits;
745 #define _T0CKPS0 0x01
746 #define _T0CKPS1 0x02
747 #define _T0CKPS2 0x04
748 #define _T0CKPS3 0x08
749 #define _T0ASYNC 0x10
750 #define _T0CS0 0x20
751 #define _T0CS1 0x40
752 #define _T0CS2 0x80
754 //==============================================================================
756 extern __at(0x0019) __sfr TMR1;
757 extern __at(0x0019) __sfr TMR1L;
758 extern __at(0x001A) __sfr TMR1H;
760 //==============================================================================
761 // T1CON Bits
763 extern __at(0x001B) __sfr T1CON;
765 typedef union
767 struct
769 unsigned TMR1ON : 1;
770 unsigned : 1;
771 unsigned T1SYNC : 1;
772 unsigned T1SOSC : 1;
773 unsigned T1CKPS0 : 1;
774 unsigned T1CKPS1 : 1;
775 unsigned TMR1CS0 : 1;
776 unsigned TMR1CS1 : 1;
779 struct
781 unsigned : 4;
782 unsigned T1CKPS : 2;
783 unsigned : 2;
786 struct
788 unsigned : 6;
789 unsigned TMR1CS : 2;
791 } __T1CONbits_t;
793 extern __at(0x001B) volatile __T1CONbits_t T1CONbits;
795 #define _TMR1ON 0x01
796 #define _T1SYNC 0x04
797 #define _T1SOSC 0x08
798 #define _T1CKPS0 0x10
799 #define _T1CKPS1 0x20
800 #define _TMR1CS0 0x40
801 #define _TMR1CS1 0x80
803 //==============================================================================
806 //==============================================================================
807 // T1GCON Bits
809 extern __at(0x001C) __sfr T1GCON;
811 typedef union
813 struct
815 unsigned T1GSS0 : 1;
816 unsigned T1GSS1 : 1;
817 unsigned T1GVAL : 1;
818 unsigned T1GGO_NOT_DONE : 1;
819 unsigned T1GSPM : 1;
820 unsigned T1GTM : 1;
821 unsigned T1GPOL : 1;
822 unsigned TMR1GE : 1;
825 struct
827 unsigned T1GSS : 2;
828 unsigned : 6;
830 } __T1GCONbits_t;
832 extern __at(0x001C) volatile __T1GCONbits_t T1GCONbits;
834 #define _T1GSS0 0x01
835 #define _T1GSS1 0x02
836 #define _T1GVAL 0x04
837 #define _T1GGO_NOT_DONE 0x08
838 #define _T1GSPM 0x10
839 #define _T1GTM 0x20
840 #define _T1GPOL 0x40
841 #define _TMR1GE 0x80
843 //==============================================================================
845 extern __at(0x001D) __sfr TMR2;
846 extern __at(0x001E) __sfr PR2;
848 //==============================================================================
849 // T2CON Bits
851 extern __at(0x001F) __sfr T2CON;
853 typedef union
855 struct
857 unsigned T2CKPS0 : 1;
858 unsigned T2CKPS1 : 1;
859 unsigned TMR2ON : 1;
860 unsigned T2OUTPS0 : 1;
861 unsigned T2OUTPS1 : 1;
862 unsigned T2OUTPS2 : 1;
863 unsigned T2OUTPS3 : 1;
864 unsigned : 1;
867 struct
869 unsigned T2CKPS : 2;
870 unsigned : 6;
873 struct
875 unsigned : 3;
876 unsigned T2OUTPS : 4;
877 unsigned : 1;
879 } __T2CONbits_t;
881 extern __at(0x001F) volatile __T2CONbits_t T2CONbits;
883 #define _T2CKPS0 0x01
884 #define _T2CKPS1 0x02
885 #define _TMR2ON 0x04
886 #define _T2OUTPS0 0x08
887 #define _T2OUTPS1 0x10
888 #define _T2OUTPS2 0x20
889 #define _T2OUTPS3 0x40
891 //==============================================================================
894 //==============================================================================
895 // TRISA Bits
897 extern __at(0x008C) __sfr TRISA;
899 typedef struct
901 unsigned TRISA0 : 1;
902 unsigned TRISA1 : 1;
903 unsigned TRISA2 : 1;
904 unsigned : 1;
905 unsigned TRISA4 : 1;
906 unsigned TRISA5 : 1;
907 unsigned : 1;
908 unsigned : 1;
909 } __TRISAbits_t;
911 extern __at(0x008C) volatile __TRISAbits_t TRISAbits;
913 #define _TRISA0 0x01
914 #define _TRISA1 0x02
915 #define _TRISA2 0x04
916 #define _TRISA4 0x10
917 #define _TRISA5 0x20
919 //==============================================================================
922 //==============================================================================
923 // TRISC Bits
925 extern __at(0x008E) __sfr TRISC;
927 typedef union
929 struct
931 unsigned TRISC0 : 1;
932 unsigned TRISC1 : 1;
933 unsigned TRISC2 : 1;
934 unsigned TRISC3 : 1;
935 unsigned TRISC4 : 1;
936 unsigned TRISC5 : 1;
937 unsigned : 1;
938 unsigned : 1;
941 struct
943 unsigned TRISC : 6;
944 unsigned : 2;
946 } __TRISCbits_t;
948 extern __at(0x008E) volatile __TRISCbits_t TRISCbits;
950 #define _TRISC0 0x01
951 #define _TRISC1 0x02
952 #define _TRISC2 0x04
953 #define _TRISC3 0x08
954 #define _TRISC4 0x10
955 #define _TRISC5 0x20
957 //==============================================================================
960 //==============================================================================
961 // PIE0 Bits
963 extern __at(0x0090) __sfr PIE0;
965 typedef struct
967 unsigned INTE : 1;
968 unsigned : 1;
969 unsigned : 1;
970 unsigned : 1;
971 unsigned IOCIE : 1;
972 unsigned TMR0IE : 1;
973 unsigned : 1;
974 unsigned : 1;
975 } __PIE0bits_t;
977 extern __at(0x0090) volatile __PIE0bits_t PIE0bits;
979 #define _INTE 0x01
980 #define _IOCIE 0x10
981 #define _TMR0IE 0x20
983 //==============================================================================
986 //==============================================================================
987 // PIE1 Bits
989 extern __at(0x0091) __sfr PIE1;
991 typedef struct
993 unsigned TMR1IE : 1;
994 unsigned TMR2IE : 1;
995 unsigned BCL1IE : 1;
996 unsigned SSP1IE : 1;
997 unsigned TXIE : 1;
998 unsigned RCIE : 1;
999 unsigned ADIE : 1;
1000 unsigned TMR1GIE : 1;
1001 } __PIE1bits_t;
1003 extern __at(0x0091) volatile __PIE1bits_t PIE1bits;
1005 #define _TMR1IE 0x01
1006 #define _TMR2IE 0x02
1007 #define _BCL1IE 0x04
1008 #define _SSP1IE 0x08
1009 #define _TXIE 0x10
1010 #define _RCIE 0x20
1011 #define _ADIE 0x40
1012 #define _TMR1GIE 0x80
1014 //==============================================================================
1017 //==============================================================================
1018 // PIE2 Bits
1020 extern __at(0x0092) __sfr PIE2;
1022 typedef struct
1024 unsigned NCO1IE : 1;
1025 unsigned : 1;
1026 unsigned : 1;
1027 unsigned : 1;
1028 unsigned NVMIE : 1;
1029 unsigned C1IE : 1;
1030 unsigned C2IE : 1;
1031 unsigned : 1;
1032 } __PIE2bits_t;
1034 extern __at(0x0092) volatile __PIE2bits_t PIE2bits;
1036 #define _NCO1IE 0x01
1037 #define _NVMIE 0x10
1038 #define _C1IE 0x20
1039 #define _C2IE 0x40
1041 //==============================================================================
1044 //==============================================================================
1045 // PIE3 Bits
1047 extern __at(0x0093) __sfr PIE3;
1049 typedef struct
1051 unsigned CLC1IE : 1;
1052 unsigned CLC2IE : 1;
1053 unsigned : 1;
1054 unsigned : 1;
1055 unsigned : 1;
1056 unsigned : 1;
1057 unsigned CSWIE : 1;
1058 unsigned OSFIE : 1;
1059 } __PIE3bits_t;
1061 extern __at(0x0093) volatile __PIE3bits_t PIE3bits;
1063 #define _CLC1IE 0x01
1064 #define _CLC2IE 0x02
1065 #define _CSWIE 0x40
1066 #define _OSFIE 0x80
1068 //==============================================================================
1071 //==============================================================================
1072 // PIE4 Bits
1074 extern __at(0x0094) __sfr PIE4;
1076 typedef struct
1078 unsigned CCP1IE : 1;
1079 unsigned CCP2IE : 1;
1080 unsigned : 1;
1081 unsigned : 1;
1082 unsigned : 1;
1083 unsigned : 1;
1084 unsigned CWG1IE : 1;
1085 unsigned : 1;
1086 } __PIE4bits_t;
1088 extern __at(0x0094) volatile __PIE4bits_t PIE4bits;
1090 #define _CCP1IE 0x01
1091 #define _CCP2IE 0x02
1092 #define _CWG1IE 0x40
1094 //==============================================================================
1097 //==============================================================================
1098 // WDTCON Bits
1100 extern __at(0x0097) __sfr WDTCON;
1102 typedef union
1104 struct
1106 unsigned SWDTEN : 1;
1107 unsigned WDTPS0 : 1;
1108 unsigned WDTPS1 : 1;
1109 unsigned WDTPS2 : 1;
1110 unsigned WDTPS3 : 1;
1111 unsigned WDTPS4 : 1;
1112 unsigned : 1;
1113 unsigned : 1;
1116 struct
1118 unsigned : 1;
1119 unsigned WDTPS : 5;
1120 unsigned : 2;
1122 } __WDTCONbits_t;
1124 extern __at(0x0097) volatile __WDTCONbits_t WDTCONbits;
1126 #define _SWDTEN 0x01
1127 #define _WDTPS0 0x02
1128 #define _WDTPS1 0x04
1129 #define _WDTPS2 0x08
1130 #define _WDTPS3 0x10
1131 #define _WDTPS4 0x20
1133 //==============================================================================
1135 extern __at(0x009B) __sfr ADRES;
1136 extern __at(0x009B) __sfr ADRESL;
1137 extern __at(0x009C) __sfr ADRESH;
1139 //==============================================================================
1140 // ADCON0 Bits
1142 extern __at(0x009D) __sfr ADCON0;
1144 typedef union
1146 struct
1148 unsigned ADON : 1;
1149 unsigned GO_NOT_DONE : 1;
1150 unsigned CHS0 : 1;
1151 unsigned CHS1 : 1;
1152 unsigned CHS2 : 1;
1153 unsigned CHS3 : 1;
1154 unsigned CHS4 : 1;
1155 unsigned CHS5 : 1;
1158 struct
1160 unsigned : 1;
1161 unsigned ADGO : 1;
1162 unsigned : 1;
1163 unsigned : 1;
1164 unsigned : 1;
1165 unsigned : 1;
1166 unsigned : 1;
1167 unsigned : 1;
1170 struct
1172 unsigned : 1;
1173 unsigned GO : 1;
1174 unsigned : 1;
1175 unsigned : 1;
1176 unsigned : 1;
1177 unsigned : 1;
1178 unsigned : 1;
1179 unsigned : 1;
1182 struct
1184 unsigned : 2;
1185 unsigned CHS : 6;
1187 } __ADCON0bits_t;
1189 extern __at(0x009D) volatile __ADCON0bits_t ADCON0bits;
1191 #define _ADON 0x01
1192 #define _GO_NOT_DONE 0x02
1193 #define _ADGO 0x02
1194 #define _GO 0x02
1195 #define _CHS0 0x04
1196 #define _CHS1 0x08
1197 #define _CHS2 0x10
1198 #define _CHS3 0x20
1199 #define _CHS4 0x40
1200 #define _CHS5 0x80
1202 //==============================================================================
1205 //==============================================================================
1206 // ADCON1 Bits
1208 extern __at(0x009E) __sfr ADCON1;
1210 typedef union
1212 struct
1214 unsigned ADPREF0 : 1;
1215 unsigned ADPREF1 : 1;
1216 unsigned ADNREF : 1;
1217 unsigned : 1;
1218 unsigned ADCS0 : 1;
1219 unsigned ADCS1 : 1;
1220 unsigned ADCS2 : 1;
1221 unsigned ADFM : 1;
1224 struct
1226 unsigned ADPREF : 2;
1227 unsigned : 6;
1230 struct
1232 unsigned : 4;
1233 unsigned ADCS : 3;
1234 unsigned : 1;
1236 } __ADCON1bits_t;
1238 extern __at(0x009E) volatile __ADCON1bits_t ADCON1bits;
1240 #define _ADPREF0 0x01
1241 #define _ADPREF1 0x02
1242 #define _ADNREF 0x04
1243 #define _ADCS0 0x10
1244 #define _ADCS1 0x20
1245 #define _ADCS2 0x40
1246 #define _ADFM 0x80
1248 //==============================================================================
1251 //==============================================================================
1252 // ADACT Bits
1254 extern __at(0x009F) __sfr ADACT;
1256 typedef union
1258 struct
1260 unsigned ADACT0 : 1;
1261 unsigned ADACT1 : 1;
1262 unsigned ADACT2 : 1;
1263 unsigned ADACT3 : 1;
1264 unsigned : 1;
1265 unsigned : 1;
1266 unsigned : 1;
1267 unsigned : 1;
1270 struct
1272 unsigned ADACT : 4;
1273 unsigned : 4;
1275 } __ADACTbits_t;
1277 extern __at(0x009F) volatile __ADACTbits_t ADACTbits;
1279 #define _ADACT0 0x01
1280 #define _ADACT1 0x02
1281 #define _ADACT2 0x04
1282 #define _ADACT3 0x08
1284 //==============================================================================
1287 //==============================================================================
1288 // LATA Bits
1290 extern __at(0x010C) __sfr LATA;
1292 typedef struct
1294 unsigned LATA0 : 1;
1295 unsigned LATA1 : 1;
1296 unsigned LATA2 : 1;
1297 unsigned : 1;
1298 unsigned LATA4 : 1;
1299 unsigned LATA5 : 1;
1300 unsigned : 1;
1301 unsigned : 1;
1302 } __LATAbits_t;
1304 extern __at(0x010C) volatile __LATAbits_t LATAbits;
1306 #define _LATA0 0x01
1307 #define _LATA1 0x02
1308 #define _LATA2 0x04
1309 #define _LATA4 0x10
1310 #define _LATA5 0x20
1312 //==============================================================================
1315 //==============================================================================
1316 // LATC Bits
1318 extern __at(0x010E) __sfr LATC;
1320 typedef union
1322 struct
1324 unsigned LATC0 : 1;
1325 unsigned LATC1 : 1;
1326 unsigned LATC2 : 1;
1327 unsigned LATC3 : 1;
1328 unsigned LATC4 : 1;
1329 unsigned LATC5 : 1;
1330 unsigned : 1;
1331 unsigned : 1;
1334 struct
1336 unsigned LATC : 6;
1337 unsigned : 2;
1339 } __LATCbits_t;
1341 extern __at(0x010E) volatile __LATCbits_t LATCbits;
1343 #define _LATC0 0x01
1344 #define _LATC1 0x02
1345 #define _LATC2 0x04
1346 #define _LATC3 0x08
1347 #define _LATC4 0x10
1348 #define _LATC5 0x20
1350 //==============================================================================
1353 //==============================================================================
1354 // CM1CON0 Bits
1356 extern __at(0x0111) __sfr CM1CON0;
1358 typedef struct
1360 unsigned C1SYNC : 1;
1361 unsigned C1HYS : 1;
1362 unsigned C1SP : 1;
1363 unsigned : 1;
1364 unsigned C1POL : 1;
1365 unsigned : 1;
1366 unsigned C1OUT : 1;
1367 unsigned C1ON : 1;
1368 } __CM1CON0bits_t;
1370 extern __at(0x0111) volatile __CM1CON0bits_t CM1CON0bits;
1372 #define _C1SYNC 0x01
1373 #define _C1HYS 0x02
1374 #define _C1SP 0x04
1375 #define _C1POL 0x10
1376 #define _C1OUT 0x40
1377 #define _C1ON 0x80
1379 //==============================================================================
1382 //==============================================================================
1383 // CM1CON1 Bits
1385 extern __at(0x0112) __sfr CM1CON1;
1387 typedef union
1389 struct
1391 unsigned C1NCH0 : 1;
1392 unsigned C1NCH1 : 1;
1393 unsigned C1NCH2 : 1;
1394 unsigned C1PCH0 : 1;
1395 unsigned C1PCH1 : 1;
1396 unsigned C1PCH2 : 1;
1397 unsigned C1INTN : 1;
1398 unsigned C1INTP : 1;
1401 struct
1403 unsigned C1NCH : 3;
1404 unsigned : 5;
1407 struct
1409 unsigned : 3;
1410 unsigned C1PCH : 3;
1411 unsigned : 2;
1413 } __CM1CON1bits_t;
1415 extern __at(0x0112) volatile __CM1CON1bits_t CM1CON1bits;
1417 #define _C1NCH0 0x01
1418 #define _C1NCH1 0x02
1419 #define _C1NCH2 0x04
1420 #define _C1PCH0 0x08
1421 #define _C1PCH1 0x10
1422 #define _C1PCH2 0x20
1423 #define _C1INTN 0x40
1424 #define _C1INTP 0x80
1426 //==============================================================================
1429 //==============================================================================
1430 // CM2CON0 Bits
1432 extern __at(0x0113) __sfr CM2CON0;
1434 typedef struct
1436 unsigned C2SYNC : 1;
1437 unsigned C2HYS : 1;
1438 unsigned C2SP : 1;
1439 unsigned : 1;
1440 unsigned C2POL : 1;
1441 unsigned : 1;
1442 unsigned C2OUT : 1;
1443 unsigned C2ON : 1;
1444 } __CM2CON0bits_t;
1446 extern __at(0x0113) volatile __CM2CON0bits_t CM2CON0bits;
1448 #define _C2SYNC 0x01
1449 #define _C2HYS 0x02
1450 #define _C2SP 0x04
1451 #define _C2POL 0x10
1452 #define _C2OUT 0x40
1453 #define _C2ON 0x80
1455 //==============================================================================
1458 //==============================================================================
1459 // CM2CON1 Bits
1461 extern __at(0x0114) __sfr CM2CON1;
1463 typedef union
1465 struct
1467 unsigned C2NCH0 : 1;
1468 unsigned C2NCH1 : 1;
1469 unsigned C2NCH2 : 1;
1470 unsigned C2PCH0 : 1;
1471 unsigned C2PCH1 : 1;
1472 unsigned C2PCH2 : 1;
1473 unsigned C2INTN : 1;
1474 unsigned C2INTP : 1;
1477 struct
1479 unsigned C2NCH : 3;
1480 unsigned : 5;
1483 struct
1485 unsigned : 3;
1486 unsigned C2PCH : 3;
1487 unsigned : 2;
1489 } __CM2CON1bits_t;
1491 extern __at(0x0114) volatile __CM2CON1bits_t CM2CON1bits;
1493 #define _C2NCH0 0x01
1494 #define _C2NCH1 0x02
1495 #define _C2NCH2 0x04
1496 #define _C2PCH0 0x08
1497 #define _C2PCH1 0x10
1498 #define _C2PCH2 0x20
1499 #define _C2INTN 0x40
1500 #define _C2INTP 0x80
1502 //==============================================================================
1505 //==============================================================================
1506 // CMOUT Bits
1508 extern __at(0x0115) __sfr CMOUT;
1510 typedef struct
1512 unsigned MC1OUT : 1;
1513 unsigned MC2OUT : 1;
1514 unsigned : 1;
1515 unsigned : 1;
1516 unsigned : 1;
1517 unsigned : 1;
1518 unsigned : 1;
1519 unsigned : 1;
1520 } __CMOUTbits_t;
1522 extern __at(0x0115) volatile __CMOUTbits_t CMOUTbits;
1524 #define _MC1OUT 0x01
1525 #define _MC2OUT 0x02
1527 //==============================================================================
1530 //==============================================================================
1531 // BORCON Bits
1533 extern __at(0x0116) __sfr BORCON;
1535 typedef struct
1537 unsigned BORRDY : 1;
1538 unsigned : 1;
1539 unsigned : 1;
1540 unsigned : 1;
1541 unsigned : 1;
1542 unsigned : 1;
1543 unsigned : 1;
1544 unsigned SBOREN : 1;
1545 } __BORCONbits_t;
1547 extern __at(0x0116) volatile __BORCONbits_t BORCONbits;
1549 #define _BORRDY 0x01
1550 #define _SBOREN 0x80
1552 //==============================================================================
1555 //==============================================================================
1556 // FVRCON Bits
1558 extern __at(0x0117) __sfr FVRCON;
1560 typedef union
1562 struct
1564 unsigned ADFVR0 : 1;
1565 unsigned ADFVR1 : 1;
1566 unsigned CDAFVR0 : 1;
1567 unsigned CDAFVR1 : 1;
1568 unsigned TSRNG : 1;
1569 unsigned TSEN : 1;
1570 unsigned FVRRDY : 1;
1571 unsigned FVREN : 1;
1574 struct
1576 unsigned ADFVR : 2;
1577 unsigned : 6;
1580 struct
1582 unsigned : 2;
1583 unsigned CDAFVR : 2;
1584 unsigned : 4;
1586 } __FVRCONbits_t;
1588 extern __at(0x0117) volatile __FVRCONbits_t FVRCONbits;
1590 #define _ADFVR0 0x01
1591 #define _ADFVR1 0x02
1592 #define _CDAFVR0 0x04
1593 #define _CDAFVR1 0x08
1594 #define _TSRNG 0x10
1595 #define _TSEN 0x20
1596 #define _FVRRDY 0x40
1597 #define _FVREN 0x80
1599 //==============================================================================
1602 //==============================================================================
1603 // DACCON0 Bits
1605 extern __at(0x0118) __sfr DACCON0;
1607 typedef union
1609 struct
1611 unsigned DAC1NSS : 1;
1612 unsigned : 1;
1613 unsigned DAC1PSS0 : 1;
1614 unsigned DAC1PSS1 : 1;
1615 unsigned : 1;
1616 unsigned DAC1OE : 1;
1617 unsigned : 1;
1618 unsigned DAC1EN : 1;
1621 struct
1623 unsigned : 2;
1624 unsigned DAC1PSS : 2;
1625 unsigned : 4;
1627 } __DACCON0bits_t;
1629 extern __at(0x0118) volatile __DACCON0bits_t DACCON0bits;
1631 #define _DAC1NSS 0x01
1632 #define _DAC1PSS0 0x04
1633 #define _DAC1PSS1 0x08
1634 #define _DAC1OE 0x20
1635 #define _DAC1EN 0x80
1637 //==============================================================================
1640 //==============================================================================
1641 // DACCON1 Bits
1643 extern __at(0x0119) __sfr DACCON1;
1645 typedef union
1647 struct
1649 unsigned DAC1R0 : 1;
1650 unsigned DAC1R1 : 1;
1651 unsigned DAC1R2 : 1;
1652 unsigned DAC1R3 : 1;
1653 unsigned DAC1R4 : 1;
1654 unsigned : 1;
1655 unsigned : 1;
1656 unsigned : 1;
1659 struct
1661 unsigned DAC1R : 5;
1662 unsigned : 3;
1664 } __DACCON1bits_t;
1666 extern __at(0x0119) volatile __DACCON1bits_t DACCON1bits;
1668 #define _DAC1R0 0x01
1669 #define _DAC1R1 0x02
1670 #define _DAC1R2 0x04
1671 #define _DAC1R3 0x08
1672 #define _DAC1R4 0x10
1674 //==============================================================================
1677 //==============================================================================
1678 // ANSELA Bits
1680 extern __at(0x018C) __sfr ANSELA;
1682 typedef struct
1684 unsigned ANSA0 : 1;
1685 unsigned ANSA1 : 1;
1686 unsigned ANSA2 : 1;
1687 unsigned : 1;
1688 unsigned ANSA4 : 1;
1689 unsigned ANSA5 : 1;
1690 unsigned : 1;
1691 unsigned : 1;
1692 } __ANSELAbits_t;
1694 extern __at(0x018C) volatile __ANSELAbits_t ANSELAbits;
1696 #define _ANSA0 0x01
1697 #define _ANSA1 0x02
1698 #define _ANSA2 0x04
1699 #define _ANSA4 0x10
1700 #define _ANSA5 0x20
1702 //==============================================================================
1705 //==============================================================================
1706 // ANSELC Bits
1708 extern __at(0x018E) __sfr ANSELC;
1710 typedef union
1712 struct
1714 unsigned ANSC0 : 1;
1715 unsigned ANSC1 : 1;
1716 unsigned ANSC2 : 1;
1717 unsigned ANSC3 : 1;
1718 unsigned ANSC4 : 1;
1719 unsigned ANSC5 : 1;
1720 unsigned : 1;
1721 unsigned : 1;
1724 struct
1726 unsigned ANSC : 6;
1727 unsigned : 2;
1729 } __ANSELCbits_t;
1731 extern __at(0x018E) volatile __ANSELCbits_t ANSELCbits;
1733 #define _ANSC0 0x01
1734 #define _ANSC1 0x02
1735 #define _ANSC2 0x04
1736 #define _ANSC3 0x08
1737 #define _ANSC4 0x10
1738 #define _ANSC5 0x20
1740 //==============================================================================
1742 extern __at(0x0199) __sfr RC1REG;
1743 extern __at(0x0199) __sfr RCREG;
1744 extern __at(0x0199) __sfr RCREG1;
1745 extern __at(0x019A) __sfr TX1REG;
1746 extern __at(0x019A) __sfr TXREG;
1747 extern __at(0x019A) __sfr TXREG1;
1748 extern __at(0x019B) __sfr SP1BRG;
1749 extern __at(0x019B) __sfr SP1BRGL;
1750 extern __at(0x019B) __sfr SPBRG;
1751 extern __at(0x019B) __sfr SPBRG1;
1752 extern __at(0x019B) __sfr SPBRGL;
1753 extern __at(0x019C) __sfr SP1BRGH;
1754 extern __at(0x019C) __sfr SPBRGH;
1755 extern __at(0x019C) __sfr SPBRGH1;
1757 //==============================================================================
1758 // RC1STA Bits
1760 extern __at(0x019D) __sfr RC1STA;
1762 typedef struct
1764 unsigned RX9D : 1;
1765 unsigned OERR : 1;
1766 unsigned FERR : 1;
1767 unsigned ADDEN : 1;
1768 unsigned CREN : 1;
1769 unsigned SREN : 1;
1770 unsigned RX9 : 1;
1771 unsigned SPEN : 1;
1772 } __RC1STAbits_t;
1774 extern __at(0x019D) volatile __RC1STAbits_t RC1STAbits;
1776 #define _RX9D 0x01
1777 #define _OERR 0x02
1778 #define _FERR 0x04
1779 #define _ADDEN 0x08
1780 #define _CREN 0x10
1781 #define _SREN 0x20
1782 #define _RX9 0x40
1783 #define _SPEN 0x80
1785 //==============================================================================
1788 //==============================================================================
1789 // RCSTA Bits
1791 extern __at(0x019D) __sfr RCSTA;
1793 typedef struct
1795 unsigned RX9D : 1;
1796 unsigned OERR : 1;
1797 unsigned FERR : 1;
1798 unsigned ADDEN : 1;
1799 unsigned CREN : 1;
1800 unsigned SREN : 1;
1801 unsigned RX9 : 1;
1802 unsigned SPEN : 1;
1803 } __RCSTAbits_t;
1805 extern __at(0x019D) volatile __RCSTAbits_t RCSTAbits;
1807 #define _RCSTA_RX9D 0x01
1808 #define _RCSTA_OERR 0x02
1809 #define _RCSTA_FERR 0x04
1810 #define _RCSTA_ADDEN 0x08
1811 #define _RCSTA_CREN 0x10
1812 #define _RCSTA_SREN 0x20
1813 #define _RCSTA_RX9 0x40
1814 #define _RCSTA_SPEN 0x80
1816 //==============================================================================
1819 //==============================================================================
1820 // RCSTA1 Bits
1822 extern __at(0x019D) __sfr RCSTA1;
1824 typedef struct
1826 unsigned RX9D : 1;
1827 unsigned OERR : 1;
1828 unsigned FERR : 1;
1829 unsigned ADDEN : 1;
1830 unsigned CREN : 1;
1831 unsigned SREN : 1;
1832 unsigned RX9 : 1;
1833 unsigned SPEN : 1;
1834 } __RCSTA1bits_t;
1836 extern __at(0x019D) volatile __RCSTA1bits_t RCSTA1bits;
1838 #define _RCSTA1_RX9D 0x01
1839 #define _RCSTA1_OERR 0x02
1840 #define _RCSTA1_FERR 0x04
1841 #define _RCSTA1_ADDEN 0x08
1842 #define _RCSTA1_CREN 0x10
1843 #define _RCSTA1_SREN 0x20
1844 #define _RCSTA1_RX9 0x40
1845 #define _RCSTA1_SPEN 0x80
1847 //==============================================================================
1850 //==============================================================================
1851 // TX1STA Bits
1853 extern __at(0x019E) __sfr TX1STA;
1855 typedef struct
1857 unsigned TX9D : 1;
1858 unsigned TRMT : 1;
1859 unsigned BRGH : 1;
1860 unsigned SENDB : 1;
1861 unsigned SYNC : 1;
1862 unsigned TXEN : 1;
1863 unsigned TX9 : 1;
1864 unsigned CSRC : 1;
1865 } __TX1STAbits_t;
1867 extern __at(0x019E) volatile __TX1STAbits_t TX1STAbits;
1869 #define _TX9D 0x01
1870 #define _TRMT 0x02
1871 #define _BRGH 0x04
1872 #define _SENDB 0x08
1873 #define _SYNC 0x10
1874 #define _TXEN 0x20
1875 #define _TX9 0x40
1876 #define _CSRC 0x80
1878 //==============================================================================
1881 //==============================================================================
1882 // TXSTA Bits
1884 extern __at(0x019E) __sfr TXSTA;
1886 typedef struct
1888 unsigned TX9D : 1;
1889 unsigned TRMT : 1;
1890 unsigned BRGH : 1;
1891 unsigned SENDB : 1;
1892 unsigned SYNC : 1;
1893 unsigned TXEN : 1;
1894 unsigned TX9 : 1;
1895 unsigned CSRC : 1;
1896 } __TXSTAbits_t;
1898 extern __at(0x019E) volatile __TXSTAbits_t TXSTAbits;
1900 #define _TXSTA_TX9D 0x01
1901 #define _TXSTA_TRMT 0x02
1902 #define _TXSTA_BRGH 0x04
1903 #define _TXSTA_SENDB 0x08
1904 #define _TXSTA_SYNC 0x10
1905 #define _TXSTA_TXEN 0x20
1906 #define _TXSTA_TX9 0x40
1907 #define _TXSTA_CSRC 0x80
1909 //==============================================================================
1912 //==============================================================================
1913 // TXSTA1 Bits
1915 extern __at(0x019E) __sfr TXSTA1;
1917 typedef struct
1919 unsigned TX9D : 1;
1920 unsigned TRMT : 1;
1921 unsigned BRGH : 1;
1922 unsigned SENDB : 1;
1923 unsigned SYNC : 1;
1924 unsigned TXEN : 1;
1925 unsigned TX9 : 1;
1926 unsigned CSRC : 1;
1927 } __TXSTA1bits_t;
1929 extern __at(0x019E) volatile __TXSTA1bits_t TXSTA1bits;
1931 #define _TXSTA1_TX9D 0x01
1932 #define _TXSTA1_TRMT 0x02
1933 #define _TXSTA1_BRGH 0x04
1934 #define _TXSTA1_SENDB 0x08
1935 #define _TXSTA1_SYNC 0x10
1936 #define _TXSTA1_TXEN 0x20
1937 #define _TXSTA1_TX9 0x40
1938 #define _TXSTA1_CSRC 0x80
1940 //==============================================================================
1943 //==============================================================================
1944 // BAUD1CON Bits
1946 extern __at(0x019F) __sfr BAUD1CON;
1948 typedef struct
1950 unsigned ABDEN : 1;
1951 unsigned WUE : 1;
1952 unsigned : 1;
1953 unsigned BRG16 : 1;
1954 unsigned SCKP : 1;
1955 unsigned : 1;
1956 unsigned RCIDL : 1;
1957 unsigned ABDOVF : 1;
1958 } __BAUD1CONbits_t;
1960 extern __at(0x019F) volatile __BAUD1CONbits_t BAUD1CONbits;
1962 #define _ABDEN 0x01
1963 #define _WUE 0x02
1964 #define _BRG16 0x08
1965 #define _SCKP 0x10
1966 #define _RCIDL 0x40
1967 #define _ABDOVF 0x80
1969 //==============================================================================
1972 //==============================================================================
1973 // BAUDCON Bits
1975 extern __at(0x019F) __sfr BAUDCON;
1977 typedef struct
1979 unsigned ABDEN : 1;
1980 unsigned WUE : 1;
1981 unsigned : 1;
1982 unsigned BRG16 : 1;
1983 unsigned SCKP : 1;
1984 unsigned : 1;
1985 unsigned RCIDL : 1;
1986 unsigned ABDOVF : 1;
1987 } __BAUDCONbits_t;
1989 extern __at(0x019F) volatile __BAUDCONbits_t BAUDCONbits;
1991 #define _BAUDCON_ABDEN 0x01
1992 #define _BAUDCON_WUE 0x02
1993 #define _BAUDCON_BRG16 0x08
1994 #define _BAUDCON_SCKP 0x10
1995 #define _BAUDCON_RCIDL 0x40
1996 #define _BAUDCON_ABDOVF 0x80
1998 //==============================================================================
2001 //==============================================================================
2002 // BAUDCON1 Bits
2004 extern __at(0x019F) __sfr BAUDCON1;
2006 typedef struct
2008 unsigned ABDEN : 1;
2009 unsigned WUE : 1;
2010 unsigned : 1;
2011 unsigned BRG16 : 1;
2012 unsigned SCKP : 1;
2013 unsigned : 1;
2014 unsigned RCIDL : 1;
2015 unsigned ABDOVF : 1;
2016 } __BAUDCON1bits_t;
2018 extern __at(0x019F) volatile __BAUDCON1bits_t BAUDCON1bits;
2020 #define _BAUDCON1_ABDEN 0x01
2021 #define _BAUDCON1_WUE 0x02
2022 #define _BAUDCON1_BRG16 0x08
2023 #define _BAUDCON1_SCKP 0x10
2024 #define _BAUDCON1_RCIDL 0x40
2025 #define _BAUDCON1_ABDOVF 0x80
2027 //==============================================================================
2030 //==============================================================================
2031 // BAUDCTL Bits
2033 extern __at(0x019F) __sfr BAUDCTL;
2035 typedef struct
2037 unsigned ABDEN : 1;
2038 unsigned WUE : 1;
2039 unsigned : 1;
2040 unsigned BRG16 : 1;
2041 unsigned SCKP : 1;
2042 unsigned : 1;
2043 unsigned RCIDL : 1;
2044 unsigned ABDOVF : 1;
2045 } __BAUDCTLbits_t;
2047 extern __at(0x019F) volatile __BAUDCTLbits_t BAUDCTLbits;
2049 #define _BAUDCTL_ABDEN 0x01
2050 #define _BAUDCTL_WUE 0x02
2051 #define _BAUDCTL_BRG16 0x08
2052 #define _BAUDCTL_SCKP 0x10
2053 #define _BAUDCTL_RCIDL 0x40
2054 #define _BAUDCTL_ABDOVF 0x80
2056 //==============================================================================
2059 //==============================================================================
2060 // BAUDCTL1 Bits
2062 extern __at(0x019F) __sfr BAUDCTL1;
2064 typedef struct
2066 unsigned ABDEN : 1;
2067 unsigned WUE : 1;
2068 unsigned : 1;
2069 unsigned BRG16 : 1;
2070 unsigned SCKP : 1;
2071 unsigned : 1;
2072 unsigned RCIDL : 1;
2073 unsigned ABDOVF : 1;
2074 } __BAUDCTL1bits_t;
2076 extern __at(0x019F) volatile __BAUDCTL1bits_t BAUDCTL1bits;
2078 #define _BAUDCTL1_ABDEN 0x01
2079 #define _BAUDCTL1_WUE 0x02
2080 #define _BAUDCTL1_BRG16 0x08
2081 #define _BAUDCTL1_SCKP 0x10
2082 #define _BAUDCTL1_RCIDL 0x40
2083 #define _BAUDCTL1_ABDOVF 0x80
2085 //==============================================================================
2088 //==============================================================================
2089 // WPUA Bits
2091 extern __at(0x020C) __sfr WPUA;
2093 typedef union
2095 struct
2097 unsigned WPUA0 : 1;
2098 unsigned WPUA1 : 1;
2099 unsigned WPUA2 : 1;
2100 unsigned WPUA3 : 1;
2101 unsigned WPUA4 : 1;
2102 unsigned WPUA5 : 1;
2103 unsigned : 1;
2104 unsigned : 1;
2107 struct
2109 unsigned WPUA : 6;
2110 unsigned : 2;
2112 } __WPUAbits_t;
2114 extern __at(0x020C) volatile __WPUAbits_t WPUAbits;
2116 #define _WPUA0 0x01
2117 #define _WPUA1 0x02
2118 #define _WPUA2 0x04
2119 #define _WPUA3 0x08
2120 #define _WPUA4 0x10
2121 #define _WPUA5 0x20
2123 //==============================================================================
2126 //==============================================================================
2127 // WPUC Bits
2129 extern __at(0x020E) __sfr WPUC;
2131 typedef union
2133 struct
2135 unsigned WPUC0 : 1;
2136 unsigned WPUC1 : 1;
2137 unsigned WPUC2 : 1;
2138 unsigned WPUC3 : 1;
2139 unsigned WPUC4 : 1;
2140 unsigned WPUC5 : 1;
2141 unsigned : 1;
2142 unsigned : 1;
2145 struct
2147 unsigned WPUC : 6;
2148 unsigned : 2;
2150 } __WPUCbits_t;
2152 extern __at(0x020E) volatile __WPUCbits_t WPUCbits;
2154 #define _WPUC0 0x01
2155 #define _WPUC1 0x02
2156 #define _WPUC2 0x04
2157 #define _WPUC3 0x08
2158 #define _WPUC4 0x10
2159 #define _WPUC5 0x20
2161 //==============================================================================
2164 //==============================================================================
2165 // SSP1BUF Bits
2167 extern __at(0x0211) __sfr SSP1BUF;
2169 typedef union
2171 struct
2173 unsigned SSP1BUF0 : 1;
2174 unsigned SSP1BUF1 : 1;
2175 unsigned SSP1BUF2 : 1;
2176 unsigned SSP1BUF3 : 1;
2177 unsigned SSP1BUF4 : 1;
2178 unsigned SSP1BUF5 : 1;
2179 unsigned SSP1BUF6 : 1;
2180 unsigned SSP1BUF7 : 1;
2183 struct
2185 unsigned BUF0 : 1;
2186 unsigned BUF1 : 1;
2187 unsigned BUF2 : 1;
2188 unsigned BUF3 : 1;
2189 unsigned BUF4 : 1;
2190 unsigned BUF5 : 1;
2191 unsigned BUF6 : 1;
2192 unsigned BUF7 : 1;
2194 } __SSP1BUFbits_t;
2196 extern __at(0x0211) volatile __SSP1BUFbits_t SSP1BUFbits;
2198 #define _SSP1BUF0 0x01
2199 #define _BUF0 0x01
2200 #define _SSP1BUF1 0x02
2201 #define _BUF1 0x02
2202 #define _SSP1BUF2 0x04
2203 #define _BUF2 0x04
2204 #define _SSP1BUF3 0x08
2205 #define _BUF3 0x08
2206 #define _SSP1BUF4 0x10
2207 #define _BUF4 0x10
2208 #define _SSP1BUF5 0x20
2209 #define _BUF5 0x20
2210 #define _SSP1BUF6 0x40
2211 #define _BUF6 0x40
2212 #define _SSP1BUF7 0x80
2213 #define _BUF7 0x80
2215 //==============================================================================
2218 //==============================================================================
2219 // SSPBUF Bits
2221 extern __at(0x0211) __sfr SSPBUF;
2223 typedef union
2225 struct
2227 unsigned SSP1BUF0 : 1;
2228 unsigned SSP1BUF1 : 1;
2229 unsigned SSP1BUF2 : 1;
2230 unsigned SSP1BUF3 : 1;
2231 unsigned SSP1BUF4 : 1;
2232 unsigned SSP1BUF5 : 1;
2233 unsigned SSP1BUF6 : 1;
2234 unsigned SSP1BUF7 : 1;
2237 struct
2239 unsigned BUF0 : 1;
2240 unsigned BUF1 : 1;
2241 unsigned BUF2 : 1;
2242 unsigned BUF3 : 1;
2243 unsigned BUF4 : 1;
2244 unsigned BUF5 : 1;
2245 unsigned BUF6 : 1;
2246 unsigned BUF7 : 1;
2248 } __SSPBUFbits_t;
2250 extern __at(0x0211) volatile __SSPBUFbits_t SSPBUFbits;
2252 #define _SSPBUF_SSP1BUF0 0x01
2253 #define _SSPBUF_BUF0 0x01
2254 #define _SSPBUF_SSP1BUF1 0x02
2255 #define _SSPBUF_BUF1 0x02
2256 #define _SSPBUF_SSP1BUF2 0x04
2257 #define _SSPBUF_BUF2 0x04
2258 #define _SSPBUF_SSP1BUF3 0x08
2259 #define _SSPBUF_BUF3 0x08
2260 #define _SSPBUF_SSP1BUF4 0x10
2261 #define _SSPBUF_BUF4 0x10
2262 #define _SSPBUF_SSP1BUF5 0x20
2263 #define _SSPBUF_BUF5 0x20
2264 #define _SSPBUF_SSP1BUF6 0x40
2265 #define _SSPBUF_BUF6 0x40
2266 #define _SSPBUF_SSP1BUF7 0x80
2267 #define _SSPBUF_BUF7 0x80
2269 //==============================================================================
2272 //==============================================================================
2273 // SSP1ADD Bits
2275 extern __at(0x0212) __sfr SSP1ADD;
2277 typedef union
2279 struct
2281 unsigned SSP1ADD0 : 1;
2282 unsigned SSP1ADD1 : 1;
2283 unsigned SSP1ADD2 : 1;
2284 unsigned SSP1ADD3 : 1;
2285 unsigned SSP1ADD4 : 1;
2286 unsigned SSP1ADD5 : 1;
2287 unsigned SSP1ADD6 : 1;
2288 unsigned SSP1ADD7 : 1;
2291 struct
2293 unsigned ADD0 : 1;
2294 unsigned ADD1 : 1;
2295 unsigned ADD2 : 1;
2296 unsigned ADD3 : 1;
2297 unsigned ADD4 : 1;
2298 unsigned ADD5 : 1;
2299 unsigned ADD6 : 1;
2300 unsigned ADD7 : 1;
2302 } __SSP1ADDbits_t;
2304 extern __at(0x0212) volatile __SSP1ADDbits_t SSP1ADDbits;
2306 #define _SSP1ADD0 0x01
2307 #define _ADD0 0x01
2308 #define _SSP1ADD1 0x02
2309 #define _ADD1 0x02
2310 #define _SSP1ADD2 0x04
2311 #define _ADD2 0x04
2312 #define _SSP1ADD3 0x08
2313 #define _ADD3 0x08
2314 #define _SSP1ADD4 0x10
2315 #define _ADD4 0x10
2316 #define _SSP1ADD5 0x20
2317 #define _ADD5 0x20
2318 #define _SSP1ADD6 0x40
2319 #define _ADD6 0x40
2320 #define _SSP1ADD7 0x80
2321 #define _ADD7 0x80
2323 //==============================================================================
2326 //==============================================================================
2327 // SSPADD Bits
2329 extern __at(0x0212) __sfr SSPADD;
2331 typedef union
2333 struct
2335 unsigned SSP1ADD0 : 1;
2336 unsigned SSP1ADD1 : 1;
2337 unsigned SSP1ADD2 : 1;
2338 unsigned SSP1ADD3 : 1;
2339 unsigned SSP1ADD4 : 1;
2340 unsigned SSP1ADD5 : 1;
2341 unsigned SSP1ADD6 : 1;
2342 unsigned SSP1ADD7 : 1;
2345 struct
2347 unsigned ADD0 : 1;
2348 unsigned ADD1 : 1;
2349 unsigned ADD2 : 1;
2350 unsigned ADD3 : 1;
2351 unsigned ADD4 : 1;
2352 unsigned ADD5 : 1;
2353 unsigned ADD6 : 1;
2354 unsigned ADD7 : 1;
2356 } __SSPADDbits_t;
2358 extern __at(0x0212) volatile __SSPADDbits_t SSPADDbits;
2360 #define _SSPADD_SSP1ADD0 0x01
2361 #define _SSPADD_ADD0 0x01
2362 #define _SSPADD_SSP1ADD1 0x02
2363 #define _SSPADD_ADD1 0x02
2364 #define _SSPADD_SSP1ADD2 0x04
2365 #define _SSPADD_ADD2 0x04
2366 #define _SSPADD_SSP1ADD3 0x08
2367 #define _SSPADD_ADD3 0x08
2368 #define _SSPADD_SSP1ADD4 0x10
2369 #define _SSPADD_ADD4 0x10
2370 #define _SSPADD_SSP1ADD5 0x20
2371 #define _SSPADD_ADD5 0x20
2372 #define _SSPADD_SSP1ADD6 0x40
2373 #define _SSPADD_ADD6 0x40
2374 #define _SSPADD_SSP1ADD7 0x80
2375 #define _SSPADD_ADD7 0x80
2377 //==============================================================================
2380 //==============================================================================
2381 // SSP1MSK Bits
2383 extern __at(0x0213) __sfr SSP1MSK;
2385 typedef union
2387 struct
2389 unsigned SSP1MSK0 : 1;
2390 unsigned SSP1MSK1 : 1;
2391 unsigned SSP1MSK2 : 1;
2392 unsigned SSP1MSK3 : 1;
2393 unsigned SSP1MSK4 : 1;
2394 unsigned SSP1MSK5 : 1;
2395 unsigned SSP1MSK6 : 1;
2396 unsigned SSP1MSK7 : 1;
2399 struct
2401 unsigned MSK0 : 1;
2402 unsigned MSK1 : 1;
2403 unsigned MSK2 : 1;
2404 unsigned MSK3 : 1;
2405 unsigned MSK4 : 1;
2406 unsigned MSK5 : 1;
2407 unsigned MSK6 : 1;
2408 unsigned MSK7 : 1;
2410 } __SSP1MSKbits_t;
2412 extern __at(0x0213) volatile __SSP1MSKbits_t SSP1MSKbits;
2414 #define _SSP1MSK0 0x01
2415 #define _MSK0 0x01
2416 #define _SSP1MSK1 0x02
2417 #define _MSK1 0x02
2418 #define _SSP1MSK2 0x04
2419 #define _MSK2 0x04
2420 #define _SSP1MSK3 0x08
2421 #define _MSK3 0x08
2422 #define _SSP1MSK4 0x10
2423 #define _MSK4 0x10
2424 #define _SSP1MSK5 0x20
2425 #define _MSK5 0x20
2426 #define _SSP1MSK6 0x40
2427 #define _MSK6 0x40
2428 #define _SSP1MSK7 0x80
2429 #define _MSK7 0x80
2431 //==============================================================================
2434 //==============================================================================
2435 // SSPMSK Bits
2437 extern __at(0x0213) __sfr SSPMSK;
2439 typedef union
2441 struct
2443 unsigned SSP1MSK0 : 1;
2444 unsigned SSP1MSK1 : 1;
2445 unsigned SSP1MSK2 : 1;
2446 unsigned SSP1MSK3 : 1;
2447 unsigned SSP1MSK4 : 1;
2448 unsigned SSP1MSK5 : 1;
2449 unsigned SSP1MSK6 : 1;
2450 unsigned SSP1MSK7 : 1;
2453 struct
2455 unsigned MSK0 : 1;
2456 unsigned MSK1 : 1;
2457 unsigned MSK2 : 1;
2458 unsigned MSK3 : 1;
2459 unsigned MSK4 : 1;
2460 unsigned MSK5 : 1;
2461 unsigned MSK6 : 1;
2462 unsigned MSK7 : 1;
2464 } __SSPMSKbits_t;
2466 extern __at(0x0213) volatile __SSPMSKbits_t SSPMSKbits;
2468 #define _SSPMSK_SSP1MSK0 0x01
2469 #define _SSPMSK_MSK0 0x01
2470 #define _SSPMSK_SSP1MSK1 0x02
2471 #define _SSPMSK_MSK1 0x02
2472 #define _SSPMSK_SSP1MSK2 0x04
2473 #define _SSPMSK_MSK2 0x04
2474 #define _SSPMSK_SSP1MSK3 0x08
2475 #define _SSPMSK_MSK3 0x08
2476 #define _SSPMSK_SSP1MSK4 0x10
2477 #define _SSPMSK_MSK4 0x10
2478 #define _SSPMSK_SSP1MSK5 0x20
2479 #define _SSPMSK_MSK5 0x20
2480 #define _SSPMSK_SSP1MSK6 0x40
2481 #define _SSPMSK_MSK6 0x40
2482 #define _SSPMSK_SSP1MSK7 0x80
2483 #define _SSPMSK_MSK7 0x80
2485 //==============================================================================
2488 //==============================================================================
2489 // SSP1STAT Bits
2491 extern __at(0x0214) __sfr SSP1STAT;
2493 typedef struct
2495 unsigned BF : 1;
2496 unsigned UA : 1;
2497 unsigned R_NOT_W : 1;
2498 unsigned S : 1;
2499 unsigned P : 1;
2500 unsigned D_NOT_A : 1;
2501 unsigned CKE : 1;
2502 unsigned SMP : 1;
2503 } __SSP1STATbits_t;
2505 extern __at(0x0214) volatile __SSP1STATbits_t SSP1STATbits;
2507 #define _BF 0x01
2508 #define _UA 0x02
2509 #define _R_NOT_W 0x04
2510 #define _S 0x08
2511 #define _P 0x10
2512 #define _D_NOT_A 0x20
2513 #define _CKE 0x40
2514 #define _SMP 0x80
2516 //==============================================================================
2519 //==============================================================================
2520 // SSPSTAT Bits
2522 extern __at(0x0214) __sfr SSPSTAT;
2524 typedef struct
2526 unsigned BF : 1;
2527 unsigned UA : 1;
2528 unsigned R_NOT_W : 1;
2529 unsigned S : 1;
2530 unsigned P : 1;
2531 unsigned D_NOT_A : 1;
2532 unsigned CKE : 1;
2533 unsigned SMP : 1;
2534 } __SSPSTATbits_t;
2536 extern __at(0x0214) volatile __SSPSTATbits_t SSPSTATbits;
2538 #define _SSPSTAT_BF 0x01
2539 #define _SSPSTAT_UA 0x02
2540 #define _SSPSTAT_R_NOT_W 0x04
2541 #define _SSPSTAT_S 0x08
2542 #define _SSPSTAT_P 0x10
2543 #define _SSPSTAT_D_NOT_A 0x20
2544 #define _SSPSTAT_CKE 0x40
2545 #define _SSPSTAT_SMP 0x80
2547 //==============================================================================
2550 //==============================================================================
2551 // SSP1CON Bits
2553 extern __at(0x0215) __sfr SSP1CON;
2555 typedef union
2557 struct
2559 unsigned SSPM0 : 1;
2560 unsigned SSPM1 : 1;
2561 unsigned SSPM2 : 1;
2562 unsigned SSPM3 : 1;
2563 unsigned CKP : 1;
2564 unsigned SSPEN : 1;
2565 unsigned SSPOV : 1;
2566 unsigned WCOL : 1;
2569 struct
2571 unsigned SSPM : 4;
2572 unsigned : 4;
2574 } __SSP1CONbits_t;
2576 extern __at(0x0215) volatile __SSP1CONbits_t SSP1CONbits;
2578 #define _SSPM0 0x01
2579 #define _SSPM1 0x02
2580 #define _SSPM2 0x04
2581 #define _SSPM3 0x08
2582 #define _CKP 0x10
2583 #define _SSPEN 0x20
2584 #define _SSPOV 0x40
2585 #define _WCOL 0x80
2587 //==============================================================================
2590 //==============================================================================
2591 // SSP1CON1 Bits
2593 extern __at(0x0215) __sfr SSP1CON1;
2595 typedef union
2597 struct
2599 unsigned SSPM0 : 1;
2600 unsigned SSPM1 : 1;
2601 unsigned SSPM2 : 1;
2602 unsigned SSPM3 : 1;
2603 unsigned CKP : 1;
2604 unsigned SSPEN : 1;
2605 unsigned SSPOV : 1;
2606 unsigned WCOL : 1;
2609 struct
2611 unsigned SSPM : 4;
2612 unsigned : 4;
2614 } __SSP1CON1bits_t;
2616 extern __at(0x0215) volatile __SSP1CON1bits_t SSP1CON1bits;
2618 #define _SSP1CON1_SSPM0 0x01
2619 #define _SSP1CON1_SSPM1 0x02
2620 #define _SSP1CON1_SSPM2 0x04
2621 #define _SSP1CON1_SSPM3 0x08
2622 #define _SSP1CON1_CKP 0x10
2623 #define _SSP1CON1_SSPEN 0x20
2624 #define _SSP1CON1_SSPOV 0x40
2625 #define _SSP1CON1_WCOL 0x80
2627 //==============================================================================
2630 //==============================================================================
2631 // SSPCON Bits
2633 extern __at(0x0215) __sfr SSPCON;
2635 typedef union
2637 struct
2639 unsigned SSPM0 : 1;
2640 unsigned SSPM1 : 1;
2641 unsigned SSPM2 : 1;
2642 unsigned SSPM3 : 1;
2643 unsigned CKP : 1;
2644 unsigned SSPEN : 1;
2645 unsigned SSPOV : 1;
2646 unsigned WCOL : 1;
2649 struct
2651 unsigned SSPM : 4;
2652 unsigned : 4;
2654 } __SSPCONbits_t;
2656 extern __at(0x0215) volatile __SSPCONbits_t SSPCONbits;
2658 #define _SSPCON_SSPM0 0x01
2659 #define _SSPCON_SSPM1 0x02
2660 #define _SSPCON_SSPM2 0x04
2661 #define _SSPCON_SSPM3 0x08
2662 #define _SSPCON_CKP 0x10
2663 #define _SSPCON_SSPEN 0x20
2664 #define _SSPCON_SSPOV 0x40
2665 #define _SSPCON_WCOL 0x80
2667 //==============================================================================
2670 //==============================================================================
2671 // SSPCON1 Bits
2673 extern __at(0x0215) __sfr SSPCON1;
2675 typedef union
2677 struct
2679 unsigned SSPM0 : 1;
2680 unsigned SSPM1 : 1;
2681 unsigned SSPM2 : 1;
2682 unsigned SSPM3 : 1;
2683 unsigned CKP : 1;
2684 unsigned SSPEN : 1;
2685 unsigned SSPOV : 1;
2686 unsigned WCOL : 1;
2689 struct
2691 unsigned SSPM : 4;
2692 unsigned : 4;
2694 } __SSPCON1bits_t;
2696 extern __at(0x0215) volatile __SSPCON1bits_t SSPCON1bits;
2698 #define _SSPCON1_SSPM0 0x01
2699 #define _SSPCON1_SSPM1 0x02
2700 #define _SSPCON1_SSPM2 0x04
2701 #define _SSPCON1_SSPM3 0x08
2702 #define _SSPCON1_CKP 0x10
2703 #define _SSPCON1_SSPEN 0x20
2704 #define _SSPCON1_SSPOV 0x40
2705 #define _SSPCON1_WCOL 0x80
2707 //==============================================================================
2710 //==============================================================================
2711 // SSP1CON2 Bits
2713 extern __at(0x0216) __sfr SSP1CON2;
2715 typedef struct
2717 unsigned SEN : 1;
2718 unsigned RSEN : 1;
2719 unsigned PEN : 1;
2720 unsigned RCEN : 1;
2721 unsigned ACKEN : 1;
2722 unsigned ACKDT : 1;
2723 unsigned ACKSTAT : 1;
2724 unsigned GCEN : 1;
2725 } __SSP1CON2bits_t;
2727 extern __at(0x0216) volatile __SSP1CON2bits_t SSP1CON2bits;
2729 #define _SEN 0x01
2730 #define _RSEN 0x02
2731 #define _PEN 0x04
2732 #define _RCEN 0x08
2733 #define _ACKEN 0x10
2734 #define _ACKDT 0x20
2735 #define _ACKSTAT 0x40
2736 #define _GCEN 0x80
2738 //==============================================================================
2741 //==============================================================================
2742 // SSPCON2 Bits
2744 extern __at(0x0216) __sfr SSPCON2;
2746 typedef struct
2748 unsigned SEN : 1;
2749 unsigned RSEN : 1;
2750 unsigned PEN : 1;
2751 unsigned RCEN : 1;
2752 unsigned ACKEN : 1;
2753 unsigned ACKDT : 1;
2754 unsigned ACKSTAT : 1;
2755 unsigned GCEN : 1;
2756 } __SSPCON2bits_t;
2758 extern __at(0x0216) volatile __SSPCON2bits_t SSPCON2bits;
2760 #define _SSPCON2_SEN 0x01
2761 #define _SSPCON2_RSEN 0x02
2762 #define _SSPCON2_PEN 0x04
2763 #define _SSPCON2_RCEN 0x08
2764 #define _SSPCON2_ACKEN 0x10
2765 #define _SSPCON2_ACKDT 0x20
2766 #define _SSPCON2_ACKSTAT 0x40
2767 #define _SSPCON2_GCEN 0x80
2769 //==============================================================================
2772 //==============================================================================
2773 // SSP1CON3 Bits
2775 extern __at(0x0217) __sfr SSP1CON3;
2777 typedef struct
2779 unsigned DHEN : 1;
2780 unsigned AHEN : 1;
2781 unsigned SBCDE : 1;
2782 unsigned SDAHT : 1;
2783 unsigned BOEN : 1;
2784 unsigned SCIE : 1;
2785 unsigned PCIE : 1;
2786 unsigned ACKTIM : 1;
2787 } __SSP1CON3bits_t;
2789 extern __at(0x0217) volatile __SSP1CON3bits_t SSP1CON3bits;
2791 #define _DHEN 0x01
2792 #define _AHEN 0x02
2793 #define _SBCDE 0x04
2794 #define _SDAHT 0x08
2795 #define _BOEN 0x10
2796 #define _SCIE 0x20
2797 #define _PCIE 0x40
2798 #define _ACKTIM 0x80
2800 //==============================================================================
2803 //==============================================================================
2804 // SSPCON3 Bits
2806 extern __at(0x0217) __sfr SSPCON3;
2808 typedef struct
2810 unsigned DHEN : 1;
2811 unsigned AHEN : 1;
2812 unsigned SBCDE : 1;
2813 unsigned SDAHT : 1;
2814 unsigned BOEN : 1;
2815 unsigned SCIE : 1;
2816 unsigned PCIE : 1;
2817 unsigned ACKTIM : 1;
2818 } __SSPCON3bits_t;
2820 extern __at(0x0217) volatile __SSPCON3bits_t SSPCON3bits;
2822 #define _SSPCON3_DHEN 0x01
2823 #define _SSPCON3_AHEN 0x02
2824 #define _SSPCON3_SBCDE 0x04
2825 #define _SSPCON3_SDAHT 0x08
2826 #define _SSPCON3_BOEN 0x10
2827 #define _SSPCON3_SCIE 0x20
2828 #define _SSPCON3_PCIE 0x40
2829 #define _SSPCON3_ACKTIM 0x80
2831 //==============================================================================
2834 //==============================================================================
2835 // ODCONA Bits
2837 extern __at(0x028C) __sfr ODCONA;
2839 typedef struct
2841 unsigned ODCA0 : 1;
2842 unsigned ODCA1 : 1;
2843 unsigned ODCA2 : 1;
2844 unsigned : 1;
2845 unsigned ODCA4 : 1;
2846 unsigned ODCA5 : 1;
2847 unsigned : 1;
2848 unsigned : 1;
2849 } __ODCONAbits_t;
2851 extern __at(0x028C) volatile __ODCONAbits_t ODCONAbits;
2853 #define _ODCA0 0x01
2854 #define _ODCA1 0x02
2855 #define _ODCA2 0x04
2856 #define _ODCA4 0x10
2857 #define _ODCA5 0x20
2859 //==============================================================================
2862 //==============================================================================
2863 // ODCONC Bits
2865 extern __at(0x028E) __sfr ODCONC;
2867 typedef union
2869 struct
2871 unsigned ODCC0 : 1;
2872 unsigned ODCC1 : 1;
2873 unsigned ODCC2 : 1;
2874 unsigned ODCC3 : 1;
2875 unsigned ODCC4 : 1;
2876 unsigned ODCC5 : 1;
2877 unsigned : 1;
2878 unsigned : 1;
2881 struct
2883 unsigned ODCC : 6;
2884 unsigned : 2;
2886 } __ODCONCbits_t;
2888 extern __at(0x028E) volatile __ODCONCbits_t ODCONCbits;
2890 #define _ODCC0 0x01
2891 #define _ODCC1 0x02
2892 #define _ODCC2 0x04
2893 #define _ODCC3 0x08
2894 #define _ODCC4 0x10
2895 #define _ODCC5 0x20
2897 //==============================================================================
2899 extern __at(0x0291) __sfr CCPR1;
2900 extern __at(0x0291) __sfr CCPR1L;
2901 extern __at(0x0292) __sfr CCPR1H;
2903 //==============================================================================
2904 // CCP1CON Bits
2906 extern __at(0x0293) __sfr CCP1CON;
2908 typedef union
2910 struct
2912 unsigned CCP1MODE0 : 1;
2913 unsigned CCP1MODE1 : 1;
2914 unsigned CCP1MODE2 : 1;
2915 unsigned CCP1MODE3 : 1;
2916 unsigned CCP1FMT : 1;
2917 unsigned CCP1OUT : 1;
2918 unsigned : 1;
2919 unsigned CCP1EN : 1;
2922 struct
2924 unsigned CCP1MODE : 4;
2925 unsigned : 4;
2927 } __CCP1CONbits_t;
2929 extern __at(0x0293) volatile __CCP1CONbits_t CCP1CONbits;
2931 #define _CCP1MODE0 0x01
2932 #define _CCP1MODE1 0x02
2933 #define _CCP1MODE2 0x04
2934 #define _CCP1MODE3 0x08
2935 #define _CCP1FMT 0x10
2936 #define _CCP1OUT 0x20
2937 #define _CCP1EN 0x80
2939 //==============================================================================
2942 //==============================================================================
2943 // CCP1CAP Bits
2945 extern __at(0x0294) __sfr CCP1CAP;
2947 typedef union
2949 struct
2951 unsigned CCP1CTS0 : 1;
2952 unsigned CCP1CTS1 : 1;
2953 unsigned CCP1CTS2 : 1;
2954 unsigned : 1;
2955 unsigned : 1;
2956 unsigned : 1;
2957 unsigned : 1;
2958 unsigned : 1;
2961 struct
2963 unsigned CCP1CTS : 3;
2964 unsigned : 5;
2966 } __CCP1CAPbits_t;
2968 extern __at(0x0294) volatile __CCP1CAPbits_t CCP1CAPbits;
2970 #define _CCP1CTS0 0x01
2971 #define _CCP1CTS1 0x02
2972 #define _CCP1CTS2 0x04
2974 //==============================================================================
2976 extern __at(0x0295) __sfr CCPR2;
2977 extern __at(0x0295) __sfr CCPR2L;
2978 extern __at(0x0296) __sfr CCPR2H;
2980 //==============================================================================
2981 // CCP2CON Bits
2983 extern __at(0x0297) __sfr CCP2CON;
2985 typedef union
2987 struct
2989 unsigned CCP2MODE0 : 1;
2990 unsigned CCP2MODE1 : 1;
2991 unsigned CCP2MODE2 : 1;
2992 unsigned CCP2MODE3 : 1;
2993 unsigned CCP2FMT : 1;
2994 unsigned CCP2OUT : 1;
2995 unsigned : 1;
2996 unsigned CCP2EN : 1;
2999 struct
3001 unsigned CCP2MODE : 4;
3002 unsigned : 4;
3004 } __CCP2CONbits_t;
3006 extern __at(0x0297) volatile __CCP2CONbits_t CCP2CONbits;
3008 #define _CCP2MODE0 0x01
3009 #define _CCP2MODE1 0x02
3010 #define _CCP2MODE2 0x04
3011 #define _CCP2MODE3 0x08
3012 #define _CCP2FMT 0x10
3013 #define _CCP2OUT 0x20
3014 #define _CCP2EN 0x80
3016 //==============================================================================
3019 //==============================================================================
3020 // CCP2CAP Bits
3022 extern __at(0x0298) __sfr CCP2CAP;
3024 typedef union
3026 struct
3028 unsigned CCP2CTS0 : 1;
3029 unsigned CCP2CTS1 : 1;
3030 unsigned CCP2CTS2 : 1;
3031 unsigned : 1;
3032 unsigned : 1;
3033 unsigned : 1;
3034 unsigned : 1;
3035 unsigned : 1;
3038 struct
3040 unsigned CCP2CTS : 3;
3041 unsigned : 5;
3043 } __CCP2CAPbits_t;
3045 extern __at(0x0298) volatile __CCP2CAPbits_t CCP2CAPbits;
3047 #define _CCP2CTS0 0x01
3048 #define _CCP2CTS1 0x02
3049 #define _CCP2CTS2 0x04
3051 //==============================================================================
3054 //==============================================================================
3055 // CCPTMRS Bits
3057 extern __at(0x029F) __sfr CCPTMRS;
3059 typedef struct
3061 unsigned C1TSEL : 1;
3062 unsigned : 1;
3063 unsigned C2TSEL : 1;
3064 unsigned : 1;
3065 unsigned : 1;
3066 unsigned : 1;
3067 unsigned : 1;
3068 unsigned : 1;
3069 } __CCPTMRSbits_t;
3071 extern __at(0x029F) volatile __CCPTMRSbits_t CCPTMRSbits;
3073 #define _C1TSEL 0x01
3074 #define _C2TSEL 0x04
3076 //==============================================================================
3079 //==============================================================================
3080 // SLRCONA Bits
3082 extern __at(0x030C) __sfr SLRCONA;
3084 typedef struct
3086 unsigned SLRA0 : 1;
3087 unsigned SLRA1 : 1;
3088 unsigned SLRA2 : 1;
3089 unsigned : 1;
3090 unsigned SLRA4 : 1;
3091 unsigned SLRA5 : 1;
3092 unsigned : 1;
3093 unsigned : 1;
3094 } __SLRCONAbits_t;
3096 extern __at(0x030C) volatile __SLRCONAbits_t SLRCONAbits;
3098 #define _SLRA0 0x01
3099 #define _SLRA1 0x02
3100 #define _SLRA2 0x04
3101 #define _SLRA4 0x10
3102 #define _SLRA5 0x20
3104 //==============================================================================
3107 //==============================================================================
3108 // SLRCONC Bits
3110 extern __at(0x030E) __sfr SLRCONC;
3112 typedef union
3114 struct
3116 unsigned SLRC0 : 1;
3117 unsigned SLRC1 : 1;
3118 unsigned SLRC2 : 1;
3119 unsigned SLRC3 : 1;
3120 unsigned SLRC4 : 1;
3121 unsigned SLRC5 : 1;
3122 unsigned : 1;
3123 unsigned : 1;
3126 struct
3128 unsigned SLRC : 6;
3129 unsigned : 2;
3131 } __SLRCONCbits_t;
3133 extern __at(0x030E) volatile __SLRCONCbits_t SLRCONCbits;
3135 #define _SLRC0 0x01
3136 #define _SLRC1 0x02
3137 #define _SLRC2 0x04
3138 #define _SLRC3 0x08
3139 #define _SLRC4 0x10
3140 #define _SLRC5 0x20
3142 //==============================================================================
3145 //==============================================================================
3146 // INLVLA Bits
3148 extern __at(0x038C) __sfr INLVLA;
3150 typedef union
3152 struct
3154 unsigned INLVLA0 : 1;
3155 unsigned INLVLA1 : 1;
3156 unsigned INLVLA2 : 1;
3157 unsigned INLVLA3 : 1;
3158 unsigned INLVLA4 : 1;
3159 unsigned INLVLA5 : 1;
3160 unsigned : 1;
3161 unsigned : 1;
3164 struct
3166 unsigned INLVLA : 6;
3167 unsigned : 2;
3169 } __INLVLAbits_t;
3171 extern __at(0x038C) volatile __INLVLAbits_t INLVLAbits;
3173 #define _INLVLA0 0x01
3174 #define _INLVLA1 0x02
3175 #define _INLVLA2 0x04
3176 #define _INLVLA3 0x08
3177 #define _INLVLA4 0x10
3178 #define _INLVLA5 0x20
3180 //==============================================================================
3183 //==============================================================================
3184 // INLVLC Bits
3186 extern __at(0x038E) __sfr INLVLC;
3188 typedef union
3190 struct
3192 unsigned INLVLC0 : 1;
3193 unsigned INLVLC1 : 1;
3194 unsigned INLVLC2 : 1;
3195 unsigned INLVLC3 : 1;
3196 unsigned INLVLC4 : 1;
3197 unsigned INLVLC5 : 1;
3198 unsigned : 1;
3199 unsigned : 1;
3202 struct
3204 unsigned INLVLC : 6;
3205 unsigned : 2;
3207 } __INLVLCbits_t;
3209 extern __at(0x038E) volatile __INLVLCbits_t INLVLCbits;
3211 #define _INLVLC0 0x01
3212 #define _INLVLC1 0x02
3213 #define _INLVLC2 0x04
3214 #define _INLVLC3 0x08
3215 #define _INLVLC4 0x10
3216 #define _INLVLC5 0x20
3218 //==============================================================================
3221 //==============================================================================
3222 // IOCAP Bits
3224 extern __at(0x0391) __sfr IOCAP;
3226 typedef union
3228 struct
3230 unsigned IOCAP0 : 1;
3231 unsigned IOCAP1 : 1;
3232 unsigned IOCAP2 : 1;
3233 unsigned IOCAP3 : 1;
3234 unsigned IOCAP4 : 1;
3235 unsigned IOCAP5 : 1;
3236 unsigned : 1;
3237 unsigned : 1;
3240 struct
3242 unsigned IOCAP : 6;
3243 unsigned : 2;
3245 } __IOCAPbits_t;
3247 extern __at(0x0391) volatile __IOCAPbits_t IOCAPbits;
3249 #define _IOCAP0 0x01
3250 #define _IOCAP1 0x02
3251 #define _IOCAP2 0x04
3252 #define _IOCAP3 0x08
3253 #define _IOCAP4 0x10
3254 #define _IOCAP5 0x20
3256 //==============================================================================
3259 //==============================================================================
3260 // IOCAN Bits
3262 extern __at(0x0392) __sfr IOCAN;
3264 typedef union
3266 struct
3268 unsigned IOCAN0 : 1;
3269 unsigned IOCAN1 : 1;
3270 unsigned IOCAN2 : 1;
3271 unsigned IOCAN3 : 1;
3272 unsigned IOCAN4 : 1;
3273 unsigned IOCAN5 : 1;
3274 unsigned : 1;
3275 unsigned : 1;
3278 struct
3280 unsigned IOCAN : 6;
3281 unsigned : 2;
3283 } __IOCANbits_t;
3285 extern __at(0x0392) volatile __IOCANbits_t IOCANbits;
3287 #define _IOCAN0 0x01
3288 #define _IOCAN1 0x02
3289 #define _IOCAN2 0x04
3290 #define _IOCAN3 0x08
3291 #define _IOCAN4 0x10
3292 #define _IOCAN5 0x20
3294 //==============================================================================
3297 //==============================================================================
3298 // IOCAF Bits
3300 extern __at(0x0393) __sfr IOCAF;
3302 typedef union
3304 struct
3306 unsigned IOCAF0 : 1;
3307 unsigned IOCAF1 : 1;
3308 unsigned IOCAF2 : 1;
3309 unsigned IOCAF3 : 1;
3310 unsigned IOCAF4 : 1;
3311 unsigned IOCAF5 : 1;
3312 unsigned : 1;
3313 unsigned : 1;
3316 struct
3318 unsigned IOCAF : 6;
3319 unsigned : 2;
3321 } __IOCAFbits_t;
3323 extern __at(0x0393) volatile __IOCAFbits_t IOCAFbits;
3325 #define _IOCAF0 0x01
3326 #define _IOCAF1 0x02
3327 #define _IOCAF2 0x04
3328 #define _IOCAF3 0x08
3329 #define _IOCAF4 0x10
3330 #define _IOCAF5 0x20
3332 //==============================================================================
3335 //==============================================================================
3336 // IOCCP Bits
3338 extern __at(0x0397) __sfr IOCCP;
3340 typedef union
3342 struct
3344 unsigned IOCCP0 : 1;
3345 unsigned IOCCP1 : 1;
3346 unsigned IOCCP2 : 1;
3347 unsigned IOCCP3 : 1;
3348 unsigned IOCCP4 : 1;
3349 unsigned IOCCP5 : 1;
3350 unsigned : 1;
3351 unsigned : 1;
3354 struct
3356 unsigned IOCCP : 6;
3357 unsigned : 2;
3359 } __IOCCPbits_t;
3361 extern __at(0x0397) volatile __IOCCPbits_t IOCCPbits;
3363 #define _IOCCP0 0x01
3364 #define _IOCCP1 0x02
3365 #define _IOCCP2 0x04
3366 #define _IOCCP3 0x08
3367 #define _IOCCP4 0x10
3368 #define _IOCCP5 0x20
3370 //==============================================================================
3373 //==============================================================================
3374 // IOCCN Bits
3376 extern __at(0x0398) __sfr IOCCN;
3378 typedef union
3380 struct
3382 unsigned IOCCN0 : 1;
3383 unsigned IOCCN1 : 1;
3384 unsigned IOCCN2 : 1;
3385 unsigned IOCCN3 : 1;
3386 unsigned IOCCN4 : 1;
3387 unsigned IOCCN5 : 1;
3388 unsigned : 1;
3389 unsigned : 1;
3392 struct
3394 unsigned IOCCN : 6;
3395 unsigned : 2;
3397 } __IOCCNbits_t;
3399 extern __at(0x0398) volatile __IOCCNbits_t IOCCNbits;
3401 #define _IOCCN0 0x01
3402 #define _IOCCN1 0x02
3403 #define _IOCCN2 0x04
3404 #define _IOCCN3 0x08
3405 #define _IOCCN4 0x10
3406 #define _IOCCN5 0x20
3408 //==============================================================================
3411 //==============================================================================
3412 // IOCCF Bits
3414 extern __at(0x0399) __sfr IOCCF;
3416 typedef union
3418 struct
3420 unsigned IOCCF0 : 1;
3421 unsigned IOCCF1 : 1;
3422 unsigned IOCCF2 : 1;
3423 unsigned IOCCF3 : 1;
3424 unsigned IOCCF4 : 1;
3425 unsigned IOCCF5 : 1;
3426 unsigned : 1;
3427 unsigned : 1;
3430 struct
3432 unsigned IOCCF : 6;
3433 unsigned : 2;
3435 } __IOCCFbits_t;
3437 extern __at(0x0399) volatile __IOCCFbits_t IOCCFbits;
3439 #define _IOCCF0 0x01
3440 #define _IOCCF1 0x02
3441 #define _IOCCF2 0x04
3442 #define _IOCCF3 0x08
3443 #define _IOCCF4 0x10
3444 #define _IOCCF5 0x20
3446 //==============================================================================
3449 //==============================================================================
3450 // CLKRCON Bits
3452 extern __at(0x039A) __sfr CLKRCON;
3454 typedef union
3456 struct
3458 unsigned CLKRDIV0 : 1;
3459 unsigned CLKRDIV1 : 1;
3460 unsigned CLKRDIV2 : 1;
3461 unsigned CLKRDC0 : 1;
3462 unsigned CLKRDC1 : 1;
3463 unsigned : 1;
3464 unsigned : 1;
3465 unsigned CLKREN : 1;
3468 struct
3470 unsigned CLKRDIV : 3;
3471 unsigned : 5;
3474 struct
3476 unsigned : 3;
3477 unsigned CLKRDC : 2;
3478 unsigned : 3;
3480 } __CLKRCONbits_t;
3482 extern __at(0x039A) volatile __CLKRCONbits_t CLKRCONbits;
3484 #define _CLKRDIV0 0x01
3485 #define _CLKRDIV1 0x02
3486 #define _CLKRDIV2 0x04
3487 #define _CLKRDC0 0x08
3488 #define _CLKRDC1 0x10
3489 #define _CLKREN 0x80
3491 //==============================================================================
3494 //==============================================================================
3495 // MDCON Bits
3497 extern __at(0x039C) __sfr MDCON;
3499 typedef struct
3501 unsigned MDBIT : 1;
3502 unsigned : 1;
3503 unsigned : 1;
3504 unsigned MDOUT : 1;
3505 unsigned MDOPOL : 1;
3506 unsigned : 1;
3507 unsigned : 1;
3508 unsigned MDEN : 1;
3509 } __MDCONbits_t;
3511 extern __at(0x039C) volatile __MDCONbits_t MDCONbits;
3513 #define _MDBIT 0x01
3514 #define _MDOUT 0x08
3515 #define _MDOPOL 0x10
3516 #define _MDEN 0x80
3518 //==============================================================================
3521 //==============================================================================
3522 // MDSRC Bits
3524 extern __at(0x039D) __sfr MDSRC;
3526 typedef union
3528 struct
3530 unsigned MDMS0 : 1;
3531 unsigned MDMS1 : 1;
3532 unsigned MDMS2 : 1;
3533 unsigned MDMS3 : 1;
3534 unsigned : 1;
3535 unsigned : 1;
3536 unsigned : 1;
3537 unsigned : 1;
3540 struct
3542 unsigned MDMS : 4;
3543 unsigned : 4;
3545 } __MDSRCbits_t;
3547 extern __at(0x039D) volatile __MDSRCbits_t MDSRCbits;
3549 #define _MDMS0 0x01
3550 #define _MDMS1 0x02
3551 #define _MDMS2 0x04
3552 #define _MDMS3 0x08
3554 //==============================================================================
3557 //==============================================================================
3558 // MDCARH Bits
3560 extern __at(0x039E) __sfr MDCARH;
3562 typedef union
3564 struct
3566 unsigned MDCH0 : 1;
3567 unsigned MDCH1 : 1;
3568 unsigned MDCH2 : 1;
3569 unsigned MDCH3 : 1;
3570 unsigned : 1;
3571 unsigned MDCHSYNC : 1;
3572 unsigned MDCHPOL : 1;
3573 unsigned : 1;
3576 struct
3578 unsigned MDCH : 4;
3579 unsigned : 4;
3581 } __MDCARHbits_t;
3583 extern __at(0x039E) volatile __MDCARHbits_t MDCARHbits;
3585 #define _MDCH0 0x01
3586 #define _MDCH1 0x02
3587 #define _MDCH2 0x04
3588 #define _MDCH3 0x08
3589 #define _MDCHSYNC 0x20
3590 #define _MDCHPOL 0x40
3592 //==============================================================================
3595 //==============================================================================
3596 // MDCARL Bits
3598 extern __at(0x039F) __sfr MDCARL;
3600 typedef union
3602 struct
3604 unsigned MDCL0 : 1;
3605 unsigned MDCL1 : 1;
3606 unsigned MDCL2 : 1;
3607 unsigned MDCL3 : 1;
3608 unsigned : 1;
3609 unsigned MDCLSYNC : 1;
3610 unsigned MDCLPOL : 1;
3611 unsigned : 1;
3614 struct
3616 unsigned MDCL : 4;
3617 unsigned : 4;
3619 } __MDCARLbits_t;
3621 extern __at(0x039F) volatile __MDCARLbits_t MDCARLbits;
3623 #define _MDCL0 0x01
3624 #define _MDCL1 0x02
3625 #define _MDCL2 0x04
3626 #define _MDCL3 0x08
3627 #define _MDCLSYNC 0x20
3628 #define _MDCLPOL 0x40
3630 //==============================================================================
3633 //==============================================================================
3634 // CCDNA Bits
3636 extern __at(0x040C) __sfr CCDNA;
3638 typedef struct
3640 unsigned CCDNA0 : 1;
3641 unsigned CCDNA1 : 1;
3642 unsigned CCDNA2 : 1;
3643 unsigned : 1;
3644 unsigned CCDNA4 : 1;
3645 unsigned CCDNA5 : 1;
3646 unsigned : 1;
3647 unsigned : 1;
3648 } __CCDNAbits_t;
3650 extern __at(0x040C) volatile __CCDNAbits_t CCDNAbits;
3652 #define _CCDNA0 0x01
3653 #define _CCDNA1 0x02
3654 #define _CCDNA2 0x04
3655 #define _CCDNA4 0x10
3656 #define _CCDNA5 0x20
3658 //==============================================================================
3661 //==============================================================================
3662 // CCDNC Bits
3664 extern __at(0x040E) __sfr CCDNC;
3666 typedef union
3668 struct
3670 unsigned CCDNC0 : 1;
3671 unsigned CCDNC1 : 1;
3672 unsigned CCDNC2 : 1;
3673 unsigned CCDNC3 : 1;
3674 unsigned CCDNC4 : 1;
3675 unsigned CCDNC5 : 1;
3676 unsigned : 1;
3677 unsigned : 1;
3680 struct
3682 unsigned CCDNC : 6;
3683 unsigned : 2;
3685 } __CCDNCbits_t;
3687 extern __at(0x040E) volatile __CCDNCbits_t CCDNCbits;
3689 #define _CCDNC0 0x01
3690 #define _CCDNC1 0x02
3691 #define _CCDNC2 0x04
3692 #define _CCDNC3 0x08
3693 #define _CCDNC4 0x10
3694 #define _CCDNC5 0x20
3696 //==============================================================================
3699 //==============================================================================
3700 // CCDCON Bits
3702 extern __at(0x041F) __sfr CCDCON;
3704 typedef union
3706 struct
3708 unsigned CCDS0 : 1;
3709 unsigned CCDS1 : 1;
3710 unsigned : 1;
3711 unsigned : 1;
3712 unsigned : 1;
3713 unsigned : 1;
3714 unsigned : 1;
3715 unsigned CCDEN : 1;
3718 struct
3720 unsigned CCDS : 2;
3721 unsigned : 6;
3723 } __CCDCONbits_t;
3725 extern __at(0x041F) volatile __CCDCONbits_t CCDCONbits;
3727 #define _CCDS0 0x01
3728 #define _CCDS1 0x02
3729 #define _CCDEN 0x80
3731 //==============================================================================
3734 //==============================================================================
3735 // CCDPA Bits
3737 extern __at(0x048C) __sfr CCDPA;
3739 typedef struct
3741 unsigned CCDPA0 : 1;
3742 unsigned CCDPA1 : 1;
3743 unsigned CCDPA2 : 1;
3744 unsigned : 1;
3745 unsigned CCDPA4 : 1;
3746 unsigned CCDPA5 : 1;
3747 unsigned : 1;
3748 unsigned : 1;
3749 } __CCDPAbits_t;
3751 extern __at(0x048C) volatile __CCDPAbits_t CCDPAbits;
3753 #define _CCDPA0 0x01
3754 #define _CCDPA1 0x02
3755 #define _CCDPA2 0x04
3756 #define _CCDPA4 0x10
3757 #define _CCDPA5 0x20
3759 //==============================================================================
3762 //==============================================================================
3763 // CCDPC Bits
3765 extern __at(0x048E) __sfr CCDPC;
3767 typedef union
3769 struct
3771 unsigned CCDPC0 : 1;
3772 unsigned CCDPC1 : 1;
3773 unsigned CCDPC2 : 1;
3774 unsigned CCDPC3 : 1;
3775 unsigned CCDPC4 : 1;
3776 unsigned CCDPC5 : 1;
3777 unsigned : 1;
3778 unsigned : 1;
3781 struct
3783 unsigned CCDPC : 6;
3784 unsigned : 2;
3786 } __CCDPCbits_t;
3788 extern __at(0x048E) volatile __CCDPCbits_t CCDPCbits;
3790 #define _CCDPC0 0x01
3791 #define _CCDPC1 0x02
3792 #define _CCDPC2 0x04
3793 #define _CCDPC3 0x08
3794 #define _CCDPC4 0x10
3795 #define _CCDPC5 0x20
3797 //==============================================================================
3799 extern __at(0x0498) __sfr NCO1ACC;
3800 extern __at(0x0498) __sfr NCO1ACCL;
3801 extern __at(0x0499) __sfr NCO1ACCH;
3802 extern __at(0x049A) __sfr NCO1ACCU;
3803 extern __at(0x049B) __sfr NCO1INC;
3804 extern __at(0x049B) __sfr NCO1INCL;
3805 extern __at(0x049C) __sfr NCO1INCH;
3806 extern __at(0x049D) __sfr NCO1INCU;
3808 //==============================================================================
3809 // NCO1CON Bits
3811 extern __at(0x049E) __sfr NCO1CON;
3813 typedef struct
3815 unsigned N1PFM : 1;
3816 unsigned : 1;
3817 unsigned : 1;
3818 unsigned : 1;
3819 unsigned N1POL : 1;
3820 unsigned N1OUT : 1;
3821 unsigned : 1;
3822 unsigned N1EN : 1;
3823 } __NCO1CONbits_t;
3825 extern __at(0x049E) volatile __NCO1CONbits_t NCO1CONbits;
3827 #define _N1PFM 0x01
3828 #define _N1POL 0x10
3829 #define _N1OUT 0x20
3830 #define _N1EN 0x80
3832 //==============================================================================
3834 extern __at(0x049F) __sfr NCO1CLK;
3836 //==============================================================================
3837 // PWM5DCL Bits
3839 extern __at(0x0617) __sfr PWM5DCL;
3841 typedef union
3843 struct
3845 unsigned : 1;
3846 unsigned : 1;
3847 unsigned : 1;
3848 unsigned : 1;
3849 unsigned : 1;
3850 unsigned : 1;
3851 unsigned PWM5DCL0 : 1;
3852 unsigned PWM5DCL1 : 1;
3855 struct
3857 unsigned : 6;
3858 unsigned PWM5DCL : 2;
3860 } __PWM5DCLbits_t;
3862 extern __at(0x0617) volatile __PWM5DCLbits_t PWM5DCLbits;
3864 #define _PWM5DCL0 0x40
3865 #define _PWM5DCL1 0x80
3867 //==============================================================================
3870 //==============================================================================
3871 // PWM5DCH Bits
3873 extern __at(0x0618) __sfr PWM5DCH;
3875 typedef struct
3877 unsigned PWM5DCH0 : 1;
3878 unsigned PWM5DCH1 : 1;
3879 unsigned PWM5DCH2 : 1;
3880 unsigned PWM5DCH3 : 1;
3881 unsigned PWM5DCH4 : 1;
3882 unsigned PWM5DCH5 : 1;
3883 unsigned PWM5DCH6 : 1;
3884 unsigned PWM5DCH7 : 1;
3885 } __PWM5DCHbits_t;
3887 extern __at(0x0618) volatile __PWM5DCHbits_t PWM5DCHbits;
3889 #define _PWM5DCH0 0x01
3890 #define _PWM5DCH1 0x02
3891 #define _PWM5DCH2 0x04
3892 #define _PWM5DCH3 0x08
3893 #define _PWM5DCH4 0x10
3894 #define _PWM5DCH5 0x20
3895 #define _PWM5DCH6 0x40
3896 #define _PWM5DCH7 0x80
3898 //==============================================================================
3901 //==============================================================================
3902 // PWM5CON Bits
3904 extern __at(0x0619) __sfr PWM5CON;
3906 typedef struct
3908 unsigned : 1;
3909 unsigned : 1;
3910 unsigned : 1;
3911 unsigned : 1;
3912 unsigned PWM5POL : 1;
3913 unsigned PWM5OUT : 1;
3914 unsigned : 1;
3915 unsigned PWM5EN : 1;
3916 } __PWM5CONbits_t;
3918 extern __at(0x0619) volatile __PWM5CONbits_t PWM5CONbits;
3920 #define _PWM5POL 0x10
3921 #define _PWM5OUT 0x20
3922 #define _PWM5EN 0x80
3924 //==============================================================================
3927 //==============================================================================
3928 // PWM5CON0 Bits
3930 extern __at(0x0619) __sfr PWM5CON0;
3932 typedef struct
3934 unsigned : 1;
3935 unsigned : 1;
3936 unsigned : 1;
3937 unsigned : 1;
3938 unsigned PWM5POL : 1;
3939 unsigned PWM5OUT : 1;
3940 unsigned : 1;
3941 unsigned PWM5EN : 1;
3942 } __PWM5CON0bits_t;
3944 extern __at(0x0619) volatile __PWM5CON0bits_t PWM5CON0bits;
3946 #define _PWM5CON0_PWM5POL 0x10
3947 #define _PWM5CON0_PWM5OUT 0x20
3948 #define _PWM5CON0_PWM5EN 0x80
3950 //==============================================================================
3953 //==============================================================================
3954 // PWM6DCL Bits
3956 extern __at(0x061A) __sfr PWM6DCL;
3958 typedef union
3960 struct
3962 unsigned : 1;
3963 unsigned : 1;
3964 unsigned : 1;
3965 unsigned : 1;
3966 unsigned : 1;
3967 unsigned : 1;
3968 unsigned PWM6DCL0 : 1;
3969 unsigned PWM6DCL1 : 1;
3972 struct
3974 unsigned : 6;
3975 unsigned PWM6DCL : 2;
3977 } __PWM6DCLbits_t;
3979 extern __at(0x061A) volatile __PWM6DCLbits_t PWM6DCLbits;
3981 #define _PWM6DCL0 0x40
3982 #define _PWM6DCL1 0x80
3984 //==============================================================================
3987 //==============================================================================
3988 // PWM6DCH Bits
3990 extern __at(0x061B) __sfr PWM6DCH;
3992 typedef struct
3994 unsigned PWM6DCH0 : 1;
3995 unsigned PWM6DCH1 : 1;
3996 unsigned PWM6DCH2 : 1;
3997 unsigned PWM6DCH3 : 1;
3998 unsigned PWM6DCH4 : 1;
3999 unsigned PWM6DCH5 : 1;
4000 unsigned PWM6DCH6 : 1;
4001 unsigned PWM6DCH7 : 1;
4002 } __PWM6DCHbits_t;
4004 extern __at(0x061B) volatile __PWM6DCHbits_t PWM6DCHbits;
4006 #define _PWM6DCH0 0x01
4007 #define _PWM6DCH1 0x02
4008 #define _PWM6DCH2 0x04
4009 #define _PWM6DCH3 0x08
4010 #define _PWM6DCH4 0x10
4011 #define _PWM6DCH5 0x20
4012 #define _PWM6DCH6 0x40
4013 #define _PWM6DCH7 0x80
4015 //==============================================================================
4018 //==============================================================================
4019 // PWM6CON Bits
4021 extern __at(0x061C) __sfr PWM6CON;
4023 typedef struct
4025 unsigned : 1;
4026 unsigned : 1;
4027 unsigned : 1;
4028 unsigned : 1;
4029 unsigned PWM6POL : 1;
4030 unsigned PWM6OUT : 1;
4031 unsigned : 1;
4032 unsigned PWM6EN : 1;
4033 } __PWM6CONbits_t;
4035 extern __at(0x061C) volatile __PWM6CONbits_t PWM6CONbits;
4037 #define _PWM6POL 0x10
4038 #define _PWM6OUT 0x20
4039 #define _PWM6EN 0x80
4041 //==============================================================================
4044 //==============================================================================
4045 // PWM6CON0 Bits
4047 extern __at(0x061C) __sfr PWM6CON0;
4049 typedef struct
4051 unsigned : 1;
4052 unsigned : 1;
4053 unsigned : 1;
4054 unsigned : 1;
4055 unsigned PWM6POL : 1;
4056 unsigned PWM6OUT : 1;
4057 unsigned : 1;
4058 unsigned PWM6EN : 1;
4059 } __PWM6CON0bits_t;
4061 extern __at(0x061C) volatile __PWM6CON0bits_t PWM6CON0bits;
4063 #define _PWM6CON0_PWM6POL 0x10
4064 #define _PWM6CON0_PWM6OUT 0x20
4065 #define _PWM6CON0_PWM6EN 0x80
4067 //==============================================================================
4070 //==============================================================================
4071 // CWG1CLKCON Bits
4073 extern __at(0x0691) __sfr CWG1CLKCON;
4075 typedef union
4077 struct
4079 unsigned CS : 1;
4080 unsigned : 1;
4081 unsigned : 1;
4082 unsigned : 1;
4083 unsigned : 1;
4084 unsigned : 1;
4085 unsigned : 1;
4086 unsigned : 1;
4089 struct
4091 unsigned CWG1CS : 1;
4092 unsigned : 1;
4093 unsigned : 1;
4094 unsigned : 1;
4095 unsigned : 1;
4096 unsigned : 1;
4097 unsigned : 1;
4098 unsigned : 1;
4100 } __CWG1CLKCONbits_t;
4102 extern __at(0x0691) volatile __CWG1CLKCONbits_t CWG1CLKCONbits;
4104 #define _CS 0x01
4105 #define _CWG1CS 0x01
4107 //==============================================================================
4110 //==============================================================================
4111 // CWG1DAT Bits
4113 extern __at(0x0692) __sfr CWG1DAT;
4115 typedef union
4117 struct
4119 unsigned CWG1DAT0 : 1;
4120 unsigned CWG1DAT1 : 1;
4121 unsigned CWG1DAT2 : 1;
4122 unsigned CWG1DAT3 : 1;
4123 unsigned : 1;
4124 unsigned : 1;
4125 unsigned : 1;
4126 unsigned : 1;
4129 struct
4131 unsigned CWG1DAT : 4;
4132 unsigned : 4;
4134 } __CWG1DATbits_t;
4136 extern __at(0x0692) volatile __CWG1DATbits_t CWG1DATbits;
4138 #define _CWG1DAT0 0x01
4139 #define _CWG1DAT1 0x02
4140 #define _CWG1DAT2 0x04
4141 #define _CWG1DAT3 0x08
4143 //==============================================================================
4146 //==============================================================================
4147 // CWG1DBR Bits
4149 extern __at(0x0693) __sfr CWG1DBR;
4151 typedef union
4153 struct
4155 unsigned DBR0 : 1;
4156 unsigned DBR1 : 1;
4157 unsigned DBR2 : 1;
4158 unsigned DBR3 : 1;
4159 unsigned DBR4 : 1;
4160 unsigned DBR5 : 1;
4161 unsigned : 1;
4162 unsigned : 1;
4165 struct
4167 unsigned CWG1DBR0 : 1;
4168 unsigned CWG1DBR1 : 1;
4169 unsigned CWG1DBR2 : 1;
4170 unsigned CWG1DBR3 : 1;
4171 unsigned CWG1DBR4 : 1;
4172 unsigned CWG1DBR5 : 1;
4173 unsigned : 1;
4174 unsigned : 1;
4177 struct
4179 unsigned CWG1DBR : 6;
4180 unsigned : 2;
4183 struct
4185 unsigned DBR : 6;
4186 unsigned : 2;
4188 } __CWG1DBRbits_t;
4190 extern __at(0x0693) volatile __CWG1DBRbits_t CWG1DBRbits;
4192 #define _DBR0 0x01
4193 #define _CWG1DBR0 0x01
4194 #define _DBR1 0x02
4195 #define _CWG1DBR1 0x02
4196 #define _DBR2 0x04
4197 #define _CWG1DBR2 0x04
4198 #define _DBR3 0x08
4199 #define _CWG1DBR3 0x08
4200 #define _DBR4 0x10
4201 #define _CWG1DBR4 0x10
4202 #define _DBR5 0x20
4203 #define _CWG1DBR5 0x20
4205 //==============================================================================
4208 //==============================================================================
4209 // CWG1DBF Bits
4211 extern __at(0x0694) __sfr CWG1DBF;
4213 typedef union
4215 struct
4217 unsigned DBF0 : 1;
4218 unsigned DBF1 : 1;
4219 unsigned DBF2 : 1;
4220 unsigned DBF3 : 1;
4221 unsigned DBF4 : 1;
4222 unsigned DBF5 : 1;
4223 unsigned : 1;
4224 unsigned : 1;
4227 struct
4229 unsigned CWG1DBF0 : 1;
4230 unsigned CWG1DBF1 : 1;
4231 unsigned CWG1DBF2 : 1;
4232 unsigned CWG1DBF3 : 1;
4233 unsigned CWG1DBF4 : 1;
4234 unsigned CWG1DBF5 : 1;
4235 unsigned : 1;
4236 unsigned : 1;
4239 struct
4241 unsigned CWG1DBF : 6;
4242 unsigned : 2;
4245 struct
4247 unsigned DBF : 6;
4248 unsigned : 2;
4250 } __CWG1DBFbits_t;
4252 extern __at(0x0694) volatile __CWG1DBFbits_t CWG1DBFbits;
4254 #define _DBF0 0x01
4255 #define _CWG1DBF0 0x01
4256 #define _DBF1 0x02
4257 #define _CWG1DBF1 0x02
4258 #define _DBF2 0x04
4259 #define _CWG1DBF2 0x04
4260 #define _DBF3 0x08
4261 #define _CWG1DBF3 0x08
4262 #define _DBF4 0x10
4263 #define _CWG1DBF4 0x10
4264 #define _DBF5 0x20
4265 #define _CWG1DBF5 0x20
4267 //==============================================================================
4270 //==============================================================================
4271 // CWG1CON0 Bits
4273 extern __at(0x0695) __sfr CWG1CON0;
4275 typedef union
4277 struct
4279 unsigned MODE0 : 1;
4280 unsigned MODE1 : 1;
4281 unsigned MODE2 : 1;
4282 unsigned : 1;
4283 unsigned : 1;
4284 unsigned : 1;
4285 unsigned LD : 1;
4286 unsigned EN : 1;
4289 struct
4291 unsigned CWG1MODE0 : 1;
4292 unsigned CWG1MODE1 : 1;
4293 unsigned CWG1MODE2 : 1;
4294 unsigned : 1;
4295 unsigned : 1;
4296 unsigned : 1;
4297 unsigned CWG1LD : 1;
4298 unsigned G1EN : 1;
4301 struct
4303 unsigned : 1;
4304 unsigned : 1;
4305 unsigned : 1;
4306 unsigned : 1;
4307 unsigned : 1;
4308 unsigned : 1;
4309 unsigned : 1;
4310 unsigned CWG1EN : 1;
4313 struct
4315 unsigned MODE : 3;
4316 unsigned : 5;
4319 struct
4321 unsigned CWG1MODE : 3;
4322 unsigned : 5;
4324 } __CWG1CON0bits_t;
4326 extern __at(0x0695) volatile __CWG1CON0bits_t CWG1CON0bits;
4328 #define _CWG1CON0_MODE0 0x01
4329 #define _CWG1CON0_CWG1MODE0 0x01
4330 #define _CWG1CON0_MODE1 0x02
4331 #define _CWG1CON0_CWG1MODE1 0x02
4332 #define _CWG1CON0_MODE2 0x04
4333 #define _CWG1CON0_CWG1MODE2 0x04
4334 #define _CWG1CON0_LD 0x40
4335 #define _CWG1CON0_CWG1LD 0x40
4336 #define _CWG1CON0_EN 0x80
4337 #define _CWG1CON0_G1EN 0x80
4338 #define _CWG1CON0_CWG1EN 0x80
4340 //==============================================================================
4343 //==============================================================================
4344 // CWG1CON1 Bits
4346 extern __at(0x0696) __sfr CWG1CON1;
4348 typedef union
4350 struct
4352 unsigned POLA : 1;
4353 unsigned POLB : 1;
4354 unsigned POLC : 1;
4355 unsigned POLD : 1;
4356 unsigned : 1;
4357 unsigned IN : 1;
4358 unsigned : 1;
4359 unsigned : 1;
4362 struct
4364 unsigned CWG1POLA : 1;
4365 unsigned CWG1POLB : 1;
4366 unsigned CWG1POLC : 1;
4367 unsigned CWG1POLD : 1;
4368 unsigned : 1;
4369 unsigned CWG1IN : 1;
4370 unsigned : 1;
4371 unsigned : 1;
4373 } __CWG1CON1bits_t;
4375 extern __at(0x0696) volatile __CWG1CON1bits_t CWG1CON1bits;
4377 #define _POLA 0x01
4378 #define _CWG1POLA 0x01
4379 #define _POLB 0x02
4380 #define _CWG1POLB 0x02
4381 #define _POLC 0x04
4382 #define _CWG1POLC 0x04
4383 #define _POLD 0x08
4384 #define _CWG1POLD 0x08
4385 #define _IN 0x20
4386 #define _CWG1IN 0x20
4388 //==============================================================================
4391 //==============================================================================
4392 // CWG1AS0 Bits
4394 extern __at(0x0697) __sfr CWG1AS0;
4396 typedef union
4398 struct
4400 unsigned : 1;
4401 unsigned : 1;
4402 unsigned LSAC0 : 1;
4403 unsigned LSAC1 : 1;
4404 unsigned LSBD0 : 1;
4405 unsigned LSBD1 : 1;
4406 unsigned REN : 1;
4407 unsigned SHUTDOWN : 1;
4410 struct
4412 unsigned : 1;
4413 unsigned : 1;
4414 unsigned CWG1LSAC0 : 1;
4415 unsigned CWG1LSAC1 : 1;
4416 unsigned CWG1LSBD0 : 1;
4417 unsigned CWG1LSBD1 : 1;
4418 unsigned CWG1REN : 1;
4419 unsigned CWG1SHUTDOWN : 1;
4422 struct
4424 unsigned : 2;
4425 unsigned CWG1LSAC : 2;
4426 unsigned : 4;
4429 struct
4431 unsigned : 2;
4432 unsigned LSAC : 2;
4433 unsigned : 4;
4436 struct
4438 unsigned : 4;
4439 unsigned CWG1LSBD : 2;
4440 unsigned : 2;
4443 struct
4445 unsigned : 4;
4446 unsigned LSBD : 2;
4447 unsigned : 2;
4449 } __CWG1AS0bits_t;
4451 extern __at(0x0697) volatile __CWG1AS0bits_t CWG1AS0bits;
4453 #define _LSAC0 0x04
4454 #define _CWG1LSAC0 0x04
4455 #define _LSAC1 0x08
4456 #define _CWG1LSAC1 0x08
4457 #define _LSBD0 0x10
4458 #define _CWG1LSBD0 0x10
4459 #define _LSBD1 0x20
4460 #define _CWG1LSBD1 0x20
4461 #define _REN 0x40
4462 #define _CWG1REN 0x40
4463 #define _SHUTDOWN 0x80
4464 #define _CWG1SHUTDOWN 0x80
4466 //==============================================================================
4469 //==============================================================================
4470 // CWG1AS1 Bits
4472 extern __at(0x0698) __sfr CWG1AS1;
4474 typedef struct
4476 unsigned AS0E : 1;
4477 unsigned AS1E : 1;
4478 unsigned AS2E : 1;
4479 unsigned AS3E : 1;
4480 unsigned : 1;
4481 unsigned : 1;
4482 unsigned : 1;
4483 unsigned : 1;
4484 } __CWG1AS1bits_t;
4486 extern __at(0x0698) volatile __CWG1AS1bits_t CWG1AS1bits;
4488 #define _AS0E 0x01
4489 #define _AS1E 0x02
4490 #define _AS2E 0x04
4491 #define _AS3E 0x08
4493 //==============================================================================
4496 //==============================================================================
4497 // CWG1STR Bits
4499 extern __at(0x0699) __sfr CWG1STR;
4501 typedef union
4503 struct
4505 unsigned STRA : 1;
4506 unsigned STRB : 1;
4507 unsigned STRC : 1;
4508 unsigned STRD : 1;
4509 unsigned OVRA : 1;
4510 unsigned OVRB : 1;
4511 unsigned OVRC : 1;
4512 unsigned OVRD : 1;
4515 struct
4517 unsigned CWG1STRA : 1;
4518 unsigned CWG1STRB : 1;
4519 unsigned CWG1STRC : 1;
4520 unsigned CWG1STRD : 1;
4521 unsigned CWG1OVRA : 1;
4522 unsigned CWG1OVRB : 1;
4523 unsigned CWG1OVRC : 1;
4524 unsigned CWG1OVRD : 1;
4526 } __CWG1STRbits_t;
4528 extern __at(0x0699) volatile __CWG1STRbits_t CWG1STRbits;
4530 #define _STRA 0x01
4531 #define _CWG1STRA 0x01
4532 #define _STRB 0x02
4533 #define _CWG1STRB 0x02
4534 #define _STRC 0x04
4535 #define _CWG1STRC 0x04
4536 #define _STRD 0x08
4537 #define _CWG1STRD 0x08
4538 #define _OVRA 0x10
4539 #define _CWG1OVRA 0x10
4540 #define _OVRB 0x20
4541 #define _CWG1OVRB 0x20
4542 #define _OVRC 0x40
4543 #define _CWG1OVRC 0x40
4544 #define _OVRD 0x80
4545 #define _CWG1OVRD 0x80
4547 //==============================================================================
4549 extern __at(0x0891) __sfr NVMADR;
4551 //==============================================================================
4552 // NVMADRL Bits
4554 extern __at(0x0891) __sfr NVMADRL;
4556 typedef struct
4558 unsigned NVMADR0 : 1;
4559 unsigned NVMADR1 : 1;
4560 unsigned NVMADR2 : 1;
4561 unsigned NVMADR3 : 1;
4562 unsigned NVMADR4 : 1;
4563 unsigned NVMADR5 : 1;
4564 unsigned NVMADR6 : 1;
4565 unsigned NVMADR7 : 1;
4566 } __NVMADRLbits_t;
4568 extern __at(0x0891) volatile __NVMADRLbits_t NVMADRLbits;
4570 #define _NVMADR0 0x01
4571 #define _NVMADR1 0x02
4572 #define _NVMADR2 0x04
4573 #define _NVMADR3 0x08
4574 #define _NVMADR4 0x10
4575 #define _NVMADR5 0x20
4576 #define _NVMADR6 0x40
4577 #define _NVMADR7 0x80
4579 //==============================================================================
4582 //==============================================================================
4583 // NVMADRH Bits
4585 extern __at(0x0892) __sfr NVMADRH;
4587 typedef struct
4589 unsigned NVMADR8 : 1;
4590 unsigned NVMADR9 : 1;
4591 unsigned NVMADR10 : 1;
4592 unsigned NVMADR11 : 1;
4593 unsigned NVMADR12 : 1;
4594 unsigned NVMADR13 : 1;
4595 unsigned NVMADR14 : 1;
4596 unsigned : 1;
4597 } __NVMADRHbits_t;
4599 extern __at(0x0892) volatile __NVMADRHbits_t NVMADRHbits;
4601 #define _NVMADR8 0x01
4602 #define _NVMADR9 0x02
4603 #define _NVMADR10 0x04
4604 #define _NVMADR11 0x08
4605 #define _NVMADR12 0x10
4606 #define _NVMADR13 0x20
4607 #define _NVMADR14 0x40
4609 //==============================================================================
4611 extern __at(0x0893) __sfr NVMDAT;
4613 //==============================================================================
4614 // NVMDATL Bits
4616 extern __at(0x0893) __sfr NVMDATL;
4618 typedef struct
4620 unsigned NVMDAT0 : 1;
4621 unsigned NVMDAT1 : 1;
4622 unsigned NVMDAT2 : 1;
4623 unsigned NVMDAT3 : 1;
4624 unsigned NVMDAT4 : 1;
4625 unsigned NVMDAT5 : 1;
4626 unsigned NVMDAT6 : 1;
4627 unsigned NVMDAT7 : 1;
4628 } __NVMDATLbits_t;
4630 extern __at(0x0893) volatile __NVMDATLbits_t NVMDATLbits;
4632 #define _NVMDAT0 0x01
4633 #define _NVMDAT1 0x02
4634 #define _NVMDAT2 0x04
4635 #define _NVMDAT3 0x08
4636 #define _NVMDAT4 0x10
4637 #define _NVMDAT5 0x20
4638 #define _NVMDAT6 0x40
4639 #define _NVMDAT7 0x80
4641 //==============================================================================
4644 //==============================================================================
4645 // NVMDATH Bits
4647 extern __at(0x0894) __sfr NVMDATH;
4649 typedef struct
4651 unsigned NVMDAT8 : 1;
4652 unsigned NVMDAT9 : 1;
4653 unsigned NVMDAT10 : 1;
4654 unsigned NVMDAT11 : 1;
4655 unsigned NVMDAT12 : 1;
4656 unsigned NVMDAT13 : 1;
4657 unsigned : 1;
4658 unsigned : 1;
4659 } __NVMDATHbits_t;
4661 extern __at(0x0894) volatile __NVMDATHbits_t NVMDATHbits;
4663 #define _NVMDAT8 0x01
4664 #define _NVMDAT9 0x02
4665 #define _NVMDAT10 0x04
4666 #define _NVMDAT11 0x08
4667 #define _NVMDAT12 0x10
4668 #define _NVMDAT13 0x20
4670 //==============================================================================
4673 //==============================================================================
4674 // NVMCON1 Bits
4676 extern __at(0x0895) __sfr NVMCON1;
4678 typedef struct
4680 unsigned RD : 1;
4681 unsigned WR : 1;
4682 unsigned WREN : 1;
4683 unsigned WRERR : 1;
4684 unsigned FREE : 1;
4685 unsigned LWLO : 1;
4686 unsigned NVMREGS : 1;
4687 unsigned : 1;
4688 } __NVMCON1bits_t;
4690 extern __at(0x0895) volatile __NVMCON1bits_t NVMCON1bits;
4692 #define _RD 0x01
4693 #define _WR 0x02
4694 #define _WREN 0x04
4695 #define _WRERR 0x08
4696 #define _FREE 0x10
4697 #define _LWLO 0x20
4698 #define _NVMREGS 0x40
4700 //==============================================================================
4702 extern __at(0x0896) __sfr NVMCON2;
4704 //==============================================================================
4705 // PCON0 Bits
4707 extern __at(0x089B) __sfr PCON0;
4709 typedef struct
4711 unsigned NOT_BOR : 1;
4712 unsigned NOT_POR : 1;
4713 unsigned NOT_RI : 1;
4714 unsigned NOT_RMCLR : 1;
4715 unsigned NOT_RWDT : 1;
4716 unsigned : 1;
4717 unsigned STKUNF : 1;
4718 unsigned STKOVF : 1;
4719 } __PCON0bits_t;
4721 extern __at(0x089B) volatile __PCON0bits_t PCON0bits;
4723 #define _NOT_BOR 0x01
4724 #define _NOT_POR 0x02
4725 #define _NOT_RI 0x04
4726 #define _NOT_RMCLR 0x08
4727 #define _NOT_RWDT 0x10
4728 #define _STKUNF 0x40
4729 #define _STKOVF 0x80
4731 //==============================================================================
4734 //==============================================================================
4735 // PMD0 Bits
4737 extern __at(0x0911) __sfr PMD0;
4739 typedef struct
4741 unsigned IOCMD : 1;
4742 unsigned CLKRMD : 1;
4743 unsigned NVMMD : 1;
4744 unsigned : 1;
4745 unsigned : 1;
4746 unsigned : 1;
4747 unsigned FVRMD : 1;
4748 unsigned SYSCMD : 1;
4749 } __PMD0bits_t;
4751 extern __at(0x0911) volatile __PMD0bits_t PMD0bits;
4753 #define _IOCMD 0x01
4754 #define _CLKRMD 0x02
4755 #define _NVMMD 0x04
4756 #define _FVRMD 0x40
4757 #define _SYSCMD 0x80
4759 //==============================================================================
4762 //==============================================================================
4763 // PMD1 Bits
4765 extern __at(0x0912) __sfr PMD1;
4767 typedef struct
4769 unsigned TMR0MD : 1;
4770 unsigned TMR1MD : 1;
4771 unsigned TMR2MD : 1;
4772 unsigned : 1;
4773 unsigned : 1;
4774 unsigned : 1;
4775 unsigned : 1;
4776 unsigned NCOMD : 1;
4777 } __PMD1bits_t;
4779 extern __at(0x0912) volatile __PMD1bits_t PMD1bits;
4781 #define _TMR0MD 0x01
4782 #define _TMR1MD 0x02
4783 #define _TMR2MD 0x04
4784 #define _NCOMD 0x80
4786 //==============================================================================
4789 //==============================================================================
4790 // PMD2 Bits
4792 extern __at(0x0913) __sfr PMD2;
4794 typedef struct
4796 unsigned : 1;
4797 unsigned CMP1MD : 1;
4798 unsigned CMP2MD : 1;
4799 unsigned : 1;
4800 unsigned : 1;
4801 unsigned ADCMD : 1;
4802 unsigned DACMD : 1;
4803 unsigned : 1;
4804 } __PMD2bits_t;
4806 extern __at(0x0913) volatile __PMD2bits_t PMD2bits;
4808 #define _CMP1MD 0x02
4809 #define _CMP2MD 0x04
4810 #define _ADCMD 0x20
4811 #define _DACMD 0x40
4813 //==============================================================================
4816 //==============================================================================
4817 // PMD3 Bits
4819 extern __at(0x0914) __sfr PMD3;
4821 typedef struct
4823 unsigned CCP1MD : 1;
4824 unsigned CCP2MD : 1;
4825 unsigned : 1;
4826 unsigned : 1;
4827 unsigned PWM5MD : 1;
4828 unsigned PWM6MD : 1;
4829 unsigned CWG1MD : 1;
4830 unsigned : 1;
4831 } __PMD3bits_t;
4833 extern __at(0x0914) volatile __PMD3bits_t PMD3bits;
4835 #define _CCP1MD 0x01
4836 #define _CCP2MD 0x02
4837 #define _PWM5MD 0x10
4838 #define _PWM6MD 0x20
4839 #define _CWG1MD 0x40
4841 //==============================================================================
4844 //==============================================================================
4845 // PMD4 Bits
4847 extern __at(0x0915) __sfr PMD4;
4849 typedef struct
4851 unsigned : 1;
4852 unsigned MSSP1MD : 1;
4853 unsigned : 1;
4854 unsigned : 1;
4855 unsigned : 1;
4856 unsigned UART1MD : 1;
4857 unsigned : 1;
4858 unsigned : 1;
4859 } __PMD4bits_t;
4861 extern __at(0x0915) volatile __PMD4bits_t PMD4bits;
4863 #define _MSSP1MD 0x02
4864 #define _UART1MD 0x20
4866 //==============================================================================
4869 //==============================================================================
4870 // PMD5 Bits
4872 extern __at(0x0916) __sfr PMD5;
4874 typedef struct
4876 unsigned DSMMD : 1;
4877 unsigned CLC1MD : 1;
4878 unsigned CLC2MD : 1;
4879 unsigned : 1;
4880 unsigned : 1;
4881 unsigned : 1;
4882 unsigned : 1;
4883 unsigned : 1;
4884 } __PMD5bits_t;
4886 extern __at(0x0916) volatile __PMD5bits_t PMD5bits;
4888 #define _DSMMD 0x01
4889 #define _CLC1MD 0x02
4890 #define _CLC2MD 0x04
4892 //==============================================================================
4895 //==============================================================================
4896 // CPUDOZE Bits
4898 extern __at(0x0918) __sfr CPUDOZE;
4900 typedef union
4902 struct
4904 unsigned DOZE0 : 1;
4905 unsigned DOZE1 : 1;
4906 unsigned DOZE2 : 1;
4907 unsigned : 1;
4908 unsigned DOE : 1;
4909 unsigned ROI : 1;
4910 unsigned DOZEN : 1;
4911 unsigned IDLEN : 1;
4914 struct
4916 unsigned DOZE : 3;
4917 unsigned : 5;
4919 } __CPUDOZEbits_t;
4921 extern __at(0x0918) volatile __CPUDOZEbits_t CPUDOZEbits;
4923 #define _DOZE0 0x01
4924 #define _DOZE1 0x02
4925 #define _DOZE2 0x04
4926 #define _DOE 0x10
4927 #define _ROI 0x20
4928 #define _DOZEN 0x40
4929 #define _IDLEN 0x80
4931 //==============================================================================
4934 //==============================================================================
4935 // OSCCON1 Bits
4937 extern __at(0x0919) __sfr OSCCON1;
4939 typedef union
4941 struct
4943 unsigned NDIV0 : 1;
4944 unsigned NDIV1 : 1;
4945 unsigned NDIV2 : 1;
4946 unsigned NDIV3 : 1;
4947 unsigned NOSC0 : 1;
4948 unsigned NOSC1 : 1;
4949 unsigned NOSC2 : 1;
4950 unsigned : 1;
4953 struct
4955 unsigned NDIV : 4;
4956 unsigned : 4;
4959 struct
4961 unsigned : 4;
4962 unsigned NOSC : 3;
4963 unsigned : 1;
4965 } __OSCCON1bits_t;
4967 extern __at(0x0919) volatile __OSCCON1bits_t OSCCON1bits;
4969 #define _NDIV0 0x01
4970 #define _NDIV1 0x02
4971 #define _NDIV2 0x04
4972 #define _NDIV3 0x08
4973 #define _NOSC0 0x10
4974 #define _NOSC1 0x20
4975 #define _NOSC2 0x40
4977 //==============================================================================
4980 //==============================================================================
4981 // OSCCON2 Bits
4983 extern __at(0x091A) __sfr OSCCON2;
4985 typedef union
4987 struct
4989 unsigned CDIV0 : 1;
4990 unsigned CDIV1 : 1;
4991 unsigned CDIV2 : 1;
4992 unsigned CDIV3 : 1;
4993 unsigned COSC0 : 1;
4994 unsigned COSC1 : 1;
4995 unsigned COSC2 : 1;
4996 unsigned : 1;
4999 struct
5001 unsigned CDIV : 4;
5002 unsigned : 4;
5005 struct
5007 unsigned : 4;
5008 unsigned COSC : 3;
5009 unsigned : 1;
5011 } __OSCCON2bits_t;
5013 extern __at(0x091A) volatile __OSCCON2bits_t OSCCON2bits;
5015 #define _CDIV0 0x01
5016 #define _CDIV1 0x02
5017 #define _CDIV2 0x04
5018 #define _CDIV3 0x08
5019 #define _COSC0 0x10
5020 #define _COSC1 0x20
5021 #define _COSC2 0x40
5023 //==============================================================================
5026 //==============================================================================
5027 // OSCCON3 Bits
5029 extern __at(0x091B) __sfr OSCCON3;
5031 typedef struct
5033 unsigned : 1;
5034 unsigned : 1;
5035 unsigned : 1;
5036 unsigned NOSCR : 1;
5037 unsigned ORDY : 1;
5038 unsigned SOSCBE : 1;
5039 unsigned SOSCPWR : 1;
5040 unsigned CSWHOLD : 1;
5041 } __OSCCON3bits_t;
5043 extern __at(0x091B) volatile __OSCCON3bits_t OSCCON3bits;
5045 #define _NOSCR 0x08
5046 #define _ORDY 0x10
5047 #define _SOSCBE 0x20
5048 #define _SOSCPWR 0x40
5049 #define _CSWHOLD 0x80
5051 //==============================================================================
5054 //==============================================================================
5055 // OSCSTAT1 Bits
5057 extern __at(0x091C) __sfr OSCSTAT1;
5059 typedef struct
5061 unsigned PLLR : 1;
5062 unsigned : 1;
5063 unsigned ADOR : 1;
5064 unsigned SOR : 1;
5065 unsigned LFOR : 1;
5066 unsigned : 1;
5067 unsigned HFOR : 1;
5068 unsigned EXTOR : 1;
5069 } __OSCSTAT1bits_t;
5071 extern __at(0x091C) volatile __OSCSTAT1bits_t OSCSTAT1bits;
5073 #define _PLLR 0x01
5074 #define _ADOR 0x04
5075 #define _SOR 0x08
5076 #define _LFOR 0x10
5077 #define _HFOR 0x40
5078 #define _EXTOR 0x80
5080 //==============================================================================
5083 //==============================================================================
5084 // OSCEN Bits
5086 extern __at(0x091D) __sfr OSCEN;
5088 typedef struct
5090 unsigned : 1;
5091 unsigned : 1;
5092 unsigned ADOEN : 1;
5093 unsigned SOSCEN : 1;
5094 unsigned LFOEN : 1;
5095 unsigned : 1;
5096 unsigned HFOEN : 1;
5097 unsigned EXTOEN : 1;
5098 } __OSCENbits_t;
5100 extern __at(0x091D) volatile __OSCENbits_t OSCENbits;
5102 #define _ADOEN 0x04
5103 #define _SOSCEN 0x08
5104 #define _LFOEN 0x10
5105 #define _HFOEN 0x40
5106 #define _EXTOEN 0x80
5108 //==============================================================================
5111 //==============================================================================
5112 // OSCTUNE Bits
5114 extern __at(0x091E) __sfr OSCTUNE;
5116 typedef union
5118 struct
5120 unsigned HFTUN0 : 1;
5121 unsigned HFTUN1 : 1;
5122 unsigned HFTUN2 : 1;
5123 unsigned HFTUN3 : 1;
5124 unsigned HFTUN4 : 1;
5125 unsigned HFTUN5 : 1;
5126 unsigned : 1;
5127 unsigned : 1;
5130 struct
5132 unsigned HFTUN : 6;
5133 unsigned : 2;
5135 } __OSCTUNEbits_t;
5137 extern __at(0x091E) volatile __OSCTUNEbits_t OSCTUNEbits;
5139 #define _HFTUN0 0x01
5140 #define _HFTUN1 0x02
5141 #define _HFTUN2 0x04
5142 #define _HFTUN3 0x08
5143 #define _HFTUN4 0x10
5144 #define _HFTUN5 0x20
5146 //==============================================================================
5149 //==============================================================================
5150 // OSCFRQ Bits
5152 extern __at(0x091F) __sfr OSCFRQ;
5154 typedef union
5156 struct
5158 unsigned HFFRQ0 : 1;
5159 unsigned HFFRQ1 : 1;
5160 unsigned HFFRQ2 : 1;
5161 unsigned HFFRQ3 : 1;
5162 unsigned : 1;
5163 unsigned : 1;
5164 unsigned : 1;
5165 unsigned : 1;
5168 struct
5170 unsigned HFFRQ : 4;
5171 unsigned : 4;
5173 } __OSCFRQbits_t;
5175 extern __at(0x091F) volatile __OSCFRQbits_t OSCFRQbits;
5177 #define _HFFRQ0 0x01
5178 #define _HFFRQ1 0x02
5179 #define _HFFRQ2 0x04
5180 #define _HFFRQ3 0x08
5182 //==============================================================================
5185 //==============================================================================
5186 // PPSLOCK Bits
5188 extern __at(0x0E0F) __sfr PPSLOCK;
5190 typedef struct
5192 unsigned PPSLOCKED : 1;
5193 unsigned : 1;
5194 unsigned : 1;
5195 unsigned : 1;
5196 unsigned : 1;
5197 unsigned : 1;
5198 unsigned : 1;
5199 unsigned : 1;
5200 } __PPSLOCKbits_t;
5202 extern __at(0x0E0F) volatile __PPSLOCKbits_t PPSLOCKbits;
5204 #define _PPSLOCKED 0x01
5206 //==============================================================================
5209 //==============================================================================
5210 // INTPPS Bits
5212 extern __at(0x0E10) __sfr INTPPS;
5214 typedef union
5216 struct
5218 unsigned INTPPS0 : 1;
5219 unsigned INTPPS1 : 1;
5220 unsigned INTPPS2 : 1;
5221 unsigned INTPPS3 : 1;
5222 unsigned INTPPS4 : 1;
5223 unsigned : 1;
5224 unsigned : 1;
5225 unsigned : 1;
5228 struct
5230 unsigned INTPPS : 5;
5231 unsigned : 3;
5233 } __INTPPSbits_t;
5235 extern __at(0x0E10) volatile __INTPPSbits_t INTPPSbits;
5237 #define _INTPPS0 0x01
5238 #define _INTPPS1 0x02
5239 #define _INTPPS2 0x04
5240 #define _INTPPS3 0x08
5241 #define _INTPPS4 0x10
5243 //==============================================================================
5246 //==============================================================================
5247 // T0CKIPPS Bits
5249 extern __at(0x0E11) __sfr T0CKIPPS;
5251 typedef union
5253 struct
5255 unsigned T0CKIPPS0 : 1;
5256 unsigned T0CKIPPS1 : 1;
5257 unsigned T0CKIPPS2 : 1;
5258 unsigned T0CKIPPS3 : 1;
5259 unsigned T0CKIPPS4 : 1;
5260 unsigned : 1;
5261 unsigned : 1;
5262 unsigned : 1;
5265 struct
5267 unsigned T0CKIPPS : 5;
5268 unsigned : 3;
5270 } __T0CKIPPSbits_t;
5272 extern __at(0x0E11) volatile __T0CKIPPSbits_t T0CKIPPSbits;
5274 #define _T0CKIPPS0 0x01
5275 #define _T0CKIPPS1 0x02
5276 #define _T0CKIPPS2 0x04
5277 #define _T0CKIPPS3 0x08
5278 #define _T0CKIPPS4 0x10
5280 //==============================================================================
5283 //==============================================================================
5284 // T1CKIPPS Bits
5286 extern __at(0x0E12) __sfr T1CKIPPS;
5288 typedef union
5290 struct
5292 unsigned T1CKIPPS0 : 1;
5293 unsigned T1CKIPPS1 : 1;
5294 unsigned T1CKIPPS2 : 1;
5295 unsigned T1CKIPPS3 : 1;
5296 unsigned T1CKIPPS4 : 1;
5297 unsigned : 1;
5298 unsigned : 1;
5299 unsigned : 1;
5302 struct
5304 unsigned T1CKIPPS : 5;
5305 unsigned : 3;
5307 } __T1CKIPPSbits_t;
5309 extern __at(0x0E12) volatile __T1CKIPPSbits_t T1CKIPPSbits;
5311 #define _T1CKIPPS0 0x01
5312 #define _T1CKIPPS1 0x02
5313 #define _T1CKIPPS2 0x04
5314 #define _T1CKIPPS3 0x08
5315 #define _T1CKIPPS4 0x10
5317 //==============================================================================
5320 //==============================================================================
5321 // T1GPPS Bits
5323 extern __at(0x0E13) __sfr T1GPPS;
5325 typedef union
5327 struct
5329 unsigned T1GPPS0 : 1;
5330 unsigned T1GPPS1 : 1;
5331 unsigned T1GPPS2 : 1;
5332 unsigned T1GPPS3 : 1;
5333 unsigned T1GPPS4 : 1;
5334 unsigned : 1;
5335 unsigned : 1;
5336 unsigned : 1;
5339 struct
5341 unsigned T1GPPS : 5;
5342 unsigned : 3;
5344 } __T1GPPSbits_t;
5346 extern __at(0x0E13) volatile __T1GPPSbits_t T1GPPSbits;
5348 #define _T1GPPS0 0x01
5349 #define _T1GPPS1 0x02
5350 #define _T1GPPS2 0x04
5351 #define _T1GPPS3 0x08
5352 #define _T1GPPS4 0x10
5354 //==============================================================================
5357 //==============================================================================
5358 // CCP1PPS Bits
5360 extern __at(0x0E14) __sfr CCP1PPS;
5362 typedef union
5364 struct
5366 unsigned CCP1PPS0 : 1;
5367 unsigned CCP1PPS1 : 1;
5368 unsigned CCP1PPS2 : 1;
5369 unsigned CCP1PPS3 : 1;
5370 unsigned CCP1PPS4 : 1;
5371 unsigned : 1;
5372 unsigned : 1;
5373 unsigned : 1;
5376 struct
5378 unsigned CCP1PPS : 5;
5379 unsigned : 3;
5381 } __CCP1PPSbits_t;
5383 extern __at(0x0E14) volatile __CCP1PPSbits_t CCP1PPSbits;
5385 #define _CCP1PPS0 0x01
5386 #define _CCP1PPS1 0x02
5387 #define _CCP1PPS2 0x04
5388 #define _CCP1PPS3 0x08
5389 #define _CCP1PPS4 0x10
5391 //==============================================================================
5394 //==============================================================================
5395 // CCP2PPS Bits
5397 extern __at(0x0E15) __sfr CCP2PPS;
5399 typedef union
5401 struct
5403 unsigned CCP2PPS0 : 1;
5404 unsigned CCP2PPS1 : 1;
5405 unsigned CCP2PPS2 : 1;
5406 unsigned CCP2PPS3 : 1;
5407 unsigned CCP2PPS4 : 1;
5408 unsigned : 1;
5409 unsigned : 1;
5410 unsigned : 1;
5413 struct
5415 unsigned CCP2PPS : 5;
5416 unsigned : 3;
5418 } __CCP2PPSbits_t;
5420 extern __at(0x0E15) volatile __CCP2PPSbits_t CCP2PPSbits;
5422 #define _CCP2PPS0 0x01
5423 #define _CCP2PPS1 0x02
5424 #define _CCP2PPS2 0x04
5425 #define _CCP2PPS3 0x08
5426 #define _CCP2PPS4 0x10
5428 //==============================================================================
5431 //==============================================================================
5432 // CWG1PPS Bits
5434 extern __at(0x0E18) __sfr CWG1PPS;
5436 typedef union
5438 struct
5440 unsigned CWG1PPS0 : 1;
5441 unsigned CWG1PPS1 : 1;
5442 unsigned CWG1PPS2 : 1;
5443 unsigned CWG1PPS3 : 1;
5444 unsigned CWG1PPS4 : 1;
5445 unsigned : 1;
5446 unsigned : 1;
5447 unsigned : 1;
5450 struct
5452 unsigned CWG1PPS : 5;
5453 unsigned : 3;
5455 } __CWG1PPSbits_t;
5457 extern __at(0x0E18) volatile __CWG1PPSbits_t CWG1PPSbits;
5459 #define _CWG1PPS0 0x01
5460 #define _CWG1PPS1 0x02
5461 #define _CWG1PPS2 0x04
5462 #define _CWG1PPS3 0x08
5463 #define _CWG1PPS4 0x10
5465 //==============================================================================
5468 //==============================================================================
5469 // MDCIN1PPS Bits
5471 extern __at(0x0E1A) __sfr MDCIN1PPS;
5473 typedef union
5475 struct
5477 unsigned MDCIN1PPS0 : 1;
5478 unsigned MDCIN1PPS1 : 1;
5479 unsigned MDCIN1PPS2 : 1;
5480 unsigned MDCIN1PPS3 : 1;
5481 unsigned MDCIN1PPS4 : 1;
5482 unsigned : 1;
5483 unsigned : 1;
5484 unsigned : 1;
5487 struct
5489 unsigned MDCIN1PPS : 5;
5490 unsigned : 3;
5492 } __MDCIN1PPSbits_t;
5494 extern __at(0x0E1A) volatile __MDCIN1PPSbits_t MDCIN1PPSbits;
5496 #define _MDCIN1PPS0 0x01
5497 #define _MDCIN1PPS1 0x02
5498 #define _MDCIN1PPS2 0x04
5499 #define _MDCIN1PPS3 0x08
5500 #define _MDCIN1PPS4 0x10
5502 //==============================================================================
5505 //==============================================================================
5506 // MDCIN2PPS Bits
5508 extern __at(0x0E1B) __sfr MDCIN2PPS;
5510 typedef union
5512 struct
5514 unsigned MDCIN2PPS0 : 1;
5515 unsigned MDCIN2PPS1 : 1;
5516 unsigned MDCIN2PPS2 : 1;
5517 unsigned MDCIN2PPS3 : 1;
5518 unsigned MDCIN2PPS4 : 1;
5519 unsigned : 1;
5520 unsigned : 1;
5521 unsigned : 1;
5524 struct
5526 unsigned MDCIN2PPS : 5;
5527 unsigned : 3;
5529 } __MDCIN2PPSbits_t;
5531 extern __at(0x0E1B) volatile __MDCIN2PPSbits_t MDCIN2PPSbits;
5533 #define _MDCIN2PPS0 0x01
5534 #define _MDCIN2PPS1 0x02
5535 #define _MDCIN2PPS2 0x04
5536 #define _MDCIN2PPS3 0x08
5537 #define _MDCIN2PPS4 0x10
5539 //==============================================================================
5542 //==============================================================================
5543 // MDMINPPS Bits
5545 extern __at(0x0E1C) __sfr MDMINPPS;
5547 typedef union
5549 struct
5551 unsigned MDMINPPS0 : 1;
5552 unsigned MDMINPPS1 : 1;
5553 unsigned MDMINPPS2 : 1;
5554 unsigned MDMINPPS3 : 1;
5555 unsigned MDMINPPS4 : 1;
5556 unsigned : 1;
5557 unsigned : 1;
5558 unsigned : 1;
5561 struct
5563 unsigned MDMINPPS : 5;
5564 unsigned : 3;
5566 } __MDMINPPSbits_t;
5568 extern __at(0x0E1C) volatile __MDMINPPSbits_t MDMINPPSbits;
5570 #define _MDMINPPS0 0x01
5571 #define _MDMINPPS1 0x02
5572 #define _MDMINPPS2 0x04
5573 #define _MDMINPPS3 0x08
5574 #define _MDMINPPS4 0x10
5576 //==============================================================================
5579 //==============================================================================
5580 // SSP1CLKPPS Bits
5582 extern __at(0x0E20) __sfr SSP1CLKPPS;
5584 typedef union
5586 struct
5588 unsigned SSP1CLKPPS0 : 1;
5589 unsigned SSP1CLKPPS1 : 1;
5590 unsigned SSP1CLKPPS2 : 1;
5591 unsigned SSP1CLKPPS3 : 1;
5592 unsigned SSP1CLKPPS4 : 1;
5593 unsigned : 1;
5594 unsigned : 1;
5595 unsigned : 1;
5598 struct
5600 unsigned SSP1CLKPPS : 5;
5601 unsigned : 3;
5603 } __SSP1CLKPPSbits_t;
5605 extern __at(0x0E20) volatile __SSP1CLKPPSbits_t SSP1CLKPPSbits;
5607 #define _SSP1CLKPPS0 0x01
5608 #define _SSP1CLKPPS1 0x02
5609 #define _SSP1CLKPPS2 0x04
5610 #define _SSP1CLKPPS3 0x08
5611 #define _SSP1CLKPPS4 0x10
5613 //==============================================================================
5616 //==============================================================================
5617 // SSP1DATPPS Bits
5619 extern __at(0x0E21) __sfr SSP1DATPPS;
5621 typedef union
5623 struct
5625 unsigned SSP1DATPPS0 : 1;
5626 unsigned SSP1DATPPS1 : 1;
5627 unsigned SSP1DATPPS2 : 1;
5628 unsigned SSP1DATPPS3 : 1;
5629 unsigned SSP1DATPPS4 : 1;
5630 unsigned : 1;
5631 unsigned : 1;
5632 unsigned : 1;
5635 struct
5637 unsigned SSP1DATPPS : 5;
5638 unsigned : 3;
5640 } __SSP1DATPPSbits_t;
5642 extern __at(0x0E21) volatile __SSP1DATPPSbits_t SSP1DATPPSbits;
5644 #define _SSP1DATPPS0 0x01
5645 #define _SSP1DATPPS1 0x02
5646 #define _SSP1DATPPS2 0x04
5647 #define _SSP1DATPPS3 0x08
5648 #define _SSP1DATPPS4 0x10
5650 //==============================================================================
5653 //==============================================================================
5654 // SSP1SSPPS Bits
5656 extern __at(0x0E22) __sfr SSP1SSPPS;
5658 typedef union
5660 struct
5662 unsigned SSP1SSPPS0 : 1;
5663 unsigned SSP1SSPPS1 : 1;
5664 unsigned SSP1SSPPS2 : 1;
5665 unsigned SSP1SSPPS3 : 1;
5666 unsigned SSP1SSPPS4 : 1;
5667 unsigned : 1;
5668 unsigned : 1;
5669 unsigned : 1;
5672 struct
5674 unsigned SSP1SSPPS : 5;
5675 unsigned : 3;
5677 } __SSP1SSPPSbits_t;
5679 extern __at(0x0E22) volatile __SSP1SSPPSbits_t SSP1SSPPSbits;
5681 #define _SSP1SSPPS0 0x01
5682 #define _SSP1SSPPS1 0x02
5683 #define _SSP1SSPPS2 0x04
5684 #define _SSP1SSPPS3 0x08
5685 #define _SSP1SSPPS4 0x10
5687 //==============================================================================
5690 //==============================================================================
5691 // RXPPS Bits
5693 extern __at(0x0E24) __sfr RXPPS;
5695 typedef union
5697 struct
5699 unsigned RXPPS0 : 1;
5700 unsigned RXPPS1 : 1;
5701 unsigned RXPPS2 : 1;
5702 unsigned RXPPS3 : 1;
5703 unsigned RXPPS4 : 1;
5704 unsigned : 1;
5705 unsigned : 1;
5706 unsigned : 1;
5709 struct
5711 unsigned RXPPS : 5;
5712 unsigned : 3;
5714 } __RXPPSbits_t;
5716 extern __at(0x0E24) volatile __RXPPSbits_t RXPPSbits;
5718 #define _RXPPS0 0x01
5719 #define _RXPPS1 0x02
5720 #define _RXPPS2 0x04
5721 #define _RXPPS3 0x08
5722 #define _RXPPS4 0x10
5724 //==============================================================================
5727 //==============================================================================
5728 // TXPPS Bits
5730 extern __at(0x0E25) __sfr TXPPS;
5732 typedef union
5734 struct
5736 unsigned TXPPS0 : 1;
5737 unsigned TXPPS1 : 1;
5738 unsigned TXPPS2 : 1;
5739 unsigned TXPPS3 : 1;
5740 unsigned TXPPS4 : 1;
5741 unsigned : 1;
5742 unsigned : 1;
5743 unsigned : 1;
5746 struct
5748 unsigned TXPPS : 5;
5749 unsigned : 3;
5751 } __TXPPSbits_t;
5753 extern __at(0x0E25) volatile __TXPPSbits_t TXPPSbits;
5755 #define _TXPPS0 0x01
5756 #define _TXPPS1 0x02
5757 #define _TXPPS2 0x04
5758 #define _TXPPS3 0x08
5759 #define _TXPPS4 0x10
5761 //==============================================================================
5764 //==============================================================================
5765 // CLCIN0PPS Bits
5767 extern __at(0x0E28) __sfr CLCIN0PPS;
5769 typedef union
5771 struct
5773 unsigned CLCIN0PPS0 : 1;
5774 unsigned CLCIN0PPS1 : 1;
5775 unsigned CLCIN0PPS2 : 1;
5776 unsigned CLCIN0PPS3 : 1;
5777 unsigned CLCIN0PPS4 : 1;
5778 unsigned : 1;
5779 unsigned : 1;
5780 unsigned : 1;
5783 struct
5785 unsigned CLCIN0PPS : 5;
5786 unsigned : 3;
5788 } __CLCIN0PPSbits_t;
5790 extern __at(0x0E28) volatile __CLCIN0PPSbits_t CLCIN0PPSbits;
5792 #define _CLCIN0PPS0 0x01
5793 #define _CLCIN0PPS1 0x02
5794 #define _CLCIN0PPS2 0x04
5795 #define _CLCIN0PPS3 0x08
5796 #define _CLCIN0PPS4 0x10
5798 //==============================================================================
5801 //==============================================================================
5802 // CLCIN1PPS Bits
5804 extern __at(0x0E29) __sfr CLCIN1PPS;
5806 typedef union
5808 struct
5810 unsigned CLCIN1PPS0 : 1;
5811 unsigned CLCIN1PPS1 : 1;
5812 unsigned CLCIN1PPS2 : 1;
5813 unsigned CLCIN1PPS3 : 1;
5814 unsigned CLCIN1PPS4 : 1;
5815 unsigned : 1;
5816 unsigned : 1;
5817 unsigned : 1;
5820 struct
5822 unsigned CLCIN1PPS : 5;
5823 unsigned : 3;
5825 } __CLCIN1PPSbits_t;
5827 extern __at(0x0E29) volatile __CLCIN1PPSbits_t CLCIN1PPSbits;
5829 #define _CLCIN1PPS0 0x01
5830 #define _CLCIN1PPS1 0x02
5831 #define _CLCIN1PPS2 0x04
5832 #define _CLCIN1PPS3 0x08
5833 #define _CLCIN1PPS4 0x10
5835 //==============================================================================
5838 //==============================================================================
5839 // CLCIN2PPS Bits
5841 extern __at(0x0E2A) __sfr CLCIN2PPS;
5843 typedef union
5845 struct
5847 unsigned CLCIN2PPS0 : 1;
5848 unsigned CLCIN2PPS1 : 1;
5849 unsigned CLCIN2PPS2 : 1;
5850 unsigned CLCIN2PPS3 : 1;
5851 unsigned CLCIN2PPS4 : 1;
5852 unsigned : 1;
5853 unsigned : 1;
5854 unsigned : 1;
5857 struct
5859 unsigned CLCIN2PPS : 5;
5860 unsigned : 3;
5862 } __CLCIN2PPSbits_t;
5864 extern __at(0x0E2A) volatile __CLCIN2PPSbits_t CLCIN2PPSbits;
5866 #define _CLCIN2PPS0 0x01
5867 #define _CLCIN2PPS1 0x02
5868 #define _CLCIN2PPS2 0x04
5869 #define _CLCIN2PPS3 0x08
5870 #define _CLCIN2PPS4 0x10
5872 //==============================================================================
5875 //==============================================================================
5876 // CLCIN3PPS Bits
5878 extern __at(0x0E2B) __sfr CLCIN3PPS;
5880 typedef union
5882 struct
5884 unsigned CLCIN3PPS0 : 1;
5885 unsigned CLCIN3PPS1 : 1;
5886 unsigned CLCIN3PPS2 : 1;
5887 unsigned CLCIN3PPS3 : 1;
5888 unsigned CLCIN3PPS4 : 1;
5889 unsigned : 1;
5890 unsigned : 1;
5891 unsigned : 1;
5894 struct
5896 unsigned CLCIN3PPS : 5;
5897 unsigned : 3;
5899 } __CLCIN3PPSbits_t;
5901 extern __at(0x0E2B) volatile __CLCIN3PPSbits_t CLCIN3PPSbits;
5903 #define _CLCIN3PPS0 0x01
5904 #define _CLCIN3PPS1 0x02
5905 #define _CLCIN3PPS2 0x04
5906 #define _CLCIN3PPS3 0x08
5907 #define _CLCIN3PPS4 0x10
5909 //==============================================================================
5912 //==============================================================================
5913 // RA0PPS Bits
5915 extern __at(0x0E90) __sfr RA0PPS;
5917 typedef union
5919 struct
5921 unsigned RA0PPS0 : 1;
5922 unsigned RA0PPS1 : 1;
5923 unsigned RA0PPS2 : 1;
5924 unsigned RA0PPS3 : 1;
5925 unsigned RA0PPS4 : 1;
5926 unsigned : 1;
5927 unsigned : 1;
5928 unsigned : 1;
5931 struct
5933 unsigned RA0PPS : 5;
5934 unsigned : 3;
5936 } __RA0PPSbits_t;
5938 extern __at(0x0E90) volatile __RA0PPSbits_t RA0PPSbits;
5940 #define _RA0PPS0 0x01
5941 #define _RA0PPS1 0x02
5942 #define _RA0PPS2 0x04
5943 #define _RA0PPS3 0x08
5944 #define _RA0PPS4 0x10
5946 //==============================================================================
5949 //==============================================================================
5950 // RA1PPS Bits
5952 extern __at(0x0E91) __sfr RA1PPS;
5954 typedef union
5956 struct
5958 unsigned RA1PPS0 : 1;
5959 unsigned RA1PPS1 : 1;
5960 unsigned RA1PPS2 : 1;
5961 unsigned RA1PPS3 : 1;
5962 unsigned RA1PPS4 : 1;
5963 unsigned : 1;
5964 unsigned : 1;
5965 unsigned : 1;
5968 struct
5970 unsigned RA1PPS : 5;
5971 unsigned : 3;
5973 } __RA1PPSbits_t;
5975 extern __at(0x0E91) volatile __RA1PPSbits_t RA1PPSbits;
5977 #define _RA1PPS0 0x01
5978 #define _RA1PPS1 0x02
5979 #define _RA1PPS2 0x04
5980 #define _RA1PPS3 0x08
5981 #define _RA1PPS4 0x10
5983 //==============================================================================
5986 //==============================================================================
5987 // RA2PPS Bits
5989 extern __at(0x0E92) __sfr RA2PPS;
5991 typedef union
5993 struct
5995 unsigned RA2PPS0 : 1;
5996 unsigned RA2PPS1 : 1;
5997 unsigned RA2PPS2 : 1;
5998 unsigned RA2PPS3 : 1;
5999 unsigned RA2PPS4 : 1;
6000 unsigned : 1;
6001 unsigned : 1;
6002 unsigned : 1;
6005 struct
6007 unsigned RA2PPS : 5;
6008 unsigned : 3;
6010 } __RA2PPSbits_t;
6012 extern __at(0x0E92) volatile __RA2PPSbits_t RA2PPSbits;
6014 #define _RA2PPS0 0x01
6015 #define _RA2PPS1 0x02
6016 #define _RA2PPS2 0x04
6017 #define _RA2PPS3 0x08
6018 #define _RA2PPS4 0x10
6020 //==============================================================================
6023 //==============================================================================
6024 // RA4PPS Bits
6026 extern __at(0x0E94) __sfr RA4PPS;
6028 typedef union
6030 struct
6032 unsigned RA4PPS0 : 1;
6033 unsigned RA4PPS1 : 1;
6034 unsigned RA4PPS2 : 1;
6035 unsigned RA4PPS3 : 1;
6036 unsigned RA4PPS4 : 1;
6037 unsigned : 1;
6038 unsigned : 1;
6039 unsigned : 1;
6042 struct
6044 unsigned RA4PPS : 5;
6045 unsigned : 3;
6047 } __RA4PPSbits_t;
6049 extern __at(0x0E94) volatile __RA4PPSbits_t RA4PPSbits;
6051 #define _RA4PPS0 0x01
6052 #define _RA4PPS1 0x02
6053 #define _RA4PPS2 0x04
6054 #define _RA4PPS3 0x08
6055 #define _RA4PPS4 0x10
6057 //==============================================================================
6060 //==============================================================================
6061 // RA5PPS Bits
6063 extern __at(0x0E95) __sfr RA5PPS;
6065 typedef union
6067 struct
6069 unsigned RA5PPS0 : 1;
6070 unsigned RA5PPS1 : 1;
6071 unsigned RA5PPS2 : 1;
6072 unsigned RA5PPS3 : 1;
6073 unsigned RA5PPS4 : 1;
6074 unsigned : 1;
6075 unsigned : 1;
6076 unsigned : 1;
6079 struct
6081 unsigned RA5PPS : 5;
6082 unsigned : 3;
6084 } __RA5PPSbits_t;
6086 extern __at(0x0E95) volatile __RA5PPSbits_t RA5PPSbits;
6088 #define _RA5PPS0 0x01
6089 #define _RA5PPS1 0x02
6090 #define _RA5PPS2 0x04
6091 #define _RA5PPS3 0x08
6092 #define _RA5PPS4 0x10
6094 //==============================================================================
6097 //==============================================================================
6098 // RC0PPS Bits
6100 extern __at(0x0EA0) __sfr RC0PPS;
6102 typedef union
6104 struct
6106 unsigned RC0PPS0 : 1;
6107 unsigned RC0PPS1 : 1;
6108 unsigned RC0PPS2 : 1;
6109 unsigned RC0PPS3 : 1;
6110 unsigned RC0PPS4 : 1;
6111 unsigned : 1;
6112 unsigned : 1;
6113 unsigned : 1;
6116 struct
6118 unsigned RC0PPS : 5;
6119 unsigned : 3;
6121 } __RC0PPSbits_t;
6123 extern __at(0x0EA0) volatile __RC0PPSbits_t RC0PPSbits;
6125 #define _RC0PPS0 0x01
6126 #define _RC0PPS1 0x02
6127 #define _RC0PPS2 0x04
6128 #define _RC0PPS3 0x08
6129 #define _RC0PPS4 0x10
6131 //==============================================================================
6134 //==============================================================================
6135 // RC1PPS Bits
6137 extern __at(0x0EA1) __sfr RC1PPS;
6139 typedef union
6141 struct
6143 unsigned RC1PPS0 : 1;
6144 unsigned RC1PPS1 : 1;
6145 unsigned RC1PPS2 : 1;
6146 unsigned RC1PPS3 : 1;
6147 unsigned RC1PPS4 : 1;
6148 unsigned : 1;
6149 unsigned : 1;
6150 unsigned : 1;
6153 struct
6155 unsigned RC1PPS : 5;
6156 unsigned : 3;
6158 } __RC1PPSbits_t;
6160 extern __at(0x0EA1) volatile __RC1PPSbits_t RC1PPSbits;
6162 #define _RC1PPS0 0x01
6163 #define _RC1PPS1 0x02
6164 #define _RC1PPS2 0x04
6165 #define _RC1PPS3 0x08
6166 #define _RC1PPS4 0x10
6168 //==============================================================================
6171 //==============================================================================
6172 // RC2PPS Bits
6174 extern __at(0x0EA2) __sfr RC2PPS;
6176 typedef union
6178 struct
6180 unsigned RC2PPS0 : 1;
6181 unsigned RC2PPS1 : 1;
6182 unsigned RC2PPS2 : 1;
6183 unsigned RC2PPS3 : 1;
6184 unsigned RC2PPS4 : 1;
6185 unsigned : 1;
6186 unsigned : 1;
6187 unsigned : 1;
6190 struct
6192 unsigned RC2PPS : 5;
6193 unsigned : 3;
6195 } __RC2PPSbits_t;
6197 extern __at(0x0EA2) volatile __RC2PPSbits_t RC2PPSbits;
6199 #define _RC2PPS0 0x01
6200 #define _RC2PPS1 0x02
6201 #define _RC2PPS2 0x04
6202 #define _RC2PPS3 0x08
6203 #define _RC2PPS4 0x10
6205 //==============================================================================
6208 //==============================================================================
6209 // RC3PPS Bits
6211 extern __at(0x0EA3) __sfr RC3PPS;
6213 typedef union
6215 struct
6217 unsigned RC3PPS0 : 1;
6218 unsigned RC3PPS1 : 1;
6219 unsigned RC3PPS2 : 1;
6220 unsigned RC3PPS3 : 1;
6221 unsigned RC3PPS4 : 1;
6222 unsigned : 1;
6223 unsigned : 1;
6224 unsigned : 1;
6227 struct
6229 unsigned RC3PPS : 5;
6230 unsigned : 3;
6232 } __RC3PPSbits_t;
6234 extern __at(0x0EA3) volatile __RC3PPSbits_t RC3PPSbits;
6236 #define _RC3PPS0 0x01
6237 #define _RC3PPS1 0x02
6238 #define _RC3PPS2 0x04
6239 #define _RC3PPS3 0x08
6240 #define _RC3PPS4 0x10
6242 //==============================================================================
6245 //==============================================================================
6246 // RC4PPS Bits
6248 extern __at(0x0EA4) __sfr RC4PPS;
6250 typedef union
6252 struct
6254 unsigned RC4PPS0 : 1;
6255 unsigned RC4PPS1 : 1;
6256 unsigned RC4PPS2 : 1;
6257 unsigned RC4PPS3 : 1;
6258 unsigned RC4PPS4 : 1;
6259 unsigned : 1;
6260 unsigned : 1;
6261 unsigned : 1;
6264 struct
6266 unsigned RC4PPS : 5;
6267 unsigned : 3;
6269 } __RC4PPSbits_t;
6271 extern __at(0x0EA4) volatile __RC4PPSbits_t RC4PPSbits;
6273 #define _RC4PPS0 0x01
6274 #define _RC4PPS1 0x02
6275 #define _RC4PPS2 0x04
6276 #define _RC4PPS3 0x08
6277 #define _RC4PPS4 0x10
6279 //==============================================================================
6282 //==============================================================================
6283 // RC5PPS Bits
6285 extern __at(0x0EA5) __sfr RC5PPS;
6287 typedef union
6289 struct
6291 unsigned RC5PPS0 : 1;
6292 unsigned RC5PPS1 : 1;
6293 unsigned RC5PPS2 : 1;
6294 unsigned RC5PPS3 : 1;
6295 unsigned RC5PPS4 : 1;
6296 unsigned : 1;
6297 unsigned : 1;
6298 unsigned : 1;
6301 struct
6303 unsigned RC5PPS : 5;
6304 unsigned : 3;
6306 } __RC5PPSbits_t;
6308 extern __at(0x0EA5) volatile __RC5PPSbits_t RC5PPSbits;
6310 #define _RC5PPS0 0x01
6311 #define _RC5PPS1 0x02
6312 #define _RC5PPS2 0x04
6313 #define _RC5PPS3 0x08
6314 #define _RC5PPS4 0x10
6316 //==============================================================================
6319 //==============================================================================
6320 // CLCDATA Bits
6322 extern __at(0x0F0F) __sfr CLCDATA;
6324 typedef struct
6326 unsigned MLC1OUT : 1;
6327 unsigned MLC2OUT : 1;
6328 unsigned : 1;
6329 unsigned : 1;
6330 unsigned : 1;
6331 unsigned : 1;
6332 unsigned : 1;
6333 unsigned : 1;
6334 } __CLCDATAbits_t;
6336 extern __at(0x0F0F) volatile __CLCDATAbits_t CLCDATAbits;
6338 #define _MLC1OUT 0x01
6339 #define _MLC2OUT 0x02
6341 //==============================================================================
6344 //==============================================================================
6345 // CLC1CON Bits
6347 extern __at(0x0F10) __sfr CLC1CON;
6349 typedef union
6351 struct
6353 unsigned LC1MODE0 : 1;
6354 unsigned LC1MODE1 : 1;
6355 unsigned LC1MODE2 : 1;
6356 unsigned LC1INTN : 1;
6357 unsigned LC1INTP : 1;
6358 unsigned LC1OUT : 1;
6359 unsigned : 1;
6360 unsigned LC1EN : 1;
6363 struct
6365 unsigned MODE0 : 1;
6366 unsigned MODE1 : 1;
6367 unsigned MODE2 : 1;
6368 unsigned INTN : 1;
6369 unsigned INTP : 1;
6370 unsigned OUT : 1;
6371 unsigned : 1;
6372 unsigned EN : 1;
6375 struct
6377 unsigned MODE : 3;
6378 unsigned : 5;
6381 struct
6383 unsigned LC1MODE : 3;
6384 unsigned : 5;
6386 } __CLC1CONbits_t;
6388 extern __at(0x0F10) volatile __CLC1CONbits_t CLC1CONbits;
6390 #define _LC1MODE0 0x01
6391 #define _MODE0 0x01
6392 #define _LC1MODE1 0x02
6393 #define _MODE1 0x02
6394 #define _LC1MODE2 0x04
6395 #define _MODE2 0x04
6396 #define _LC1INTN 0x08
6397 #define _INTN 0x08
6398 #define _LC1INTP 0x10
6399 #define _INTP 0x10
6400 #define _LC1OUT 0x20
6401 #define _OUT 0x20
6402 #define _LC1EN 0x80
6403 #define _EN 0x80
6405 //==============================================================================
6408 //==============================================================================
6409 // CLC1POL Bits
6411 extern __at(0x0F11) __sfr CLC1POL;
6413 typedef union
6415 struct
6417 unsigned LC1G1POL : 1;
6418 unsigned LC1G2POL : 1;
6419 unsigned LC1G3POL : 1;
6420 unsigned LC1G4POL : 1;
6421 unsigned : 1;
6422 unsigned : 1;
6423 unsigned : 1;
6424 unsigned LC1POL : 1;
6427 struct
6429 unsigned G1POL : 1;
6430 unsigned G2POL : 1;
6431 unsigned G3POL : 1;
6432 unsigned G4POL : 1;
6433 unsigned : 1;
6434 unsigned : 1;
6435 unsigned : 1;
6436 unsigned POL : 1;
6438 } __CLC1POLbits_t;
6440 extern __at(0x0F11) volatile __CLC1POLbits_t CLC1POLbits;
6442 #define _LC1G1POL 0x01
6443 #define _G1POL 0x01
6444 #define _LC1G2POL 0x02
6445 #define _G2POL 0x02
6446 #define _LC1G3POL 0x04
6447 #define _G3POL 0x04
6448 #define _LC1G4POL 0x08
6449 #define _G4POL 0x08
6450 #define _LC1POL 0x80
6451 #define _POL 0x80
6453 //==============================================================================
6456 //==============================================================================
6457 // CLC1SEL0 Bits
6459 extern __at(0x0F12) __sfr CLC1SEL0;
6461 typedef union
6463 struct
6465 unsigned LC1D1S0 : 1;
6466 unsigned LC1D1S1 : 1;
6467 unsigned LC1D1S2 : 1;
6468 unsigned LC1D1S3 : 1;
6469 unsigned LC1D1S4 : 1;
6470 unsigned : 1;
6471 unsigned : 1;
6472 unsigned : 1;
6475 struct
6477 unsigned D1S0 : 1;
6478 unsigned D1S1 : 1;
6479 unsigned D1S2 : 1;
6480 unsigned D1S3 : 1;
6481 unsigned D1S4 : 1;
6482 unsigned : 1;
6483 unsigned : 1;
6484 unsigned : 1;
6487 struct
6489 unsigned D1S : 5;
6490 unsigned : 3;
6493 struct
6495 unsigned LC1D1S : 5;
6496 unsigned : 3;
6498 } __CLC1SEL0bits_t;
6500 extern __at(0x0F12) volatile __CLC1SEL0bits_t CLC1SEL0bits;
6502 #define _LC1D1S0 0x01
6503 #define _D1S0 0x01
6504 #define _LC1D1S1 0x02
6505 #define _D1S1 0x02
6506 #define _LC1D1S2 0x04
6507 #define _D1S2 0x04
6508 #define _LC1D1S3 0x08
6509 #define _D1S3 0x08
6510 #define _LC1D1S4 0x10
6511 #define _D1S4 0x10
6513 //==============================================================================
6516 //==============================================================================
6517 // CLC1SEL1 Bits
6519 extern __at(0x0F13) __sfr CLC1SEL1;
6521 typedef union
6523 struct
6525 unsigned LC1D2S0 : 1;
6526 unsigned LC1D2S1 : 1;
6527 unsigned LC1D2S2 : 1;
6528 unsigned LC1D2S3 : 1;
6529 unsigned LC1D2S4 : 1;
6530 unsigned : 1;
6531 unsigned : 1;
6532 unsigned : 1;
6535 struct
6537 unsigned D2S0 : 1;
6538 unsigned D2S1 : 1;
6539 unsigned D2S2 : 1;
6540 unsigned D2S3 : 1;
6541 unsigned D2S4 : 1;
6542 unsigned : 1;
6543 unsigned : 1;
6544 unsigned : 1;
6547 struct
6549 unsigned LC1D2S : 5;
6550 unsigned : 3;
6553 struct
6555 unsigned D2S : 5;
6556 unsigned : 3;
6558 } __CLC1SEL1bits_t;
6560 extern __at(0x0F13) volatile __CLC1SEL1bits_t CLC1SEL1bits;
6562 #define _LC1D2S0 0x01
6563 #define _D2S0 0x01
6564 #define _LC1D2S1 0x02
6565 #define _D2S1 0x02
6566 #define _LC1D2S2 0x04
6567 #define _D2S2 0x04
6568 #define _LC1D2S3 0x08
6569 #define _D2S3 0x08
6570 #define _LC1D2S4 0x10
6571 #define _D2S4 0x10
6573 //==============================================================================
6576 //==============================================================================
6577 // CLC1SEL2 Bits
6579 extern __at(0x0F14) __sfr CLC1SEL2;
6581 typedef union
6583 struct
6585 unsigned LC1D3S0 : 1;
6586 unsigned LC1D3S1 : 1;
6587 unsigned LC1D3S2 : 1;
6588 unsigned LC1D3S3 : 1;
6589 unsigned LC1D3S4 : 1;
6590 unsigned : 1;
6591 unsigned : 1;
6592 unsigned : 1;
6595 struct
6597 unsigned D3S0 : 1;
6598 unsigned D3S1 : 1;
6599 unsigned D3S2 : 1;
6600 unsigned D3S3 : 1;
6601 unsigned D3S4 : 1;
6602 unsigned : 1;
6603 unsigned : 1;
6604 unsigned : 1;
6607 struct
6609 unsigned LC1D3S : 5;
6610 unsigned : 3;
6613 struct
6615 unsigned D3S : 5;
6616 unsigned : 3;
6618 } __CLC1SEL2bits_t;
6620 extern __at(0x0F14) volatile __CLC1SEL2bits_t CLC1SEL2bits;
6622 #define _LC1D3S0 0x01
6623 #define _D3S0 0x01
6624 #define _LC1D3S1 0x02
6625 #define _D3S1 0x02
6626 #define _LC1D3S2 0x04
6627 #define _D3S2 0x04
6628 #define _LC1D3S3 0x08
6629 #define _D3S3 0x08
6630 #define _LC1D3S4 0x10
6631 #define _D3S4 0x10
6633 //==============================================================================
6636 //==============================================================================
6637 // CLC1SEL3 Bits
6639 extern __at(0x0F15) __sfr CLC1SEL3;
6641 typedef union
6643 struct
6645 unsigned LC1D4S0 : 1;
6646 unsigned LC1D4S1 : 1;
6647 unsigned LC1D4S2 : 1;
6648 unsigned LC1D4S3 : 1;
6649 unsigned LC1D4S4 : 1;
6650 unsigned : 1;
6651 unsigned : 1;
6652 unsigned : 1;
6655 struct
6657 unsigned D4S0 : 1;
6658 unsigned D4S1 : 1;
6659 unsigned D4S2 : 1;
6660 unsigned D4S3 : 1;
6661 unsigned D4S4 : 1;
6662 unsigned : 1;
6663 unsigned : 1;
6664 unsigned : 1;
6667 struct
6669 unsigned D4S : 5;
6670 unsigned : 3;
6673 struct
6675 unsigned LC1D4S : 5;
6676 unsigned : 3;
6678 } __CLC1SEL3bits_t;
6680 extern __at(0x0F15) volatile __CLC1SEL3bits_t CLC1SEL3bits;
6682 #define _LC1D4S0 0x01
6683 #define _D4S0 0x01
6684 #define _LC1D4S1 0x02
6685 #define _D4S1 0x02
6686 #define _LC1D4S2 0x04
6687 #define _D4S2 0x04
6688 #define _LC1D4S3 0x08
6689 #define _D4S3 0x08
6690 #define _LC1D4S4 0x10
6691 #define _D4S4 0x10
6693 //==============================================================================
6696 //==============================================================================
6697 // CLC1GLS0 Bits
6699 extern __at(0x0F16) __sfr CLC1GLS0;
6701 typedef union
6703 struct
6705 unsigned LC1G1D1N : 1;
6706 unsigned LC1G1D1T : 1;
6707 unsigned LC1G1D2N : 1;
6708 unsigned LC1G1D2T : 1;
6709 unsigned LC1G1D3N : 1;
6710 unsigned LC1G1D3T : 1;
6711 unsigned LC1G1D4N : 1;
6712 unsigned LC1G1D4T : 1;
6715 struct
6717 unsigned D1N : 1;
6718 unsigned D1T : 1;
6719 unsigned D2N : 1;
6720 unsigned D2T : 1;
6721 unsigned D3N : 1;
6722 unsigned D3T : 1;
6723 unsigned D4N : 1;
6724 unsigned D4T : 1;
6726 } __CLC1GLS0bits_t;
6728 extern __at(0x0F16) volatile __CLC1GLS0bits_t CLC1GLS0bits;
6730 #define _LC1G1D1N 0x01
6731 #define _D1N 0x01
6732 #define _LC1G1D1T 0x02
6733 #define _D1T 0x02
6734 #define _LC1G1D2N 0x04
6735 #define _D2N 0x04
6736 #define _LC1G1D2T 0x08
6737 #define _D2T 0x08
6738 #define _LC1G1D3N 0x10
6739 #define _D3N 0x10
6740 #define _LC1G1D3T 0x20
6741 #define _D3T 0x20
6742 #define _LC1G1D4N 0x40
6743 #define _D4N 0x40
6744 #define _LC1G1D4T 0x80
6745 #define _D4T 0x80
6747 //==============================================================================
6750 //==============================================================================
6751 // CLC1GLS1 Bits
6753 extern __at(0x0F17) __sfr CLC1GLS1;
6755 typedef union
6757 struct
6759 unsigned LC1G2D1N : 1;
6760 unsigned LC1G2D1T : 1;
6761 unsigned LC1G2D2N : 1;
6762 unsigned LC1G2D2T : 1;
6763 unsigned LC1G2D3N : 1;
6764 unsigned LC1G2D3T : 1;
6765 unsigned LC1G2D4N : 1;
6766 unsigned LC1G2D4T : 1;
6769 struct
6771 unsigned D1N : 1;
6772 unsigned D1T : 1;
6773 unsigned D2N : 1;
6774 unsigned D2T : 1;
6775 unsigned D3N : 1;
6776 unsigned D3T : 1;
6777 unsigned D4N : 1;
6778 unsigned D4T : 1;
6780 } __CLC1GLS1bits_t;
6782 extern __at(0x0F17) volatile __CLC1GLS1bits_t CLC1GLS1bits;
6784 #define _CLC1GLS1_LC1G2D1N 0x01
6785 #define _CLC1GLS1_D1N 0x01
6786 #define _CLC1GLS1_LC1G2D1T 0x02
6787 #define _CLC1GLS1_D1T 0x02
6788 #define _CLC1GLS1_LC1G2D2N 0x04
6789 #define _CLC1GLS1_D2N 0x04
6790 #define _CLC1GLS1_LC1G2D2T 0x08
6791 #define _CLC1GLS1_D2T 0x08
6792 #define _CLC1GLS1_LC1G2D3N 0x10
6793 #define _CLC1GLS1_D3N 0x10
6794 #define _CLC1GLS1_LC1G2D3T 0x20
6795 #define _CLC1GLS1_D3T 0x20
6796 #define _CLC1GLS1_LC1G2D4N 0x40
6797 #define _CLC1GLS1_D4N 0x40
6798 #define _CLC1GLS1_LC1G2D4T 0x80
6799 #define _CLC1GLS1_D4T 0x80
6801 //==============================================================================
6804 //==============================================================================
6805 // CLC1GLS2 Bits
6807 extern __at(0x0F18) __sfr CLC1GLS2;
6809 typedef union
6811 struct
6813 unsigned LC1G3D1N : 1;
6814 unsigned LC1G3D1T : 1;
6815 unsigned LC1G3D2N : 1;
6816 unsigned LC1G3D2T : 1;
6817 unsigned LC1G3D3N : 1;
6818 unsigned LC1G3D3T : 1;
6819 unsigned LC1G3D4N : 1;
6820 unsigned LC1G3D4T : 1;
6823 struct
6825 unsigned D1N : 1;
6826 unsigned D1T : 1;
6827 unsigned D2N : 1;
6828 unsigned D2T : 1;
6829 unsigned D3N : 1;
6830 unsigned D3T : 1;
6831 unsigned D4N : 1;
6832 unsigned D4T : 1;
6834 } __CLC1GLS2bits_t;
6836 extern __at(0x0F18) volatile __CLC1GLS2bits_t CLC1GLS2bits;
6838 #define _CLC1GLS2_LC1G3D1N 0x01
6839 #define _CLC1GLS2_D1N 0x01
6840 #define _CLC1GLS2_LC1G3D1T 0x02
6841 #define _CLC1GLS2_D1T 0x02
6842 #define _CLC1GLS2_LC1G3D2N 0x04
6843 #define _CLC1GLS2_D2N 0x04
6844 #define _CLC1GLS2_LC1G3D2T 0x08
6845 #define _CLC1GLS2_D2T 0x08
6846 #define _CLC1GLS2_LC1G3D3N 0x10
6847 #define _CLC1GLS2_D3N 0x10
6848 #define _CLC1GLS2_LC1G3D3T 0x20
6849 #define _CLC1GLS2_D3T 0x20
6850 #define _CLC1GLS2_LC1G3D4N 0x40
6851 #define _CLC1GLS2_D4N 0x40
6852 #define _CLC1GLS2_LC1G3D4T 0x80
6853 #define _CLC1GLS2_D4T 0x80
6855 //==============================================================================
6858 //==============================================================================
6859 // CLC1GLS3 Bits
6861 extern __at(0x0F19) __sfr CLC1GLS3;
6863 typedef union
6865 struct
6867 unsigned LC1G4D1N : 1;
6868 unsigned LC1G4D1T : 1;
6869 unsigned LC1G4D2N : 1;
6870 unsigned LC1G4D2T : 1;
6871 unsigned LC1G4D3N : 1;
6872 unsigned LC1G4D3T : 1;
6873 unsigned LC1G4D4N : 1;
6874 unsigned LC1G4D4T : 1;
6877 struct
6879 unsigned G4D1N : 1;
6880 unsigned G4D1T : 1;
6881 unsigned G4D2N : 1;
6882 unsigned G4D2T : 1;
6883 unsigned G4D3N : 1;
6884 unsigned G4D3T : 1;
6885 unsigned G4D4N : 1;
6886 unsigned G4D4T : 1;
6888 } __CLC1GLS3bits_t;
6890 extern __at(0x0F19) volatile __CLC1GLS3bits_t CLC1GLS3bits;
6892 #define _LC1G4D1N 0x01
6893 #define _G4D1N 0x01
6894 #define _LC1G4D1T 0x02
6895 #define _G4D1T 0x02
6896 #define _LC1G4D2N 0x04
6897 #define _G4D2N 0x04
6898 #define _LC1G4D2T 0x08
6899 #define _G4D2T 0x08
6900 #define _LC1G4D3N 0x10
6901 #define _G4D3N 0x10
6902 #define _LC1G4D3T 0x20
6903 #define _G4D3T 0x20
6904 #define _LC1G4D4N 0x40
6905 #define _G4D4N 0x40
6906 #define _LC1G4D4T 0x80
6907 #define _G4D4T 0x80
6909 //==============================================================================
6912 //==============================================================================
6913 // CLC2CON Bits
6915 extern __at(0x0F1A) __sfr CLC2CON;
6917 typedef union
6919 struct
6921 unsigned LC2MODE0 : 1;
6922 unsigned LC2MODE1 : 1;
6923 unsigned LC2MODE2 : 1;
6924 unsigned LC2INTN : 1;
6925 unsigned LC2INTP : 1;
6926 unsigned LC2OUT : 1;
6927 unsigned : 1;
6928 unsigned LC2EN : 1;
6931 struct
6933 unsigned MODE0 : 1;
6934 unsigned MODE1 : 1;
6935 unsigned MODE2 : 1;
6936 unsigned INTN : 1;
6937 unsigned INTP : 1;
6938 unsigned OUT : 1;
6939 unsigned : 1;
6940 unsigned EN : 1;
6943 struct
6945 unsigned MODE : 3;
6946 unsigned : 5;
6949 struct
6951 unsigned LC2MODE : 3;
6952 unsigned : 5;
6954 } __CLC2CONbits_t;
6956 extern __at(0x0F1A) volatile __CLC2CONbits_t CLC2CONbits;
6958 #define _CLC2CON_LC2MODE0 0x01
6959 #define _CLC2CON_MODE0 0x01
6960 #define _CLC2CON_LC2MODE1 0x02
6961 #define _CLC2CON_MODE1 0x02
6962 #define _CLC2CON_LC2MODE2 0x04
6963 #define _CLC2CON_MODE2 0x04
6964 #define _CLC2CON_LC2INTN 0x08
6965 #define _CLC2CON_INTN 0x08
6966 #define _CLC2CON_LC2INTP 0x10
6967 #define _CLC2CON_INTP 0x10
6968 #define _CLC2CON_LC2OUT 0x20
6969 #define _CLC2CON_OUT 0x20
6970 #define _CLC2CON_LC2EN 0x80
6971 #define _CLC2CON_EN 0x80
6973 //==============================================================================
6976 //==============================================================================
6977 // CLC2POL Bits
6979 extern __at(0x0F1B) __sfr CLC2POL;
6981 typedef union
6983 struct
6985 unsigned LC2G1POL : 1;
6986 unsigned LC2G2POL : 1;
6987 unsigned LC2G3POL : 1;
6988 unsigned LC2G4POL : 1;
6989 unsigned : 1;
6990 unsigned : 1;
6991 unsigned : 1;
6992 unsigned LC2POL : 1;
6995 struct
6997 unsigned G1POL : 1;
6998 unsigned G2POL : 1;
6999 unsigned G3POL : 1;
7000 unsigned G4POL : 1;
7001 unsigned : 1;
7002 unsigned : 1;
7003 unsigned : 1;
7004 unsigned POL : 1;
7006 } __CLC2POLbits_t;
7008 extern __at(0x0F1B) volatile __CLC2POLbits_t CLC2POLbits;
7010 #define _CLC2POL_LC2G1POL 0x01
7011 #define _CLC2POL_G1POL 0x01
7012 #define _CLC2POL_LC2G2POL 0x02
7013 #define _CLC2POL_G2POL 0x02
7014 #define _CLC2POL_LC2G3POL 0x04
7015 #define _CLC2POL_G3POL 0x04
7016 #define _CLC2POL_LC2G4POL 0x08
7017 #define _CLC2POL_G4POL 0x08
7018 #define _CLC2POL_LC2POL 0x80
7019 #define _CLC2POL_POL 0x80
7021 //==============================================================================
7024 //==============================================================================
7025 // CLC2SEL0 Bits
7027 extern __at(0x0F1C) __sfr CLC2SEL0;
7029 typedef union
7031 struct
7033 unsigned LC2D1S0 : 1;
7034 unsigned LC2D1S1 : 1;
7035 unsigned LC2D1S2 : 1;
7036 unsigned LC2D1S3 : 1;
7037 unsigned LC2D1S4 : 1;
7038 unsigned : 1;
7039 unsigned : 1;
7040 unsigned : 1;
7043 struct
7045 unsigned D1S0 : 1;
7046 unsigned D1S1 : 1;
7047 unsigned D1S2 : 1;
7048 unsigned D1S3 : 1;
7049 unsigned D1S4 : 1;
7050 unsigned : 1;
7051 unsigned : 1;
7052 unsigned : 1;
7055 struct
7057 unsigned LC2D1S : 5;
7058 unsigned : 3;
7061 struct
7063 unsigned D1S : 5;
7064 unsigned : 3;
7066 } __CLC2SEL0bits_t;
7068 extern __at(0x0F1C) volatile __CLC2SEL0bits_t CLC2SEL0bits;
7070 #define _CLC2SEL0_LC2D1S0 0x01
7071 #define _CLC2SEL0_D1S0 0x01
7072 #define _CLC2SEL0_LC2D1S1 0x02
7073 #define _CLC2SEL0_D1S1 0x02
7074 #define _CLC2SEL0_LC2D1S2 0x04
7075 #define _CLC2SEL0_D1S2 0x04
7076 #define _CLC2SEL0_LC2D1S3 0x08
7077 #define _CLC2SEL0_D1S3 0x08
7078 #define _CLC2SEL0_LC2D1S4 0x10
7079 #define _CLC2SEL0_D1S4 0x10
7081 //==============================================================================
7084 //==============================================================================
7085 // CLC2SEL1 Bits
7087 extern __at(0x0F1D) __sfr CLC2SEL1;
7089 typedef union
7091 struct
7093 unsigned LC2D2S0 : 1;
7094 unsigned LC2D2S1 : 1;
7095 unsigned LC2D2S2 : 1;
7096 unsigned LC2D2S3 : 1;
7097 unsigned LC2D2S4 : 1;
7098 unsigned : 1;
7099 unsigned : 1;
7100 unsigned : 1;
7103 struct
7105 unsigned D2S0 : 1;
7106 unsigned D2S1 : 1;
7107 unsigned D2S2 : 1;
7108 unsigned D2S3 : 1;
7109 unsigned D2S4 : 1;
7110 unsigned : 1;
7111 unsigned : 1;
7112 unsigned : 1;
7115 struct
7117 unsigned LC2D2S : 5;
7118 unsigned : 3;
7121 struct
7123 unsigned D2S : 5;
7124 unsigned : 3;
7126 } __CLC2SEL1bits_t;
7128 extern __at(0x0F1D) volatile __CLC2SEL1bits_t CLC2SEL1bits;
7130 #define _CLC2SEL1_LC2D2S0 0x01
7131 #define _CLC2SEL1_D2S0 0x01
7132 #define _CLC2SEL1_LC2D2S1 0x02
7133 #define _CLC2SEL1_D2S1 0x02
7134 #define _CLC2SEL1_LC2D2S2 0x04
7135 #define _CLC2SEL1_D2S2 0x04
7136 #define _CLC2SEL1_LC2D2S3 0x08
7137 #define _CLC2SEL1_D2S3 0x08
7138 #define _CLC2SEL1_LC2D2S4 0x10
7139 #define _CLC2SEL1_D2S4 0x10
7141 //==============================================================================
7144 //==============================================================================
7145 // CLC2SEL2 Bits
7147 extern __at(0x0F1E) __sfr CLC2SEL2;
7149 typedef union
7151 struct
7153 unsigned LC2D3S0 : 1;
7154 unsigned LC2D3S1 : 1;
7155 unsigned LC2D3S2 : 1;
7156 unsigned LC2D3S3 : 1;
7157 unsigned LC2D3S4 : 1;
7158 unsigned : 1;
7159 unsigned : 1;
7160 unsigned : 1;
7163 struct
7165 unsigned D3S0 : 1;
7166 unsigned D3S1 : 1;
7167 unsigned D3S2 : 1;
7168 unsigned D3S3 : 1;
7169 unsigned D3S4 : 1;
7170 unsigned : 1;
7171 unsigned : 1;
7172 unsigned : 1;
7175 struct
7177 unsigned LC2D3S : 5;
7178 unsigned : 3;
7181 struct
7183 unsigned D3S : 5;
7184 unsigned : 3;
7186 } __CLC2SEL2bits_t;
7188 extern __at(0x0F1E) volatile __CLC2SEL2bits_t CLC2SEL2bits;
7190 #define _CLC2SEL2_LC2D3S0 0x01
7191 #define _CLC2SEL2_D3S0 0x01
7192 #define _CLC2SEL2_LC2D3S1 0x02
7193 #define _CLC2SEL2_D3S1 0x02
7194 #define _CLC2SEL2_LC2D3S2 0x04
7195 #define _CLC2SEL2_D3S2 0x04
7196 #define _CLC2SEL2_LC2D3S3 0x08
7197 #define _CLC2SEL2_D3S3 0x08
7198 #define _CLC2SEL2_LC2D3S4 0x10
7199 #define _CLC2SEL2_D3S4 0x10
7201 //==============================================================================
7204 //==============================================================================
7205 // CLC2SEL3 Bits
7207 extern __at(0x0F1F) __sfr CLC2SEL3;
7209 typedef union
7211 struct
7213 unsigned LC2D4S0 : 1;
7214 unsigned LC2D4S1 : 1;
7215 unsigned LC2D4S2 : 1;
7216 unsigned LC2D4S3 : 1;
7217 unsigned LC2D4S4 : 1;
7218 unsigned : 1;
7219 unsigned : 1;
7220 unsigned : 1;
7223 struct
7225 unsigned D4S0 : 1;
7226 unsigned D4S1 : 1;
7227 unsigned D4S2 : 1;
7228 unsigned D4S3 : 1;
7229 unsigned D4S4 : 1;
7230 unsigned : 1;
7231 unsigned : 1;
7232 unsigned : 1;
7235 struct
7237 unsigned LC2D4S : 5;
7238 unsigned : 3;
7241 struct
7243 unsigned D4S : 5;
7244 unsigned : 3;
7246 } __CLC2SEL3bits_t;
7248 extern __at(0x0F1F) volatile __CLC2SEL3bits_t CLC2SEL3bits;
7250 #define _CLC2SEL3_LC2D4S0 0x01
7251 #define _CLC2SEL3_D4S0 0x01
7252 #define _CLC2SEL3_LC2D4S1 0x02
7253 #define _CLC2SEL3_D4S1 0x02
7254 #define _CLC2SEL3_LC2D4S2 0x04
7255 #define _CLC2SEL3_D4S2 0x04
7256 #define _CLC2SEL3_LC2D4S3 0x08
7257 #define _CLC2SEL3_D4S3 0x08
7258 #define _CLC2SEL3_LC2D4S4 0x10
7259 #define _CLC2SEL3_D4S4 0x10
7261 //==============================================================================
7264 //==============================================================================
7265 // CLC2GLS0 Bits
7267 extern __at(0x0F20) __sfr CLC2GLS0;
7269 typedef union
7271 struct
7273 unsigned LC2G1D1N : 1;
7274 unsigned LC2G1D1T : 1;
7275 unsigned LC2G1D2N : 1;
7276 unsigned LC2G1D2T : 1;
7277 unsigned LC2G1D3N : 1;
7278 unsigned LC2G1D3T : 1;
7279 unsigned LC2G1D4N : 1;
7280 unsigned LC2G1D4T : 1;
7283 struct
7285 unsigned D1N : 1;
7286 unsigned D1T : 1;
7287 unsigned D2N : 1;
7288 unsigned D2T : 1;
7289 unsigned D3N : 1;
7290 unsigned D3T : 1;
7291 unsigned D4N : 1;
7292 unsigned D4T : 1;
7294 } __CLC2GLS0bits_t;
7296 extern __at(0x0F20) volatile __CLC2GLS0bits_t CLC2GLS0bits;
7298 #define _CLC2GLS0_LC2G1D1N 0x01
7299 #define _CLC2GLS0_D1N 0x01
7300 #define _CLC2GLS0_LC2G1D1T 0x02
7301 #define _CLC2GLS0_D1T 0x02
7302 #define _CLC2GLS0_LC2G1D2N 0x04
7303 #define _CLC2GLS0_D2N 0x04
7304 #define _CLC2GLS0_LC2G1D2T 0x08
7305 #define _CLC2GLS0_D2T 0x08
7306 #define _CLC2GLS0_LC2G1D3N 0x10
7307 #define _CLC2GLS0_D3N 0x10
7308 #define _CLC2GLS0_LC2G1D3T 0x20
7309 #define _CLC2GLS0_D3T 0x20
7310 #define _CLC2GLS0_LC2G1D4N 0x40
7311 #define _CLC2GLS0_D4N 0x40
7312 #define _CLC2GLS0_LC2G1D4T 0x80
7313 #define _CLC2GLS0_D4T 0x80
7315 //==============================================================================
7318 //==============================================================================
7319 // CLC2GLS1 Bits
7321 extern __at(0x0F21) __sfr CLC2GLS1;
7323 typedef union
7325 struct
7327 unsigned LC2G2D1N : 1;
7328 unsigned LC2G2D1T : 1;
7329 unsigned LC2G2D2N : 1;
7330 unsigned LC2G2D2T : 1;
7331 unsigned LC2G2D3N : 1;
7332 unsigned LC2G2D3T : 1;
7333 unsigned LC2G2D4N : 1;
7334 unsigned LC2G2D4T : 1;
7337 struct
7339 unsigned D1N : 1;
7340 unsigned D1T : 1;
7341 unsigned D2N : 1;
7342 unsigned D2T : 1;
7343 unsigned D3N : 1;
7344 unsigned D3T : 1;
7345 unsigned D4N : 1;
7346 unsigned D4T : 1;
7348 } __CLC2GLS1bits_t;
7350 extern __at(0x0F21) volatile __CLC2GLS1bits_t CLC2GLS1bits;
7352 #define _CLC2GLS1_LC2G2D1N 0x01
7353 #define _CLC2GLS1_D1N 0x01
7354 #define _CLC2GLS1_LC2G2D1T 0x02
7355 #define _CLC2GLS1_D1T 0x02
7356 #define _CLC2GLS1_LC2G2D2N 0x04
7357 #define _CLC2GLS1_D2N 0x04
7358 #define _CLC2GLS1_LC2G2D2T 0x08
7359 #define _CLC2GLS1_D2T 0x08
7360 #define _CLC2GLS1_LC2G2D3N 0x10
7361 #define _CLC2GLS1_D3N 0x10
7362 #define _CLC2GLS1_LC2G2D3T 0x20
7363 #define _CLC2GLS1_D3T 0x20
7364 #define _CLC2GLS1_LC2G2D4N 0x40
7365 #define _CLC2GLS1_D4N 0x40
7366 #define _CLC2GLS1_LC2G2D4T 0x80
7367 #define _CLC2GLS1_D4T 0x80
7369 //==============================================================================
7372 //==============================================================================
7373 // CLC2GLS2 Bits
7375 extern __at(0x0F22) __sfr CLC2GLS2;
7377 typedef union
7379 struct
7381 unsigned LC2G3D1N : 1;
7382 unsigned LC2G3D1T : 1;
7383 unsigned LC2G3D2N : 1;
7384 unsigned LC2G3D2T : 1;
7385 unsigned LC2G3D3N : 1;
7386 unsigned LC2G3D3T : 1;
7387 unsigned LC2G3D4N : 1;
7388 unsigned LC2G3D4T : 1;
7391 struct
7393 unsigned D1N : 1;
7394 unsigned D1T : 1;
7395 unsigned D2N : 1;
7396 unsigned D2T : 1;
7397 unsigned D3N : 1;
7398 unsigned D3T : 1;
7399 unsigned D4N : 1;
7400 unsigned D4T : 1;
7402 } __CLC2GLS2bits_t;
7404 extern __at(0x0F22) volatile __CLC2GLS2bits_t CLC2GLS2bits;
7406 #define _CLC2GLS2_LC2G3D1N 0x01
7407 #define _CLC2GLS2_D1N 0x01
7408 #define _CLC2GLS2_LC2G3D1T 0x02
7409 #define _CLC2GLS2_D1T 0x02
7410 #define _CLC2GLS2_LC2G3D2N 0x04
7411 #define _CLC2GLS2_D2N 0x04
7412 #define _CLC2GLS2_LC2G3D2T 0x08
7413 #define _CLC2GLS2_D2T 0x08
7414 #define _CLC2GLS2_LC2G3D3N 0x10
7415 #define _CLC2GLS2_D3N 0x10
7416 #define _CLC2GLS2_LC2G3D3T 0x20
7417 #define _CLC2GLS2_D3T 0x20
7418 #define _CLC2GLS2_LC2G3D4N 0x40
7419 #define _CLC2GLS2_D4N 0x40
7420 #define _CLC2GLS2_LC2G3D4T 0x80
7421 #define _CLC2GLS2_D4T 0x80
7423 //==============================================================================
7426 //==============================================================================
7427 // CLC2GLS3 Bits
7429 extern __at(0x0F23) __sfr CLC2GLS3;
7431 typedef union
7433 struct
7435 unsigned LC2G4D1N : 1;
7436 unsigned LC2G4D1T : 1;
7437 unsigned LC2G4D2N : 1;
7438 unsigned LC2G4D2T : 1;
7439 unsigned LC2G4D3N : 1;
7440 unsigned LC2G4D3T : 1;
7441 unsigned LC2G4D4N : 1;
7442 unsigned LC2G4D4T : 1;
7445 struct
7447 unsigned G4D1N : 1;
7448 unsigned G4D1T : 1;
7449 unsigned G4D2N : 1;
7450 unsigned G4D2T : 1;
7451 unsigned G4D3N : 1;
7452 unsigned G4D3T : 1;
7453 unsigned G4D4N : 1;
7454 unsigned G4D4T : 1;
7456 } __CLC2GLS3bits_t;
7458 extern __at(0x0F23) volatile __CLC2GLS3bits_t CLC2GLS3bits;
7460 #define _CLC2GLS3_LC2G4D1N 0x01
7461 #define _CLC2GLS3_G4D1N 0x01
7462 #define _CLC2GLS3_LC2G4D1T 0x02
7463 #define _CLC2GLS3_G4D1T 0x02
7464 #define _CLC2GLS3_LC2G4D2N 0x04
7465 #define _CLC2GLS3_G4D2N 0x04
7466 #define _CLC2GLS3_LC2G4D2T 0x08
7467 #define _CLC2GLS3_G4D2T 0x08
7468 #define _CLC2GLS3_LC2G4D3N 0x10
7469 #define _CLC2GLS3_G4D3N 0x10
7470 #define _CLC2GLS3_LC2G4D3T 0x20
7471 #define _CLC2GLS3_G4D3T 0x20
7472 #define _CLC2GLS3_LC2G4D4N 0x40
7473 #define _CLC2GLS3_G4D4N 0x40
7474 #define _CLC2GLS3_LC2G4D4T 0x80
7475 #define _CLC2GLS3_G4D4T 0x80
7477 //==============================================================================
7480 //==============================================================================
7481 // STATUS_SHAD Bits
7483 extern __at(0x0FE4) __sfr STATUS_SHAD;
7485 typedef struct
7487 unsigned C_SHAD : 1;
7488 unsigned DC_SHAD : 1;
7489 unsigned Z_SHAD : 1;
7490 unsigned : 1;
7491 unsigned : 1;
7492 unsigned : 1;
7493 unsigned : 1;
7494 unsigned : 1;
7495 } __STATUS_SHADbits_t;
7497 extern __at(0x0FE4) volatile __STATUS_SHADbits_t STATUS_SHADbits;
7499 #define _C_SHAD 0x01
7500 #define _DC_SHAD 0x02
7501 #define _Z_SHAD 0x04
7503 //==============================================================================
7505 extern __at(0x0FE5) __sfr WREG_SHAD;
7506 extern __at(0x0FE6) __sfr BSR_SHAD;
7507 extern __at(0x0FE7) __sfr PCLATH_SHAD;
7508 extern __at(0x0FE8) __sfr FSR0L_SHAD;
7509 extern __at(0x0FE9) __sfr FSR0H_SHAD;
7510 extern __at(0x0FEA) __sfr FSR1L_SHAD;
7511 extern __at(0x0FEB) __sfr FSR1H_SHAD;
7512 extern __at(0x0FED) __sfr STKPTR;
7513 extern __at(0x0FEE) __sfr TOSL;
7514 extern __at(0x0FEF) __sfr TOSH;
7516 //==============================================================================
7518 // Configuration Bits
7520 //==============================================================================
7522 #define _CONFIG1 0x8007
7523 #define _CONFIG2 0x8008
7524 #define _CONFIG3 0x8009
7525 #define _CONFIG4 0x800A
7527 //----------------------------- CONFIG1 Options -------------------------------
7529 #define _FEXTOSC_LP 0x3FF8 // LP (crystal oscillator) optimized for 32.768 kHz.
7530 #define _FEXTOSC_XT 0x3FF9 // XT (crystal oscillator) from 100 kHz to 4 MHz.
7531 #define _FEXTOSC_HS 0x3FFA // HS (crystal oscillator) above 4 MHz.
7532 #define _FEXTOSC_OFF 0x3FFC // Oscillator not enabled.
7533 #define _FEXTOSC_ECL 0x3FFD // EC (external clock) below 100 kHz.
7534 #define _FEXTOSC_ECM 0x3FFE // EC (external clock) for 100 kHz to 8 MHz.
7535 #define _FEXTOSC_ECH 0x3FFF // EC (external clock) above 8 MHz.
7536 #define _RSTOSC_HFINT32 0x3F8F // HFINTOSC with 2x PLL (32MHz).
7537 #define _RSTOSC_EXT4X 0x3F9F // EXTOSC with 4x PLL, with EXTOSC operating per FEXTOSC bits.
7538 #define _RSTOSC_SOSC 0x3FBF // SOSC (31kHz).
7539 #define _RSTOSC_LFINT 0x3FCF // LFINTOSC (31kHz).
7540 #define _RSTOSC_HFINT1 0x3FEF // HFINTOSC (1MHz).
7541 #define _RSTOSC_EXT1X 0x3FFF // EXTOSC operating per FEXTOSC bits.
7542 #define _CLKOUTEN_ON 0x3EFF // CLKOUT function is enabled; FOSC/4 clock appears at OSC2.
7543 #define _CLKOUTEN_OFF 0x3FFF // CLKOUT function is disabled; I/O or oscillator function on OSC2.
7544 #define _CSWEN_OFF 0x37FF // The NOSC and NDIV bits cannot be changed by user software.
7545 #define _CSWEN_ON 0x3FFF // Writing to NOSC and NDIV is allowed.
7546 #define _FCMEN_OFF 0x1FFF // Fail-Safe Clock Monitor is disabled.
7547 #define _FCMEN_ON 0x3FFF // Fail-Safe Clock Monitor is enabled.
7549 //----------------------------- CONFIG2 Options -------------------------------
7551 #define _MCLRE_OFF 0x3FFE // MCLR/VPP pin function is digital input; MCLR internally disabled; Weak pull-up under control of port pin's WPU control bit.
7552 #define _MCLRE_ON 0x3FFF // MCLR/VPP pin function is MCLR; Weak pull-up enabled.
7553 #define _PWRTE_ON 0x3FFD // PWRT enabled.
7554 #define _PWRTE_OFF 0x3FFF // PWRT disabled.
7555 #define _WDTE_OFF 0x3FF3 // WDT disabled; SWDTEN is ignored.
7556 #define _WDTE_SWDTEN 0x3FF7 // WDT controlled by the SWDTEN bit in the WDTCON register.
7557 #define _WDTE_SLEEP 0x3FFB // WDT enabled while running and disabled in SLEEP/IDLE; SWDTEN is ignored.
7558 #define _WDTE_ON 0x3FFF // WDT enabled, SWDTEN is ignored.
7559 #define _LPBOREN_ON 0x3FDF // ULPBOR enabled.
7560 #define _LPBOREN_OFF 0x3FFF // ULPBOR disabled.
7561 #define _BOREN_OFF 0x3F3F // Brown-out Reset disabled.
7562 #define _BOREN_SBOREN 0x3F7F // Brown-out Reset enabled according to SBOREN.
7563 #define _BOREN_SLEEP 0x3FBF // Brown-out Reset enabled while running, disabled in Sleep; SBOREN is ignored.
7564 #define _BOREN_ON 0x3FFF // Brown-out Reset enabled, SBOREN bit ignored.
7565 #define _BORV_HIGH 0x3DFF // Brown-out voltage (Vbor) set to 2.7V.
7566 #define _BORV_LOW 0x3FFF // Brown-out voltage (Vbor) set to 2.45V.
7567 #define _PPS1WAY_OFF 0x37FF // The PPSLOCK bit can be set and cleared repeatedly (subject to the unlock sequence).
7568 #define _PPS1WAY_ON 0x3FFF // The PPSLOCK bit can be cleared and set only once; PPS registers remain locked after one clear/set cycle.
7569 #define _STVREN_OFF 0x2FFF // Stack Overflow or Underflow will not cause a Reset.
7570 #define _STVREN_ON 0x3FFF // Stack Overflow or Underflow will cause a Reset.
7571 #define _DEBUG_ON 0x1FFF // Background debugger enabled.
7572 #define _DEBUG_OFF 0x3FFF // Background debugger disabled.
7574 //----------------------------- CONFIG3 Options -------------------------------
7576 #define _WRT_ALL 0x3FFC // 0000h to 07FFh write protected, no addresses may be modified.
7577 #define _WRT_HALF 0x3FFD // 0000h to 03FFh write-protected, 0400h to 07FFh may be modified.
7578 #define _WRT_BOOT 0x3FFE // 0000h to 01FFh write-protected, 0200h to 07FFh may be modified.
7579 #define _WRT_OFF 0x3FFF // Write protection off.
7580 #define _LVP_OFF 0x1FFF // High Voltage on MCLR/VPP must be used for programming.
7581 #define _LVP_ON 0x3FFF // Low Voltage programming enabled. MCLR/VPP pin function is MCLR. MCLRE configuration bit is ignored.
7583 //----------------------------- CONFIG4 Options -------------------------------
7585 #define _CP_ON 0x3FFE // User NVM code protection enabled.
7586 #define _CP_OFF 0x3FFF // User NVM code protection disabled.
7587 #define _CPD_ON 0x3FFD // Data NVM code protection enabled.
7588 #define _CPD_OFF 0x3FFF // Data NVM code protection disabled.
7590 //==============================================================================
7592 #define _DEVID1 0x8006
7594 #define _IDLOC0 0x8000
7595 #define _IDLOC1 0x8001
7596 #define _IDLOC2 0x8002
7597 #define _IDLOC3 0x8003
7599 //==============================================================================
7601 #ifndef NO_BIT_DEFINES
7603 #define ADACT0 ADACTbits.ADACT0 // bit 0
7604 #define ADACT1 ADACTbits.ADACT1 // bit 1
7605 #define ADACT2 ADACTbits.ADACT2 // bit 2
7606 #define ADACT3 ADACTbits.ADACT3 // bit 3
7608 #define ADON ADCON0bits.ADON // bit 0
7609 #define GO_NOT_DONE ADCON0bits.GO_NOT_DONE // bit 1, shadows bit in ADCON0bits
7610 #define ADGO ADCON0bits.ADGO // bit 1, shadows bit in ADCON0bits
7611 #define GO ADCON0bits.GO // bit 1, shadows bit in ADCON0bits
7612 #define CHS0 ADCON0bits.CHS0 // bit 2
7613 #define CHS1 ADCON0bits.CHS1 // bit 3
7614 #define CHS2 ADCON0bits.CHS2 // bit 4
7615 #define CHS3 ADCON0bits.CHS3 // bit 5
7616 #define CHS4 ADCON0bits.CHS4 // bit 6
7617 #define CHS5 ADCON0bits.CHS5 // bit 7
7619 #define ADPREF0 ADCON1bits.ADPREF0 // bit 0
7620 #define ADPREF1 ADCON1bits.ADPREF1 // bit 1
7621 #define ADNREF ADCON1bits.ADNREF // bit 2
7622 #define ADCS0 ADCON1bits.ADCS0 // bit 4
7623 #define ADCS1 ADCON1bits.ADCS1 // bit 5
7624 #define ADCS2 ADCON1bits.ADCS2 // bit 6
7625 #define ADFM ADCON1bits.ADFM // bit 7
7627 #define ANSA0 ANSELAbits.ANSA0 // bit 0
7628 #define ANSA1 ANSELAbits.ANSA1 // bit 1
7629 #define ANSA2 ANSELAbits.ANSA2 // bit 2
7630 #define ANSA4 ANSELAbits.ANSA4 // bit 4
7631 #define ANSA5 ANSELAbits.ANSA5 // bit 5
7633 #define ANSC0 ANSELCbits.ANSC0 // bit 0
7634 #define ANSC1 ANSELCbits.ANSC1 // bit 1
7635 #define ANSC2 ANSELCbits.ANSC2 // bit 2
7636 #define ANSC3 ANSELCbits.ANSC3 // bit 3
7637 #define ANSC4 ANSELCbits.ANSC4 // bit 4
7638 #define ANSC5 ANSELCbits.ANSC5 // bit 5
7640 #define ABDEN BAUD1CONbits.ABDEN // bit 0
7641 #define WUE BAUD1CONbits.WUE // bit 1
7642 #define BRG16 BAUD1CONbits.BRG16 // bit 3
7643 #define SCKP BAUD1CONbits.SCKP // bit 4
7644 #define RCIDL BAUD1CONbits.RCIDL // bit 6
7645 #define ABDOVF BAUD1CONbits.ABDOVF // bit 7
7647 #define BORRDY BORCONbits.BORRDY // bit 0
7648 #define SBOREN BORCONbits.SBOREN // bit 7
7650 #define BSR0 BSRbits.BSR0 // bit 0
7651 #define BSR1 BSRbits.BSR1 // bit 1
7652 #define BSR2 BSRbits.BSR2 // bit 2
7653 #define BSR3 BSRbits.BSR3 // bit 3
7654 #define BSR4 BSRbits.BSR4 // bit 4
7656 #define CCDS0 CCDCONbits.CCDS0 // bit 0
7657 #define CCDS1 CCDCONbits.CCDS1 // bit 1
7658 #define CCDEN CCDCONbits.CCDEN // bit 7
7660 #define CCDNA0 CCDNAbits.CCDNA0 // bit 0
7661 #define CCDNA1 CCDNAbits.CCDNA1 // bit 1
7662 #define CCDNA2 CCDNAbits.CCDNA2 // bit 2
7663 #define CCDNA4 CCDNAbits.CCDNA4 // bit 4
7664 #define CCDNA5 CCDNAbits.CCDNA5 // bit 5
7666 #define CCDNC0 CCDNCbits.CCDNC0 // bit 0
7667 #define CCDNC1 CCDNCbits.CCDNC1 // bit 1
7668 #define CCDNC2 CCDNCbits.CCDNC2 // bit 2
7669 #define CCDNC3 CCDNCbits.CCDNC3 // bit 3
7670 #define CCDNC4 CCDNCbits.CCDNC4 // bit 4
7671 #define CCDNC5 CCDNCbits.CCDNC5 // bit 5
7673 #define CCDPA0 CCDPAbits.CCDPA0 // bit 0
7674 #define CCDPA1 CCDPAbits.CCDPA1 // bit 1
7675 #define CCDPA2 CCDPAbits.CCDPA2 // bit 2
7676 #define CCDPA4 CCDPAbits.CCDPA4 // bit 4
7677 #define CCDPA5 CCDPAbits.CCDPA5 // bit 5
7679 #define CCDPC0 CCDPCbits.CCDPC0 // bit 0
7680 #define CCDPC1 CCDPCbits.CCDPC1 // bit 1
7681 #define CCDPC2 CCDPCbits.CCDPC2 // bit 2
7682 #define CCDPC3 CCDPCbits.CCDPC3 // bit 3
7683 #define CCDPC4 CCDPCbits.CCDPC4 // bit 4
7684 #define CCDPC5 CCDPCbits.CCDPC5 // bit 5
7686 #define CCP1CTS0 CCP1CAPbits.CCP1CTS0 // bit 0
7687 #define CCP1CTS1 CCP1CAPbits.CCP1CTS1 // bit 1
7688 #define CCP1CTS2 CCP1CAPbits.CCP1CTS2 // bit 2
7690 #define CCP1MODE0 CCP1CONbits.CCP1MODE0 // bit 0
7691 #define CCP1MODE1 CCP1CONbits.CCP1MODE1 // bit 1
7692 #define CCP1MODE2 CCP1CONbits.CCP1MODE2 // bit 2
7693 #define CCP1MODE3 CCP1CONbits.CCP1MODE3 // bit 3
7694 #define CCP1FMT CCP1CONbits.CCP1FMT // bit 4
7695 #define CCP1OUT CCP1CONbits.CCP1OUT // bit 5
7696 #define CCP1EN CCP1CONbits.CCP1EN // bit 7
7698 #define CCP1PPS0 CCP1PPSbits.CCP1PPS0 // bit 0
7699 #define CCP1PPS1 CCP1PPSbits.CCP1PPS1 // bit 1
7700 #define CCP1PPS2 CCP1PPSbits.CCP1PPS2 // bit 2
7701 #define CCP1PPS3 CCP1PPSbits.CCP1PPS3 // bit 3
7702 #define CCP1PPS4 CCP1PPSbits.CCP1PPS4 // bit 4
7704 #define CCP2CTS0 CCP2CAPbits.CCP2CTS0 // bit 0
7705 #define CCP2CTS1 CCP2CAPbits.CCP2CTS1 // bit 1
7706 #define CCP2CTS2 CCP2CAPbits.CCP2CTS2 // bit 2
7708 #define CCP2MODE0 CCP2CONbits.CCP2MODE0 // bit 0
7709 #define CCP2MODE1 CCP2CONbits.CCP2MODE1 // bit 1
7710 #define CCP2MODE2 CCP2CONbits.CCP2MODE2 // bit 2
7711 #define CCP2MODE3 CCP2CONbits.CCP2MODE3 // bit 3
7712 #define CCP2FMT CCP2CONbits.CCP2FMT // bit 4
7713 #define CCP2OUT CCP2CONbits.CCP2OUT // bit 5
7714 #define CCP2EN CCP2CONbits.CCP2EN // bit 7
7716 #define CCP2PPS0 CCP2PPSbits.CCP2PPS0 // bit 0
7717 #define CCP2PPS1 CCP2PPSbits.CCP2PPS1 // bit 1
7718 #define CCP2PPS2 CCP2PPSbits.CCP2PPS2 // bit 2
7719 #define CCP2PPS3 CCP2PPSbits.CCP2PPS3 // bit 3
7720 #define CCP2PPS4 CCP2PPSbits.CCP2PPS4 // bit 4
7722 #define C1TSEL CCPTMRSbits.C1TSEL // bit 0
7723 #define C2TSEL CCPTMRSbits.C2TSEL // bit 2
7725 #define LC1MODE0 CLC1CONbits.LC1MODE0 // bit 0, shadows bit in CLC1CONbits
7726 #define MODE0 CLC1CONbits.MODE0 // bit 0, shadows bit in CLC1CONbits
7727 #define LC1MODE1 CLC1CONbits.LC1MODE1 // bit 1, shadows bit in CLC1CONbits
7728 #define MODE1 CLC1CONbits.MODE1 // bit 1, shadows bit in CLC1CONbits
7729 #define LC1MODE2 CLC1CONbits.LC1MODE2 // bit 2, shadows bit in CLC1CONbits
7730 #define MODE2 CLC1CONbits.MODE2 // bit 2, shadows bit in CLC1CONbits
7731 #define LC1INTN CLC1CONbits.LC1INTN // bit 3, shadows bit in CLC1CONbits
7732 #define INTN CLC1CONbits.INTN // bit 3, shadows bit in CLC1CONbits
7733 #define LC1INTP CLC1CONbits.LC1INTP // bit 4, shadows bit in CLC1CONbits
7734 #define INTP CLC1CONbits.INTP // bit 4, shadows bit in CLC1CONbits
7735 #define LC1OUT CLC1CONbits.LC1OUT // bit 5, shadows bit in CLC1CONbits
7736 #define OUT CLC1CONbits.OUT // bit 5, shadows bit in CLC1CONbits
7737 #define LC1EN CLC1CONbits.LC1EN // bit 7, shadows bit in CLC1CONbits
7738 #define EN CLC1CONbits.EN // bit 7, shadows bit in CLC1CONbits
7740 #define LC1G1D1N CLC1GLS0bits.LC1G1D1N // bit 0, shadows bit in CLC1GLS0bits
7741 #define D1N CLC1GLS0bits.D1N // bit 0, shadows bit in CLC1GLS0bits
7742 #define LC1G1D1T CLC1GLS0bits.LC1G1D1T // bit 1, shadows bit in CLC1GLS0bits
7743 #define D1T CLC1GLS0bits.D1T // bit 1, shadows bit in CLC1GLS0bits
7744 #define LC1G1D2N CLC1GLS0bits.LC1G1D2N // bit 2, shadows bit in CLC1GLS0bits
7745 #define D2N CLC1GLS0bits.D2N // bit 2, shadows bit in CLC1GLS0bits
7746 #define LC1G1D2T CLC1GLS0bits.LC1G1D2T // bit 3, shadows bit in CLC1GLS0bits
7747 #define D2T CLC1GLS0bits.D2T // bit 3, shadows bit in CLC1GLS0bits
7748 #define LC1G1D3N CLC1GLS0bits.LC1G1D3N // bit 4, shadows bit in CLC1GLS0bits
7749 #define D3N CLC1GLS0bits.D3N // bit 4, shadows bit in CLC1GLS0bits
7750 #define LC1G1D3T CLC1GLS0bits.LC1G1D3T // bit 5, shadows bit in CLC1GLS0bits
7751 #define D3T CLC1GLS0bits.D3T // bit 5, shadows bit in CLC1GLS0bits
7752 #define LC1G1D4N CLC1GLS0bits.LC1G1D4N // bit 6, shadows bit in CLC1GLS0bits
7753 #define D4N CLC1GLS0bits.D4N // bit 6, shadows bit in CLC1GLS0bits
7754 #define LC1G1D4T CLC1GLS0bits.LC1G1D4T // bit 7, shadows bit in CLC1GLS0bits
7755 #define D4T CLC1GLS0bits.D4T // bit 7, shadows bit in CLC1GLS0bits
7757 #define LC1G4D1N CLC1GLS3bits.LC1G4D1N // bit 0, shadows bit in CLC1GLS3bits
7758 #define G4D1N CLC1GLS3bits.G4D1N // bit 0, shadows bit in CLC1GLS3bits
7759 #define LC1G4D1T CLC1GLS3bits.LC1G4D1T // bit 1, shadows bit in CLC1GLS3bits
7760 #define G4D1T CLC1GLS3bits.G4D1T // bit 1, shadows bit in CLC1GLS3bits
7761 #define LC1G4D2N CLC1GLS3bits.LC1G4D2N // bit 2, shadows bit in CLC1GLS3bits
7762 #define G4D2N CLC1GLS3bits.G4D2N // bit 2, shadows bit in CLC1GLS3bits
7763 #define LC1G4D2T CLC1GLS3bits.LC1G4D2T // bit 3, shadows bit in CLC1GLS3bits
7764 #define G4D2T CLC1GLS3bits.G4D2T // bit 3, shadows bit in CLC1GLS3bits
7765 #define LC1G4D3N CLC1GLS3bits.LC1G4D3N // bit 4, shadows bit in CLC1GLS3bits
7766 #define G4D3N CLC1GLS3bits.G4D3N // bit 4, shadows bit in CLC1GLS3bits
7767 #define LC1G4D3T CLC1GLS3bits.LC1G4D3T // bit 5, shadows bit in CLC1GLS3bits
7768 #define G4D3T CLC1GLS3bits.G4D3T // bit 5, shadows bit in CLC1GLS3bits
7769 #define LC1G4D4N CLC1GLS3bits.LC1G4D4N // bit 6, shadows bit in CLC1GLS3bits
7770 #define G4D4N CLC1GLS3bits.G4D4N // bit 6, shadows bit in CLC1GLS3bits
7771 #define LC1G4D4T CLC1GLS3bits.LC1G4D4T // bit 7, shadows bit in CLC1GLS3bits
7772 #define G4D4T CLC1GLS3bits.G4D4T // bit 7, shadows bit in CLC1GLS3bits
7774 #define LC1G1POL CLC1POLbits.LC1G1POL // bit 0, shadows bit in CLC1POLbits
7775 #define G1POL CLC1POLbits.G1POL // bit 0, shadows bit in CLC1POLbits
7776 #define LC1G2POL CLC1POLbits.LC1G2POL // bit 1, shadows bit in CLC1POLbits
7777 #define G2POL CLC1POLbits.G2POL // bit 1, shadows bit in CLC1POLbits
7778 #define LC1G3POL CLC1POLbits.LC1G3POL // bit 2, shadows bit in CLC1POLbits
7779 #define G3POL CLC1POLbits.G3POL // bit 2, shadows bit in CLC1POLbits
7780 #define LC1G4POL CLC1POLbits.LC1G4POL // bit 3, shadows bit in CLC1POLbits
7781 #define G4POL CLC1POLbits.G4POL // bit 3, shadows bit in CLC1POLbits
7782 #define LC1POL CLC1POLbits.LC1POL // bit 7, shadows bit in CLC1POLbits
7783 #define POL CLC1POLbits.POL // bit 7, shadows bit in CLC1POLbits
7785 #define LC1D1S0 CLC1SEL0bits.LC1D1S0 // bit 0, shadows bit in CLC1SEL0bits
7786 #define D1S0 CLC1SEL0bits.D1S0 // bit 0, shadows bit in CLC1SEL0bits
7787 #define LC1D1S1 CLC1SEL0bits.LC1D1S1 // bit 1, shadows bit in CLC1SEL0bits
7788 #define D1S1 CLC1SEL0bits.D1S1 // bit 1, shadows bit in CLC1SEL0bits
7789 #define LC1D1S2 CLC1SEL0bits.LC1D1S2 // bit 2, shadows bit in CLC1SEL0bits
7790 #define D1S2 CLC1SEL0bits.D1S2 // bit 2, shadows bit in CLC1SEL0bits
7791 #define LC1D1S3 CLC1SEL0bits.LC1D1S3 // bit 3, shadows bit in CLC1SEL0bits
7792 #define D1S3 CLC1SEL0bits.D1S3 // bit 3, shadows bit in CLC1SEL0bits
7793 #define LC1D1S4 CLC1SEL0bits.LC1D1S4 // bit 4, shadows bit in CLC1SEL0bits
7794 #define D1S4 CLC1SEL0bits.D1S4 // bit 4, shadows bit in CLC1SEL0bits
7796 #define LC1D2S0 CLC1SEL1bits.LC1D2S0 // bit 0, shadows bit in CLC1SEL1bits
7797 #define D2S0 CLC1SEL1bits.D2S0 // bit 0, shadows bit in CLC1SEL1bits
7798 #define LC1D2S1 CLC1SEL1bits.LC1D2S1 // bit 1, shadows bit in CLC1SEL1bits
7799 #define D2S1 CLC1SEL1bits.D2S1 // bit 1, shadows bit in CLC1SEL1bits
7800 #define LC1D2S2 CLC1SEL1bits.LC1D2S2 // bit 2, shadows bit in CLC1SEL1bits
7801 #define D2S2 CLC1SEL1bits.D2S2 // bit 2, shadows bit in CLC1SEL1bits
7802 #define LC1D2S3 CLC1SEL1bits.LC1D2S3 // bit 3, shadows bit in CLC1SEL1bits
7803 #define D2S3 CLC1SEL1bits.D2S3 // bit 3, shadows bit in CLC1SEL1bits
7804 #define LC1D2S4 CLC1SEL1bits.LC1D2S4 // bit 4, shadows bit in CLC1SEL1bits
7805 #define D2S4 CLC1SEL1bits.D2S4 // bit 4, shadows bit in CLC1SEL1bits
7807 #define LC1D3S0 CLC1SEL2bits.LC1D3S0 // bit 0, shadows bit in CLC1SEL2bits
7808 #define D3S0 CLC1SEL2bits.D3S0 // bit 0, shadows bit in CLC1SEL2bits
7809 #define LC1D3S1 CLC1SEL2bits.LC1D3S1 // bit 1, shadows bit in CLC1SEL2bits
7810 #define D3S1 CLC1SEL2bits.D3S1 // bit 1, shadows bit in CLC1SEL2bits
7811 #define LC1D3S2 CLC1SEL2bits.LC1D3S2 // bit 2, shadows bit in CLC1SEL2bits
7812 #define D3S2 CLC1SEL2bits.D3S2 // bit 2, shadows bit in CLC1SEL2bits
7813 #define LC1D3S3 CLC1SEL2bits.LC1D3S3 // bit 3, shadows bit in CLC1SEL2bits
7814 #define D3S3 CLC1SEL2bits.D3S3 // bit 3, shadows bit in CLC1SEL2bits
7815 #define LC1D3S4 CLC1SEL2bits.LC1D3S4 // bit 4, shadows bit in CLC1SEL2bits
7816 #define D3S4 CLC1SEL2bits.D3S4 // bit 4, shadows bit in CLC1SEL2bits
7818 #define LC1D4S0 CLC1SEL3bits.LC1D4S0 // bit 0, shadows bit in CLC1SEL3bits
7819 #define D4S0 CLC1SEL3bits.D4S0 // bit 0, shadows bit in CLC1SEL3bits
7820 #define LC1D4S1 CLC1SEL3bits.LC1D4S1 // bit 1, shadows bit in CLC1SEL3bits
7821 #define D4S1 CLC1SEL3bits.D4S1 // bit 1, shadows bit in CLC1SEL3bits
7822 #define LC1D4S2 CLC1SEL3bits.LC1D4S2 // bit 2, shadows bit in CLC1SEL3bits
7823 #define D4S2 CLC1SEL3bits.D4S2 // bit 2, shadows bit in CLC1SEL3bits
7824 #define LC1D4S3 CLC1SEL3bits.LC1D4S3 // bit 3, shadows bit in CLC1SEL3bits
7825 #define D4S3 CLC1SEL3bits.D4S3 // bit 3, shadows bit in CLC1SEL3bits
7826 #define LC1D4S4 CLC1SEL3bits.LC1D4S4 // bit 4, shadows bit in CLC1SEL3bits
7827 #define D4S4 CLC1SEL3bits.D4S4 // bit 4, shadows bit in CLC1SEL3bits
7829 #define MLC1OUT CLCDATAbits.MLC1OUT // bit 0
7830 #define MLC2OUT CLCDATAbits.MLC2OUT // bit 1
7832 #define CLCIN0PPS0 CLCIN0PPSbits.CLCIN0PPS0 // bit 0
7833 #define CLCIN0PPS1 CLCIN0PPSbits.CLCIN0PPS1 // bit 1
7834 #define CLCIN0PPS2 CLCIN0PPSbits.CLCIN0PPS2 // bit 2
7835 #define CLCIN0PPS3 CLCIN0PPSbits.CLCIN0PPS3 // bit 3
7836 #define CLCIN0PPS4 CLCIN0PPSbits.CLCIN0PPS4 // bit 4
7838 #define CLCIN1PPS0 CLCIN1PPSbits.CLCIN1PPS0 // bit 0
7839 #define CLCIN1PPS1 CLCIN1PPSbits.CLCIN1PPS1 // bit 1
7840 #define CLCIN1PPS2 CLCIN1PPSbits.CLCIN1PPS2 // bit 2
7841 #define CLCIN1PPS3 CLCIN1PPSbits.CLCIN1PPS3 // bit 3
7842 #define CLCIN1PPS4 CLCIN1PPSbits.CLCIN1PPS4 // bit 4
7844 #define CLCIN2PPS0 CLCIN2PPSbits.CLCIN2PPS0 // bit 0
7845 #define CLCIN2PPS1 CLCIN2PPSbits.CLCIN2PPS1 // bit 1
7846 #define CLCIN2PPS2 CLCIN2PPSbits.CLCIN2PPS2 // bit 2
7847 #define CLCIN2PPS3 CLCIN2PPSbits.CLCIN2PPS3 // bit 3
7848 #define CLCIN2PPS4 CLCIN2PPSbits.CLCIN2PPS4 // bit 4
7850 #define CLCIN3PPS0 CLCIN3PPSbits.CLCIN3PPS0 // bit 0
7851 #define CLCIN3PPS1 CLCIN3PPSbits.CLCIN3PPS1 // bit 1
7852 #define CLCIN3PPS2 CLCIN3PPSbits.CLCIN3PPS2 // bit 2
7853 #define CLCIN3PPS3 CLCIN3PPSbits.CLCIN3PPS3 // bit 3
7854 #define CLCIN3PPS4 CLCIN3PPSbits.CLCIN3PPS4 // bit 4
7856 #define CLKRDIV0 CLKRCONbits.CLKRDIV0 // bit 0
7857 #define CLKRDIV1 CLKRCONbits.CLKRDIV1 // bit 1
7858 #define CLKRDIV2 CLKRCONbits.CLKRDIV2 // bit 2
7859 #define CLKRDC0 CLKRCONbits.CLKRDC0 // bit 3
7860 #define CLKRDC1 CLKRCONbits.CLKRDC1 // bit 4
7861 #define CLKREN CLKRCONbits.CLKREN // bit 7
7863 #define C1SYNC CM1CON0bits.C1SYNC // bit 0
7864 #define C1HYS CM1CON0bits.C1HYS // bit 1
7865 #define C1SP CM1CON0bits.C1SP // bit 2
7866 #define C1POL CM1CON0bits.C1POL // bit 4
7867 #define C1OUT CM1CON0bits.C1OUT // bit 6
7868 #define C1ON CM1CON0bits.C1ON // bit 7
7870 #define C1NCH0 CM1CON1bits.C1NCH0 // bit 0
7871 #define C1NCH1 CM1CON1bits.C1NCH1 // bit 1
7872 #define C1NCH2 CM1CON1bits.C1NCH2 // bit 2
7873 #define C1PCH0 CM1CON1bits.C1PCH0 // bit 3
7874 #define C1PCH1 CM1CON1bits.C1PCH1 // bit 4
7875 #define C1PCH2 CM1CON1bits.C1PCH2 // bit 5
7876 #define C1INTN CM1CON1bits.C1INTN // bit 6
7877 #define C1INTP CM1CON1bits.C1INTP // bit 7
7879 #define C2SYNC CM2CON0bits.C2SYNC // bit 0
7880 #define C2HYS CM2CON0bits.C2HYS // bit 1
7881 #define C2SP CM2CON0bits.C2SP // bit 2
7882 #define C2POL CM2CON0bits.C2POL // bit 4
7883 #define C2OUT CM2CON0bits.C2OUT // bit 6
7884 #define C2ON CM2CON0bits.C2ON // bit 7
7886 #define C2NCH0 CM2CON1bits.C2NCH0 // bit 0
7887 #define C2NCH1 CM2CON1bits.C2NCH1 // bit 1
7888 #define C2NCH2 CM2CON1bits.C2NCH2 // bit 2
7889 #define C2PCH0 CM2CON1bits.C2PCH0 // bit 3
7890 #define C2PCH1 CM2CON1bits.C2PCH1 // bit 4
7891 #define C2PCH2 CM2CON1bits.C2PCH2 // bit 5
7892 #define C2INTN CM2CON1bits.C2INTN // bit 6
7893 #define C2INTP CM2CON1bits.C2INTP // bit 7
7895 #define MC1OUT CMOUTbits.MC1OUT // bit 0
7896 #define MC2OUT CMOUTbits.MC2OUT // bit 1
7898 #define DOZE0 CPUDOZEbits.DOZE0 // bit 0
7899 #define DOZE1 CPUDOZEbits.DOZE1 // bit 1
7900 #define DOZE2 CPUDOZEbits.DOZE2 // bit 2
7901 #define DOE CPUDOZEbits.DOE // bit 4
7902 #define ROI CPUDOZEbits.ROI // bit 5
7903 #define DOZEN CPUDOZEbits.DOZEN // bit 6
7904 #define IDLEN CPUDOZEbits.IDLEN // bit 7
7906 #define LSAC0 CWG1AS0bits.LSAC0 // bit 2, shadows bit in CWG1AS0bits
7907 #define CWG1LSAC0 CWG1AS0bits.CWG1LSAC0 // bit 2, shadows bit in CWG1AS0bits
7908 #define LSAC1 CWG1AS0bits.LSAC1 // bit 3, shadows bit in CWG1AS0bits
7909 #define CWG1LSAC1 CWG1AS0bits.CWG1LSAC1 // bit 3, shadows bit in CWG1AS0bits
7910 #define LSBD0 CWG1AS0bits.LSBD0 // bit 4, shadows bit in CWG1AS0bits
7911 #define CWG1LSBD0 CWG1AS0bits.CWG1LSBD0 // bit 4, shadows bit in CWG1AS0bits
7912 #define LSBD1 CWG1AS0bits.LSBD1 // bit 5, shadows bit in CWG1AS0bits
7913 #define CWG1LSBD1 CWG1AS0bits.CWG1LSBD1 // bit 5, shadows bit in CWG1AS0bits
7914 #define REN CWG1AS0bits.REN // bit 6, shadows bit in CWG1AS0bits
7915 #define CWG1REN CWG1AS0bits.CWG1REN // bit 6, shadows bit in CWG1AS0bits
7916 #define SHUTDOWN CWG1AS0bits.SHUTDOWN // bit 7, shadows bit in CWG1AS0bits
7917 #define CWG1SHUTDOWN CWG1AS0bits.CWG1SHUTDOWN // bit 7, shadows bit in CWG1AS0bits
7919 #define AS0E CWG1AS1bits.AS0E // bit 0
7920 #define AS1E CWG1AS1bits.AS1E // bit 1
7921 #define AS2E CWG1AS1bits.AS2E // bit 2
7922 #define AS3E CWG1AS1bits.AS3E // bit 3
7924 #define CS CWG1CLKCONbits.CS // bit 0, shadows bit in CWG1CLKCONbits
7925 #define CWG1CS CWG1CLKCONbits.CWG1CS // bit 0, shadows bit in CWG1CLKCONbits
7927 #define POLA CWG1CON1bits.POLA // bit 0, shadows bit in CWG1CON1bits
7928 #define CWG1POLA CWG1CON1bits.CWG1POLA // bit 0, shadows bit in CWG1CON1bits
7929 #define POLB CWG1CON1bits.POLB // bit 1, shadows bit in CWG1CON1bits
7930 #define CWG1POLB CWG1CON1bits.CWG1POLB // bit 1, shadows bit in CWG1CON1bits
7931 #define POLC CWG1CON1bits.POLC // bit 2, shadows bit in CWG1CON1bits
7932 #define CWG1POLC CWG1CON1bits.CWG1POLC // bit 2, shadows bit in CWG1CON1bits
7933 #define POLD CWG1CON1bits.POLD // bit 3, shadows bit in CWG1CON1bits
7934 #define CWG1POLD CWG1CON1bits.CWG1POLD // bit 3, shadows bit in CWG1CON1bits
7935 #define IN CWG1CON1bits.IN // bit 5, shadows bit in CWG1CON1bits
7936 #define CWG1IN CWG1CON1bits.CWG1IN // bit 5, shadows bit in CWG1CON1bits
7938 #define CWG1DAT0 CWG1DATbits.CWG1DAT0 // bit 0
7939 #define CWG1DAT1 CWG1DATbits.CWG1DAT1 // bit 1
7940 #define CWG1DAT2 CWG1DATbits.CWG1DAT2 // bit 2
7941 #define CWG1DAT3 CWG1DATbits.CWG1DAT3 // bit 3
7943 #define DBF0 CWG1DBFbits.DBF0 // bit 0, shadows bit in CWG1DBFbits
7944 #define CWG1DBF0 CWG1DBFbits.CWG1DBF0 // bit 0, shadows bit in CWG1DBFbits
7945 #define DBF1 CWG1DBFbits.DBF1 // bit 1, shadows bit in CWG1DBFbits
7946 #define CWG1DBF1 CWG1DBFbits.CWG1DBF1 // bit 1, shadows bit in CWG1DBFbits
7947 #define DBF2 CWG1DBFbits.DBF2 // bit 2, shadows bit in CWG1DBFbits
7948 #define CWG1DBF2 CWG1DBFbits.CWG1DBF2 // bit 2, shadows bit in CWG1DBFbits
7949 #define DBF3 CWG1DBFbits.DBF3 // bit 3, shadows bit in CWG1DBFbits
7950 #define CWG1DBF3 CWG1DBFbits.CWG1DBF3 // bit 3, shadows bit in CWG1DBFbits
7951 #define DBF4 CWG1DBFbits.DBF4 // bit 4, shadows bit in CWG1DBFbits
7952 #define CWG1DBF4 CWG1DBFbits.CWG1DBF4 // bit 4, shadows bit in CWG1DBFbits
7953 #define DBF5 CWG1DBFbits.DBF5 // bit 5, shadows bit in CWG1DBFbits
7954 #define CWG1DBF5 CWG1DBFbits.CWG1DBF5 // bit 5, shadows bit in CWG1DBFbits
7956 #define DBR0 CWG1DBRbits.DBR0 // bit 0, shadows bit in CWG1DBRbits
7957 #define CWG1DBR0 CWG1DBRbits.CWG1DBR0 // bit 0, shadows bit in CWG1DBRbits
7958 #define DBR1 CWG1DBRbits.DBR1 // bit 1, shadows bit in CWG1DBRbits
7959 #define CWG1DBR1 CWG1DBRbits.CWG1DBR1 // bit 1, shadows bit in CWG1DBRbits
7960 #define DBR2 CWG1DBRbits.DBR2 // bit 2, shadows bit in CWG1DBRbits
7961 #define CWG1DBR2 CWG1DBRbits.CWG1DBR2 // bit 2, shadows bit in CWG1DBRbits
7962 #define DBR3 CWG1DBRbits.DBR3 // bit 3, shadows bit in CWG1DBRbits
7963 #define CWG1DBR3 CWG1DBRbits.CWG1DBR3 // bit 3, shadows bit in CWG1DBRbits
7964 #define DBR4 CWG1DBRbits.DBR4 // bit 4, shadows bit in CWG1DBRbits
7965 #define CWG1DBR4 CWG1DBRbits.CWG1DBR4 // bit 4, shadows bit in CWG1DBRbits
7966 #define DBR5 CWG1DBRbits.DBR5 // bit 5, shadows bit in CWG1DBRbits
7967 #define CWG1DBR5 CWG1DBRbits.CWG1DBR5 // bit 5, shadows bit in CWG1DBRbits
7969 #define CWG1PPS0 CWG1PPSbits.CWG1PPS0 // bit 0
7970 #define CWG1PPS1 CWG1PPSbits.CWG1PPS1 // bit 1
7971 #define CWG1PPS2 CWG1PPSbits.CWG1PPS2 // bit 2
7972 #define CWG1PPS3 CWG1PPSbits.CWG1PPS3 // bit 3
7973 #define CWG1PPS4 CWG1PPSbits.CWG1PPS4 // bit 4
7975 #define STRA CWG1STRbits.STRA // bit 0, shadows bit in CWG1STRbits
7976 #define CWG1STRA CWG1STRbits.CWG1STRA // bit 0, shadows bit in CWG1STRbits
7977 #define STRB CWG1STRbits.STRB // bit 1, shadows bit in CWG1STRbits
7978 #define CWG1STRB CWG1STRbits.CWG1STRB // bit 1, shadows bit in CWG1STRbits
7979 #define STRC CWG1STRbits.STRC // bit 2, shadows bit in CWG1STRbits
7980 #define CWG1STRC CWG1STRbits.CWG1STRC // bit 2, shadows bit in CWG1STRbits
7981 #define STRD CWG1STRbits.STRD // bit 3, shadows bit in CWG1STRbits
7982 #define CWG1STRD CWG1STRbits.CWG1STRD // bit 3, shadows bit in CWG1STRbits
7983 #define OVRA CWG1STRbits.OVRA // bit 4, shadows bit in CWG1STRbits
7984 #define CWG1OVRA CWG1STRbits.CWG1OVRA // bit 4, shadows bit in CWG1STRbits
7985 #define OVRB CWG1STRbits.OVRB // bit 5, shadows bit in CWG1STRbits
7986 #define CWG1OVRB CWG1STRbits.CWG1OVRB // bit 5, shadows bit in CWG1STRbits
7987 #define OVRC CWG1STRbits.OVRC // bit 6, shadows bit in CWG1STRbits
7988 #define CWG1OVRC CWG1STRbits.CWG1OVRC // bit 6, shadows bit in CWG1STRbits
7989 #define OVRD CWG1STRbits.OVRD // bit 7, shadows bit in CWG1STRbits
7990 #define CWG1OVRD CWG1STRbits.CWG1OVRD // bit 7, shadows bit in CWG1STRbits
7992 #define DAC1NSS DACCON0bits.DAC1NSS // bit 0
7993 #define DAC1PSS0 DACCON0bits.DAC1PSS0 // bit 2
7994 #define DAC1PSS1 DACCON0bits.DAC1PSS1 // bit 3
7995 #define DAC1OE DACCON0bits.DAC1OE // bit 5
7996 #define DAC1EN DACCON0bits.DAC1EN // bit 7
7998 #define DAC1R0 DACCON1bits.DAC1R0 // bit 0
7999 #define DAC1R1 DACCON1bits.DAC1R1 // bit 1
8000 #define DAC1R2 DACCON1bits.DAC1R2 // bit 2
8001 #define DAC1R3 DACCON1bits.DAC1R3 // bit 3
8002 #define DAC1R4 DACCON1bits.DAC1R4 // bit 4
8004 #define ADFVR0 FVRCONbits.ADFVR0 // bit 0
8005 #define ADFVR1 FVRCONbits.ADFVR1 // bit 1
8006 #define CDAFVR0 FVRCONbits.CDAFVR0 // bit 2
8007 #define CDAFVR1 FVRCONbits.CDAFVR1 // bit 3
8008 #define TSRNG FVRCONbits.TSRNG // bit 4
8009 #define TSEN FVRCONbits.TSEN // bit 5
8010 #define FVRRDY FVRCONbits.FVRRDY // bit 6
8011 #define FVREN FVRCONbits.FVREN // bit 7
8013 #define INLVLA0 INLVLAbits.INLVLA0 // bit 0
8014 #define INLVLA1 INLVLAbits.INLVLA1 // bit 1
8015 #define INLVLA2 INLVLAbits.INLVLA2 // bit 2
8016 #define INLVLA3 INLVLAbits.INLVLA3 // bit 3
8017 #define INLVLA4 INLVLAbits.INLVLA4 // bit 4
8018 #define INLVLA5 INLVLAbits.INLVLA5 // bit 5
8020 #define INLVLC0 INLVLCbits.INLVLC0 // bit 0
8021 #define INLVLC1 INLVLCbits.INLVLC1 // bit 1
8022 #define INLVLC2 INLVLCbits.INLVLC2 // bit 2
8023 #define INLVLC3 INLVLCbits.INLVLC3 // bit 3
8024 #define INLVLC4 INLVLCbits.INLVLC4 // bit 4
8025 #define INLVLC5 INLVLCbits.INLVLC5 // bit 5
8027 #define INTEDG INTCONbits.INTEDG // bit 0
8028 #define PEIE INTCONbits.PEIE // bit 6
8029 #define GIE INTCONbits.GIE // bit 7
8031 #define INTPPS0 INTPPSbits.INTPPS0 // bit 0
8032 #define INTPPS1 INTPPSbits.INTPPS1 // bit 1
8033 #define INTPPS2 INTPPSbits.INTPPS2 // bit 2
8034 #define INTPPS3 INTPPSbits.INTPPS3 // bit 3
8035 #define INTPPS4 INTPPSbits.INTPPS4 // bit 4
8037 #define IOCAF0 IOCAFbits.IOCAF0 // bit 0
8038 #define IOCAF1 IOCAFbits.IOCAF1 // bit 1
8039 #define IOCAF2 IOCAFbits.IOCAF2 // bit 2
8040 #define IOCAF3 IOCAFbits.IOCAF3 // bit 3
8041 #define IOCAF4 IOCAFbits.IOCAF4 // bit 4
8042 #define IOCAF5 IOCAFbits.IOCAF5 // bit 5
8044 #define IOCAN0 IOCANbits.IOCAN0 // bit 0
8045 #define IOCAN1 IOCANbits.IOCAN1 // bit 1
8046 #define IOCAN2 IOCANbits.IOCAN2 // bit 2
8047 #define IOCAN3 IOCANbits.IOCAN3 // bit 3
8048 #define IOCAN4 IOCANbits.IOCAN4 // bit 4
8049 #define IOCAN5 IOCANbits.IOCAN5 // bit 5
8051 #define IOCAP0 IOCAPbits.IOCAP0 // bit 0
8052 #define IOCAP1 IOCAPbits.IOCAP1 // bit 1
8053 #define IOCAP2 IOCAPbits.IOCAP2 // bit 2
8054 #define IOCAP3 IOCAPbits.IOCAP3 // bit 3
8055 #define IOCAP4 IOCAPbits.IOCAP4 // bit 4
8056 #define IOCAP5 IOCAPbits.IOCAP5 // bit 5
8058 #define IOCCF0 IOCCFbits.IOCCF0 // bit 0
8059 #define IOCCF1 IOCCFbits.IOCCF1 // bit 1
8060 #define IOCCF2 IOCCFbits.IOCCF2 // bit 2
8061 #define IOCCF3 IOCCFbits.IOCCF3 // bit 3
8062 #define IOCCF4 IOCCFbits.IOCCF4 // bit 4
8063 #define IOCCF5 IOCCFbits.IOCCF5 // bit 5
8065 #define IOCCN0 IOCCNbits.IOCCN0 // bit 0
8066 #define IOCCN1 IOCCNbits.IOCCN1 // bit 1
8067 #define IOCCN2 IOCCNbits.IOCCN2 // bit 2
8068 #define IOCCN3 IOCCNbits.IOCCN3 // bit 3
8069 #define IOCCN4 IOCCNbits.IOCCN4 // bit 4
8070 #define IOCCN5 IOCCNbits.IOCCN5 // bit 5
8072 #define IOCCP0 IOCCPbits.IOCCP0 // bit 0
8073 #define IOCCP1 IOCCPbits.IOCCP1 // bit 1
8074 #define IOCCP2 IOCCPbits.IOCCP2 // bit 2
8075 #define IOCCP3 IOCCPbits.IOCCP3 // bit 3
8076 #define IOCCP4 IOCCPbits.IOCCP4 // bit 4
8077 #define IOCCP5 IOCCPbits.IOCCP5 // bit 5
8079 #define LATA0 LATAbits.LATA0 // bit 0
8080 #define LATA1 LATAbits.LATA1 // bit 1
8081 #define LATA2 LATAbits.LATA2 // bit 2
8082 #define LATA4 LATAbits.LATA4 // bit 4
8083 #define LATA5 LATAbits.LATA5 // bit 5
8085 #define LATC0 LATCbits.LATC0 // bit 0
8086 #define LATC1 LATCbits.LATC1 // bit 1
8087 #define LATC2 LATCbits.LATC2 // bit 2
8088 #define LATC3 LATCbits.LATC3 // bit 3
8089 #define LATC4 LATCbits.LATC4 // bit 4
8090 #define LATC5 LATCbits.LATC5 // bit 5
8092 #define MDCH0 MDCARHbits.MDCH0 // bit 0
8093 #define MDCH1 MDCARHbits.MDCH1 // bit 1
8094 #define MDCH2 MDCARHbits.MDCH2 // bit 2
8095 #define MDCH3 MDCARHbits.MDCH3 // bit 3
8096 #define MDCHSYNC MDCARHbits.MDCHSYNC // bit 5
8097 #define MDCHPOL MDCARHbits.MDCHPOL // bit 6
8099 #define MDCL0 MDCARLbits.MDCL0 // bit 0
8100 #define MDCL1 MDCARLbits.MDCL1 // bit 1
8101 #define MDCL2 MDCARLbits.MDCL2 // bit 2
8102 #define MDCL3 MDCARLbits.MDCL3 // bit 3
8103 #define MDCLSYNC MDCARLbits.MDCLSYNC // bit 5
8104 #define MDCLPOL MDCARLbits.MDCLPOL // bit 6
8106 #define MDCIN1PPS0 MDCIN1PPSbits.MDCIN1PPS0 // bit 0
8107 #define MDCIN1PPS1 MDCIN1PPSbits.MDCIN1PPS1 // bit 1
8108 #define MDCIN1PPS2 MDCIN1PPSbits.MDCIN1PPS2 // bit 2
8109 #define MDCIN1PPS3 MDCIN1PPSbits.MDCIN1PPS3 // bit 3
8110 #define MDCIN1PPS4 MDCIN1PPSbits.MDCIN1PPS4 // bit 4
8112 #define MDCIN2PPS0 MDCIN2PPSbits.MDCIN2PPS0 // bit 0
8113 #define MDCIN2PPS1 MDCIN2PPSbits.MDCIN2PPS1 // bit 1
8114 #define MDCIN2PPS2 MDCIN2PPSbits.MDCIN2PPS2 // bit 2
8115 #define MDCIN2PPS3 MDCIN2PPSbits.MDCIN2PPS3 // bit 3
8116 #define MDCIN2PPS4 MDCIN2PPSbits.MDCIN2PPS4 // bit 4
8118 #define MDBIT MDCONbits.MDBIT // bit 0
8119 #define MDOUT MDCONbits.MDOUT // bit 3
8120 #define MDOPOL MDCONbits.MDOPOL // bit 4
8121 #define MDEN MDCONbits.MDEN // bit 7
8123 #define MDMINPPS0 MDMINPPSbits.MDMINPPS0 // bit 0
8124 #define MDMINPPS1 MDMINPPSbits.MDMINPPS1 // bit 1
8125 #define MDMINPPS2 MDMINPPSbits.MDMINPPS2 // bit 2
8126 #define MDMINPPS3 MDMINPPSbits.MDMINPPS3 // bit 3
8127 #define MDMINPPS4 MDMINPPSbits.MDMINPPS4 // bit 4
8129 #define MDMS0 MDSRCbits.MDMS0 // bit 0
8130 #define MDMS1 MDSRCbits.MDMS1 // bit 1
8131 #define MDMS2 MDSRCbits.MDMS2 // bit 2
8132 #define MDMS3 MDSRCbits.MDMS3 // bit 3
8134 #define N1PFM NCO1CONbits.N1PFM // bit 0
8135 #define N1POL NCO1CONbits.N1POL // bit 4
8136 #define N1OUT NCO1CONbits.N1OUT // bit 5
8137 #define N1EN NCO1CONbits.N1EN // bit 7
8139 #define NVMADR8 NVMADRHbits.NVMADR8 // bit 0
8140 #define NVMADR9 NVMADRHbits.NVMADR9 // bit 1
8141 #define NVMADR10 NVMADRHbits.NVMADR10 // bit 2
8142 #define NVMADR11 NVMADRHbits.NVMADR11 // bit 3
8143 #define NVMADR12 NVMADRHbits.NVMADR12 // bit 4
8144 #define NVMADR13 NVMADRHbits.NVMADR13 // bit 5
8145 #define NVMADR14 NVMADRHbits.NVMADR14 // bit 6
8147 #define NVMADR0 NVMADRLbits.NVMADR0 // bit 0
8148 #define NVMADR1 NVMADRLbits.NVMADR1 // bit 1
8149 #define NVMADR2 NVMADRLbits.NVMADR2 // bit 2
8150 #define NVMADR3 NVMADRLbits.NVMADR3 // bit 3
8151 #define NVMADR4 NVMADRLbits.NVMADR4 // bit 4
8152 #define NVMADR5 NVMADRLbits.NVMADR5 // bit 5
8153 #define NVMADR6 NVMADRLbits.NVMADR6 // bit 6
8154 #define NVMADR7 NVMADRLbits.NVMADR7 // bit 7
8156 #define RD NVMCON1bits.RD // bit 0
8157 #define WR NVMCON1bits.WR // bit 1
8158 #define WREN NVMCON1bits.WREN // bit 2
8159 #define WRERR NVMCON1bits.WRERR // bit 3
8160 #define FREE NVMCON1bits.FREE // bit 4
8161 #define LWLO NVMCON1bits.LWLO // bit 5
8162 #define NVMREGS NVMCON1bits.NVMREGS // bit 6
8164 #define NVMDAT8 NVMDATHbits.NVMDAT8 // bit 0
8165 #define NVMDAT9 NVMDATHbits.NVMDAT9 // bit 1
8166 #define NVMDAT10 NVMDATHbits.NVMDAT10 // bit 2
8167 #define NVMDAT11 NVMDATHbits.NVMDAT11 // bit 3
8168 #define NVMDAT12 NVMDATHbits.NVMDAT12 // bit 4
8169 #define NVMDAT13 NVMDATHbits.NVMDAT13 // bit 5
8171 #define NVMDAT0 NVMDATLbits.NVMDAT0 // bit 0
8172 #define NVMDAT1 NVMDATLbits.NVMDAT1 // bit 1
8173 #define NVMDAT2 NVMDATLbits.NVMDAT2 // bit 2
8174 #define NVMDAT3 NVMDATLbits.NVMDAT3 // bit 3
8175 #define NVMDAT4 NVMDATLbits.NVMDAT4 // bit 4
8176 #define NVMDAT5 NVMDATLbits.NVMDAT5 // bit 5
8177 #define NVMDAT6 NVMDATLbits.NVMDAT6 // bit 6
8178 #define NVMDAT7 NVMDATLbits.NVMDAT7 // bit 7
8180 #define ODCA0 ODCONAbits.ODCA0 // bit 0
8181 #define ODCA1 ODCONAbits.ODCA1 // bit 1
8182 #define ODCA2 ODCONAbits.ODCA2 // bit 2
8183 #define ODCA4 ODCONAbits.ODCA4 // bit 4
8184 #define ODCA5 ODCONAbits.ODCA5 // bit 5
8186 #define ODCC0 ODCONCbits.ODCC0 // bit 0
8187 #define ODCC1 ODCONCbits.ODCC1 // bit 1
8188 #define ODCC2 ODCONCbits.ODCC2 // bit 2
8189 #define ODCC3 ODCONCbits.ODCC3 // bit 3
8190 #define ODCC4 ODCONCbits.ODCC4 // bit 4
8191 #define ODCC5 ODCONCbits.ODCC5 // bit 5
8193 #define NDIV0 OSCCON1bits.NDIV0 // bit 0
8194 #define NDIV1 OSCCON1bits.NDIV1 // bit 1
8195 #define NDIV2 OSCCON1bits.NDIV2 // bit 2
8196 #define NDIV3 OSCCON1bits.NDIV3 // bit 3
8197 #define NOSC0 OSCCON1bits.NOSC0 // bit 4
8198 #define NOSC1 OSCCON1bits.NOSC1 // bit 5
8199 #define NOSC2 OSCCON1bits.NOSC2 // bit 6
8201 #define CDIV0 OSCCON2bits.CDIV0 // bit 0
8202 #define CDIV1 OSCCON2bits.CDIV1 // bit 1
8203 #define CDIV2 OSCCON2bits.CDIV2 // bit 2
8204 #define CDIV3 OSCCON2bits.CDIV3 // bit 3
8205 #define COSC0 OSCCON2bits.COSC0 // bit 4
8206 #define COSC1 OSCCON2bits.COSC1 // bit 5
8207 #define COSC2 OSCCON2bits.COSC2 // bit 6
8209 #define NOSCR OSCCON3bits.NOSCR // bit 3
8210 #define ORDY OSCCON3bits.ORDY // bit 4
8211 #define SOSCBE OSCCON3bits.SOSCBE // bit 5
8212 #define SOSCPWR OSCCON3bits.SOSCPWR // bit 6
8213 #define CSWHOLD OSCCON3bits.CSWHOLD // bit 7
8215 #define ADOEN OSCENbits.ADOEN // bit 2
8216 #define SOSCEN OSCENbits.SOSCEN // bit 3
8217 #define LFOEN OSCENbits.LFOEN // bit 4
8218 #define HFOEN OSCENbits.HFOEN // bit 6
8219 #define EXTOEN OSCENbits.EXTOEN // bit 7
8221 #define HFFRQ0 OSCFRQbits.HFFRQ0 // bit 0
8222 #define HFFRQ1 OSCFRQbits.HFFRQ1 // bit 1
8223 #define HFFRQ2 OSCFRQbits.HFFRQ2 // bit 2
8224 #define HFFRQ3 OSCFRQbits.HFFRQ3 // bit 3
8226 #define PLLR OSCSTAT1bits.PLLR // bit 0
8227 #define ADOR OSCSTAT1bits.ADOR // bit 2
8228 #define SOR OSCSTAT1bits.SOR // bit 3
8229 #define LFOR OSCSTAT1bits.LFOR // bit 4
8230 #define HFOR OSCSTAT1bits.HFOR // bit 6
8231 #define EXTOR OSCSTAT1bits.EXTOR // bit 7
8233 #define HFTUN0 OSCTUNEbits.HFTUN0 // bit 0
8234 #define HFTUN1 OSCTUNEbits.HFTUN1 // bit 1
8235 #define HFTUN2 OSCTUNEbits.HFTUN2 // bit 2
8236 #define HFTUN3 OSCTUNEbits.HFTUN3 // bit 3
8237 #define HFTUN4 OSCTUNEbits.HFTUN4 // bit 4
8238 #define HFTUN5 OSCTUNEbits.HFTUN5 // bit 5
8240 #define NOT_BOR PCON0bits.NOT_BOR // bit 0
8241 #define NOT_POR PCON0bits.NOT_POR // bit 1
8242 #define NOT_RI PCON0bits.NOT_RI // bit 2
8243 #define NOT_RMCLR PCON0bits.NOT_RMCLR // bit 3
8244 #define NOT_RWDT PCON0bits.NOT_RWDT // bit 4
8245 #define STKUNF PCON0bits.STKUNF // bit 6
8246 #define STKOVF PCON0bits.STKOVF // bit 7
8248 #define INTE PIE0bits.INTE // bit 0
8249 #define IOCIE PIE0bits.IOCIE // bit 4
8250 #define TMR0IE PIE0bits.TMR0IE // bit 5
8252 #define TMR1IE PIE1bits.TMR1IE // bit 0
8253 #define TMR2IE PIE1bits.TMR2IE // bit 1
8254 #define BCL1IE PIE1bits.BCL1IE // bit 2
8255 #define SSP1IE PIE1bits.SSP1IE // bit 3
8256 #define TXIE PIE1bits.TXIE // bit 4
8257 #define RCIE PIE1bits.RCIE // bit 5
8258 #define ADIE PIE1bits.ADIE // bit 6
8259 #define TMR1GIE PIE1bits.TMR1GIE // bit 7
8261 #define NCO1IE PIE2bits.NCO1IE // bit 0
8262 #define NVMIE PIE2bits.NVMIE // bit 4
8263 #define C1IE PIE2bits.C1IE // bit 5
8264 #define C2IE PIE2bits.C2IE // bit 6
8266 #define CLC1IE PIE3bits.CLC1IE // bit 0
8267 #define CLC2IE PIE3bits.CLC2IE // bit 1
8268 #define CSWIE PIE3bits.CSWIE // bit 6
8269 #define OSFIE PIE3bits.OSFIE // bit 7
8271 #define CCP1IE PIE4bits.CCP1IE // bit 0
8272 #define CCP2IE PIE4bits.CCP2IE // bit 1
8273 #define CWG1IE PIE4bits.CWG1IE // bit 6
8275 #define INTF PIR0bits.INTF // bit 0
8276 #define IOCIF PIR0bits.IOCIF // bit 4
8277 #define TMR0IF PIR0bits.TMR0IF // bit 5
8279 #define TMR1IF PIR1bits.TMR1IF // bit 0
8280 #define TMR2IF PIR1bits.TMR2IF // bit 1
8281 #define BCL1IF PIR1bits.BCL1IF // bit 2
8282 #define SSP1IF PIR1bits.SSP1IF // bit 3
8283 #define TXIF PIR1bits.TXIF // bit 4
8284 #define RCIF PIR1bits.RCIF // bit 5
8285 #define ADIF PIR1bits.ADIF // bit 6
8286 #define TMR1GIF PIR1bits.TMR1GIF // bit 7
8288 #define NCO1IF PIR2bits.NCO1IF // bit 0
8289 #define NVMIF PIR2bits.NVMIF // bit 4
8290 #define C1IF PIR2bits.C1IF // bit 5
8291 #define C2IF PIR2bits.C2IF // bit 6
8293 #define CLC1IF PIR3bits.CLC1IF // bit 0
8294 #define CLC2IF PIR3bits.CLC2IF // bit 1
8295 #define CSWIF PIR3bits.CSWIF // bit 6
8296 #define OSFIF PIR3bits.OSFIF // bit 7
8298 #define CCP1IF PIR4bits.CCP1IF // bit 0
8299 #define CCP2IF PIR4bits.CCP2IF // bit 1
8300 #define CWG1IF PIR4bits.CWG1IF // bit 6
8302 #define IOCMD PMD0bits.IOCMD // bit 0
8303 #define CLKRMD PMD0bits.CLKRMD // bit 1
8304 #define NVMMD PMD0bits.NVMMD // bit 2
8305 #define FVRMD PMD0bits.FVRMD // bit 6
8306 #define SYSCMD PMD0bits.SYSCMD // bit 7
8308 #define TMR0MD PMD1bits.TMR0MD // bit 0
8309 #define TMR1MD PMD1bits.TMR1MD // bit 1
8310 #define TMR2MD PMD1bits.TMR2MD // bit 2
8311 #define NCOMD PMD1bits.NCOMD // bit 7
8313 #define CMP1MD PMD2bits.CMP1MD // bit 1
8314 #define CMP2MD PMD2bits.CMP2MD // bit 2
8315 #define ADCMD PMD2bits.ADCMD // bit 5
8316 #define DACMD PMD2bits.DACMD // bit 6
8318 #define CCP1MD PMD3bits.CCP1MD // bit 0
8319 #define CCP2MD PMD3bits.CCP2MD // bit 1
8320 #define PWM5MD PMD3bits.PWM5MD // bit 4
8321 #define PWM6MD PMD3bits.PWM6MD // bit 5
8322 #define CWG1MD PMD3bits.CWG1MD // bit 6
8324 #define MSSP1MD PMD4bits.MSSP1MD // bit 1
8325 #define UART1MD PMD4bits.UART1MD // bit 5
8327 #define DSMMD PMD5bits.DSMMD // bit 0
8328 #define CLC1MD PMD5bits.CLC1MD // bit 1
8329 #define CLC2MD PMD5bits.CLC2MD // bit 2
8331 #define RA0 PORTAbits.RA0 // bit 0
8332 #define RA1 PORTAbits.RA1 // bit 1
8333 #define RA2 PORTAbits.RA2 // bit 2
8334 #define RA3 PORTAbits.RA3 // bit 3
8335 #define RA4 PORTAbits.RA4 // bit 4
8336 #define RA5 PORTAbits.RA5 // bit 5
8338 #define RC0 PORTCbits.RC0 // bit 0
8339 #define RC1 PORTCbits.RC1 // bit 1
8340 #define RC2 PORTCbits.RC2 // bit 2
8341 #define RC3 PORTCbits.RC3 // bit 3
8342 #define RC4 PORTCbits.RC4 // bit 4
8343 #define RC5 PORTCbits.RC5 // bit 5
8345 #define PPSLOCKED PPSLOCKbits.PPSLOCKED // bit 0
8347 #define PWM5POL PWM5CONbits.PWM5POL // bit 4
8348 #define PWM5OUT PWM5CONbits.PWM5OUT // bit 5
8349 #define PWM5EN PWM5CONbits.PWM5EN // bit 7
8351 #define PWM5DCH0 PWM5DCHbits.PWM5DCH0 // bit 0
8352 #define PWM5DCH1 PWM5DCHbits.PWM5DCH1 // bit 1
8353 #define PWM5DCH2 PWM5DCHbits.PWM5DCH2 // bit 2
8354 #define PWM5DCH3 PWM5DCHbits.PWM5DCH3 // bit 3
8355 #define PWM5DCH4 PWM5DCHbits.PWM5DCH4 // bit 4
8356 #define PWM5DCH5 PWM5DCHbits.PWM5DCH5 // bit 5
8357 #define PWM5DCH6 PWM5DCHbits.PWM5DCH6 // bit 6
8358 #define PWM5DCH7 PWM5DCHbits.PWM5DCH7 // bit 7
8360 #define PWM5DCL0 PWM5DCLbits.PWM5DCL0 // bit 6
8361 #define PWM5DCL1 PWM5DCLbits.PWM5DCL1 // bit 7
8363 #define PWM6POL PWM6CONbits.PWM6POL // bit 4
8364 #define PWM6OUT PWM6CONbits.PWM6OUT // bit 5
8365 #define PWM6EN PWM6CONbits.PWM6EN // bit 7
8367 #define PWM6DCH0 PWM6DCHbits.PWM6DCH0 // bit 0
8368 #define PWM6DCH1 PWM6DCHbits.PWM6DCH1 // bit 1
8369 #define PWM6DCH2 PWM6DCHbits.PWM6DCH2 // bit 2
8370 #define PWM6DCH3 PWM6DCHbits.PWM6DCH3 // bit 3
8371 #define PWM6DCH4 PWM6DCHbits.PWM6DCH4 // bit 4
8372 #define PWM6DCH5 PWM6DCHbits.PWM6DCH5 // bit 5
8373 #define PWM6DCH6 PWM6DCHbits.PWM6DCH6 // bit 6
8374 #define PWM6DCH7 PWM6DCHbits.PWM6DCH7 // bit 7
8376 #define PWM6DCL0 PWM6DCLbits.PWM6DCL0 // bit 6
8377 #define PWM6DCL1 PWM6DCLbits.PWM6DCL1 // bit 7
8379 #define RA0PPS0 RA0PPSbits.RA0PPS0 // bit 0
8380 #define RA0PPS1 RA0PPSbits.RA0PPS1 // bit 1
8381 #define RA0PPS2 RA0PPSbits.RA0PPS2 // bit 2
8382 #define RA0PPS3 RA0PPSbits.RA0PPS3 // bit 3
8383 #define RA0PPS4 RA0PPSbits.RA0PPS4 // bit 4
8385 #define RA1PPS0 RA1PPSbits.RA1PPS0 // bit 0
8386 #define RA1PPS1 RA1PPSbits.RA1PPS1 // bit 1
8387 #define RA1PPS2 RA1PPSbits.RA1PPS2 // bit 2
8388 #define RA1PPS3 RA1PPSbits.RA1PPS3 // bit 3
8389 #define RA1PPS4 RA1PPSbits.RA1PPS4 // bit 4
8391 #define RA2PPS0 RA2PPSbits.RA2PPS0 // bit 0
8392 #define RA2PPS1 RA2PPSbits.RA2PPS1 // bit 1
8393 #define RA2PPS2 RA2PPSbits.RA2PPS2 // bit 2
8394 #define RA2PPS3 RA2PPSbits.RA2PPS3 // bit 3
8395 #define RA2PPS4 RA2PPSbits.RA2PPS4 // bit 4
8397 #define RA4PPS0 RA4PPSbits.RA4PPS0 // bit 0
8398 #define RA4PPS1 RA4PPSbits.RA4PPS1 // bit 1
8399 #define RA4PPS2 RA4PPSbits.RA4PPS2 // bit 2
8400 #define RA4PPS3 RA4PPSbits.RA4PPS3 // bit 3
8401 #define RA4PPS4 RA4PPSbits.RA4PPS4 // bit 4
8403 #define RA5PPS0 RA5PPSbits.RA5PPS0 // bit 0
8404 #define RA5PPS1 RA5PPSbits.RA5PPS1 // bit 1
8405 #define RA5PPS2 RA5PPSbits.RA5PPS2 // bit 2
8406 #define RA5PPS3 RA5PPSbits.RA5PPS3 // bit 3
8407 #define RA5PPS4 RA5PPSbits.RA5PPS4 // bit 4
8409 #define RC0PPS0 RC0PPSbits.RC0PPS0 // bit 0
8410 #define RC0PPS1 RC0PPSbits.RC0PPS1 // bit 1
8411 #define RC0PPS2 RC0PPSbits.RC0PPS2 // bit 2
8412 #define RC0PPS3 RC0PPSbits.RC0PPS3 // bit 3
8413 #define RC0PPS4 RC0PPSbits.RC0PPS4 // bit 4
8415 #define RC1PPS0 RC1PPSbits.RC1PPS0 // bit 0
8416 #define RC1PPS1 RC1PPSbits.RC1PPS1 // bit 1
8417 #define RC1PPS2 RC1PPSbits.RC1PPS2 // bit 2
8418 #define RC1PPS3 RC1PPSbits.RC1PPS3 // bit 3
8419 #define RC1PPS4 RC1PPSbits.RC1PPS4 // bit 4
8421 #define RX9D RC1STAbits.RX9D // bit 0
8422 #define OERR RC1STAbits.OERR // bit 1
8423 #define FERR RC1STAbits.FERR // bit 2
8424 #define ADDEN RC1STAbits.ADDEN // bit 3
8425 #define CREN RC1STAbits.CREN // bit 4
8426 #define SREN RC1STAbits.SREN // bit 5
8427 #define RX9 RC1STAbits.RX9 // bit 6
8428 #define SPEN RC1STAbits.SPEN // bit 7
8430 #define RC2PPS0 RC2PPSbits.RC2PPS0 // bit 0
8431 #define RC2PPS1 RC2PPSbits.RC2PPS1 // bit 1
8432 #define RC2PPS2 RC2PPSbits.RC2PPS2 // bit 2
8433 #define RC2PPS3 RC2PPSbits.RC2PPS3 // bit 3
8434 #define RC2PPS4 RC2PPSbits.RC2PPS4 // bit 4
8436 #define RC3PPS0 RC3PPSbits.RC3PPS0 // bit 0
8437 #define RC3PPS1 RC3PPSbits.RC3PPS1 // bit 1
8438 #define RC3PPS2 RC3PPSbits.RC3PPS2 // bit 2
8439 #define RC3PPS3 RC3PPSbits.RC3PPS3 // bit 3
8440 #define RC3PPS4 RC3PPSbits.RC3PPS4 // bit 4
8442 #define RC4PPS0 RC4PPSbits.RC4PPS0 // bit 0
8443 #define RC4PPS1 RC4PPSbits.RC4PPS1 // bit 1
8444 #define RC4PPS2 RC4PPSbits.RC4PPS2 // bit 2
8445 #define RC4PPS3 RC4PPSbits.RC4PPS3 // bit 3
8446 #define RC4PPS4 RC4PPSbits.RC4PPS4 // bit 4
8448 #define RC5PPS0 RC5PPSbits.RC5PPS0 // bit 0
8449 #define RC5PPS1 RC5PPSbits.RC5PPS1 // bit 1
8450 #define RC5PPS2 RC5PPSbits.RC5PPS2 // bit 2
8451 #define RC5PPS3 RC5PPSbits.RC5PPS3 // bit 3
8452 #define RC5PPS4 RC5PPSbits.RC5PPS4 // bit 4
8454 #define RXPPS0 RXPPSbits.RXPPS0 // bit 0
8455 #define RXPPS1 RXPPSbits.RXPPS1 // bit 1
8456 #define RXPPS2 RXPPSbits.RXPPS2 // bit 2
8457 #define RXPPS3 RXPPSbits.RXPPS3 // bit 3
8458 #define RXPPS4 RXPPSbits.RXPPS4 // bit 4
8460 #define SLRA0 SLRCONAbits.SLRA0 // bit 0
8461 #define SLRA1 SLRCONAbits.SLRA1 // bit 1
8462 #define SLRA2 SLRCONAbits.SLRA2 // bit 2
8463 #define SLRA4 SLRCONAbits.SLRA4 // bit 4
8464 #define SLRA5 SLRCONAbits.SLRA5 // bit 5
8466 #define SLRC0 SLRCONCbits.SLRC0 // bit 0
8467 #define SLRC1 SLRCONCbits.SLRC1 // bit 1
8468 #define SLRC2 SLRCONCbits.SLRC2 // bit 2
8469 #define SLRC3 SLRCONCbits.SLRC3 // bit 3
8470 #define SLRC4 SLRCONCbits.SLRC4 // bit 4
8471 #define SLRC5 SLRCONCbits.SLRC5 // bit 5
8473 #define SSP1ADD0 SSP1ADDbits.SSP1ADD0 // bit 0, shadows bit in SSP1ADDbits
8474 #define ADD0 SSP1ADDbits.ADD0 // bit 0, shadows bit in SSP1ADDbits
8475 #define SSP1ADD1 SSP1ADDbits.SSP1ADD1 // bit 1, shadows bit in SSP1ADDbits
8476 #define ADD1 SSP1ADDbits.ADD1 // bit 1, shadows bit in SSP1ADDbits
8477 #define SSP1ADD2 SSP1ADDbits.SSP1ADD2 // bit 2, shadows bit in SSP1ADDbits
8478 #define ADD2 SSP1ADDbits.ADD2 // bit 2, shadows bit in SSP1ADDbits
8479 #define SSP1ADD3 SSP1ADDbits.SSP1ADD3 // bit 3, shadows bit in SSP1ADDbits
8480 #define ADD3 SSP1ADDbits.ADD3 // bit 3, shadows bit in SSP1ADDbits
8481 #define SSP1ADD4 SSP1ADDbits.SSP1ADD4 // bit 4, shadows bit in SSP1ADDbits
8482 #define ADD4 SSP1ADDbits.ADD4 // bit 4, shadows bit in SSP1ADDbits
8483 #define SSP1ADD5 SSP1ADDbits.SSP1ADD5 // bit 5, shadows bit in SSP1ADDbits
8484 #define ADD5 SSP1ADDbits.ADD5 // bit 5, shadows bit in SSP1ADDbits
8485 #define SSP1ADD6 SSP1ADDbits.SSP1ADD6 // bit 6, shadows bit in SSP1ADDbits
8486 #define ADD6 SSP1ADDbits.ADD6 // bit 6, shadows bit in SSP1ADDbits
8487 #define SSP1ADD7 SSP1ADDbits.SSP1ADD7 // bit 7, shadows bit in SSP1ADDbits
8488 #define ADD7 SSP1ADDbits.ADD7 // bit 7, shadows bit in SSP1ADDbits
8490 #define SSP1BUF0 SSP1BUFbits.SSP1BUF0 // bit 0, shadows bit in SSP1BUFbits
8491 #define BUF0 SSP1BUFbits.BUF0 // bit 0, shadows bit in SSP1BUFbits
8492 #define SSP1BUF1 SSP1BUFbits.SSP1BUF1 // bit 1, shadows bit in SSP1BUFbits
8493 #define BUF1 SSP1BUFbits.BUF1 // bit 1, shadows bit in SSP1BUFbits
8494 #define SSP1BUF2 SSP1BUFbits.SSP1BUF2 // bit 2, shadows bit in SSP1BUFbits
8495 #define BUF2 SSP1BUFbits.BUF2 // bit 2, shadows bit in SSP1BUFbits
8496 #define SSP1BUF3 SSP1BUFbits.SSP1BUF3 // bit 3, shadows bit in SSP1BUFbits
8497 #define BUF3 SSP1BUFbits.BUF3 // bit 3, shadows bit in SSP1BUFbits
8498 #define SSP1BUF4 SSP1BUFbits.SSP1BUF4 // bit 4, shadows bit in SSP1BUFbits
8499 #define BUF4 SSP1BUFbits.BUF4 // bit 4, shadows bit in SSP1BUFbits
8500 #define SSP1BUF5 SSP1BUFbits.SSP1BUF5 // bit 5, shadows bit in SSP1BUFbits
8501 #define BUF5 SSP1BUFbits.BUF5 // bit 5, shadows bit in SSP1BUFbits
8502 #define SSP1BUF6 SSP1BUFbits.SSP1BUF6 // bit 6, shadows bit in SSP1BUFbits
8503 #define BUF6 SSP1BUFbits.BUF6 // bit 6, shadows bit in SSP1BUFbits
8504 #define SSP1BUF7 SSP1BUFbits.SSP1BUF7 // bit 7, shadows bit in SSP1BUFbits
8505 #define BUF7 SSP1BUFbits.BUF7 // bit 7, shadows bit in SSP1BUFbits
8507 #define SSP1CLKPPS0 SSP1CLKPPSbits.SSP1CLKPPS0 // bit 0
8508 #define SSP1CLKPPS1 SSP1CLKPPSbits.SSP1CLKPPS1 // bit 1
8509 #define SSP1CLKPPS2 SSP1CLKPPSbits.SSP1CLKPPS2 // bit 2
8510 #define SSP1CLKPPS3 SSP1CLKPPSbits.SSP1CLKPPS3 // bit 3
8511 #define SSP1CLKPPS4 SSP1CLKPPSbits.SSP1CLKPPS4 // bit 4
8513 #define SSPM0 SSP1CONbits.SSPM0 // bit 0
8514 #define SSPM1 SSP1CONbits.SSPM1 // bit 1
8515 #define SSPM2 SSP1CONbits.SSPM2 // bit 2
8516 #define SSPM3 SSP1CONbits.SSPM3 // bit 3
8517 #define CKP SSP1CONbits.CKP // bit 4
8518 #define SSPEN SSP1CONbits.SSPEN // bit 5
8519 #define SSPOV SSP1CONbits.SSPOV // bit 6
8520 #define WCOL SSP1CONbits.WCOL // bit 7
8522 #define SEN SSP1CON2bits.SEN // bit 0
8523 #define RSEN SSP1CON2bits.RSEN // bit 1
8524 #define PEN SSP1CON2bits.PEN // bit 2
8525 #define RCEN SSP1CON2bits.RCEN // bit 3
8526 #define ACKEN SSP1CON2bits.ACKEN // bit 4
8527 #define ACKDT SSP1CON2bits.ACKDT // bit 5
8528 #define ACKSTAT SSP1CON2bits.ACKSTAT // bit 6
8529 #define GCEN SSP1CON2bits.GCEN // bit 7
8531 #define DHEN SSP1CON3bits.DHEN // bit 0
8532 #define AHEN SSP1CON3bits.AHEN // bit 1
8533 #define SBCDE SSP1CON3bits.SBCDE // bit 2
8534 #define SDAHT SSP1CON3bits.SDAHT // bit 3
8535 #define BOEN SSP1CON3bits.BOEN // bit 4
8536 #define SCIE SSP1CON3bits.SCIE // bit 5
8537 #define PCIE SSP1CON3bits.PCIE // bit 6
8538 #define ACKTIM SSP1CON3bits.ACKTIM // bit 7
8540 #define SSP1DATPPS0 SSP1DATPPSbits.SSP1DATPPS0 // bit 0
8541 #define SSP1DATPPS1 SSP1DATPPSbits.SSP1DATPPS1 // bit 1
8542 #define SSP1DATPPS2 SSP1DATPPSbits.SSP1DATPPS2 // bit 2
8543 #define SSP1DATPPS3 SSP1DATPPSbits.SSP1DATPPS3 // bit 3
8544 #define SSP1DATPPS4 SSP1DATPPSbits.SSP1DATPPS4 // bit 4
8546 #define SSP1MSK0 SSP1MSKbits.SSP1MSK0 // bit 0, shadows bit in SSP1MSKbits
8547 #define MSK0 SSP1MSKbits.MSK0 // bit 0, shadows bit in SSP1MSKbits
8548 #define SSP1MSK1 SSP1MSKbits.SSP1MSK1 // bit 1, shadows bit in SSP1MSKbits
8549 #define MSK1 SSP1MSKbits.MSK1 // bit 1, shadows bit in SSP1MSKbits
8550 #define SSP1MSK2 SSP1MSKbits.SSP1MSK2 // bit 2, shadows bit in SSP1MSKbits
8551 #define MSK2 SSP1MSKbits.MSK2 // bit 2, shadows bit in SSP1MSKbits
8552 #define SSP1MSK3 SSP1MSKbits.SSP1MSK3 // bit 3, shadows bit in SSP1MSKbits
8553 #define MSK3 SSP1MSKbits.MSK3 // bit 3, shadows bit in SSP1MSKbits
8554 #define SSP1MSK4 SSP1MSKbits.SSP1MSK4 // bit 4, shadows bit in SSP1MSKbits
8555 #define MSK4 SSP1MSKbits.MSK4 // bit 4, shadows bit in SSP1MSKbits
8556 #define SSP1MSK5 SSP1MSKbits.SSP1MSK5 // bit 5, shadows bit in SSP1MSKbits
8557 #define MSK5 SSP1MSKbits.MSK5 // bit 5, shadows bit in SSP1MSKbits
8558 #define SSP1MSK6 SSP1MSKbits.SSP1MSK6 // bit 6, shadows bit in SSP1MSKbits
8559 #define MSK6 SSP1MSKbits.MSK6 // bit 6, shadows bit in SSP1MSKbits
8560 #define SSP1MSK7 SSP1MSKbits.SSP1MSK7 // bit 7, shadows bit in SSP1MSKbits
8561 #define MSK7 SSP1MSKbits.MSK7 // bit 7, shadows bit in SSP1MSKbits
8563 #define SSP1SSPPS0 SSP1SSPPSbits.SSP1SSPPS0 // bit 0
8564 #define SSP1SSPPS1 SSP1SSPPSbits.SSP1SSPPS1 // bit 1
8565 #define SSP1SSPPS2 SSP1SSPPSbits.SSP1SSPPS2 // bit 2
8566 #define SSP1SSPPS3 SSP1SSPPSbits.SSP1SSPPS3 // bit 3
8567 #define SSP1SSPPS4 SSP1SSPPSbits.SSP1SSPPS4 // bit 4
8569 #define BF SSP1STATbits.BF // bit 0
8570 #define UA SSP1STATbits.UA // bit 1
8571 #define R_NOT_W SSP1STATbits.R_NOT_W // bit 2
8572 #define S SSP1STATbits.S // bit 3
8573 #define P SSP1STATbits.P // bit 4
8574 #define D_NOT_A SSP1STATbits.D_NOT_A // bit 5
8575 #define CKE SSP1STATbits.CKE // bit 6
8576 #define SMP SSP1STATbits.SMP // bit 7
8578 #define C STATUSbits.C // bit 0
8579 #define DC STATUSbits.DC // bit 1
8580 #define Z STATUSbits.Z // bit 2
8581 #define NOT_PD STATUSbits.NOT_PD // bit 3
8582 #define NOT_TO STATUSbits.NOT_TO // bit 4
8584 #define C_SHAD STATUS_SHADbits.C_SHAD // bit 0
8585 #define DC_SHAD STATUS_SHADbits.DC_SHAD // bit 1
8586 #define Z_SHAD STATUS_SHADbits.Z_SHAD // bit 2
8588 #define T0CKIPPS0 T0CKIPPSbits.T0CKIPPS0 // bit 0
8589 #define T0CKIPPS1 T0CKIPPSbits.T0CKIPPS1 // bit 1
8590 #define T0CKIPPS2 T0CKIPPSbits.T0CKIPPS2 // bit 2
8591 #define T0CKIPPS3 T0CKIPPSbits.T0CKIPPS3 // bit 3
8592 #define T0CKIPPS4 T0CKIPPSbits.T0CKIPPS4 // bit 4
8594 #define T0OUTPS0 T0CON0bits.T0OUTPS0 // bit 0
8595 #define T0OUTPS1 T0CON0bits.T0OUTPS1 // bit 1
8596 #define T0OUTPS2 T0CON0bits.T0OUTPS2 // bit 2
8597 #define T0OUTPS3 T0CON0bits.T0OUTPS3 // bit 3
8598 #define T016BIT T0CON0bits.T016BIT // bit 4
8599 #define T0OUT T0CON0bits.T0OUT // bit 5
8600 #define T0EN T0CON0bits.T0EN // bit 7
8602 #define T0CKPS0 T0CON1bits.T0CKPS0 // bit 0
8603 #define T0CKPS1 T0CON1bits.T0CKPS1 // bit 1
8604 #define T0CKPS2 T0CON1bits.T0CKPS2 // bit 2
8605 #define T0CKPS3 T0CON1bits.T0CKPS3 // bit 3
8606 #define T0ASYNC T0CON1bits.T0ASYNC // bit 4
8607 #define T0CS0 T0CON1bits.T0CS0 // bit 5
8608 #define T0CS1 T0CON1bits.T0CS1 // bit 6
8609 #define T0CS2 T0CON1bits.T0CS2 // bit 7
8611 #define T1CKIPPS0 T1CKIPPSbits.T1CKIPPS0 // bit 0
8612 #define T1CKIPPS1 T1CKIPPSbits.T1CKIPPS1 // bit 1
8613 #define T1CKIPPS2 T1CKIPPSbits.T1CKIPPS2 // bit 2
8614 #define T1CKIPPS3 T1CKIPPSbits.T1CKIPPS3 // bit 3
8615 #define T1CKIPPS4 T1CKIPPSbits.T1CKIPPS4 // bit 4
8617 #define TMR1ON T1CONbits.TMR1ON // bit 0
8618 #define T1SYNC T1CONbits.T1SYNC // bit 2
8619 #define T1SOSC T1CONbits.T1SOSC // bit 3
8620 #define T1CKPS0 T1CONbits.T1CKPS0 // bit 4
8621 #define T1CKPS1 T1CONbits.T1CKPS1 // bit 5
8622 #define TMR1CS0 T1CONbits.TMR1CS0 // bit 6
8623 #define TMR1CS1 T1CONbits.TMR1CS1 // bit 7
8625 #define T1GSS0 T1GCONbits.T1GSS0 // bit 0
8626 #define T1GSS1 T1GCONbits.T1GSS1 // bit 1
8627 #define T1GVAL T1GCONbits.T1GVAL // bit 2
8628 #define T1GGO_NOT_DONE T1GCONbits.T1GGO_NOT_DONE // bit 3
8629 #define T1GSPM T1GCONbits.T1GSPM // bit 4
8630 #define T1GTM T1GCONbits.T1GTM // bit 5
8631 #define T1GPOL T1GCONbits.T1GPOL // bit 6
8632 #define TMR1GE T1GCONbits.TMR1GE // bit 7
8634 #define T1GPPS0 T1GPPSbits.T1GPPS0 // bit 0
8635 #define T1GPPS1 T1GPPSbits.T1GPPS1 // bit 1
8636 #define T1GPPS2 T1GPPSbits.T1GPPS2 // bit 2
8637 #define T1GPPS3 T1GPPSbits.T1GPPS3 // bit 3
8638 #define T1GPPS4 T1GPPSbits.T1GPPS4 // bit 4
8640 #define T2CKPS0 T2CONbits.T2CKPS0 // bit 0
8641 #define T2CKPS1 T2CONbits.T2CKPS1 // bit 1
8642 #define TMR2ON T2CONbits.TMR2ON // bit 2
8643 #define T2OUTPS0 T2CONbits.T2OUTPS0 // bit 3
8644 #define T2OUTPS1 T2CONbits.T2OUTPS1 // bit 4
8645 #define T2OUTPS2 T2CONbits.T2OUTPS2 // bit 5
8646 #define T2OUTPS3 T2CONbits.T2OUTPS3 // bit 6
8648 #define TMR08 TMR0Hbits.TMR08 // bit 0
8649 #define TMR09 TMR0Hbits.TMR09 // bit 1
8650 #define TMR010 TMR0Hbits.TMR010 // bit 2
8651 #define TMR011 TMR0Hbits.TMR011 // bit 3
8652 #define TMR012 TMR0Hbits.TMR012 // bit 4
8653 #define TMR013 TMR0Hbits.TMR013 // bit 5
8654 #define TMR014 TMR0Hbits.TMR014 // bit 6
8655 #define TMR015 TMR0Hbits.TMR015 // bit 7
8657 #define TMR00 TMR0Lbits.TMR00 // bit 0
8658 #define TMR01 TMR0Lbits.TMR01 // bit 1
8659 #define TMR02 TMR0Lbits.TMR02 // bit 2
8660 #define TMR03 TMR0Lbits.TMR03 // bit 3
8661 #define TMR04 TMR0Lbits.TMR04 // bit 4
8662 #define TMR05 TMR0Lbits.TMR05 // bit 5
8663 #define TMR06 TMR0Lbits.TMR06 // bit 6
8664 #define TMR07 TMR0Lbits.TMR07 // bit 7
8666 #define TRISA0 TRISAbits.TRISA0 // bit 0
8667 #define TRISA1 TRISAbits.TRISA1 // bit 1
8668 #define TRISA2 TRISAbits.TRISA2 // bit 2
8669 #define TRISA4 TRISAbits.TRISA4 // bit 4
8670 #define TRISA5 TRISAbits.TRISA5 // bit 5
8672 #define TRISC0 TRISCbits.TRISC0 // bit 0
8673 #define TRISC1 TRISCbits.TRISC1 // bit 1
8674 #define TRISC2 TRISCbits.TRISC2 // bit 2
8675 #define TRISC3 TRISCbits.TRISC3 // bit 3
8676 #define TRISC4 TRISCbits.TRISC4 // bit 4
8677 #define TRISC5 TRISCbits.TRISC5 // bit 5
8679 #define TX9D TX1STAbits.TX9D // bit 0
8680 #define TRMT TX1STAbits.TRMT // bit 1
8681 #define BRGH TX1STAbits.BRGH // bit 2
8682 #define SENDB TX1STAbits.SENDB // bit 3
8683 #define SYNC TX1STAbits.SYNC // bit 4
8684 #define TXEN TX1STAbits.TXEN // bit 5
8685 #define TX9 TX1STAbits.TX9 // bit 6
8686 #define CSRC TX1STAbits.CSRC // bit 7
8688 #define TXPPS0 TXPPSbits.TXPPS0 // bit 0
8689 #define TXPPS1 TXPPSbits.TXPPS1 // bit 1
8690 #define TXPPS2 TXPPSbits.TXPPS2 // bit 2
8691 #define TXPPS3 TXPPSbits.TXPPS3 // bit 3
8692 #define TXPPS4 TXPPSbits.TXPPS4 // bit 4
8694 #define SWDTEN WDTCONbits.SWDTEN // bit 0
8695 #define WDTPS0 WDTCONbits.WDTPS0 // bit 1
8696 #define WDTPS1 WDTCONbits.WDTPS1 // bit 2
8697 #define WDTPS2 WDTCONbits.WDTPS2 // bit 3
8698 #define WDTPS3 WDTCONbits.WDTPS3 // bit 4
8699 #define WDTPS4 WDTCONbits.WDTPS4 // bit 5
8701 #define WPUA0 WPUAbits.WPUA0 // bit 0
8702 #define WPUA1 WPUAbits.WPUA1 // bit 1
8703 #define WPUA2 WPUAbits.WPUA2 // bit 2
8704 #define WPUA3 WPUAbits.WPUA3 // bit 3
8705 #define WPUA4 WPUAbits.WPUA4 // bit 4
8706 #define WPUA5 WPUAbits.WPUA5 // bit 5
8708 #define WPUC0 WPUCbits.WPUC0 // bit 0
8709 #define WPUC1 WPUCbits.WPUC1 // bit 1
8710 #define WPUC2 WPUCbits.WPUC2 // bit 2
8711 #define WPUC3 WPUCbits.WPUC3 // bit 3
8712 #define WPUC4 WPUCbits.WPUC4 // bit 4
8713 #define WPUC5 WPUCbits.WPUC5 // bit 5
8715 #endif // #ifndef NO_BIT_DEFINES
8717 #endif // #ifndef __PIC16LF18323_H__