Initial import of onewire-to-usb bridge
[onewire] / build / XC8_12F1822 / production / onewire.pre
1
2 # 1 "onewire.c"
3
4 # 44 "/opt/microchip/xc8/v1.12/include/pic12f1822.h"
5 extern volatile unsigned char INDF0 @ 0x000;
6
7 asm("INDF0 equ 00h");
8
9
10 typedef union {
11 struct {
12 unsigned INDF0 :8;
13 };
14 } INDF0bits_t;
15 extern volatile INDF0bits_t INDF0bits @ 0x000;
16
17 # 63
18 extern volatile unsigned char INDF1 @ 0x001;
19
20 asm("INDF1 equ 01h");
21
22
23 typedef union {
24 struct {
25 unsigned INDF1 :8;
26 };
27 } INDF1bits_t;
28 extern volatile INDF1bits_t INDF1bits @ 0x001;
29
30 # 82
31 extern volatile unsigned char PCL @ 0x002;
32
33 asm("PCL equ 02h");
34
35
36 typedef union {
37 struct {
38 unsigned PCL :8;
39 };
40 } PCLbits_t;
41 extern volatile PCLbits_t PCLbits @ 0x002;
42
43 # 101
44 extern volatile unsigned char STATUS @ 0x003;
45
46 asm("STATUS equ 03h");
47
48
49 typedef union {
50 struct {
51 unsigned C :1;
52 unsigned DC :1;
53 unsigned Z :1;
54 unsigned nPD :1;
55 unsigned nTO :1;
56 };
57 struct {
58 unsigned CARRY :1;
59 };
60 struct {
61 unsigned :2;
62 unsigned ZERO :1;
63 };
64 } STATUSbits_t;
65 extern volatile STATUSbits_t STATUSbits @ 0x003;
66
67 # 161
68 extern volatile unsigned short FSR0 @ 0x004;
69
70
71 extern volatile unsigned char FSR0L @ 0x004;
72
73 asm("FSR0L equ 04h");
74
75
76 typedef union {
77 struct {
78 unsigned FSR0L :8;
79 };
80 } FSR0Lbits_t;
81 extern volatile FSR0Lbits_t FSR0Lbits @ 0x004;
82
83 # 183
84 extern volatile unsigned char FSR0H @ 0x005;
85
86 asm("FSR0H equ 05h");
87
88
89 typedef union {
90 struct {
91 unsigned FSR0H :8;
92 };
93 } FSR0Hbits_t;
94 extern volatile FSR0Hbits_t FSR0Hbits @ 0x005;
95
96 # 202
97 extern volatile unsigned short FSR1 @ 0x006;
98
99
100 extern volatile unsigned char FSR1L @ 0x006;
101
102 asm("FSR1L equ 06h");
103
104
105 typedef union {
106 struct {
107 unsigned FSR1L :8;
108 };
109 } FSR1Lbits_t;
110 extern volatile FSR1Lbits_t FSR1Lbits @ 0x006;
111
112 # 224
113 extern volatile unsigned char FSR1H @ 0x007;
114
115 asm("FSR1H equ 07h");
116
117
118 typedef union {
119 struct {
120 unsigned FSR1H :8;
121 };
122 } FSR1Hbits_t;
123 extern volatile FSR1Hbits_t FSR1Hbits @ 0x007;
124
125 # 243
126 extern volatile unsigned char BSR @ 0x008;
127
128 asm("BSR equ 08h");
129
130
131 typedef union {
132 struct {
133 unsigned BSR0 :1;
134 unsigned BSR1 :1;
135 unsigned BSR2 :1;
136 unsigned BSR3 :1;
137 unsigned BSR4 :1;
138 };
139 struct {
140 unsigned BSR :5;
141 };
142 } BSRbits_t;
143 extern volatile BSRbits_t BSRbits @ 0x008;
144
145 # 294
146 extern volatile unsigned char WREG @ 0x009;
147
148 asm("WREG equ 09h");
149
150
151 typedef union {
152 struct {
153 unsigned WREG0 :8;
154 };
155 } WREGbits_t;
156 extern volatile WREGbits_t WREGbits @ 0x009;
157
158 # 313
159 extern volatile unsigned char PCLATH @ 0x00A;
160
161 asm("PCLATH equ 0Ah");
162
163
164 typedef union {
165 struct {
166 unsigned PCLATH :7;
167 };
168 } PCLATHbits_t;
169 extern volatile PCLATHbits_t PCLATHbits @ 0x00A;
170
171 # 332
172 extern volatile unsigned char INTCON @ 0x00B;
173
174 asm("INTCON equ 0Bh");
175
176
177 typedef union {
178 struct {
179 unsigned IOCIF :1;
180 unsigned INTF :1;
181 unsigned TMR0IF :1;
182 unsigned IOCIE :1;
183 unsigned INTE :1;
184 unsigned TMR0IE :1;
185 unsigned PEIE :1;
186 unsigned GIE :1;
187 };
188 struct {
189 unsigned :2;
190 unsigned T0IF :1;
191 unsigned :2;
192 unsigned T0IE :1;
193 };
194 } INTCONbits_t;
195 extern volatile INTCONbits_t INTCONbits @ 0x00B;
196
197 # 409
198 extern volatile unsigned char PORTA @ 0x00C;
199
200 asm("PORTA equ 0Ch");
201
202
203 typedef union {
204 struct {
205 unsigned RA0 :1;
206 unsigned RA1 :1;
207 unsigned RA2 :1;
208 unsigned RA3 :1;
209 unsigned RA4 :1;
210 unsigned RA5 :1;
211 };
212 struct {
213 unsigned AN0 :1;
214 unsigned AN1 :1;
215 unsigned AN2 :1;
216 unsigned :1;
217 unsigned AN3 :1;
218 };
219 struct {
220 unsigned CPS0 :1;
221 unsigned CPS1 :1;
222 unsigned CPS2 :1;
223 unsigned :1;
224 unsigned CPS3 :1;
225 };
226 struct {
227 unsigned C1INP :1;
228 unsigned C1IN0N :1;
229 unsigned C1OUT :1;
230 unsigned :1;
231 unsigned C1IN1N :1;
232 };
233 struct {
234 unsigned DACOUT :1;
235 unsigned SRI :1;
236 unsigned SRQ :1;
237 unsigned :2;
238 unsigned SRNQ :1;
239 };
240 struct {
241 unsigned :1;
242 unsigned SCK :1;
243 unsigned T0CKI :1;
244 unsigned :1;
245 unsigned T1OSO :1;
246 unsigned T1CKI :1;
247 };
248 struct {
249 unsigned :1;
250 unsigned SCL :1;
251 unsigned SDA :1;
252 unsigned nMCLR :1;
253 unsigned CLKR :1;
254 unsigned T1OSI :1;
255 };
256 struct {
257 unsigned MDOUT :1;
258 unsigned MDMIN :1;
259 unsigned MDCIN1 :1;
260 unsigned :1;
261 unsigned MDCIN2 :1;
262 };
263 struct {
264 unsigned :2;
265 unsigned SDI :1;
266 unsigned :1;
267 unsigned OSC2 :1;
268 unsigned OSC1 :1;
269 };
270 struct {
271 unsigned :2;
272 unsigned FLT0 :1;
273 unsigned :1;
274 unsigned CLKOUT :1;
275 unsigned CLKIN :1;
276 };
277 } PORTAbits_t;
278 extern volatile PORTAbits_t PORTAbits @ 0x00C;
279
280 # 698
281 extern volatile unsigned char PIR1 @ 0x011;
282
283 asm("PIR1 equ 011h");
284
285
286 typedef union {
287 struct {
288 unsigned TMR1IF :1;
289 unsigned TMR2IF :1;
290 unsigned CCP1IF :1;
291 unsigned SSP1IF :1;
292 unsigned TXIF :1;
293 unsigned RCIF :1;
294 unsigned ADIF :1;
295 unsigned TMR1GIF :1;
296 };
297 } PIR1bits_t;
298 extern volatile PIR1bits_t PIR1bits @ 0x011;
299
300 # 759
301 extern volatile unsigned char PIR2 @ 0x012;
302
303 asm("PIR2 equ 012h");
304
305
306 typedef union {
307 struct {
308 unsigned :3;
309 unsigned BCL1IF :1;
310 unsigned EEIF :1;
311 unsigned C1IF :1;
312 unsigned :1;
313 unsigned OSFIF :1;
314 };
315 } PIR2bits_t;
316 extern volatile PIR2bits_t PIR2bits @ 0x012;
317
318 # 798
319 extern volatile unsigned char TMR0 @ 0x015;
320
321 asm("TMR0 equ 015h");
322
323
324 typedef union {
325 struct {
326 unsigned TMR0 :8;
327 };
328 } TMR0bits_t;
329 extern volatile TMR0bits_t TMR0bits @ 0x015;
330
331 # 817
332 extern volatile unsigned short TMR1 @ 0x016;
333
334 asm("TMR1 equ 016h");
335
336
337
338 extern volatile unsigned char TMR1L @ 0x016;
339
340 asm("TMR1L equ 016h");
341
342
343 typedef union {
344 struct {
345 unsigned TMR1L :8;
346 };
347 } TMR1Lbits_t;
348 extern volatile TMR1Lbits_t TMR1Lbits @ 0x016;
349
350 # 842
351 extern volatile unsigned char TMR1H @ 0x017;
352
353 asm("TMR1H equ 017h");
354
355
356 typedef union {
357 struct {
358 unsigned TMR1H :8;
359 };
360 } TMR1Hbits_t;
361 extern volatile TMR1Hbits_t TMR1Hbits @ 0x017;
362
363 # 861
364 extern volatile unsigned char T1CON @ 0x018;
365
366 asm("T1CON equ 018h");
367
368
369 typedef union {
370 struct {
371 unsigned TMR1ON :1;
372 unsigned :1;
373 unsigned nT1SYNC :1;
374 unsigned T1OSCEN :1;
375 unsigned T1CKPS0 :1;
376 unsigned T1CKPS1 :1;
377 unsigned TMR1CS0 :1;
378 unsigned TMR1CS1 :1;
379 };
380 struct {
381 unsigned :4;
382 unsigned T1CKPS :2;
383 unsigned TMR1CS :2;
384 };
385 } T1CONbits_t;
386 extern volatile T1CONbits_t T1CONbits @ 0x018;
387
388 # 932
389 extern volatile unsigned char T1GCON @ 0x019;
390
391 asm("T1GCON equ 019h");
392
393
394 typedef union {
395 struct {
396 unsigned T1GSS0 :1;
397 unsigned T1GSS1 :1;
398 unsigned T1GVAL :1;
399 unsigned T1GGO_nDONE :1;
400 unsigned T1GSPM :1;
401 unsigned T1GTM :1;
402 unsigned T1GPOL :1;
403 unsigned TMR1GE :1;
404 };
405 struct {
406 unsigned T1GSS :2;
407 unsigned :1;
408 unsigned T1GGO :1;
409 };
410 } T1GCONbits_t;
411 extern volatile T1GCONbits_t T1GCONbits @ 0x019;
412
413 # 1008
414 extern volatile unsigned char TMR2 @ 0x01A;
415
416 asm("TMR2 equ 01Ah");
417
418
419 typedef union {
420 struct {
421 unsigned TMR2 :8;
422 };
423 } TMR2bits_t;
424 extern volatile TMR2bits_t TMR2bits @ 0x01A;
425
426 # 1027
427 extern volatile unsigned char PR2 @ 0x01B;
428
429 asm("PR2 equ 01Bh");
430
431
432 typedef union {
433 struct {
434 unsigned PR2 :8;
435 };
436 } PR2bits_t;
437 extern volatile PR2bits_t PR2bits @ 0x01B;
438
439 # 1046
440 extern volatile unsigned char T2CON @ 0x01C;
441
442 asm("T2CON equ 01Ch");
443
444
445 typedef union {
446 struct {
447 unsigned T2CKPS0 :1;
448 unsigned T2CKPS1 :1;
449 unsigned TMR2ON :1;
450 unsigned T2OUTPS0 :1;
451 unsigned T2OUTPS1 :1;
452 unsigned T2OUTPS2 :1;
453 unsigned T2OUTPS3 :1;
454 };
455 struct {
456 unsigned T2CKPS :2;
457 unsigned :1;
458 unsigned T2OUTPS :4;
459 };
460 } T2CONbits_t;
461 extern volatile T2CONbits_t T2CONbits @ 0x01C;
462
463 # 1116
464 extern volatile unsigned char CPSCON0 @ 0x01E;
465
466 asm("CPSCON0 equ 01Eh");
467
468
469 typedef union {
470 struct {
471 unsigned T0XCS :1;
472 unsigned CPSOUT :1;
473 unsigned CPSRNG0 :1;
474 unsigned CPSRNG1 :1;
475 unsigned :2;
476 unsigned CPSRM :1;
477 unsigned CPSON :1;
478 };
479 struct {
480 unsigned :2;
481 unsigned CPSRNG :2;
482 };
483 } CPSCON0bits_t;
484 extern volatile CPSCON0bits_t CPSCON0bits @ 0x01E;
485
486 # 1175
487 extern volatile unsigned char CPSCON1 @ 0x01F;
488
489 asm("CPSCON1 equ 01Fh");
490
491
492 typedef union {
493 struct {
494 unsigned CPSCH0 :1;
495 unsigned CPSCH1 :1;
496 };
497 struct {
498 unsigned CPSCH :2;
499 };
500 } CPSCON1bits_t;
501 extern volatile CPSCON1bits_t CPSCON1bits @ 0x01F;
502
503 # 1208
504 extern volatile unsigned char TRISA @ 0x08C;
505
506 asm("TRISA equ 08Ch");
507
508
509 typedef union {
510 struct {
511 unsigned TRISA0 :1;
512 unsigned TRISA1 :1;
513 unsigned TRISA2 :1;
514 unsigned TRISA3 :1;
515 unsigned TRISA4 :1;
516 unsigned TRISA5 :1;
517 };
518 } TRISAbits_t;
519 extern volatile TRISAbits_t TRISAbits @ 0x08C;
520
521 # 1257
522 extern volatile unsigned char PIE1 @ 0x091;
523
524 asm("PIE1 equ 091h");
525
526
527 typedef union {
528 struct {
529 unsigned TMR1IE :1;
530 unsigned TMR2IE :1;
531 unsigned CCP1IE :1;
532 unsigned SSP1IE :1;
533 unsigned TXIE :1;
534 unsigned RCIE :1;
535 unsigned ADIE :1;
536 unsigned TMR1GIE :1;
537 };
538 } PIE1bits_t;
539 extern volatile PIE1bits_t PIE1bits @ 0x091;
540
541 # 1318
542 extern volatile unsigned char PIE2 @ 0x092;
543
544 asm("PIE2 equ 092h");
545
546
547 typedef union {
548 struct {
549 unsigned :3;
550 unsigned BCL1IE :1;
551 unsigned EEIE :1;
552 unsigned C1IE :1;
553 unsigned :1;
554 unsigned OSFIE :1;
555 };
556 } PIE2bits_t;
557 extern volatile PIE2bits_t PIE2bits @ 0x092;
558
559 # 1357
560 extern volatile unsigned char OPTION_REG @ 0x095;
561
562 asm("OPTION_REG equ 095h");
563
564
565 typedef union {
566 struct {
567 unsigned PS0 :1;
568 unsigned PS1 :1;
569 unsigned PS2 :1;
570 unsigned PSA :1;
571 unsigned TMR0SE :1;
572 unsigned TMR0CS :1;
573 unsigned INTEDG :1;
574 unsigned nWPUEN :1;
575 };
576 struct {
577 unsigned PS :3;
578 unsigned :1;
579 unsigned T0SE :1;
580 unsigned T0CS :1;
581 };
582 } OPTION_REGbits_t;
583 extern volatile OPTION_REGbits_t OPTION_REGbits @ 0x095;
584
585 # 1439
586 extern volatile unsigned char PCON @ 0x096;
587
588 asm("PCON equ 096h");
589
590
591 typedef union {
592 struct {
593 unsigned nBOR :1;
594 unsigned nPOR :1;
595 unsigned nRI :1;
596 unsigned nRMCLR :1;
597 unsigned :2;
598 unsigned STKUNF :1;
599 unsigned STKOVF :1;
600 };
601 } PCONbits_t;
602 extern volatile PCONbits_t PCONbits @ 0x096;
603
604 # 1489
605 extern volatile unsigned char WDTCON @ 0x097;
606
607 asm("WDTCON equ 097h");
608
609
610 typedef union {
611 struct {
612 unsigned SWDTEN :1;
613 unsigned WDTPS0 :1;
614 unsigned WDTPS1 :1;
615 unsigned WDTPS2 :1;
616 unsigned WDTPS3 :1;
617 unsigned WDTPS4 :1;
618 };
619 struct {
620 unsigned :1;
621 unsigned WDTPS :5;
622 };
623 } WDTCONbits_t;
624 extern volatile WDTCONbits_t WDTCONbits @ 0x097;
625
626 # 1547
627 extern volatile unsigned char OSCTUNE @ 0x098;
628
629 asm("OSCTUNE equ 098h");
630
631
632 typedef union {
633 struct {
634 unsigned TUN0 :1;
635 unsigned TUN1 :1;
636 unsigned TUN2 :1;
637 unsigned TUN3 :1;
638 unsigned TUN4 :1;
639 unsigned TUN5 :1;
640 };
641 struct {
642 unsigned TUN :6;
643 };
644 } OSCTUNEbits_t;
645 extern volatile OSCTUNEbits_t OSCTUNEbits @ 0x098;
646
647 # 1604
648 extern volatile unsigned char OSCCON @ 0x099;
649
650 asm("OSCCON equ 099h");
651
652
653 typedef union {
654 struct {
655 unsigned SCS0 :1;
656 unsigned SCS1 :1;
657 unsigned :1;
658 unsigned IRCF0 :1;
659 unsigned IRCF1 :1;
660 unsigned IRCF2 :1;
661 unsigned IRCF3 :1;
662 unsigned SPLLEN :1;
663 };
664 struct {
665 unsigned SCS :2;
666 unsigned :1;
667 unsigned IRCF :4;
668 };
669 } OSCCONbits_t;
670 extern volatile OSCCONbits_t OSCCONbits @ 0x099;
671
672 # 1675
673 extern volatile unsigned char OSCSTAT @ 0x09A;
674
675 asm("OSCSTAT equ 09Ah");
676
677
678 typedef union {
679 struct {
680 unsigned HFIOFS :1;
681 unsigned LFIOFR :1;
682 unsigned MFIOFR :1;
683 unsigned HFIOFL :1;
684 unsigned HFIOFR :1;
685 unsigned OSTS :1;
686 unsigned PLLR :1;
687 unsigned T1OSCR :1;
688 };
689 } OSCSTATbits_t;
690 extern volatile OSCSTATbits_t OSCSTATbits @ 0x09A;
691
692 # 1736
693 extern volatile unsigned short ADRES @ 0x09B;
694
695 asm("ADRES equ 09Bh");
696
697
698
699 extern volatile unsigned char ADRESL @ 0x09B;
700
701 asm("ADRESL equ 09Bh");
702
703
704 typedef union {
705 struct {
706 unsigned ADRESL :8;
707 };
708 } ADRESLbits_t;
709 extern volatile ADRESLbits_t ADRESLbits @ 0x09B;
710
711 # 1761
712 extern volatile unsigned char ADRESH @ 0x09C;
713
714 asm("ADRESH equ 09Ch");
715
716
717 typedef union {
718 struct {
719 unsigned ADRESH :8;
720 };
721 } ADRESHbits_t;
722 extern volatile ADRESHbits_t ADRESHbits @ 0x09C;
723
724 # 1780
725 extern volatile unsigned char ADCON0 @ 0x09D;
726
727 asm("ADCON0 equ 09Dh");
728
729
730 typedef union {
731 struct {
732 unsigned ADON :1;
733 unsigned GO_nDONE :1;
734 unsigned CHS0 :1;
735 unsigned CHS1 :1;
736 unsigned CHS2 :1;
737 unsigned CHS3 :1;
738 unsigned CHS4 :1;
739 };
740 struct {
741 unsigned :1;
742 unsigned ADGO :1;
743 unsigned CHS :5;
744 };
745 struct {
746 unsigned :1;
747 unsigned GO :1;
748 };
749 struct {
750 unsigned :1;
751 unsigned nDONE :1;
752 };
753 } ADCON0bits_t;
754 extern volatile ADCON0bits_t ADCON0bits @ 0x09D;
755
756 # 1868
757 extern volatile unsigned char ADCON1 @ 0x09E;
758
759 asm("ADCON1 equ 09Eh");
760
761
762 typedef union {
763 struct {
764 unsigned ADPREF0 :1;
765 unsigned ADPREF1 :1;
766 unsigned :2;
767 unsigned ADCS0 :1;
768 unsigned ADCS1 :1;
769 unsigned ADCS2 :1;
770 unsigned ADFM :1;
771 };
772 struct {
773 unsigned ADPREF :2;
774 unsigned :2;
775 unsigned ADCS :3;
776 };
777 } ADCON1bits_t;
778 extern volatile ADCON1bits_t ADCON1bits @ 0x09E;
779
780 # 1933
781 extern volatile unsigned char LATA @ 0x10C;
782
783 asm("LATA equ 010Ch");
784
785
786 typedef union {
787 struct {
788 unsigned LATA0 :1;
789 unsigned LATA1 :1;
790 unsigned LATA2 :1;
791 unsigned :1;
792 unsigned LATA4 :1;
793 unsigned LATA5 :1;
794 };
795 } LATAbits_t;
796 extern volatile LATAbits_t LATAbits @ 0x10C;
797
798 # 1977
799 extern volatile unsigned char CM1CON0 @ 0x111;
800
801 asm("CM1CON0 equ 0111h");
802
803
804 typedef union {
805 struct {
806 unsigned C1SYNC :1;
807 unsigned C1HYS :1;
808 unsigned C1SP :1;
809 unsigned :1;
810 unsigned C1POL :1;
811 unsigned C1OE :1;
812 unsigned C1OUT :1;
813 unsigned C1ON :1;
814 };
815 } CM1CON0bits_t;
816 extern volatile CM1CON0bits_t CM1CON0bits @ 0x111;
817
818 # 2033
819 extern volatile unsigned char CM1CON1 @ 0x112;
820
821 asm("CM1CON1 equ 0112h");
822
823
824 typedef union {
825 struct {
826 unsigned C1NCH0 :1;
827 unsigned :3;
828 unsigned C1PCH0 :1;
829 unsigned C1PCH1 :1;
830 unsigned C1INTN :1;
831 unsigned C1INTP :1;
832 };
833 struct {
834 unsigned :4;
835 unsigned C1PCH :2;
836 };
837 } CM1CON1bits_t;
838 extern volatile CM1CON1bits_t CM1CON1bits @ 0x112;
839
840 # 2086
841 extern volatile unsigned char CMOUT @ 0x115;
842
843 asm("CMOUT equ 0115h");
844
845
846 typedef union {
847 struct {
848 unsigned MC1OUT :1;
849 };
850 } CMOUTbits_t;
851 extern volatile CMOUTbits_t CMOUTbits @ 0x115;
852
853 # 2105
854 extern volatile unsigned char BORCON @ 0x116;
855
856 asm("BORCON equ 0116h");
857
858
859 typedef union {
860 struct {
861 unsigned BORRDY :1;
862 unsigned :6;
863 unsigned SBOREN :1;
864 };
865 } BORCONbits_t;
866 extern volatile BORCONbits_t BORCONbits @ 0x116;
867
868 # 2131
869 extern volatile unsigned char FVRCON @ 0x117;
870
871 asm("FVRCON equ 0117h");
872
873
874 typedef union {
875 struct {
876 unsigned ADFVR0 :1;
877 unsigned ADFVR1 :1;
878 unsigned CDAFVR0 :1;
879 unsigned CDAFVR1 :1;
880 unsigned TSRNG :1;
881 unsigned TSEN :1;
882 unsigned FVRRDY :1;
883 unsigned FVREN :1;
884 };
885 struct {
886 unsigned ADFVR :2;
887 unsigned CDAFVR :2;
888 };
889 } FVRCONbits_t;
890 extern volatile FVRCONbits_t FVRCONbits @ 0x117;
891
892 # 2206
893 extern volatile unsigned char DACCON0 @ 0x118;
894
895 asm("DACCON0 equ 0118h");
896
897
898 typedef union {
899 struct {
900 unsigned :2;
901 unsigned DACPSS0 :1;
902 unsigned DACPSS1 :1;
903 unsigned :1;
904 unsigned DACOE :1;
905 unsigned DACLPS :1;
906 unsigned DACEN :1;
907 };
908 struct {
909 unsigned :2;
910 unsigned DACPSS :2;
911 };
912 } DACCON0bits_t;
913 extern volatile DACCON0bits_t DACCON0bits @ 0x118;
914
915 # 2260
916 extern volatile unsigned char DACCON1 @ 0x119;
917
918 asm("DACCON1 equ 0119h");
919
920
921 typedef union {
922 struct {
923 unsigned DACR0 :1;
924 unsigned DACR1 :1;
925 unsigned DACR2 :1;
926 unsigned DACR3 :1;
927 unsigned DACR4 :1;
928 };
929 struct {
930 unsigned DACR :5;
931 };
932 } DACCON1bits_t;
933 extern volatile DACCON1bits_t DACCON1bits @ 0x119;
934
935 # 2311
936 extern volatile unsigned char SRCON0 @ 0x11A;
937
938 asm("SRCON0 equ 011Ah");
939
940
941 typedef union {
942 struct {
943 unsigned SRPR :1;
944 unsigned SRPS :1;
945 unsigned SRNQEN :1;
946 unsigned SRQEN :1;
947 unsigned SRCLK0 :1;
948 unsigned SRCLK1 :1;
949 unsigned SRCLK2 :1;
950 unsigned SRLEN :1;
951 };
952 struct {
953 unsigned :4;
954 unsigned SRCLK :3;
955 };
956 } SRCON0bits_t;
957 extern volatile SRCON0bits_t SRCON0bits @ 0x11A;
958
959 # 2381
960 extern volatile unsigned char SRCON1 @ 0x11B;
961
962 asm("SRCON1 equ 011Bh");
963
964
965 typedef union {
966 struct {
967 unsigned SRRC1E :1;
968 unsigned :1;
969 unsigned SRRCKE :1;
970 unsigned SRRPE :1;
971 unsigned SRSC1E :1;
972 unsigned :1;
973 unsigned SRSCKE :1;
974 unsigned SRSPE :1;
975 };
976 } SRCON1bits_t;
977 extern volatile SRCON1bits_t SRCON1bits @ 0x11B;
978
979 # 2432
980 extern volatile unsigned char APFCON @ 0x11D;
981
982 asm("APFCON equ 011Dh");
983
984
985 extern volatile unsigned char APFCON0 @ 0x11D;
986
987 asm("APFCON0 equ 011Dh");
988
989
990 typedef union {
991 struct {
992 unsigned CCP1SEL :1;
993 unsigned P1BSEL :1;
994 unsigned TXCKSEL :1;
995 unsigned T1GSEL :1;
996 unsigned :1;
997 unsigned SSSEL :1;
998 unsigned SDOSEL :1;
999 unsigned RXDTSEL :1;
1000 };
1001 struct {
1002 unsigned :5;
1003 unsigned SS1SEL :1;
1004 unsigned SDO1SEL :1;
1005 };
1006 } APFCONbits_t;
1007 extern volatile APFCONbits_t APFCONbits @ 0x11D;
1008
1009 # 2507
1010 typedef union {
1011 struct {
1012 unsigned CCP1SEL :1;
1013 unsigned P1BSEL :1;
1014 unsigned TXCKSEL :1;
1015 unsigned T1GSEL :1;
1016 unsigned :1;
1017 unsigned SSSEL :1;
1018 unsigned SDOSEL :1;
1019 unsigned RXDTSEL :1;
1020 };
1021 struct {
1022 unsigned :5;
1023 unsigned SS1SEL :1;
1024 unsigned SDO1SEL :1;
1025 };
1026 } APFCON0bits_t;
1027 extern volatile APFCON0bits_t APFCON0bits @ 0x11D;
1028
1029 # 2573
1030 extern volatile unsigned char ANSELA @ 0x18C;
1031
1032 asm("ANSELA equ 018Ch");
1033
1034
1035 typedef union {
1036 struct {
1037 unsigned ANSA0 :1;
1038 unsigned ANSA1 :1;
1039 unsigned ANSA2 :1;
1040 unsigned :1;
1041 unsigned ANSA4 :1;
1042 };
1043 struct {
1044 unsigned ANSELA :5;
1045 };
1046 } ANSELAbits_t;
1047 extern volatile ANSELAbits_t ANSELAbits @ 0x18C;
1048
1049 # 2619
1050 extern volatile unsigned short EEADR @ 0x191;
1051
1052 asm("EEADR equ 0191h");
1053
1054
1055
1056 extern volatile unsigned char EEADRL @ 0x191;
1057
1058 asm("EEADRL equ 0191h");
1059
1060
1061 typedef union {
1062 struct {
1063 unsigned EEADRL :8;
1064 };
1065 } EEADRLbits_t;
1066 extern volatile EEADRLbits_t EEADRLbits @ 0x191;
1067
1068 # 2644
1069 extern volatile unsigned char EEADRH @ 0x192;
1070
1071 asm("EEADRH equ 0192h");
1072
1073
1074 typedef union {
1075 struct {
1076 unsigned EEADRH :7;
1077 };
1078 } EEADRHbits_t;
1079 extern volatile EEADRHbits_t EEADRHbits @ 0x192;
1080
1081 # 2663
1082 extern volatile unsigned short EEDAT @ 0x193;
1083
1084 asm("EEDAT equ 0193h");
1085
1086
1087
1088 extern volatile unsigned char EEDATL @ 0x193;
1089
1090 asm("EEDATL equ 0193h");
1091
1092
1093 extern volatile unsigned char EEDATA @ 0x193;
1094
1095 asm("EEDATA equ 0193h");
1096
1097
1098 typedef union {
1099 struct {
1100 unsigned EEDATL :8;
1101 };
1102 } EEDATLbits_t;
1103 extern volatile EEDATLbits_t EEDATLbits @ 0x193;
1104
1105 # 2692
1106 typedef union {
1107 struct {
1108 unsigned EEDATL :8;
1109 };
1110 } EEDATAbits_t;
1111 extern volatile EEDATAbits_t EEDATAbits @ 0x193;
1112
1113 # 2706
1114 extern volatile unsigned char EEDATH @ 0x194;
1115
1116 asm("EEDATH equ 0194h");
1117
1118
1119 typedef union {
1120 struct {
1121 unsigned EEDATH :6;
1122 };
1123 } EEDATHbits_t;
1124 extern volatile EEDATHbits_t EEDATHbits @ 0x194;
1125
1126 # 2725
1127 extern volatile unsigned char EECON1 @ 0x195;
1128
1129 asm("EECON1 equ 0195h");
1130
1131
1132 typedef union {
1133 struct {
1134 unsigned RD :1;
1135 unsigned WR :1;
1136 unsigned WREN :1;
1137 unsigned WRERR :1;
1138 unsigned FREE :1;
1139 unsigned LWLO :1;
1140 unsigned CFGS :1;
1141 unsigned EEPGD :1;
1142 };
1143 } EECON1bits_t;
1144 extern volatile EECON1bits_t EECON1bits @ 0x195;
1145
1146 # 2786
1147 extern volatile unsigned char EECON2 @ 0x196;
1148
1149 asm("EECON2 equ 0196h");
1150
1151
1152 typedef union {
1153 struct {
1154 unsigned EECON2 :8;
1155 };
1156 } EECON2bits_t;
1157 extern volatile EECON2bits_t EECON2bits @ 0x196;
1158
1159 # 2805
1160 extern volatile unsigned char RCREG @ 0x199;
1161
1162 asm("RCREG equ 0199h");
1163
1164
1165 typedef union {
1166 struct {
1167 unsigned RCREG :8;
1168 };
1169 } RCREGbits_t;
1170 extern volatile RCREGbits_t RCREGbits @ 0x199;
1171
1172 # 2824
1173 extern volatile unsigned char TXREG @ 0x19A;
1174
1175 asm("TXREG equ 019Ah");
1176
1177
1178 typedef union {
1179 struct {
1180 unsigned TXREG :8;
1181 };
1182 } TXREGbits_t;
1183 extern volatile TXREGbits_t TXREGbits @ 0x19A;
1184
1185 # 2843
1186 extern volatile unsigned char SPBRGL @ 0x19B;
1187
1188 asm("SPBRGL equ 019Bh");
1189
1190
1191 extern volatile unsigned char SPBRG @ 0x19B;
1192
1193 asm("SPBRG equ 019Bh");
1194
1195
1196 typedef union {
1197 struct {
1198 unsigned SPBRGL :8;
1199 };
1200 } SPBRGLbits_t;
1201 extern volatile SPBRGLbits_t SPBRGLbits @ 0x19B;
1202
1203 # 2866
1204 typedef union {
1205 struct {
1206 unsigned SPBRGL :8;
1207 };
1208 } SPBRGbits_t;
1209 extern volatile SPBRGbits_t SPBRGbits @ 0x19B;
1210
1211 # 2880
1212 extern volatile unsigned char SPBRGH @ 0x19C;
1213
1214 asm("SPBRGH equ 019Ch");
1215
1216
1217 typedef union {
1218 struct {
1219 unsigned SPBRGH :8;
1220 };
1221 } SPBRGHbits_t;
1222 extern volatile SPBRGHbits_t SPBRGHbits @ 0x19C;
1223
1224 # 2899
1225 extern volatile unsigned char RCSTA @ 0x19D;
1226
1227 asm("RCSTA equ 019Dh");
1228
1229
1230 typedef union {
1231 struct {
1232 unsigned RX9D :1;
1233 unsigned OERR :1;
1234 unsigned FERR :1;
1235 unsigned ADDEN :1;
1236 unsigned CREN :1;
1237 unsigned SREN :1;
1238 unsigned RX9 :1;
1239 unsigned SPEN :1;
1240 };
1241 } RCSTAbits_t;
1242 extern volatile RCSTAbits_t RCSTAbits @ 0x19D;
1243
1244 # 2960
1245 extern volatile unsigned char TXSTA @ 0x19E;
1246
1247 asm("TXSTA equ 019Eh");
1248
1249
1250 typedef union {
1251 struct {
1252 unsigned TX9D :1;
1253 unsigned TRMT :1;
1254 unsigned BRGH :1;
1255 unsigned SENDB :1;
1256 unsigned SYNC :1;
1257 unsigned TXEN :1;
1258 unsigned TX9 :1;
1259 unsigned CSRC :1;
1260 };
1261 } TXSTAbits_t;
1262 extern volatile TXSTAbits_t TXSTAbits @ 0x19E;
1263
1264 # 3021
1265 extern volatile unsigned char BAUDCON @ 0x19F;
1266
1267 asm("BAUDCON equ 019Fh");
1268
1269
1270 typedef union {
1271 struct {
1272 unsigned ABDEN :1;
1273 unsigned WUE :1;
1274 unsigned :1;
1275 unsigned BRG16 :1;
1276 unsigned SCKP :1;
1277 unsigned :1;
1278 unsigned RCIDL :1;
1279 unsigned ABDOVF :1;
1280 };
1281 } BAUDCONbits_t;
1282 extern volatile BAUDCONbits_t BAUDCONbits @ 0x19F;
1283
1284 # 3072
1285 extern volatile unsigned char WPUA @ 0x20C;
1286
1287 asm("WPUA equ 020Ch");
1288
1289
1290 typedef union {
1291 struct {
1292 unsigned WPUA0 :1;
1293 unsigned WPUA1 :1;
1294 unsigned WPUA2 :1;
1295 unsigned WPUA3 :1;
1296 unsigned WPUA4 :1;
1297 unsigned WPUA5 :1;
1298 };
1299 struct {
1300 unsigned WPUA :6;
1301 };
1302 } WPUAbits_t;
1303 extern volatile WPUAbits_t WPUAbits @ 0x20C;
1304
1305 # 3129
1306 extern volatile unsigned char SSP1BUF @ 0x211;
1307
1308 asm("SSP1BUF equ 0211h");
1309
1310
1311 extern volatile unsigned char SSPBUF @ 0x211;
1312
1313 asm("SSPBUF equ 0211h");
1314
1315
1316 typedef union {
1317 struct {
1318 unsigned SSPBUF :8;
1319 };
1320 } SSP1BUFbits_t;
1321 extern volatile SSP1BUFbits_t SSP1BUFbits @ 0x211;
1322
1323 # 3152
1324 typedef union {
1325 struct {
1326 unsigned SSPBUF :8;
1327 };
1328 } SSPBUFbits_t;
1329 extern volatile SSPBUFbits_t SSPBUFbits @ 0x211;
1330
1331 # 3166
1332 extern volatile unsigned char SSP1ADD @ 0x212;
1333
1334 asm("SSP1ADD equ 0212h");
1335
1336
1337 extern volatile unsigned char SSPADD @ 0x212;
1338
1339 asm("SSPADD equ 0212h");
1340
1341
1342 typedef union {
1343 struct {
1344 unsigned SSPADD :8;
1345 };
1346 } SSP1ADDbits_t;
1347 extern volatile SSP1ADDbits_t SSP1ADDbits @ 0x212;
1348
1349 # 3189
1350 typedef union {
1351 struct {
1352 unsigned SSPADD :8;
1353 };
1354 } SSPADDbits_t;
1355 extern volatile SSPADDbits_t SSPADDbits @ 0x212;
1356
1357 # 3203
1358 extern volatile unsigned char SSP1MSK @ 0x213;
1359
1360 asm("SSP1MSK equ 0213h");
1361
1362
1363 extern volatile unsigned char SSPMSK @ 0x213;
1364
1365 asm("SSPMSK equ 0213h");
1366
1367
1368 typedef union {
1369 struct {
1370 unsigned SSPMSK :8;
1371 };
1372 } SSP1MSKbits_t;
1373 extern volatile SSP1MSKbits_t SSP1MSKbits @ 0x213;
1374
1375 # 3226
1376 typedef union {
1377 struct {
1378 unsigned SSPMSK :8;
1379 };
1380 } SSPMSKbits_t;
1381 extern volatile SSPMSKbits_t SSPMSKbits @ 0x213;
1382
1383 # 3240
1384 extern volatile unsigned char SSP1STAT @ 0x214;
1385
1386 asm("SSP1STAT equ 0214h");
1387
1388
1389 extern volatile unsigned char SSPSTAT @ 0x214;
1390
1391 asm("SSPSTAT equ 0214h");
1392
1393
1394 typedef union {
1395 struct {
1396 unsigned BF :1;
1397 unsigned UA :1;
1398 unsigned R_nW :1;
1399 unsigned S :1;
1400 unsigned P :1;
1401 unsigned D_nA :1;
1402 unsigned CKE :1;
1403 unsigned SMP :1;
1404 };
1405 } SSP1STATbits_t;
1406 extern volatile SSP1STATbits_t SSP1STATbits @ 0x214;
1407
1408 # 3305
1409 typedef union {
1410 struct {
1411 unsigned BF :1;
1412 unsigned UA :1;
1413 unsigned R_nW :1;
1414 unsigned S :1;
1415 unsigned P :1;
1416 unsigned D_nA :1;
1417 unsigned CKE :1;
1418 unsigned SMP :1;
1419 };
1420 } SSPSTATbits_t;
1421 extern volatile SSPSTATbits_t SSPSTATbits @ 0x214;
1422
1423 # 3361
1424 extern volatile unsigned char SSP1CON1 @ 0x215;
1425
1426 asm("SSP1CON1 equ 0215h");
1427
1428
1429 extern volatile unsigned char SSPCON1 @ 0x215;
1430
1431 asm("SSPCON1 equ 0215h");
1432
1433 extern volatile unsigned char SSPCON @ 0x215;
1434
1435 asm("SSPCON equ 0215h");
1436
1437
1438 typedef union {
1439 struct {
1440 unsigned SSPM0 :1;
1441 unsigned SSPM1 :1;
1442 unsigned SSPM2 :1;
1443 unsigned SSPM3 :1;
1444 unsigned CKP :1;
1445 unsigned SSPEN :1;
1446 unsigned SSPOV :1;
1447 unsigned WCOL :1;
1448 };
1449 struct {
1450 unsigned SSPM :4;
1451 };
1452 } SSP1CON1bits_t;
1453 extern volatile SSP1CON1bits_t SSP1CON1bits @ 0x215;
1454
1455 # 3438
1456 typedef union {
1457 struct {
1458 unsigned SSPM0 :1;
1459 unsigned SSPM1 :1;
1460 unsigned SSPM2 :1;
1461 unsigned SSPM3 :1;
1462 unsigned CKP :1;
1463 unsigned SSPEN :1;
1464 unsigned SSPOV :1;
1465 unsigned WCOL :1;
1466 };
1467 struct {
1468 unsigned SSPM :4;
1469 };
1470 } SSPCON1bits_t;
1471 extern volatile SSPCON1bits_t SSPCON1bits @ 0x215;
1472
1473 # 3500
1474 typedef union {
1475 struct {
1476 unsigned SSPM0 :1;
1477 unsigned SSPM1 :1;
1478 unsigned SSPM2 :1;
1479 unsigned SSPM3 :1;
1480 unsigned CKP :1;
1481 unsigned SSPEN :1;
1482 unsigned SSPOV :1;
1483 unsigned WCOL :1;
1484 };
1485 struct {
1486 unsigned SSPM :4;
1487 };
1488 } SSPCONbits_t;
1489 extern volatile SSPCONbits_t SSPCONbits @ 0x215;
1490
1491 # 3564
1492 extern volatile unsigned char SSP1CON2 @ 0x216;
1493
1494 asm("SSP1CON2 equ 0216h");
1495
1496
1497 extern volatile unsigned char SSPCON2 @ 0x216;
1498
1499 asm("SSPCON2 equ 0216h");
1500
1501
1502 typedef union {
1503 struct {
1504 unsigned SEN :1;
1505 unsigned RSEN :1;
1506 unsigned PEN :1;
1507 unsigned RCEN :1;
1508 unsigned ACKEN :1;
1509 unsigned ACKDT :1;
1510 unsigned ACKSTAT :1;
1511 unsigned GCEN :1;
1512 };
1513 } SSP1CON2bits_t;
1514 extern volatile SSP1CON2bits_t SSP1CON2bits @ 0x216;
1515
1516 # 3629
1517 typedef union {
1518 struct {
1519 unsigned SEN :1;
1520 unsigned RSEN :1;
1521 unsigned PEN :1;
1522 unsigned RCEN :1;
1523 unsigned ACKEN :1;
1524 unsigned ACKDT :1;
1525 unsigned ACKSTAT :1;
1526 unsigned GCEN :1;
1527 };
1528 } SSPCON2bits_t;
1529 extern volatile SSPCON2bits_t SSPCON2bits @ 0x216;
1530
1531 # 3685
1532 extern volatile unsigned char SSP1CON3 @ 0x217;
1533
1534 asm("SSP1CON3 equ 0217h");
1535
1536
1537 extern volatile unsigned char SSPCON3 @ 0x217;
1538
1539 asm("SSPCON3 equ 0217h");
1540
1541
1542 typedef union {
1543 struct {
1544 unsigned DHEN :1;
1545 unsigned AHEN :1;
1546 unsigned SBCDE :1;
1547 unsigned SDAHT :1;
1548 unsigned BOEN :1;
1549 unsigned SCIE :1;
1550 unsigned PCIE :1;
1551 unsigned ACKTIM :1;
1552 };
1553 } SSP1CON3bits_t;
1554 extern volatile SSP1CON3bits_t SSP1CON3bits @ 0x217;
1555
1556 # 3750
1557 typedef union {
1558 struct {
1559 unsigned DHEN :1;
1560 unsigned AHEN :1;
1561 unsigned SBCDE :1;
1562 unsigned SDAHT :1;
1563 unsigned BOEN :1;
1564 unsigned SCIE :1;
1565 unsigned PCIE :1;
1566 unsigned ACKTIM :1;
1567 };
1568 } SSPCON3bits_t;
1569 extern volatile SSPCON3bits_t SSPCON3bits @ 0x217;
1570
1571 # 3806
1572 extern volatile unsigned char CCPR1L @ 0x291;
1573
1574 asm("CCPR1L equ 0291h");
1575
1576
1577 typedef union {
1578 struct {
1579 unsigned CCPR1L :8;
1580 };
1581 } CCPR1Lbits_t;
1582 extern volatile CCPR1Lbits_t CCPR1Lbits @ 0x291;
1583
1584 # 3825
1585 extern volatile unsigned char CCPR1H @ 0x292;
1586
1587 asm("CCPR1H equ 0292h");
1588
1589
1590 typedef union {
1591 struct {
1592 unsigned CCPR1H :8;
1593 };
1594 } CCPR1Hbits_t;
1595 extern volatile CCPR1Hbits_t CCPR1Hbits @ 0x292;
1596
1597 # 3844
1598 extern volatile unsigned char CCP1CON @ 0x293;
1599
1600 asm("CCP1CON equ 0293h");
1601
1602
1603 typedef union {
1604 struct {
1605 unsigned CCP1M0 :1;
1606 unsigned CCP1M1 :1;
1607 unsigned CCP1M2 :1;
1608 unsigned CCP1M3 :1;
1609 unsigned DC1B0 :1;
1610 unsigned DC1B1 :1;
1611 unsigned P1M0 :1;
1612 unsigned P1M1 :1;
1613 };
1614 struct {
1615 unsigned CCP1M :4;
1616 unsigned DC1B :2;
1617 unsigned P1M :2;
1618 };
1619 } CCP1CONbits_t;
1620 extern volatile CCP1CONbits_t CCP1CONbits @ 0x293;
1621
1622 # 3925
1623 extern volatile unsigned char PWM1CON @ 0x294;
1624
1625 asm("PWM1CON equ 0294h");
1626
1627
1628 typedef union {
1629 struct {
1630 unsigned P1DC0 :1;
1631 unsigned P1DC1 :1;
1632 unsigned P1DC2 :1;
1633 unsigned P1DC3 :1;
1634 unsigned P1DC4 :1;
1635 unsigned P1DC5 :1;
1636 unsigned P1DC6 :1;
1637 unsigned P1RSEN :1;
1638 };
1639 struct {
1640 unsigned P1DC :7;
1641 };
1642 } PWM1CONbits_t;
1643 extern volatile PWM1CONbits_t PWM1CONbits @ 0x294;
1644
1645 # 3994
1646 extern volatile unsigned char CCP1AS @ 0x295;
1647
1648 asm("CCP1AS equ 0295h");
1649
1650
1651 extern volatile unsigned char ECCP1AS @ 0x295;
1652
1653 asm("ECCP1AS equ 0295h");
1654
1655
1656 typedef union {
1657 struct {
1658 unsigned PSS1BD0 :1;
1659 unsigned PSS1BD1 :1;
1660 unsigned PSS1AC0 :1;
1661 unsigned PSS1AC1 :1;
1662 unsigned CCP1AS0 :1;
1663 unsigned CCP1AS1 :1;
1664 unsigned CCP1AS2 :1;
1665 unsigned CCP1ASE :1;
1666 };
1667 struct {
1668 unsigned PSS1BD :2;
1669 unsigned PSS1AC :2;
1670 unsigned CCP1AS :3;
1671 };
1672 } CCP1ASbits_t;
1673 extern volatile CCP1ASbits_t CCP1ASbits @ 0x295;
1674
1675 # 4079
1676 typedef union {
1677 struct {
1678 unsigned PSS1BD0 :1;
1679 unsigned PSS1BD1 :1;
1680 unsigned PSS1AC0 :1;
1681 unsigned PSS1AC1 :1;
1682 unsigned CCP1AS0 :1;
1683 unsigned CCP1AS1 :1;
1684 unsigned CCP1AS2 :1;
1685 unsigned CCP1ASE :1;
1686 };
1687 struct {
1688 unsigned PSS1BD :2;
1689 unsigned PSS1AC :2;
1690 unsigned CCP1AS :3;
1691 };
1692 } ECCP1ASbits_t;
1693 extern volatile ECCP1ASbits_t ECCP1ASbits @ 0x295;
1694
1695 # 4155
1696 extern volatile unsigned char PSTR1CON @ 0x296;
1697
1698 asm("PSTR1CON equ 0296h");
1699
1700
1701 typedef union {
1702 struct {
1703 unsigned STR1A :1;
1704 unsigned STR1B :1;
1705 unsigned STR1C :1;
1706 unsigned STR1D :1;
1707 unsigned STR1SYNC :1;
1708 };
1709 } PSTR1CONbits_t;
1710 extern volatile PSTR1CONbits_t PSTR1CONbits @ 0x296;
1711
1712 # 4198
1713 extern volatile unsigned char IOCAP @ 0x391;
1714
1715 asm("IOCAP equ 0391h");
1716
1717
1718 typedef union {
1719 struct {
1720 unsigned IOCAP0 :1;
1721 unsigned IOCAP1 :1;
1722 unsigned IOCAP2 :1;
1723 unsigned IOCAP3 :1;
1724 unsigned IOCAP4 :1;
1725 unsigned IOCAP5 :1;
1726 };
1727 struct {
1728 unsigned IOCAP :6;
1729 };
1730 } IOCAPbits_t;
1731 extern volatile IOCAPbits_t IOCAPbits @ 0x391;
1732
1733 # 4255
1734 extern volatile unsigned char IOCAN @ 0x392;
1735
1736 asm("IOCAN equ 0392h");
1737
1738
1739 typedef union {
1740 struct {
1741 unsigned IOCAN0 :1;
1742 unsigned IOCAN1 :1;
1743 unsigned IOCAN2 :1;
1744 unsigned IOCAN3 :1;
1745 unsigned IOCAN4 :1;
1746 unsigned IOCAN5 :1;
1747 };
1748 struct {
1749 unsigned IOCAN :6;
1750 };
1751 } IOCANbits_t;
1752 extern volatile IOCANbits_t IOCANbits @ 0x392;
1753
1754 # 4312
1755 extern volatile unsigned char IOCAF @ 0x393;
1756
1757 asm("IOCAF equ 0393h");
1758
1759
1760 typedef union {
1761 struct {
1762 unsigned IOCAF0 :1;
1763 unsigned IOCAF1 :1;
1764 unsigned IOCAF2 :1;
1765 unsigned IOCAF3 :1;
1766 unsigned IOCAF4 :1;
1767 unsigned IOCAF5 :1;
1768 };
1769 struct {
1770 unsigned IOCAF :6;
1771 };
1772 } IOCAFbits_t;
1773 extern volatile IOCAFbits_t IOCAFbits @ 0x393;
1774
1775 # 4369
1776 extern volatile unsigned char CLKRCON @ 0x39A;
1777
1778 asm("CLKRCON equ 039Ah");
1779
1780
1781 typedef union {
1782 struct {
1783 unsigned CLKRDIV0 :1;
1784 unsigned CLKRDIV1 :1;
1785 unsigned CLKRDIV2 :1;
1786 unsigned CLKRDC0 :1;
1787 unsigned CLKRDC1 :1;
1788 unsigned CLKRSLR :1;
1789 unsigned CLKROE :1;
1790 unsigned CLKREN :1;
1791 };
1792 struct {
1793 unsigned CLKRDIV :3;
1794 unsigned CLKRDC :2;
1795 };
1796 } CLKRCONbits_t;
1797 extern volatile CLKRCONbits_t CLKRCONbits @ 0x39A;
1798
1799 # 4444
1800 extern volatile unsigned char MDCON @ 0x39C;
1801
1802 asm("MDCON equ 039Ch");
1803
1804
1805 typedef union {
1806 struct {
1807 unsigned MDBIT :1;
1808 unsigned :2;
1809 unsigned MDOUT :1;
1810 unsigned MDOPOL :1;
1811 unsigned MDSLR :1;
1812 unsigned MDOE :1;
1813 unsigned MDEN :1;
1814 };
1815 } MDCONbits_t;
1816 extern volatile MDCONbits_t MDCONbits @ 0x39C;
1817
1818 # 4494
1819 extern volatile unsigned char MDSRC @ 0x39D;
1820
1821 asm("MDSRC equ 039Dh");
1822
1823
1824 typedef union {
1825 struct {
1826 unsigned MDMS0 :1;
1827 unsigned MDMS1 :1;
1828 unsigned MDMS2 :1;
1829 unsigned MDMS3 :1;
1830 unsigned :3;
1831 unsigned MDMSODIS :1;
1832 };
1833 struct {
1834 unsigned MDMS :4;
1835 };
1836 } MDSRCbits_t;
1837 extern volatile MDSRCbits_t MDSRCbits @ 0x39D;
1838
1839 # 4546
1840 extern volatile unsigned char MDCARL @ 0x39E;
1841
1842 asm("MDCARL equ 039Eh");
1843
1844
1845 typedef union {
1846 struct {
1847 unsigned MDCL0 :1;
1848 unsigned MDCL1 :1;
1849 unsigned MDCL2 :1;
1850 unsigned MDCL3 :1;
1851 unsigned :1;
1852 unsigned MDCLSYNC :1;
1853 unsigned MDCLPOL :1;
1854 unsigned MDCLODIS :1;
1855 };
1856 struct {
1857 unsigned MDCL :4;
1858 };
1859 } MDCARLbits_t;
1860 extern volatile MDCARLbits_t MDCARLbits @ 0x39E;
1861
1862 # 4610
1863 extern volatile unsigned char MDCARH @ 0x39F;
1864
1865 asm("MDCARH equ 039Fh");
1866
1867
1868 typedef union {
1869 struct {
1870 unsigned MDCH0 :1;
1871 unsigned MDCH1 :1;
1872 unsigned MDCH2 :1;
1873 unsigned MDCH3 :1;
1874 unsigned :1;
1875 unsigned MDCHSYNC :1;
1876 unsigned MDCHPOL :1;
1877 unsigned MDCHODIS :1;
1878 };
1879 struct {
1880 unsigned MDCH :4;
1881 };
1882 } MDCARHbits_t;
1883 extern volatile MDCARHbits_t MDCARHbits @ 0x39F;
1884
1885 # 4674
1886 extern volatile unsigned char STATUS_SHAD @ 0xFE4;
1887
1888 asm("STATUS_SHAD equ 0FE4h");
1889
1890
1891 typedef union {
1892 struct {
1893 unsigned C_SHAD :1;
1894 unsigned DC_SHAD :1;
1895 unsigned Z_SHAD :1;
1896 };
1897 } STATUS_SHADbits_t;
1898 extern volatile STATUS_SHADbits_t STATUS_SHADbits @ 0xFE4;
1899
1900 # 4705
1901 extern volatile unsigned char WREG_SHAD @ 0xFE5;
1902
1903 asm("WREG_SHAD equ 0FE5h");
1904
1905
1906 typedef union {
1907 struct {
1908 unsigned WREG_SHAD :8;
1909 };
1910 } WREG_SHADbits_t;
1911 extern volatile WREG_SHADbits_t WREG_SHADbits @ 0xFE5;
1912
1913 # 4724
1914 extern volatile unsigned char BSR_SHAD @ 0xFE6;
1915
1916 asm("BSR_SHAD equ 0FE6h");
1917
1918
1919 typedef union {
1920 struct {
1921 unsigned BSR_SHAD :5;
1922 };
1923 } BSR_SHADbits_t;
1924 extern volatile BSR_SHADbits_t BSR_SHADbits @ 0xFE6;
1925
1926 # 4743
1927 extern volatile unsigned char PCLATH_SHAD @ 0xFE7;
1928
1929 asm("PCLATH_SHAD equ 0FE7h");
1930
1931
1932 typedef union {
1933 struct {
1934 unsigned PCLATH_SHAD :7;
1935 };
1936 } PCLATH_SHADbits_t;
1937 extern volatile PCLATH_SHADbits_t PCLATH_SHADbits @ 0xFE7;
1938
1939 # 4762
1940 extern volatile unsigned char FSR0L_SHAD @ 0xFE8;
1941
1942 asm("FSR0L_SHAD equ 0FE8h");
1943
1944
1945 typedef union {
1946 struct {
1947 unsigned FSR0L_SHAD :8;
1948 };
1949 } FSR0L_SHADbits_t;
1950 extern volatile FSR0L_SHADbits_t FSR0L_SHADbits @ 0xFE8;
1951
1952 # 4781
1953 extern volatile unsigned char FSR0H_SHAD @ 0xFE9;
1954
1955 asm("FSR0H_SHAD equ 0FE9h");
1956
1957
1958 typedef union {
1959 struct {
1960 unsigned FSR0H_SHAD :8;
1961 };
1962 } FSR0H_SHADbits_t;
1963 extern volatile FSR0H_SHADbits_t FSR0H_SHADbits @ 0xFE9;
1964
1965 # 4800
1966 extern volatile unsigned char FSR1L_SHAD @ 0xFEA;
1967
1968 asm("FSR1L_SHAD equ 0FEAh");
1969
1970
1971 typedef union {
1972 struct {
1973 unsigned FSR1L_SHAD :8;
1974 };
1975 } FSR1L_SHADbits_t;
1976 extern volatile FSR1L_SHADbits_t FSR1L_SHADbits @ 0xFEA;
1977
1978 # 4819
1979 extern volatile unsigned char FSR1H_SHAD @ 0xFEB;
1980
1981 asm("FSR1H_SHAD equ 0FEBh");
1982
1983
1984 typedef union {
1985 struct {
1986 unsigned FSR1H_SHAD :8;
1987 };
1988 } FSR1H_SHADbits_t;
1989 extern volatile FSR1H_SHADbits_t FSR1H_SHADbits @ 0xFEB;
1990
1991 # 4838
1992 extern volatile unsigned char STKPTR @ 0xFED;
1993
1994 asm("STKPTR equ 0FEDh");
1995
1996
1997 typedef union {
1998 struct {
1999 unsigned STKPTR :5;
2000 };
2001 } STKPTRbits_t;
2002 extern volatile STKPTRbits_t STKPTRbits @ 0xFED;
2003
2004 # 4857
2005 extern volatile unsigned char TOSL @ 0xFEE;
2006
2007 asm("TOSL equ 0FEEh");
2008
2009
2010 typedef union {
2011 struct {
2012 unsigned TOSL :8;
2013 };
2014 } TOSLbits_t;
2015 extern volatile TOSLbits_t TOSLbits @ 0xFEE;
2016
2017 # 4876
2018 extern volatile unsigned char TOSH @ 0xFEF;
2019
2020 asm("TOSH equ 0FEFh");
2021
2022
2023 typedef union {
2024 struct {
2025 unsigned TOSH :7;
2026 };
2027 } TOSHbits_t;
2028 extern volatile TOSHbits_t TOSHbits @ 0xFEF;
2029
2030 # 4901
2031 extern volatile __bit ABDEN @ (((unsigned) &BAUDCON)*8) + 0;
2032
2033 extern volatile __bit ABDOVF @ (((unsigned) &BAUDCON)*8) + 7;
2034
2035 extern volatile __bit ACKDT @ (((unsigned) &SSP1CON2)*8) + 5;
2036
2037 extern volatile __bit ACKEN @ (((unsigned) &SSP1CON2)*8) + 4;
2038
2039 extern volatile __bit ACKSTAT @ (((unsigned) &SSP1CON2)*8) + 6;
2040
2041 extern volatile __bit ACKTIM @ (((unsigned) &SSP1CON3)*8) + 7;
2042
2043 extern volatile __bit ADCS0 @ (((unsigned) &ADCON1)*8) + 4;
2044
2045 extern volatile __bit ADCS1 @ (((unsigned) &ADCON1)*8) + 5;
2046
2047 extern volatile __bit ADCS2 @ (((unsigned) &ADCON1)*8) + 6;
2048
2049 extern volatile __bit ADDEN @ (((unsigned) &RCSTA)*8) + 3;
2050
2051 extern volatile __bit ADFM @ (((unsigned) &ADCON1)*8) + 7;
2052
2053 extern volatile __bit ADFVR0 @ (((unsigned) &FVRCON)*8) + 0;
2054
2055 extern volatile __bit ADFVR1 @ (((unsigned) &FVRCON)*8) + 1;
2056
2057 extern volatile __bit ADGO @ (((unsigned) &ADCON0)*8) + 1;
2058
2059 extern volatile __bit ADIE @ (((unsigned) &PIE1)*8) + 6;
2060
2061 extern volatile __bit ADIF @ (((unsigned) &PIR1)*8) + 6;
2062
2063 extern volatile __bit ADON @ (((unsigned) &ADCON0)*8) + 0;
2064
2065 extern volatile __bit ADPREF0 @ (((unsigned) &ADCON1)*8) + 0;
2066
2067 extern volatile __bit ADPREF1 @ (((unsigned) &ADCON1)*8) + 1;
2068
2069 extern volatile __bit AHEN @ (((unsigned) &SSP1CON3)*8) + 1;
2070
2071 extern volatile __bit AN0 @ (((unsigned) &PORTA)*8) + 0;
2072
2073 extern volatile __bit AN1 @ (((unsigned) &PORTA)*8) + 1;
2074
2075 extern volatile __bit AN2 @ (((unsigned) &PORTA)*8) + 2;
2076
2077 extern volatile __bit AN3 @ (((unsigned) &PORTA)*8) + 4;
2078
2079 extern volatile __bit ANSA0 @ (((unsigned) &ANSELA)*8) + 0;
2080
2081 extern volatile __bit ANSA1 @ (((unsigned) &ANSELA)*8) + 1;
2082
2083 extern volatile __bit ANSA2 @ (((unsigned) &ANSELA)*8) + 2;
2084
2085 extern volatile __bit ANSA4 @ (((unsigned) &ANSELA)*8) + 4;
2086
2087 extern volatile __bit BCL1IE @ (((unsigned) &PIE2)*8) + 3;
2088
2089 extern volatile __bit BCL1IF @ (((unsigned) &PIR2)*8) + 3;
2090
2091 extern volatile __bit BF @ (((unsigned) &SSP1STAT)*8) + 0;
2092
2093 extern volatile __bit BOEN @ (((unsigned) &SSP1CON3)*8) + 4;
2094
2095 extern volatile __bit BORRDY @ (((unsigned) &BORCON)*8) + 0;
2096
2097 extern volatile __bit BRG16 @ (((unsigned) &BAUDCON)*8) + 3;
2098
2099 extern volatile __bit BRGH @ (((unsigned) &TXSTA)*8) + 2;
2100
2101 extern volatile __bit BSR0 @ (((unsigned) &BSR)*8) + 0;
2102
2103 extern volatile __bit BSR1 @ (((unsigned) &BSR)*8) + 1;
2104
2105 extern volatile __bit BSR2 @ (((unsigned) &BSR)*8) + 2;
2106
2107 extern volatile __bit BSR3 @ (((unsigned) &BSR)*8) + 3;
2108
2109 extern volatile __bit BSR4 @ (((unsigned) &BSR)*8) + 4;
2110
2111 extern volatile __bit C1HYS @ (((unsigned) &CM1CON0)*8) + 1;
2112
2113 extern volatile __bit C1IE @ (((unsigned) &PIE2)*8) + 5;
2114
2115 extern volatile __bit C1IF @ (((unsigned) &PIR2)*8) + 5;
2116
2117 extern volatile __bit C1IN0N @ (((unsigned) &PORTA)*8) + 1;
2118
2119 extern volatile __bit C1IN1N @ (((unsigned) &PORTA)*8) + 4;
2120
2121 extern volatile __bit C1INP @ (((unsigned) &PORTA)*8) + 0;
2122
2123 extern volatile __bit C1INTN @ (((unsigned) &CM1CON1)*8) + 6;
2124
2125 extern volatile __bit C1INTP @ (((unsigned) &CM1CON1)*8) + 7;
2126
2127 extern volatile __bit C1NCH0 @ (((unsigned) &CM1CON1)*8) + 0;
2128
2129 extern volatile __bit C1OE @ (((unsigned) &CM1CON0)*8) + 5;
2130
2131 extern volatile __bit C1ON @ (((unsigned) &CM1CON0)*8) + 7;
2132
2133 extern volatile __bit C1PCH0 @ (((unsigned) &CM1CON1)*8) + 4;
2134
2135 extern volatile __bit C1PCH1 @ (((unsigned) &CM1CON1)*8) + 5;
2136
2137 extern volatile __bit C1POL @ (((unsigned) &CM1CON0)*8) + 4;
2138
2139 extern volatile __bit C1SP @ (((unsigned) &CM1CON0)*8) + 2;
2140
2141 extern volatile __bit C1SYNC @ (((unsigned) &CM1CON0)*8) + 0;
2142
2143 extern volatile __bit CARRY @ (((unsigned) &STATUS)*8) + 0;
2144
2145 extern volatile __bit CCP1AS0 @ (((unsigned) &CCP1AS)*8) + 4;
2146
2147 extern volatile __bit CCP1AS1 @ (((unsigned) &CCP1AS)*8) + 5;
2148
2149 extern volatile __bit CCP1AS2 @ (((unsigned) &CCP1AS)*8) + 6;
2150
2151 extern volatile __bit CCP1ASE @ (((unsigned) &CCP1AS)*8) + 7;
2152
2153 extern volatile __bit CCP1IE @ (((unsigned) &PIE1)*8) + 2;
2154
2155 extern volatile __bit CCP1IF @ (((unsigned) &PIR1)*8) + 2;
2156
2157 extern volatile __bit CCP1M0 @ (((unsigned) &CCP1CON)*8) + 0;
2158
2159 extern volatile __bit CCP1M1 @ (((unsigned) &CCP1CON)*8) + 1;
2160
2161 extern volatile __bit CCP1M2 @ (((unsigned) &CCP1CON)*8) + 2;
2162
2163 extern volatile __bit CCP1M3 @ (((unsigned) &CCP1CON)*8) + 3;
2164
2165 extern volatile __bit CCP1SEL @ (((unsigned) &APFCON)*8) + 0;
2166
2167 extern volatile __bit CDAFVR0 @ (((unsigned) &FVRCON)*8) + 2;
2168
2169 extern volatile __bit CDAFVR1 @ (((unsigned) &FVRCON)*8) + 3;
2170
2171 extern volatile __bit CFGS @ (((unsigned) &EECON1)*8) + 6;
2172
2173 extern volatile __bit CHS0 @ (((unsigned) &ADCON0)*8) + 2;
2174
2175 extern volatile __bit CHS1 @ (((unsigned) &ADCON0)*8) + 3;
2176
2177 extern volatile __bit CHS2 @ (((unsigned) &ADCON0)*8) + 4;
2178
2179 extern volatile __bit CHS3 @ (((unsigned) &ADCON0)*8) + 5;
2180
2181 extern volatile __bit CHS4 @ (((unsigned) &ADCON0)*8) + 6;
2182
2183 extern volatile __bit CKE @ (((unsigned) &SSP1STAT)*8) + 6;
2184
2185 extern volatile __bit CKP @ (((unsigned) &SSP1CON1)*8) + 4;
2186
2187 extern volatile __bit CLKIN @ (((unsigned) &PORTA)*8) + 5;
2188
2189 extern volatile __bit CLKOUT @ (((unsigned) &PORTA)*8) + 4;
2190
2191 extern volatile __bit CLKR @ (((unsigned) &PORTA)*8) + 4;
2192
2193 extern volatile __bit CLKRDC0 @ (((unsigned) &CLKRCON)*8) + 3;
2194
2195 extern volatile __bit CLKRDC1 @ (((unsigned) &CLKRCON)*8) + 4;
2196
2197 extern volatile __bit CLKRDIV0 @ (((unsigned) &CLKRCON)*8) + 0;
2198
2199 extern volatile __bit CLKRDIV1 @ (((unsigned) &CLKRCON)*8) + 1;
2200
2201 extern volatile __bit CLKRDIV2 @ (((unsigned) &CLKRCON)*8) + 2;
2202
2203 extern volatile __bit CLKREN @ (((unsigned) &CLKRCON)*8) + 7;
2204
2205 extern volatile __bit CLKROE @ (((unsigned) &CLKRCON)*8) + 6;
2206
2207 extern volatile __bit CLKRSLR @ (((unsigned) &CLKRCON)*8) + 5;
2208
2209 extern volatile __bit CPS0 @ (((unsigned) &PORTA)*8) + 0;
2210
2211 extern volatile __bit CPS1 @ (((unsigned) &PORTA)*8) + 1;
2212
2213 extern volatile __bit CPS2 @ (((unsigned) &PORTA)*8) + 2;
2214
2215 extern volatile __bit CPS3 @ (((unsigned) &PORTA)*8) + 4;
2216
2217 extern volatile __bit CPSCH0 @ (((unsigned) &CPSCON1)*8) + 0;
2218
2219 extern volatile __bit CPSCH1 @ (((unsigned) &CPSCON1)*8) + 1;
2220
2221 extern volatile __bit CPSON @ (((unsigned) &CPSCON0)*8) + 7;
2222
2223 extern volatile __bit CPSOUT @ (((unsigned) &CPSCON0)*8) + 1;
2224
2225 extern volatile __bit CPSRM @ (((unsigned) &CPSCON0)*8) + 6;
2226
2227 extern volatile __bit CPSRNG0 @ (((unsigned) &CPSCON0)*8) + 2;
2228
2229 extern volatile __bit CPSRNG1 @ (((unsigned) &CPSCON0)*8) + 3;
2230
2231 extern volatile __bit CREN @ (((unsigned) &RCSTA)*8) + 4;
2232
2233 extern volatile __bit CSRC @ (((unsigned) &TXSTA)*8) + 7;
2234
2235 extern volatile __bit C_SHAD @ (((unsigned) &STATUS_SHAD)*8) + 0;
2236
2237 extern volatile __bit DACEN @ (((unsigned) &DACCON0)*8) + 7;
2238
2239 extern volatile __bit DACLPS @ (((unsigned) &DACCON0)*8) + 6;
2240
2241 extern volatile __bit DACOE @ (((unsigned) &DACCON0)*8) + 5;
2242
2243 extern volatile __bit DACOUT @ (((unsigned) &PORTA)*8) + 0;
2244
2245 extern volatile __bit DACPSS0 @ (((unsigned) &DACCON0)*8) + 2;
2246
2247 extern volatile __bit DACPSS1 @ (((unsigned) &DACCON0)*8) + 3;
2248
2249 extern volatile __bit DACR0 @ (((unsigned) &DACCON1)*8) + 0;
2250
2251 extern volatile __bit DACR1 @ (((unsigned) &DACCON1)*8) + 1;
2252
2253 extern volatile __bit DACR2 @ (((unsigned) &DACCON1)*8) + 2;
2254
2255 extern volatile __bit DACR3 @ (((unsigned) &DACCON1)*8) + 3;
2256
2257 extern volatile __bit DACR4 @ (((unsigned) &DACCON1)*8) + 4;
2258
2259 extern volatile __bit DC @ (((unsigned) &STATUS)*8) + 1;
2260
2261 extern volatile __bit DC1B0 @ (((unsigned) &CCP1CON)*8) + 4;
2262
2263 extern volatile __bit DC1B1 @ (((unsigned) &CCP1CON)*8) + 5;
2264
2265 extern volatile __bit DC_SHAD @ (((unsigned) &STATUS_SHAD)*8) + 1;
2266
2267 extern volatile __bit DHEN @ (((unsigned) &SSP1CON3)*8) + 0;
2268
2269 extern volatile __bit D_nA @ (((unsigned) &SSP1STAT)*8) + 5;
2270
2271 extern volatile __bit EEIE @ (((unsigned) &PIE2)*8) + 4;
2272
2273 extern volatile __bit EEIF @ (((unsigned) &PIR2)*8) + 4;
2274
2275 extern volatile __bit EEPGD @ (((unsigned) &EECON1)*8) + 7;
2276
2277 extern volatile __bit FERR @ (((unsigned) &RCSTA)*8) + 2;
2278
2279 extern volatile __bit FLT0 @ (((unsigned) &PORTA)*8) + 2;
2280
2281 extern volatile __bit FREE @ (((unsigned) &EECON1)*8) + 4;
2282
2283 extern volatile __bit FVREN @ (((unsigned) &FVRCON)*8) + 7;
2284
2285 extern volatile __bit FVRRDY @ (((unsigned) &FVRCON)*8) + 6;
2286
2287 extern volatile __bit GCEN @ (((unsigned) &SSP1CON2)*8) + 7;
2288
2289 extern volatile __bit GIE @ (((unsigned) &INTCON)*8) + 7;
2290
2291 extern volatile __bit GO @ (((unsigned) &ADCON0)*8) + 1;
2292
2293 extern volatile __bit GO_nDONE @ (((unsigned) &ADCON0)*8) + 1;
2294
2295 extern volatile __bit HFIOFL @ (((unsigned) &OSCSTAT)*8) + 3;
2296
2297 extern volatile __bit HFIOFR @ (((unsigned) &OSCSTAT)*8) + 4;
2298
2299 extern volatile __bit HFIOFS @ (((unsigned) &OSCSTAT)*8) + 0;
2300
2301 extern volatile __bit INTE @ (((unsigned) &INTCON)*8) + 4;
2302
2303 extern volatile __bit INTEDG @ (((unsigned) &OPTION_REG)*8) + 6;
2304
2305 extern volatile __bit INTF @ (((unsigned) &INTCON)*8) + 1;
2306
2307 extern volatile __bit IOCAF0 @ (((unsigned) &IOCAF)*8) + 0;
2308
2309 extern volatile __bit IOCAF1 @ (((unsigned) &IOCAF)*8) + 1;
2310
2311 extern volatile __bit IOCAF2 @ (((unsigned) &IOCAF)*8) + 2;
2312
2313 extern volatile __bit IOCAF3 @ (((unsigned) &IOCAF)*8) + 3;
2314
2315 extern volatile __bit IOCAF4 @ (((unsigned) &IOCAF)*8) + 4;
2316
2317 extern volatile __bit IOCAF5 @ (((unsigned) &IOCAF)*8) + 5;
2318
2319 extern volatile __bit IOCAN0 @ (((unsigned) &IOCAN)*8) + 0;
2320
2321 extern volatile __bit IOCAN1 @ (((unsigned) &IOCAN)*8) + 1;
2322
2323 extern volatile __bit IOCAN2 @ (((unsigned) &IOCAN)*8) + 2;
2324
2325 extern volatile __bit IOCAN3 @ (((unsigned) &IOCAN)*8) + 3;
2326
2327 extern volatile __bit IOCAN4 @ (((unsigned) &IOCAN)*8) + 4;
2328
2329 extern volatile __bit IOCAN5 @ (((unsigned) &IOCAN)*8) + 5;
2330
2331 extern volatile __bit IOCAP0 @ (((unsigned) &IOCAP)*8) + 0;
2332
2333 extern volatile __bit IOCAP1 @ (((unsigned) &IOCAP)*8) + 1;
2334
2335 extern volatile __bit IOCAP2 @ (((unsigned) &IOCAP)*8) + 2;
2336
2337 extern volatile __bit IOCAP3 @ (((unsigned) &IOCAP)*8) + 3;
2338
2339 extern volatile __bit IOCAP4 @ (((unsigned) &IOCAP)*8) + 4;
2340
2341 extern volatile __bit IOCAP5 @ (((unsigned) &IOCAP)*8) + 5;
2342
2343 extern volatile __bit IOCIE @ (((unsigned) &INTCON)*8) + 3;
2344
2345 extern volatile __bit IOCIF @ (((unsigned) &INTCON)*8) + 0;
2346
2347 extern volatile __bit IRCF0 @ (((unsigned) &OSCCON)*8) + 3;
2348
2349 extern volatile __bit IRCF1 @ (((unsigned) &OSCCON)*8) + 4;
2350
2351 extern volatile __bit IRCF2 @ (((unsigned) &OSCCON)*8) + 5;
2352
2353 extern volatile __bit IRCF3 @ (((unsigned) &OSCCON)*8) + 6;
2354
2355 extern volatile __bit LATA0 @ (((unsigned) &LATA)*8) + 0;
2356
2357 extern volatile __bit LATA1 @ (((unsigned) &LATA)*8) + 1;
2358
2359 extern volatile __bit LATA2 @ (((unsigned) &LATA)*8) + 2;
2360
2361 extern volatile __bit LATA4 @ (((unsigned) &LATA)*8) + 4;
2362
2363 extern volatile __bit LATA5 @ (((unsigned) &LATA)*8) + 5;
2364
2365 extern volatile __bit LFIOFR @ (((unsigned) &OSCSTAT)*8) + 1;
2366
2367 extern volatile __bit LWLO @ (((unsigned) &EECON1)*8) + 5;
2368
2369 extern volatile __bit MC1OUT @ (((unsigned) &CMOUT)*8) + 0;
2370
2371 extern volatile __bit MDBIT @ (((unsigned) &MDCON)*8) + 0;
2372
2373 extern volatile __bit MDCH0 @ (((unsigned) &MDCARH)*8) + 0;
2374
2375 extern volatile __bit MDCH1 @ (((unsigned) &MDCARH)*8) + 1;
2376
2377 extern volatile __bit MDCH2 @ (((unsigned) &MDCARH)*8) + 2;
2378
2379 extern volatile __bit MDCH3 @ (((unsigned) &MDCARH)*8) + 3;
2380
2381 extern volatile __bit MDCHODIS @ (((unsigned) &MDCARH)*8) + 7;
2382
2383 extern volatile __bit MDCHPOL @ (((unsigned) &MDCARH)*8) + 6;
2384
2385 extern volatile __bit MDCHSYNC @ (((unsigned) &MDCARH)*8) + 5;
2386
2387 extern volatile __bit MDCIN1 @ (((unsigned) &PORTA)*8) + 2;
2388
2389 extern volatile __bit MDCIN2 @ (((unsigned) &PORTA)*8) + 4;
2390
2391 extern volatile __bit MDCL0 @ (((unsigned) &MDCARL)*8) + 0;
2392
2393 extern volatile __bit MDCL1 @ (((unsigned) &MDCARL)*8) + 1;
2394
2395 extern volatile __bit MDCL2 @ (((unsigned) &MDCARL)*8) + 2;
2396
2397 extern volatile __bit MDCL3 @ (((unsigned) &MDCARL)*8) + 3;
2398
2399 extern volatile __bit MDCLODIS @ (((unsigned) &MDCARL)*8) + 7;
2400
2401 extern volatile __bit MDCLPOL @ (((unsigned) &MDCARL)*8) + 6;
2402
2403 extern volatile __bit MDCLSYNC @ (((unsigned) &MDCARL)*8) + 5;
2404
2405 extern volatile __bit MDEN @ (((unsigned) &MDCON)*8) + 7;
2406
2407 extern volatile __bit MDMIN @ (((unsigned) &PORTA)*8) + 1;
2408
2409 extern volatile __bit MDMS0 @ (((unsigned) &MDSRC)*8) + 0;
2410
2411 extern volatile __bit MDMS1 @ (((unsigned) &MDSRC)*8) + 1;
2412
2413 extern volatile __bit MDMS2 @ (((unsigned) &MDSRC)*8) + 2;
2414
2415 extern volatile __bit MDMS3 @ (((unsigned) &MDSRC)*8) + 3;
2416
2417 extern volatile __bit MDMSODIS @ (((unsigned) &MDSRC)*8) + 7;
2418
2419 extern volatile __bit MDOE @ (((unsigned) &MDCON)*8) + 6;
2420
2421 extern volatile __bit MDOPOL @ (((unsigned) &MDCON)*8) + 4;
2422
2423 extern volatile __bit MDSLR @ (((unsigned) &MDCON)*8) + 5;
2424
2425 extern volatile __bit MFIOFR @ (((unsigned) &OSCSTAT)*8) + 2;
2426
2427 extern volatile __bit OERR @ (((unsigned) &RCSTA)*8) + 1;
2428
2429 extern volatile __bit OSC1 @ (((unsigned) &PORTA)*8) + 5;
2430
2431 extern volatile __bit OSC2 @ (((unsigned) &PORTA)*8) + 4;
2432
2433 extern volatile __bit OSFIE @ (((unsigned) &PIE2)*8) + 7;
2434
2435 extern volatile __bit OSFIF @ (((unsigned) &PIR2)*8) + 7;
2436
2437 extern volatile __bit OSTS @ (((unsigned) &OSCSTAT)*8) + 5;
2438
2439 extern volatile __bit P1BSEL @ (((unsigned) &APFCON)*8) + 1;
2440
2441 extern volatile __bit P1DC0 @ (((unsigned) &PWM1CON)*8) + 0;
2442
2443 extern volatile __bit P1DC1 @ (((unsigned) &PWM1CON)*8) + 1;
2444
2445 extern volatile __bit P1DC2 @ (((unsigned) &PWM1CON)*8) + 2;
2446
2447 extern volatile __bit P1DC3 @ (((unsigned) &PWM1CON)*8) + 3;
2448
2449 extern volatile __bit P1DC4 @ (((unsigned) &PWM1CON)*8) + 4;
2450
2451 extern volatile __bit P1DC5 @ (((unsigned) &PWM1CON)*8) + 5;
2452
2453 extern volatile __bit P1DC6 @ (((unsigned) &PWM1CON)*8) + 6;
2454
2455 extern volatile __bit P1M0 @ (((unsigned) &CCP1CON)*8) + 6;
2456
2457 extern volatile __bit P1M1 @ (((unsigned) &CCP1CON)*8) + 7;
2458
2459 extern volatile __bit P1RSEN @ (((unsigned) &PWM1CON)*8) + 7;
2460
2461 extern volatile __bit PCIE @ (((unsigned) &SSP1CON3)*8) + 6;
2462
2463 extern volatile __bit PEIE @ (((unsigned) &INTCON)*8) + 6;
2464
2465 extern volatile __bit PEN @ (((unsigned) &SSP1CON2)*8) + 2;
2466
2467 extern volatile __bit PLLR @ (((unsigned) &OSCSTAT)*8) + 6;
2468
2469 extern volatile __bit PS0 @ (((unsigned) &OPTION_REG)*8) + 0;
2470
2471 extern volatile __bit PS1 @ (((unsigned) &OPTION_REG)*8) + 1;
2472
2473 extern volatile __bit PS2 @ (((unsigned) &OPTION_REG)*8) + 2;
2474
2475 extern volatile __bit PSA @ (((unsigned) &OPTION_REG)*8) + 3;
2476
2477 extern volatile __bit PSS1AC0 @ (((unsigned) &CCP1AS)*8) + 2;
2478
2479 extern volatile __bit PSS1AC1 @ (((unsigned) &CCP1AS)*8) + 3;
2480
2481 extern volatile __bit PSS1BD0 @ (((unsigned) &CCP1AS)*8) + 0;
2482
2483 extern volatile __bit PSS1BD1 @ (((unsigned) &CCP1AS)*8) + 1;
2484
2485 extern volatile __bit RA0 @ (((unsigned) &PORTA)*8) + 0;
2486
2487 extern volatile __bit RA1 @ (((unsigned) &PORTA)*8) + 1;
2488
2489 extern volatile __bit RA2 @ (((unsigned) &PORTA)*8) + 2;
2490
2491 extern volatile __bit RA3 @ (((unsigned) &PORTA)*8) + 3;
2492
2493 extern volatile __bit RA4 @ (((unsigned) &PORTA)*8) + 4;
2494
2495 extern volatile __bit RA5 @ (((unsigned) &PORTA)*8) + 5;
2496
2497 extern volatile __bit RCEN @ (((unsigned) &SSP1CON2)*8) + 3;
2498
2499 extern volatile __bit RCIDL @ (((unsigned) &BAUDCON)*8) + 6;
2500
2501 extern volatile __bit RCIE @ (((unsigned) &PIE1)*8) + 5;
2502
2503 extern volatile __bit RCIF @ (((unsigned) &PIR1)*8) + 5;
2504
2505 extern volatile __bit RD @ (((unsigned) &EECON1)*8) + 0;
2506
2507 extern volatile __bit RSEN @ (((unsigned) &SSP1CON2)*8) + 1;
2508
2509 extern volatile __bit RX9 @ (((unsigned) &RCSTA)*8) + 6;
2510
2511 extern volatile __bit RX9D @ (((unsigned) &RCSTA)*8) + 0;
2512
2513 extern volatile __bit RXDTSEL @ (((unsigned) &APFCON)*8) + 7;
2514
2515 extern volatile __bit R_nW @ (((unsigned) &SSP1STAT)*8) + 2;
2516
2517 extern volatile __bit SBCDE @ (((unsigned) &SSP1CON3)*8) + 2;
2518
2519 extern volatile __bit SBOREN @ (((unsigned) &BORCON)*8) + 7;
2520
2521 extern volatile __bit SCIE @ (((unsigned) &SSP1CON3)*8) + 5;
2522
2523 extern volatile __bit SCK @ (((unsigned) &PORTA)*8) + 1;
2524
2525 extern volatile __bit SCKP @ (((unsigned) &BAUDCON)*8) + 4;
2526
2527 extern volatile __bit SCL @ (((unsigned) &PORTA)*8) + 1;
2528
2529 extern volatile __bit SCS0 @ (((unsigned) &OSCCON)*8) + 0;
2530
2531 extern volatile __bit SCS1 @ (((unsigned) &OSCCON)*8) + 1;
2532
2533 extern volatile __bit SDA @ (((unsigned) &PORTA)*8) + 2;
2534
2535 extern volatile __bit SDAHT @ (((unsigned) &SSP1CON3)*8) + 3;
2536
2537 extern volatile __bit SDI @ (((unsigned) &PORTA)*8) + 2;
2538
2539 extern volatile __bit SDO1SEL @ (((unsigned) &APFCON)*8) + 6;
2540
2541 extern volatile __bit SDOSEL @ (((unsigned) &APFCON)*8) + 6;
2542
2543 extern volatile __bit SEN @ (((unsigned) &SSP1CON2)*8) + 0;
2544
2545 extern volatile __bit SENDB @ (((unsigned) &TXSTA)*8) + 3;
2546
2547 extern volatile __bit SMP @ (((unsigned) &SSP1STAT)*8) + 7;
2548
2549 extern volatile __bit SPEN @ (((unsigned) &RCSTA)*8) + 7;
2550
2551 extern volatile __bit SPLLEN @ (((unsigned) &OSCCON)*8) + 7;
2552
2553 extern volatile __bit SRCLK0 @ (((unsigned) &SRCON0)*8) + 4;
2554
2555 extern volatile __bit SRCLK1 @ (((unsigned) &SRCON0)*8) + 5;
2556
2557 extern volatile __bit SRCLK2 @ (((unsigned) &SRCON0)*8) + 6;
2558
2559 extern volatile __bit SREN @ (((unsigned) &RCSTA)*8) + 5;
2560
2561 extern volatile __bit SRI @ (((unsigned) &PORTA)*8) + 1;
2562
2563 extern volatile __bit SRLEN @ (((unsigned) &SRCON0)*8) + 7;
2564
2565 extern volatile __bit SRNQ @ (((unsigned) &PORTA)*8) + 5;
2566
2567 extern volatile __bit SRNQEN @ (((unsigned) &SRCON0)*8) + 2;
2568
2569 extern volatile __bit SRPR @ (((unsigned) &SRCON0)*8) + 0;
2570
2571 extern volatile __bit SRPS @ (((unsigned) &SRCON0)*8) + 1;
2572
2573 extern volatile __bit SRQ @ (((unsigned) &PORTA)*8) + 2;
2574
2575 extern volatile __bit SRQEN @ (((unsigned) &SRCON0)*8) + 3;
2576
2577 extern volatile __bit SRRC1E @ (((unsigned) &SRCON1)*8) + 0;
2578
2579 extern volatile __bit SRRCKE @ (((unsigned) &SRCON1)*8) + 2;
2580
2581 extern volatile __bit SRRPE @ (((unsigned) &SRCON1)*8) + 3;
2582
2583 extern volatile __bit SRSC1E @ (((unsigned) &SRCON1)*8) + 4;
2584
2585 extern volatile __bit SRSCKE @ (((unsigned) &SRCON1)*8) + 6;
2586
2587 extern volatile __bit SRSPE @ (((unsigned) &SRCON1)*8) + 7;
2588
2589 extern volatile __bit SS1SEL @ (((unsigned) &APFCON)*8) + 5;
2590
2591 extern volatile __bit SSP1IE @ (((unsigned) &PIE1)*8) + 3;
2592
2593 extern volatile __bit SSP1IF @ (((unsigned) &PIR1)*8) + 3;
2594
2595 extern volatile __bit SSPEN @ (((unsigned) &SSP1CON1)*8) + 5;
2596
2597 extern volatile __bit SSPM0 @ (((unsigned) &SSP1CON1)*8) + 0;
2598
2599 extern volatile __bit SSPM1 @ (((unsigned) &SSP1CON1)*8) + 1;
2600
2601 extern volatile __bit SSPM2 @ (((unsigned) &SSP1CON1)*8) + 2;
2602
2603 extern volatile __bit SSPM3 @ (((unsigned) &SSP1CON1)*8) + 3;
2604
2605 extern volatile __bit SSPOV @ (((unsigned) &SSP1CON1)*8) + 6;
2606
2607 extern volatile __bit SSSEL @ (((unsigned) &APFCON)*8) + 5;
2608
2609 extern volatile __bit STKOVF @ (((unsigned) &PCON)*8) + 7;
2610
2611 extern volatile __bit STKUNF @ (((unsigned) &PCON)*8) + 6;
2612
2613 extern volatile __bit STR1A @ (((unsigned) &PSTR1CON)*8) + 0;
2614
2615 extern volatile __bit STR1B @ (((unsigned) &PSTR1CON)*8) + 1;
2616
2617 extern volatile __bit STR1C @ (((unsigned) &PSTR1CON)*8) + 2;
2618
2619 extern volatile __bit STR1D @ (((unsigned) &PSTR1CON)*8) + 3;
2620
2621 extern volatile __bit STR1SYNC @ (((unsigned) &PSTR1CON)*8) + 4;
2622
2623 extern volatile __bit SWDTEN @ (((unsigned) &WDTCON)*8) + 0;
2624
2625 extern volatile __bit SYNC @ (((unsigned) &TXSTA)*8) + 4;
2626
2627 extern volatile __bit T0CKI @ (((unsigned) &PORTA)*8) + 2;
2628
2629 extern volatile __bit T0CS @ (((unsigned) &OPTION_REG)*8) + 5;
2630
2631 extern volatile __bit T0IE @ (((unsigned) &INTCON)*8) + 5;
2632
2633 extern volatile __bit T0IF @ (((unsigned) &INTCON)*8) + 2;
2634
2635 extern volatile __bit T0SE @ (((unsigned) &OPTION_REG)*8) + 4;
2636
2637 extern volatile __bit T0XCS @ (((unsigned) &CPSCON0)*8) + 0;
2638
2639 extern volatile __bit T1CKI @ (((unsigned) &PORTA)*8) + 5;
2640
2641 extern volatile __bit T1CKPS0 @ (((unsigned) &T1CON)*8) + 4;
2642
2643 extern volatile __bit T1CKPS1 @ (((unsigned) &T1CON)*8) + 5;
2644
2645 extern volatile __bit T1GGO @ (((unsigned) &T1GCON)*8) + 3;
2646
2647 extern volatile __bit T1GGO_nDONE @ (((unsigned) &T1GCON)*8) + 3;
2648
2649 extern volatile __bit T1GPOL @ (((unsigned) &T1GCON)*8) + 6;
2650
2651 extern volatile __bit T1GSEL @ (((unsigned) &APFCON)*8) + 3;
2652
2653 extern volatile __bit T1GSPM @ (((unsigned) &T1GCON)*8) + 4;
2654
2655 extern volatile __bit T1GSS0 @ (((unsigned) &T1GCON)*8) + 0;
2656
2657 extern volatile __bit T1GSS1 @ (((unsigned) &T1GCON)*8) + 1;
2658
2659 extern volatile __bit T1GTM @ (((unsigned) &T1GCON)*8) + 5;
2660
2661 extern volatile __bit T1GVAL @ (((unsigned) &T1GCON)*8) + 2;
2662
2663 extern volatile __bit T1OSCEN @ (((unsigned) &T1CON)*8) + 3;
2664
2665 extern volatile __bit T1OSCR @ (((unsigned) &OSCSTAT)*8) + 7;
2666
2667 extern volatile __bit T1OSI @ (((unsigned) &PORTA)*8) + 5;
2668
2669 extern volatile __bit T1OSO @ (((unsigned) &PORTA)*8) + 4;
2670
2671 extern volatile __bit T2CKPS0 @ (((unsigned) &T2CON)*8) + 0;
2672
2673 extern volatile __bit T2CKPS1 @ (((unsigned) &T2CON)*8) + 1;
2674
2675 extern volatile __bit T2OUTPS0 @ (((unsigned) &T2CON)*8) + 3;
2676
2677 extern volatile __bit T2OUTPS1 @ (((unsigned) &T2CON)*8) + 4;
2678
2679 extern volatile __bit T2OUTPS2 @ (((unsigned) &T2CON)*8) + 5;
2680
2681 extern volatile __bit T2OUTPS3 @ (((unsigned) &T2CON)*8) + 6;
2682
2683 extern volatile __bit TMR0CS @ (((unsigned) &OPTION_REG)*8) + 5;
2684
2685 extern volatile __bit TMR0IE @ (((unsigned) &INTCON)*8) + 5;
2686
2687 extern volatile __bit TMR0IF @ (((unsigned) &INTCON)*8) + 2;
2688
2689 extern volatile __bit TMR0SE @ (((unsigned) &OPTION_REG)*8) + 4;
2690
2691 extern volatile __bit TMR1CS0 @ (((unsigned) &T1CON)*8) + 6;
2692
2693 extern volatile __bit TMR1CS1 @ (((unsigned) &T1CON)*8) + 7;
2694
2695 extern volatile __bit TMR1GE @ (((unsigned) &T1GCON)*8) + 7;
2696
2697 extern volatile __bit TMR1GIE @ (((unsigned) &PIE1)*8) + 7;
2698
2699 extern volatile __bit TMR1GIF @ (((unsigned) &PIR1)*8) + 7;
2700
2701 extern volatile __bit TMR1IE @ (((unsigned) &PIE1)*8) + 0;
2702
2703 extern volatile __bit TMR1IF @ (((unsigned) &PIR1)*8) + 0;
2704
2705 extern volatile __bit TMR1ON @ (((unsigned) &T1CON)*8) + 0;
2706
2707 extern volatile __bit TMR2IE @ (((unsigned) &PIE1)*8) + 1;
2708
2709 extern volatile __bit TMR2IF @ (((unsigned) &PIR1)*8) + 1;
2710
2711 extern volatile __bit TMR2ON @ (((unsigned) &T2CON)*8) + 2;
2712
2713 extern volatile __bit TRISA0 @ (((unsigned) &TRISA)*8) + 0;
2714
2715 extern volatile __bit TRISA1 @ (((unsigned) &TRISA)*8) + 1;
2716
2717 extern volatile __bit TRISA2 @ (((unsigned) &TRISA)*8) + 2;
2718
2719 extern volatile __bit TRISA3 @ (((unsigned) &TRISA)*8) + 3;
2720
2721 extern volatile __bit TRISA4 @ (((unsigned) &TRISA)*8) + 4;
2722
2723 extern volatile __bit TRISA5 @ (((unsigned) &TRISA)*8) + 5;
2724
2725 extern volatile __bit TRMT @ (((unsigned) &TXSTA)*8) + 1;
2726
2727 extern volatile __bit TSEN @ (((unsigned) &FVRCON)*8) + 5;
2728
2729 extern volatile __bit TSRNG @ (((unsigned) &FVRCON)*8) + 4;
2730
2731 extern volatile __bit TUN0 @ (((unsigned) &OSCTUNE)*8) + 0;
2732
2733 extern volatile __bit TUN1 @ (((unsigned) &OSCTUNE)*8) + 1;
2734
2735 extern volatile __bit TUN2 @ (((unsigned) &OSCTUNE)*8) + 2;
2736
2737 extern volatile __bit TUN3 @ (((unsigned) &OSCTUNE)*8) + 3;
2738
2739 extern volatile __bit TUN4 @ (((unsigned) &OSCTUNE)*8) + 4;
2740
2741 extern volatile __bit TUN5 @ (((unsigned) &OSCTUNE)*8) + 5;
2742
2743 extern volatile __bit TX9 @ (((unsigned) &TXSTA)*8) + 6;
2744
2745 extern volatile __bit TX9D @ (((unsigned) &TXSTA)*8) + 0;
2746
2747 extern volatile __bit TXCKSEL @ (((unsigned) &APFCON)*8) + 2;
2748
2749 extern volatile __bit TXEN @ (((unsigned) &TXSTA)*8) + 5;
2750
2751 extern volatile __bit TXIE @ (((unsigned) &PIE1)*8) + 4;
2752
2753 extern volatile __bit TXIF @ (((unsigned) &PIR1)*8) + 4;
2754
2755 extern volatile __bit UA @ (((unsigned) &SSP1STAT)*8) + 1;
2756
2757 extern volatile __bit WCOL @ (((unsigned) &SSP1CON1)*8) + 7;
2758
2759 extern volatile __bit WDTPS0 @ (((unsigned) &WDTCON)*8) + 1;
2760
2761 extern volatile __bit WDTPS1 @ (((unsigned) &WDTCON)*8) + 2;
2762
2763 extern volatile __bit WDTPS2 @ (((unsigned) &WDTCON)*8) + 3;
2764
2765 extern volatile __bit WDTPS3 @ (((unsigned) &WDTCON)*8) + 4;
2766
2767 extern volatile __bit WDTPS4 @ (((unsigned) &WDTCON)*8) + 5;
2768
2769 extern volatile __bit WPUA0 @ (((unsigned) &WPUA)*8) + 0;
2770
2771 extern volatile __bit WPUA1 @ (((unsigned) &WPUA)*8) + 1;
2772
2773 extern volatile __bit WPUA2 @ (((unsigned) &WPUA)*8) + 2;
2774
2775 extern volatile __bit WPUA3 @ (((unsigned) &WPUA)*8) + 3;
2776
2777 extern volatile __bit WPUA4 @ (((unsigned) &WPUA)*8) + 4;
2778
2779 extern volatile __bit WPUA5 @ (((unsigned) &WPUA)*8) + 5;
2780
2781 extern volatile __bit WR @ (((unsigned) &EECON1)*8) + 1;
2782
2783 extern volatile __bit WREN @ (((unsigned) &EECON1)*8) + 2;
2784
2785 extern volatile __bit WRERR @ (((unsigned) &EECON1)*8) + 3;
2786
2787 extern volatile __bit WUE @ (((unsigned) &BAUDCON)*8) + 1;
2788
2789 extern volatile __bit ZERO @ (((unsigned) &STATUS)*8) + 2;
2790
2791 extern volatile __bit Z_SHAD @ (((unsigned) &STATUS_SHAD)*8) + 2;
2792
2793 extern volatile __bit nBOR @ (((unsigned) &PCON)*8) + 0;
2794
2795 extern volatile __bit nDONE @ (((unsigned) &ADCON0)*8) + 1;
2796
2797 extern volatile __bit nMCLR @ (((unsigned) &PORTA)*8) + 3;
2798
2799 extern volatile __bit nPD @ (((unsigned) &STATUS)*8) + 3;
2800
2801 extern volatile __bit nPOR @ (((unsigned) &PCON)*8) + 1;
2802
2803 extern volatile __bit nRI @ (((unsigned) &PCON)*8) + 2;
2804
2805 extern volatile __bit nRMCLR @ (((unsigned) &PCON)*8) + 3;
2806
2807 extern volatile __bit nT1SYNC @ (((unsigned) &T1CON)*8) + 2;
2808
2809 extern volatile __bit nTO @ (((unsigned) &STATUS)*8) + 4;
2810
2811 extern volatile __bit nWPUEN @ (((unsigned) &OPTION_REG)*8) + 7;
2812
2813
2814 # 27 "/opt/microchip/xc8/v1.12/include/pic.h"
2815 #pragma intrinsic(_nop)
2816 extern void _nop(void);
2817
2818 # 77
2819 extern unsigned int flash_read(unsigned short addr);
2820
2821 # 41 "/opt/microchip/xc8/v1.12/include/eeprom_routines.h"
2822 extern void eeprom_write(unsigned char addr, unsigned char value);
2823 extern unsigned char eeprom_read(unsigned char addr);
2824 extern void eecpymem(volatile unsigned char *to, __eeprom unsigned char *from, unsigned char size);
2825 extern void memcpyee(__eeprom unsigned char *to, const unsigned char *from, unsigned char size);
2826
2827
2828 # 150 "/opt/microchip/xc8/v1.12/include/pic.h"
2829 #pragma intrinsic(_delay)
2830 extern void _delay(unsigned long);
2831
2832 # 13 "/opt/microchip/xc8/v1.12/include/stdint.h"
2833 typedef signed char int8_t;
2834
2835 # 20
2836 typedef signed int int16_t;
2837
2838 # 28
2839 typedef signed short long int int24_t;
2840
2841 # 36
2842 typedef signed long int int32_t;
2843
2844 # 43
2845 typedef unsigned char uint8_t;
2846
2847 # 49
2848 typedef unsigned int uint16_t;
2849
2850 # 56
2851 typedef unsigned short long int uint24_t;
2852
2853 # 63
2854 typedef unsigned long int uint32_t;
2855
2856 # 71
2857 typedef signed char int_least8_t;
2858
2859 # 78
2860 typedef signed int int_least16_t;
2861
2862 # 90
2863 typedef signed short long int int_least24_t;
2864
2865 # 98
2866 typedef signed long int int_least32_t;
2867
2868 # 105
2869 typedef unsigned char uint_least8_t;
2870
2871 # 111
2872 typedef unsigned int uint_least16_t;
2873
2874 # 121
2875 typedef unsigned short long int uint_least24_t;
2876
2877 # 128
2878 typedef unsigned long int uint_least32_t;
2879
2880 # 137
2881 typedef signed char int_fast8_t;
2882
2883 # 144
2884 typedef signed int int_fast16_t;
2885
2886 # 156
2887 typedef signed short long int int_fast24_t;
2888
2889 # 164
2890 typedef signed long int int_fast32_t;
2891
2892 # 171
2893 typedef unsigned char uint_fast8_t;
2894
2895 # 177
2896 typedef unsigned int uint_fast16_t;
2897
2898 # 187
2899 typedef unsigned short long int uint_fast24_t;
2900
2901 # 194
2902 typedef unsigned long int uint_fast32_t;
2903
2904 # 200
2905 typedef int32_t intmax_t;
2906
2907
2908
2909
2910 typedef uint32_t uintmax_t;
2911
2912
2913
2914
2915 typedef int16_t intptr_t;
2916
2917
2918
2919
2920 typedef uint16_t uintptr_t;
2921
2922 # 12 "/opt/microchip/xc8/v1.12/include/stdbool.h"
2923 typedef unsigned char bool;
2924
2925 # 44 "/opt/microchip/xc8/v1.12/include/pic12f1840.h"
2926 extern volatile unsigned char INDF0 @ 0x000;
2927
2928 asm("INDF0 equ 00h");
2929
2930
2931 typedef union {
2932 struct {
2933 unsigned INDF0 :8;
2934 };
2935 } INDF0bits_t;
2936 extern volatile INDF0bits_t INDF0bits @ 0x000;
2937
2938 # 63
2939 extern volatile unsigned char INDF1 @ 0x001;
2940
2941 asm("INDF1 equ 01h");
2942
2943
2944 typedef union {
2945 struct {
2946 unsigned INDF1 :8;
2947 };
2948 } INDF1bits_t;
2949 extern volatile INDF1bits_t INDF1bits @ 0x001;
2950
2951 # 82
2952 extern volatile unsigned char PCL @ 0x002;
2953
2954 asm("PCL equ 02h");
2955
2956
2957 typedef union {
2958 struct {
2959 unsigned PCL :8;
2960 };
2961 } PCLbits_t;
2962 extern volatile PCLbits_t PCLbits @ 0x002;
2963
2964 # 101
2965 extern volatile unsigned char STATUS @ 0x003;
2966
2967 asm("STATUS equ 03h");
2968
2969
2970 typedef union {
2971 struct {
2972 unsigned C :1;
2973 unsigned DC :1;
2974 unsigned Z :1;
2975 unsigned nPD :1;
2976 unsigned nTO :1;
2977 };
2978 struct {
2979 unsigned CARRY :1;
2980 };
2981 struct {
2982 unsigned :2;
2983 unsigned ZERO :1;
2984 };
2985 } STATUSbits_t;
2986 extern volatile STATUSbits_t STATUSbits @ 0x003;
2987
2988 # 161
2989 extern volatile unsigned short FSR0 @ 0x004;
2990
2991
2992 extern volatile unsigned char FSR0L @ 0x004;
2993
2994 asm("FSR0L equ 04h");
2995
2996
2997 typedef union {
2998 struct {
2999 unsigned FSR0L :8;
3000 };
3001 } FSR0Lbits_t;
3002 extern volatile FSR0Lbits_t FSR0Lbits @ 0x004;
3003
3004 # 183
3005 extern volatile unsigned char FSR0H @ 0x005;
3006
3007 asm("FSR0H equ 05h");
3008
3009
3010 typedef union {
3011 struct {
3012 unsigned FSR0H :8;
3013 };
3014 } FSR0Hbits_t;
3015 extern volatile FSR0Hbits_t FSR0Hbits @ 0x005;
3016
3017 # 202
3018 extern volatile unsigned short FSR1 @ 0x006;
3019
3020
3021 extern volatile unsigned char FSR1L @ 0x006;
3022
3023 asm("FSR1L equ 06h");
3024
3025
3026 typedef union {
3027 struct {
3028 unsigned FSR1L :8;
3029 };
3030 } FSR1Lbits_t;
3031 extern volatile FSR1Lbits_t FSR1Lbits @ 0x006;
3032
3033 # 224
3034 extern volatile unsigned char FSR1H @ 0x007;
3035
3036 asm("FSR1H equ 07h");
3037
3038
3039 typedef union {
3040 struct {
3041 unsigned FSR1H :8;
3042 };
3043 } FSR1Hbits_t;
3044 extern volatile FSR1Hbits_t FSR1Hbits @ 0x007;
3045
3046 # 243
3047 extern volatile unsigned char BSR @ 0x008;
3048
3049 asm("BSR equ 08h");
3050
3051
3052 typedef union {
3053 struct {
3054 unsigned BSR0 :1;
3055 unsigned BSR1 :1;
3056 unsigned BSR2 :1;
3057 unsigned BSR3 :1;
3058 unsigned BSR4 :1;
3059 };
3060 struct {
3061 unsigned BSR :5;
3062 };
3063 } BSRbits_t;
3064 extern volatile BSRbits_t BSRbits @ 0x008;
3065
3066 # 294
3067 extern volatile unsigned char WREG @ 0x009;
3068
3069 asm("WREG equ 09h");
3070
3071
3072 typedef union {
3073 struct {
3074 unsigned WREG0 :8;
3075 };
3076 } WREGbits_t;
3077 extern volatile WREGbits_t WREGbits @ 0x009;
3078
3079 # 313
3080 extern volatile unsigned char PCLATH @ 0x00A;
3081
3082 asm("PCLATH equ 0Ah");
3083
3084
3085 typedef union {
3086 struct {
3087 unsigned PCLATH :7;
3088 };
3089 } PCLATHbits_t;
3090 extern volatile PCLATHbits_t PCLATHbits @ 0x00A;
3091
3092 # 332
3093 extern volatile unsigned char INTCON @ 0x00B;
3094
3095 asm("INTCON equ 0Bh");
3096
3097
3098 typedef union {
3099 struct {
3100 unsigned IOCIF :1;
3101 unsigned INTF :1;
3102 unsigned TMR0IF :1;
3103 unsigned IOCIE :1;
3104 unsigned INTE :1;
3105 unsigned TMR0IE :1;
3106 unsigned PEIE :1;
3107 unsigned GIE :1;
3108 };
3109 struct {
3110 unsigned :2;
3111 unsigned T0IF :1;
3112 unsigned :2;
3113 unsigned T0IE :1;
3114 };
3115 } INTCONbits_t;
3116 extern volatile INTCONbits_t INTCONbits @ 0x00B;
3117
3118 # 409
3119 extern volatile unsigned char PORTA @ 0x00C;
3120
3121 asm("PORTA equ 0Ch");
3122
3123
3124 typedef union {
3125 struct {
3126 unsigned RA0 :1;
3127 unsigned RA1 :1;
3128 unsigned RA2 :1;
3129 unsigned RA3 :1;
3130 unsigned RA4 :1;
3131 unsigned RA5 :1;
3132 };
3133 } PORTAbits_t;
3134 extern volatile PORTAbits_t PORTAbits @ 0x00C;
3135
3136 # 458
3137 extern volatile unsigned char PIR1 @ 0x011;
3138
3139 asm("PIR1 equ 011h");
3140
3141
3142 typedef union {
3143 struct {
3144 unsigned TMR1IF :1;
3145 unsigned TMR2IF :1;
3146 unsigned CCP1IF :1;
3147 unsigned SSP1IF :1;
3148 unsigned TXIF :1;
3149 unsigned RCIF :1;
3150 unsigned ADIF :1;
3151 unsigned TMR1GIF :1;
3152 };
3153 } PIR1bits_t;
3154 extern volatile PIR1bits_t PIR1bits @ 0x011;
3155
3156 # 519
3157 extern volatile unsigned char PIR2 @ 0x012;
3158
3159 asm("PIR2 equ 012h");
3160
3161
3162 typedef union {
3163 struct {
3164 unsigned :3;
3165 unsigned BCL1IF :1;
3166 unsigned EEIF :1;
3167 unsigned C1IF :1;
3168 unsigned :1;
3169 unsigned OSFIF :1;
3170 };
3171 } PIR2bits_t;
3172 extern volatile PIR2bits_t PIR2bits @ 0x012;
3173
3174 # 558
3175 extern volatile unsigned char TMR0 @ 0x015;
3176
3177 asm("TMR0 equ 015h");
3178
3179
3180 typedef union {
3181 struct {
3182 unsigned TMR0 :8;
3183 };
3184 } TMR0bits_t;
3185 extern volatile TMR0bits_t TMR0bits @ 0x015;
3186
3187 # 577
3188 extern volatile unsigned short TMR1 @ 0x016;
3189
3190 asm("TMR1 equ 016h");
3191
3192
3193
3194 extern volatile unsigned char TMR1L @ 0x016;
3195
3196 asm("TMR1L equ 016h");
3197
3198
3199 typedef union {
3200 struct {
3201 unsigned TMR1L :8;
3202 };
3203 } TMR1Lbits_t;
3204 extern volatile TMR1Lbits_t TMR1Lbits @ 0x016;
3205
3206 # 602
3207 extern volatile unsigned char TMR1H @ 0x017;
3208
3209 asm("TMR1H equ 017h");
3210
3211
3212 typedef union {
3213 struct {
3214 unsigned TMR1H :8;
3215 };
3216 } TMR1Hbits_t;
3217 extern volatile TMR1Hbits_t TMR1Hbits @ 0x017;
3218
3219 # 621
3220 extern volatile unsigned char T1CON @ 0x018;
3221
3222 asm("T1CON equ 018h");
3223
3224
3225 typedef union {
3226 struct {
3227 unsigned TMR1ON :1;
3228 unsigned :1;
3229 unsigned nT1SYNC :1;
3230 unsigned T1OSCEN :1;
3231 unsigned T1CKPS0 :1;
3232 unsigned T1CKPS1 :1;
3233 unsigned TMR1CS0 :1;
3234 unsigned TMR1CS1 :1;
3235 };
3236 struct {
3237 unsigned :4;
3238 unsigned T1CKPS :2;
3239 unsigned TMR1CS :2;
3240 };
3241 } T1CONbits_t;
3242 extern volatile T1CONbits_t T1CONbits @ 0x018;
3243
3244 # 692
3245 extern volatile unsigned char T1GCON @ 0x019;
3246
3247 asm("T1GCON equ 019h");
3248
3249
3250 typedef union {
3251 struct {
3252 unsigned T1GSS0 :1;
3253 unsigned T1GSS1 :1;
3254 unsigned T1GVAL :1;
3255 unsigned T1GGO_nDONE :1;
3256 unsigned T1GSPM :1;
3257 unsigned T1GTM :1;
3258 unsigned T1GPOL :1;
3259 unsigned TMR1GE :1;
3260 };
3261 struct {
3262 unsigned T1GSS :2;
3263 unsigned :1;
3264 unsigned T1GGO :1;
3265 };
3266 } T1GCONbits_t;
3267 extern volatile T1GCONbits_t T1GCONbits @ 0x019;
3268
3269 # 768
3270 extern volatile unsigned char TMR2 @ 0x01A;
3271
3272 asm("TMR2 equ 01Ah");
3273
3274
3275 typedef union {
3276 struct {
3277 unsigned TMR2 :8;
3278 };
3279 } TMR2bits_t;
3280 extern volatile TMR2bits_t TMR2bits @ 0x01A;
3281
3282 # 787
3283 extern volatile unsigned char PR2 @ 0x01B;
3284
3285 asm("PR2 equ 01Bh");
3286
3287
3288 typedef union {
3289 struct {
3290 unsigned PR2 :8;
3291 };
3292 } PR2bits_t;
3293 extern volatile PR2bits_t PR2bits @ 0x01B;
3294
3295 # 806
3296 extern volatile unsigned char T2CON @ 0x01C;
3297
3298 asm("T2CON equ 01Ch");
3299
3300
3301 typedef union {
3302 struct {
3303 unsigned T2CKPS0 :1;
3304 unsigned T2CKPS1 :1;
3305 unsigned TMR2ON :1;
3306 unsigned T2OUTPS0 :1;
3307 unsigned T2OUTPS1 :1;
3308 unsigned T2OUTPS2 :1;
3309 unsigned T2OUTPS3 :1;
3310 };
3311 struct {
3312 unsigned T2CKPS :2;
3313 unsigned :1;
3314 unsigned T2OUTPS :4;
3315 };
3316 } T2CONbits_t;
3317 extern volatile T2CONbits_t T2CONbits @ 0x01C;
3318
3319 # 876
3320 extern volatile unsigned char CPSCON0 @ 0x01E;
3321
3322 asm("CPSCON0 equ 01Eh");
3323
3324
3325 typedef union {
3326 struct {
3327 unsigned T0XCS :1;
3328 unsigned CPSOUT :1;
3329 unsigned CPSRNG0 :1;
3330 unsigned CPSRNG1 :1;
3331 unsigned :2;
3332 unsigned CPSRM :1;
3333 unsigned CPSON :1;
3334 };
3335 struct {
3336 unsigned :2;
3337 unsigned CPSRNG :2;
3338 };
3339 } CPSCON0bits_t;
3340 extern volatile CPSCON0bits_t CPSCON0bits @ 0x01E;
3341
3342 # 935
3343 extern volatile unsigned char CPSCON1 @ 0x01F;
3344
3345 asm("CPSCON1 equ 01Fh");
3346
3347
3348 typedef union {
3349 struct {
3350 unsigned CPSCH0 :1;
3351 unsigned CPSCH1 :1;
3352 };
3353 struct {
3354 unsigned CPSCH :2;
3355 };
3356 } CPSCON1bits_t;
3357 extern volatile CPSCON1bits_t CPSCON1bits @ 0x01F;
3358
3359 # 968
3360 extern volatile unsigned char TRISA @ 0x08C;
3361
3362 asm("TRISA equ 08Ch");
3363
3364
3365 typedef union {
3366 struct {
3367 unsigned TRISA0 :1;
3368 unsigned TRISA1 :1;
3369 unsigned TRISA2 :1;
3370 unsigned TRISA3 :1;
3371 unsigned TRISA4 :1;
3372 unsigned TRISA5 :1;
3373 };
3374 } TRISAbits_t;
3375 extern volatile TRISAbits_t TRISAbits @ 0x08C;
3376
3377 # 1017
3378 extern volatile unsigned char PIE1 @ 0x091;
3379
3380 asm("PIE1 equ 091h");
3381
3382
3383 typedef union {
3384 struct {
3385 unsigned TMR1IE :1;
3386 unsigned TMR2IE :1;
3387 unsigned CCP1IE :1;
3388 unsigned SSP1IE :1;
3389 unsigned TXIE :1;
3390 unsigned RCIE :1;
3391 unsigned ADIE :1;
3392 unsigned TMR1GIE :1;
3393 };
3394 } PIE1bits_t;
3395 extern volatile PIE1bits_t PIE1bits @ 0x091;
3396
3397 # 1078
3398 extern volatile unsigned char PIE2 @ 0x092;
3399
3400 asm("PIE2 equ 092h");
3401
3402
3403 typedef union {
3404 struct {
3405 unsigned :3;
3406 unsigned BCL1IE :1;
3407 unsigned EEIE :1;
3408 unsigned C1IE :1;
3409 unsigned :1;
3410 unsigned OSFIE :1;
3411 };
3412 } PIE2bits_t;
3413 extern volatile PIE2bits_t PIE2bits @ 0x092;
3414
3415 # 1117
3416 extern volatile unsigned char OPTION_REG @ 0x095;
3417
3418 asm("OPTION_REG equ 095h");
3419
3420
3421 typedef union {
3422 struct {
3423 unsigned PS0 :1;
3424 unsigned PS1 :1;
3425 unsigned PS2 :1;
3426 unsigned PSA :1;
3427 unsigned TMR0SE :1;
3428 unsigned TMR0CS :1;
3429 unsigned INTEDG :1;
3430 unsigned nWPUEN :1;
3431 };
3432 struct {
3433 unsigned PS :3;
3434 unsigned :1;
3435 unsigned T0SE :1;
3436 unsigned T0CS :1;
3437 };
3438 } OPTION_REGbits_t;
3439 extern volatile OPTION_REGbits_t OPTION_REGbits @ 0x095;
3440
3441 # 1199
3442 extern volatile unsigned char PCON @ 0x096;
3443
3444 asm("PCON equ 096h");
3445
3446
3447 typedef union {
3448 struct {
3449 unsigned nBOR :1;
3450 unsigned nPOR :1;
3451 unsigned nRI :1;
3452 unsigned nRMCLR :1;
3453 unsigned :2;
3454 unsigned STKUNF :1;
3455 unsigned STKOVF :1;
3456 };
3457 } PCONbits_t;
3458 extern volatile PCONbits_t PCONbits @ 0x096;
3459
3460 # 1249
3461 extern volatile unsigned char WDTCON @ 0x097;
3462
3463 asm("WDTCON equ 097h");
3464
3465
3466 typedef union {
3467 struct {
3468 unsigned SWDTEN :1;
3469 unsigned WDTPS0 :1;
3470 unsigned WDTPS1 :1;
3471 unsigned WDTPS2 :1;
3472 unsigned WDTPS3 :1;
3473 unsigned WDTPS4 :1;
3474 };
3475 struct {
3476 unsigned :1;
3477 unsigned WDTPS :5;
3478 };
3479 } WDTCONbits_t;
3480 extern volatile WDTCONbits_t WDTCONbits @ 0x097;
3481
3482 # 1307
3483 extern volatile unsigned char OSCTUNE @ 0x098;
3484
3485 asm("OSCTUNE equ 098h");
3486
3487
3488 typedef union {
3489 struct {
3490 unsigned TUN0 :1;
3491 unsigned TUN1 :1;
3492 unsigned TUN2 :1;
3493 unsigned TUN3 :1;
3494 unsigned TUN4 :1;
3495 unsigned TUN5 :1;
3496 };
3497 struct {
3498 unsigned TUN :6;
3499 };
3500 } OSCTUNEbits_t;
3501 extern volatile OSCTUNEbits_t OSCTUNEbits @ 0x098;
3502
3503 # 1364
3504 extern volatile unsigned char OSCCON @ 0x099;
3505
3506 asm("OSCCON equ 099h");
3507
3508
3509 typedef union {
3510 struct {
3511 unsigned SCS0 :1;
3512 unsigned SCS1 :1;
3513 unsigned :1;
3514 unsigned IRCF0 :1;
3515 unsigned IRCF1 :1;
3516 unsigned IRCF2 :1;
3517 unsigned IRCF3 :1;
3518 unsigned SPLLEN :1;
3519 };
3520 struct {
3521 unsigned SCS :2;
3522 unsigned :1;
3523 unsigned IRCF :4;
3524 };
3525 } OSCCONbits_t;
3526 extern volatile OSCCONbits_t OSCCONbits @ 0x099;
3527
3528 # 1435
3529 extern volatile unsigned char OSCSTAT @ 0x09A;
3530
3531 asm("OSCSTAT equ 09Ah");
3532
3533
3534 typedef union {
3535 struct {
3536 unsigned HFIOFS :1;
3537 unsigned LFIOFR :1;
3538 unsigned MFIOFR :1;
3539 unsigned HFIOFL :1;
3540 unsigned HFIOFR :1;
3541 unsigned OSTS :1;
3542 unsigned PLLR :1;
3543 unsigned T1OSCR :1;
3544 };
3545 } OSCSTATbits_t;
3546 extern volatile OSCSTATbits_t OSCSTATbits @ 0x09A;
3547
3548 # 1496
3549 extern volatile unsigned short ADRES @ 0x09B;
3550
3551 asm("ADRES equ 09Bh");
3552
3553
3554
3555 extern volatile unsigned char ADRESL @ 0x09B;
3556
3557 asm("ADRESL equ 09Bh");
3558
3559
3560 typedef union {
3561 struct {
3562 unsigned ADRESL :8;
3563 };
3564 } ADRESLbits_t;
3565 extern volatile ADRESLbits_t ADRESLbits @ 0x09B;
3566
3567 # 1521
3568 extern volatile unsigned char ADRESH @ 0x09C;
3569
3570 asm("ADRESH equ 09Ch");
3571
3572
3573 typedef union {
3574 struct {
3575 unsigned ADRESH :8;
3576 };
3577 } ADRESHbits_t;
3578 extern volatile ADRESHbits_t ADRESHbits @ 0x09C;
3579
3580 # 1540
3581 extern volatile unsigned char ADCON0 @ 0x09D;
3582
3583 asm("ADCON0 equ 09Dh");
3584
3585
3586 typedef union {
3587 struct {
3588 unsigned ADON :1;
3589 unsigned GO_nDONE :1;
3590 unsigned CHS0 :1;
3591 unsigned CHS1 :1;
3592 unsigned CHS2 :1;
3593 unsigned CHS3 :1;
3594 unsigned CHS4 :1;
3595 };
3596 struct {
3597 unsigned :1;
3598 unsigned ADGO :1;
3599 unsigned CHS :5;
3600 };
3601 struct {
3602 unsigned :1;
3603 unsigned GO :1;
3604 };
3605 } ADCON0bits_t;
3606 extern volatile ADCON0bits_t ADCON0bits @ 0x09D;
3607
3608 # 1619
3609 extern volatile unsigned char ADCON1 @ 0x09E;
3610
3611 asm("ADCON1 equ 09Eh");
3612
3613
3614 typedef union {
3615 struct {
3616 unsigned ADPREF0 :1;
3617 unsigned ADPREF1 :1;
3618 unsigned :2;
3619 unsigned ADCS0 :1;
3620 unsigned ADCS1 :1;
3621 unsigned ADCS2 :1;
3622 unsigned ADFM :1;
3623 };
3624 struct {
3625 unsigned ADPREF :2;
3626 unsigned :2;
3627 unsigned ADCS :3;
3628 };
3629 } ADCON1bits_t;
3630 extern volatile ADCON1bits_t ADCON1bits @ 0x09E;
3631
3632 # 1684
3633 extern volatile unsigned char LATA @ 0x10C;
3634
3635 asm("LATA equ 010Ch");
3636
3637
3638 typedef union {
3639 struct {
3640 unsigned LATA0 :1;
3641 unsigned LATA1 :1;
3642 unsigned LATA2 :1;
3643 unsigned :1;
3644 unsigned LATA4 :1;
3645 unsigned LATA5 :1;
3646 };
3647 } LATAbits_t;
3648 extern volatile LATAbits_t LATAbits @ 0x10C;
3649
3650 # 1728
3651 extern volatile unsigned char CM1CON0 @ 0x111;
3652
3653 asm("CM1CON0 equ 0111h");
3654
3655
3656 typedef union {
3657 struct {
3658 unsigned C1SYNC :1;
3659 unsigned C1HYS :1;
3660 unsigned C1SP :1;
3661 unsigned :1;
3662 unsigned C1POL :1;
3663 unsigned C1OE :1;
3664 unsigned C1OUT :1;
3665 unsigned C1ON :1;
3666 };
3667 } CM1CON0bits_t;
3668 extern volatile CM1CON0bits_t CM1CON0bits @ 0x111;
3669
3670 # 1784
3671 extern volatile unsigned char CM1CON1 @ 0x112;
3672
3673 asm("CM1CON1 equ 0112h");
3674
3675
3676 typedef union {
3677 struct {
3678 unsigned C1NCH :1;
3679 unsigned :3;
3680 unsigned C1PCH0 :1;
3681 unsigned C1PCH1 :1;
3682 unsigned C1INTN :1;
3683 unsigned C1INTP :1;
3684 };
3685 struct {
3686 unsigned C1NCH0 :1;
3687 unsigned :3;
3688 unsigned C1PCH :2;
3689 };
3690 } CM1CON1bits_t;
3691 extern volatile CM1CON1bits_t CM1CON1bits @ 0x112;
3692
3693 # 1843
3694 extern volatile unsigned char CMOUT @ 0x115;
3695
3696 asm("CMOUT equ 0115h");
3697
3698
3699 typedef union {
3700 struct {
3701 unsigned MC1OUT :1;
3702 };
3703 } CMOUTbits_t;
3704 extern volatile CMOUTbits_t CMOUTbits @ 0x115;
3705
3706 # 1862
3707 extern volatile unsigned char BORCON @ 0x116;
3708
3709 asm("BORCON equ 0116h");
3710
3711
3712 typedef union {
3713 struct {
3714 unsigned BORRDY :1;
3715 unsigned :5;
3716 unsigned BORFS :1;
3717 unsigned SBOREN :1;
3718 };
3719 } BORCONbits_t;
3720 extern volatile BORCONbits_t BORCONbits @ 0x116;
3721
3722 # 1894
3723 extern volatile unsigned char FVRCON @ 0x117;
3724
3725 asm("FVRCON equ 0117h");
3726
3727
3728 typedef union {
3729 struct {
3730 unsigned ADFVR0 :1;
3731 unsigned ADFVR1 :1;
3732 unsigned CDAFVR0 :1;
3733 unsigned CDAFVR1 :1;
3734 unsigned TSRNG :1;
3735 unsigned TSEN :1;
3736 unsigned FVRRDY :1;
3737 unsigned FVREN :1;
3738 };
3739 struct {
3740 unsigned ADFVR :2;
3741 unsigned CDAFVR :2;
3742 };
3743 } FVRCONbits_t;
3744 extern volatile FVRCONbits_t FVRCONbits @ 0x117;
3745
3746 # 1969
3747 extern volatile unsigned char DACCON0 @ 0x118;
3748
3749 asm("DACCON0 equ 0118h");
3750
3751
3752 typedef union {
3753 struct {
3754 unsigned :2;
3755 unsigned DACPSS0 :1;
3756 unsigned DACPSS1 :1;
3757 unsigned :1;
3758 unsigned DACOE :1;
3759 unsigned DACLPS :1;
3760 unsigned DACEN :1;
3761 };
3762 struct {
3763 unsigned :2;
3764 unsigned DACPSS :2;
3765 };
3766 } DACCON0bits_t;
3767 extern volatile DACCON0bits_t DACCON0bits @ 0x118;
3768
3769 # 2023
3770 extern volatile unsigned char DACCON1 @ 0x119;
3771
3772 asm("DACCON1 equ 0119h");
3773
3774
3775 typedef union {
3776 struct {
3777 unsigned DACR0 :1;
3778 unsigned DACR1 :1;
3779 unsigned DACR2 :1;
3780 unsigned DACR3 :1;
3781 unsigned DACR4 :1;
3782 };
3783 struct {
3784 unsigned DACR :5;
3785 };
3786 } DACCON1bits_t;
3787 extern volatile DACCON1bits_t DACCON1bits @ 0x119;
3788
3789 # 2074
3790 extern volatile unsigned char SRCON0 @ 0x11A;
3791
3792 asm("SRCON0 equ 011Ah");
3793
3794
3795 typedef union {
3796 struct {
3797 unsigned SRPR :1;
3798 unsigned SRPS :1;
3799 unsigned SRNQEN :1;
3800 unsigned SRQEN :1;
3801 unsigned SRCLK0 :1;
3802 unsigned SRCLK1 :1;
3803 unsigned SRCLK2 :1;
3804 unsigned SRLEN :1;
3805 };
3806 struct {
3807 unsigned :4;
3808 unsigned SRCLK :3;
3809 };
3810 } SRCON0bits_t;
3811 extern volatile SRCON0bits_t SRCON0bits @ 0x11A;
3812
3813 # 2144
3814 extern volatile unsigned char SRCON1 @ 0x11B;
3815
3816 asm("SRCON1 equ 011Bh");
3817
3818
3819 typedef union {
3820 struct {
3821 unsigned SRRC1E :1;
3822 unsigned :1;
3823 unsigned SRRCKE :1;
3824 unsigned SRRPE :1;
3825 unsigned SRSC1E :1;
3826 unsigned :1;
3827 unsigned SRSCKE :1;
3828 unsigned SRSPE :1;
3829 };
3830 } SRCON1bits_t;
3831 extern volatile SRCON1bits_t SRCON1bits @ 0x11B;
3832
3833 # 2195
3834 extern volatile unsigned char APFCON @ 0x11D;
3835
3836 asm("APFCON equ 011Dh");
3837
3838
3839 extern volatile unsigned char APFCON0 @ 0x11D;
3840
3841 asm("APFCON0 equ 011Dh");
3842
3843
3844 typedef union {
3845 struct {
3846 unsigned CCP1SEL :1;
3847 unsigned P1BSEL :1;
3848 unsigned TXCKSEL :1;
3849 unsigned T1GSEL :1;
3850 unsigned :1;
3851 unsigned SSSEL :1;
3852 unsigned SDOSEL :1;
3853 unsigned RXDTSEL :1;
3854 };
3855 struct {
3856 unsigned :5;
3857 unsigned SS1SEL :1;
3858 unsigned SDO1SEL :1;
3859 };
3860 } APFCONbits_t;
3861 extern volatile APFCONbits_t APFCONbits @ 0x11D;
3862
3863 # 2270
3864 typedef union {
3865 struct {
3866 unsigned CCP1SEL :1;
3867 unsigned P1BSEL :1;
3868 unsigned TXCKSEL :1;
3869 unsigned T1GSEL :1;
3870 unsigned :1;
3871 unsigned SSSEL :1;
3872 unsigned SDOSEL :1;
3873 unsigned RXDTSEL :1;
3874 };
3875 struct {
3876 unsigned :5;
3877 unsigned SS1SEL :1;
3878 unsigned SDO1SEL :1;
3879 };
3880 } APFCON0bits_t;
3881 extern volatile APFCON0bits_t APFCON0bits @ 0x11D;
3882
3883 # 2336
3884 extern volatile unsigned char ANSELA @ 0x18C;
3885
3886 asm("ANSELA equ 018Ch");
3887
3888
3889 typedef union {
3890 struct {
3891 unsigned ANSA0 :1;
3892 unsigned ANSA1 :1;
3893 unsigned ANSA2 :1;
3894 unsigned :1;
3895 unsigned ANSA4 :1;
3896 };
3897 struct {
3898 unsigned ANSELA :5;
3899 };
3900 } ANSELAbits_t;
3901 extern volatile ANSELAbits_t ANSELAbits @ 0x18C;
3902
3903 # 2382
3904 extern volatile unsigned short EEADR @ 0x191;
3905
3906 asm("EEADR equ 0191h");
3907
3908
3909
3910 extern volatile unsigned char EEADRL @ 0x191;
3911
3912 asm("EEADRL equ 0191h");
3913
3914
3915 typedef union {
3916 struct {
3917 unsigned EEADRL :8;
3918 };
3919 } EEADRLbits_t;
3920 extern volatile EEADRLbits_t EEADRLbits @ 0x191;
3921
3922 # 2407
3923 extern volatile unsigned char EEADRH @ 0x192;
3924
3925 asm("EEADRH equ 0192h");
3926
3927
3928 typedef union {
3929 struct {
3930 unsigned EEADRH :7;
3931 };
3932 } EEADRHbits_t;
3933 extern volatile EEADRHbits_t EEADRHbits @ 0x192;
3934
3935 # 2426
3936 extern volatile unsigned short EEDAT @ 0x193;
3937
3938 asm("EEDAT equ 0193h");
3939
3940
3941
3942 extern volatile unsigned char EEDATL @ 0x193;
3943
3944 asm("EEDATL equ 0193h");
3945
3946
3947 extern volatile unsigned char EEDATA @ 0x193;
3948
3949 asm("EEDATA equ 0193h");
3950
3951
3952 typedef union {
3953 struct {
3954 unsigned EEDATL :8;
3955 };
3956 } EEDATLbits_t;
3957 extern volatile EEDATLbits_t EEDATLbits @ 0x193;
3958
3959 # 2455
3960 typedef union {
3961 struct {
3962 unsigned EEDATL :8;
3963 };
3964 } EEDATAbits_t;
3965 extern volatile EEDATAbits_t EEDATAbits @ 0x193;
3966
3967 # 2469
3968 extern volatile unsigned char EEDATH @ 0x194;
3969
3970 asm("EEDATH equ 0194h");
3971
3972
3973 typedef union {
3974 struct {
3975 unsigned EEDATH :6;
3976 };
3977 } EEDATHbits_t;
3978 extern volatile EEDATHbits_t EEDATHbits @ 0x194;
3979
3980 # 2488
3981 extern volatile unsigned char EECON1 @ 0x195;
3982
3983 asm("EECON1 equ 0195h");
3984
3985
3986 typedef union {
3987 struct {
3988 unsigned RD :1;
3989 unsigned WR :1;
3990 unsigned WREN :1;
3991 unsigned WRERR :1;
3992 unsigned FREE :1;
3993 unsigned LWLO :1;
3994 unsigned CFGS :1;
3995 unsigned EEPGD :1;
3996 };
3997 } EECON1bits_t;
3998 extern volatile EECON1bits_t EECON1bits @ 0x195;
3999
4000 # 2549
4001 extern volatile unsigned char EECON2 @ 0x196;
4002
4003 asm("EECON2 equ 0196h");
4004
4005
4006 typedef union {
4007 struct {
4008 unsigned EECON2 :8;
4009 };
4010 } EECON2bits_t;
4011 extern volatile EECON2bits_t EECON2bits @ 0x196;
4012
4013 # 2568
4014 extern volatile unsigned char VREGCON @ 0x197;
4015
4016 asm("VREGCON equ 0197h");
4017
4018
4019 typedef union {
4020 struct {
4021 unsigned VREGPM0 :1;
4022 unsigned VREGPM1 :1;
4023 };
4024 struct {
4025 unsigned VREGPM :2;
4026 };
4027 } VREGCONbits_t;
4028 extern volatile VREGCONbits_t VREGCONbits @ 0x197;
4029
4030 # 2601
4031 extern volatile unsigned char RCREG @ 0x199;
4032
4033 asm("RCREG equ 0199h");
4034
4035
4036 typedef union {
4037 struct {
4038 unsigned RCREG :8;
4039 };
4040 } RCREGbits_t;
4041 extern volatile RCREGbits_t RCREGbits @ 0x199;
4042
4043 # 2620
4044 extern volatile unsigned char TXREG @ 0x19A;
4045
4046 asm("TXREG equ 019Ah");
4047
4048
4049 typedef union {
4050 struct {
4051 unsigned TXREG :8;
4052 };
4053 } TXREGbits_t;
4054 extern volatile TXREGbits_t TXREGbits @ 0x19A;
4055
4056 # 2639
4057 extern volatile unsigned char SPBRGL @ 0x19B;
4058
4059 asm("SPBRGL equ 019Bh");
4060
4061
4062 extern volatile unsigned char SPBRG @ 0x19B;
4063
4064 asm("SPBRG equ 019Bh");
4065
4066
4067 typedef union {
4068 struct {
4069 unsigned SPBRGL :8;
4070 };
4071 } SPBRGLbits_t;
4072 extern volatile SPBRGLbits_t SPBRGLbits @ 0x19B;
4073
4074 # 2662
4075 typedef union {
4076 struct {
4077 unsigned SPBRGL :8;
4078 };
4079 } SPBRGbits_t;
4080 extern volatile SPBRGbits_t SPBRGbits @ 0x19B;
4081
4082 # 2676
4083 extern volatile unsigned char SPBRGH @ 0x19C;
4084
4085 asm("SPBRGH equ 019Ch");
4086
4087
4088 typedef union {
4089 struct {
4090 unsigned SPBRGH :8;
4091 };
4092 } SPBRGHbits_t;
4093 extern volatile SPBRGHbits_t SPBRGHbits @ 0x19C;
4094
4095 # 2695
4096 extern volatile unsigned char RCSTA @ 0x19D;
4097
4098 asm("RCSTA equ 019Dh");
4099
4100
4101 typedef union {
4102 struct {
4103 unsigned RX9D :1;
4104 unsigned OERR :1;
4105 unsigned FERR :1;
4106 unsigned ADDEN :1;
4107 unsigned CREN :1;
4108 unsigned SREN :1;
4109 unsigned RX9 :1;
4110 unsigned SPEN :1;
4111 };
4112 } RCSTAbits_t;
4113 extern volatile RCSTAbits_t RCSTAbits @ 0x19D;
4114
4115 # 2756
4116 extern volatile unsigned char TXSTA @ 0x19E;
4117
4118 asm("TXSTA equ 019Eh");
4119
4120
4121 typedef union {
4122 struct {
4123 unsigned TX9D :1;
4124 unsigned TRMT :1;
4125 unsigned BRGH :1;
4126 unsigned SENDB :1;
4127 unsigned SYNC :1;
4128 unsigned TXEN :1;
4129 unsigned TX9 :1;
4130 unsigned CSRC :1;
4131 };
4132 } TXSTAbits_t;
4133 extern volatile TXSTAbits_t TXSTAbits @ 0x19E;
4134
4135 # 2817
4136 extern volatile unsigned char BAUDCON @ 0x19F;
4137
4138 asm("BAUDCON equ 019Fh");
4139
4140
4141 typedef union {
4142 struct {
4143 unsigned ABDEN :1;
4144 unsigned WUE :1;
4145 unsigned :1;
4146 unsigned BRG16 :1;
4147 unsigned SCKP :1;
4148 unsigned :1;
4149 unsigned RCIDL :1;
4150 unsigned ABDOVF :1;
4151 };
4152 } BAUDCONbits_t;
4153 extern volatile BAUDCONbits_t BAUDCONbits @ 0x19F;
4154
4155 # 2868
4156 extern volatile unsigned char WPUA @ 0x20C;
4157
4158 asm("WPUA equ 020Ch");
4159
4160
4161 typedef union {
4162 struct {
4163 unsigned WPUA0 :1;
4164 unsigned WPUA1 :1;
4165 unsigned WPUA2 :1;
4166 unsigned WPUA3 :1;
4167 unsigned WPUA4 :1;
4168 unsigned WPUA5 :1;
4169 };
4170 struct {
4171 unsigned WPUA :6;
4172 };
4173 } WPUAbits_t;
4174 extern volatile WPUAbits_t WPUAbits @ 0x20C;
4175
4176 # 2925
4177 extern volatile unsigned char SSP1BUF @ 0x211;
4178
4179 asm("SSP1BUF equ 0211h");
4180
4181
4182 extern volatile unsigned char SSPBUF @ 0x211;
4183
4184 asm("SSPBUF equ 0211h");
4185
4186
4187 typedef union {
4188 struct {
4189 unsigned SSPBUF :8;
4190 };
4191 } SSP1BUFbits_t;
4192 extern volatile SSP1BUFbits_t SSP1BUFbits @ 0x211;
4193
4194 # 2948
4195 typedef union {
4196 struct {
4197 unsigned SSPBUF :8;
4198 };
4199 } SSPBUFbits_t;
4200 extern volatile SSPBUFbits_t SSPBUFbits @ 0x211;
4201
4202 # 2962
4203 extern volatile unsigned char SSP1ADD @ 0x212;
4204
4205 asm("SSP1ADD equ 0212h");
4206
4207
4208 extern volatile unsigned char SSPADD @ 0x212;
4209
4210 asm("SSPADD equ 0212h");
4211
4212
4213 typedef union {
4214 struct {
4215 unsigned SSPADD :8;
4216 };
4217 } SSP1ADDbits_t;
4218 extern volatile SSP1ADDbits_t SSP1ADDbits @ 0x212;
4219
4220 # 2985
4221 typedef union {
4222 struct {
4223 unsigned SSPADD :8;
4224 };
4225 } SSPADDbits_t;
4226 extern volatile SSPADDbits_t SSPADDbits @ 0x212;
4227
4228 # 2999
4229 extern volatile unsigned char SSP1MSK @ 0x213;
4230
4231 asm("SSP1MSK equ 0213h");
4232
4233
4234 extern volatile unsigned char SSPMSK @ 0x213;
4235
4236 asm("SSPMSK equ 0213h");
4237
4238
4239 typedef union {
4240 struct {
4241 unsigned SSPMSK :8;
4242 };
4243 } SSP1MSKbits_t;
4244 extern volatile SSP1MSKbits_t SSP1MSKbits @ 0x213;
4245
4246 # 3022
4247 typedef union {
4248 struct {
4249 unsigned SSPMSK :8;
4250 };
4251 } SSPMSKbits_t;
4252 extern volatile SSPMSKbits_t SSPMSKbits @ 0x213;
4253
4254 # 3036
4255 extern volatile unsigned char SSP1STAT @ 0x214;
4256
4257 asm("SSP1STAT equ 0214h");
4258
4259
4260 extern volatile unsigned char SSPSTAT @ 0x214;
4261
4262 asm("SSPSTAT equ 0214h");
4263
4264
4265 typedef union {
4266 struct {
4267 unsigned BF :1;
4268 unsigned UA :1;
4269 unsigned R_nW :1;
4270 unsigned S :1;
4271 unsigned P :1;
4272 unsigned D_nA :1;
4273 unsigned CKE :1;
4274 unsigned SMP :1;
4275 };
4276 } SSP1STATbits_t;
4277 extern volatile SSP1STATbits_t SSP1STATbits @ 0x214;
4278
4279 # 3101
4280 typedef union {
4281 struct {
4282 unsigned BF :1;
4283 unsigned UA :1;
4284 unsigned R_nW :1;
4285 unsigned S :1;
4286 unsigned P :1;
4287 unsigned D_nA :1;
4288 unsigned CKE :1;
4289 unsigned SMP :1;
4290 };
4291 } SSPSTATbits_t;
4292 extern volatile SSPSTATbits_t SSPSTATbits @ 0x214;
4293
4294 # 3157
4295 extern volatile unsigned char SSP1CON1 @ 0x215;
4296
4297 asm("SSP1CON1 equ 0215h");
4298
4299
4300 extern volatile unsigned char SSPCON1 @ 0x215;
4301
4302 asm("SSPCON1 equ 0215h");
4303
4304 extern volatile unsigned char SSPCON @ 0x215;
4305
4306 asm("SSPCON equ 0215h");
4307
4308
4309 typedef union {
4310 struct {
4311 unsigned SSPM0 :1;
4312 unsigned SSPM1 :1;
4313 unsigned SSPM2 :1;
4314 unsigned SSPM3 :1;
4315 unsigned CKP :1;
4316 unsigned SSPEN :1;
4317 unsigned SSPOV :1;
4318 unsigned WCOL :1;
4319 };
4320 struct {
4321 unsigned SSPM :4;
4322 };
4323 } SSP1CON1bits_t;
4324 extern volatile SSP1CON1bits_t SSP1CON1bits @ 0x215;
4325
4326 # 3234
4327 typedef union {
4328 struct {
4329 unsigned SSPM0 :1;
4330 unsigned SSPM1 :1;
4331 unsigned SSPM2 :1;
4332 unsigned SSPM3 :1;
4333 unsigned CKP :1;
4334 unsigned SSPEN :1;
4335 unsigned SSPOV :1;
4336 unsigned WCOL :1;
4337 };
4338 struct {
4339 unsigned SSPM :4;
4340 };
4341 } SSPCON1bits_t;
4342 extern volatile SSPCON1bits_t SSPCON1bits @ 0x215;
4343
4344 # 3296
4345 typedef union {
4346 struct {
4347 unsigned SSPM0 :1;
4348 unsigned SSPM1 :1;
4349 unsigned SSPM2 :1;
4350 unsigned SSPM3 :1;
4351 unsigned CKP :1;
4352 unsigned SSPEN :1;
4353 unsigned SSPOV :1;
4354 unsigned WCOL :1;
4355 };
4356 struct {
4357 unsigned SSPM :4;
4358 };
4359 } SSPCONbits_t;
4360 extern volatile SSPCONbits_t SSPCONbits @ 0x215;
4361
4362 # 3360
4363 extern volatile unsigned char SSP1CON2 @ 0x216;
4364
4365 asm("SSP1CON2 equ 0216h");
4366
4367
4368 extern volatile unsigned char SSPCON2 @ 0x216;
4369
4370 asm("SSPCON2 equ 0216h");
4371
4372
4373 typedef union {
4374 struct {
4375 unsigned SEN :1;
4376 unsigned RSEN :1;
4377 unsigned PEN :1;
4378 unsigned RCEN :1;
4379 unsigned ACKEN :1;
4380 unsigned ACKDT :1;
4381 unsigned ACKSTAT :1;
4382 unsigned GCEN :1;
4383 };
4384 } SSP1CON2bits_t;
4385 extern volatile SSP1CON2bits_t SSP1CON2bits @ 0x216;
4386
4387 # 3425
4388 typedef union {
4389 struct {
4390 unsigned SEN :1;
4391 unsigned RSEN :1;
4392 unsigned PEN :1;
4393 unsigned RCEN :1;
4394 unsigned ACKEN :1;
4395 unsigned ACKDT :1;
4396 unsigned ACKSTAT :1;
4397 unsigned GCEN :1;
4398 };
4399 } SSPCON2bits_t;
4400 extern volatile SSPCON2bits_t SSPCON2bits @ 0x216;
4401
4402 # 3481
4403 extern volatile unsigned char SSP1CON3 @ 0x217;
4404
4405 asm("SSP1CON3 equ 0217h");
4406
4407
4408 extern volatile unsigned char SSPCON3 @ 0x217;
4409
4410 asm("SSPCON3 equ 0217h");
4411
4412
4413 typedef union {
4414 struct {
4415 unsigned DHEN :1;
4416 unsigned AHEN :1;
4417 unsigned SBCDE :1;
4418 unsigned SDAHT :1;
4419 unsigned BOEN :1;
4420 unsigned SCIE :1;
4421 unsigned PCIE :1;
4422 unsigned ACKTIM :1;
4423 };
4424 } SSP1CON3bits_t;
4425 extern volatile SSP1CON3bits_t SSP1CON3bits @ 0x217;
4426
4427 # 3546
4428 typedef union {
4429 struct {
4430 unsigned DHEN :1;
4431 unsigned AHEN :1;
4432 unsigned SBCDE :1;
4433 unsigned SDAHT :1;
4434 unsigned BOEN :1;
4435 unsigned SCIE :1;
4436 unsigned PCIE :1;
4437 unsigned ACKTIM :1;
4438 };
4439 } SSPCON3bits_t;
4440 extern volatile SSPCON3bits_t SSPCON3bits @ 0x217;
4441
4442 # 3602
4443 extern volatile unsigned char CCPR1L @ 0x291;
4444
4445 asm("CCPR1L equ 0291h");
4446
4447
4448 typedef union {
4449 struct {
4450 unsigned CCPR1L :8;
4451 };
4452 } CCPR1Lbits_t;
4453 extern volatile CCPR1Lbits_t CCPR1Lbits @ 0x291;
4454
4455 # 3621
4456 extern volatile unsigned char CCPR1H @ 0x292;
4457
4458 asm("CCPR1H equ 0292h");
4459
4460
4461 typedef union {
4462 struct {
4463 unsigned CCPR1H :8;
4464 };
4465 } CCPR1Hbits_t;
4466 extern volatile CCPR1Hbits_t CCPR1Hbits @ 0x292;
4467
4468 # 3640
4469 extern volatile unsigned char CCP1CON @ 0x293;
4470
4471 asm("CCP1CON equ 0293h");
4472
4473
4474 typedef union {
4475 struct {
4476 unsigned CCP1M0 :1;
4477 unsigned CCP1M1 :1;
4478 unsigned CCP1M2 :1;
4479 unsigned CCP1M3 :1;
4480 unsigned DC1B0 :1;
4481 unsigned DC1B1 :1;
4482 unsigned P1M0 :1;
4483 unsigned P1M1 :1;
4484 };
4485 struct {
4486 unsigned CCP1M :4;
4487 unsigned DC1B :2;
4488 unsigned P1M :2;
4489 };
4490 } CCP1CONbits_t;
4491 extern volatile CCP1CONbits_t CCP1CONbits @ 0x293;
4492
4493 # 3721
4494 extern volatile unsigned char PWM1CON @ 0x294;
4495
4496 asm("PWM1CON equ 0294h");
4497
4498
4499 typedef union {
4500 struct {
4501 unsigned P1DC0 :1;
4502 unsigned P1DC1 :1;
4503 unsigned P1DC2 :1;
4504 unsigned P1DC3 :1;
4505 unsigned P1DC4 :1;
4506 unsigned P1DC5 :1;
4507 unsigned P1DC6 :1;
4508 unsigned P1RSEN :1;
4509 };
4510 struct {
4511 unsigned P1DC :7;
4512 };
4513 } PWM1CONbits_t;
4514 extern volatile PWM1CONbits_t PWM1CONbits @ 0x294;
4515
4516 # 3790
4517 extern volatile unsigned char CCP1AS @ 0x295;
4518
4519 asm("CCP1AS equ 0295h");
4520
4521
4522 extern volatile unsigned char ECCP1AS @ 0x295;
4523
4524 asm("ECCP1AS equ 0295h");
4525
4526
4527 typedef union {
4528 struct {
4529 unsigned PSS1BD0 :1;
4530 unsigned PSS1BD1 :1;
4531 unsigned PSS1AC0 :1;
4532 unsigned PSS1AC1 :1;
4533 unsigned CCP1AS0 :1;
4534 unsigned CCP1AS1 :1;
4535 unsigned CCP1AS2 :1;
4536 unsigned CCP1ASE :1;
4537 };
4538 struct {
4539 unsigned PSS1BD :2;
4540 unsigned PSS1AC :2;
4541 unsigned CCP1AS :3;
4542 };
4543 } CCP1ASbits_t;
4544 extern volatile CCP1ASbits_t CCP1ASbits @ 0x295;
4545
4546 # 3875
4547 typedef union {
4548 struct {
4549 unsigned PSS1BD0 :1;
4550 unsigned PSS1BD1 :1;
4551 unsigned PSS1AC0 :1;
4552 unsigned PSS1AC1 :1;
4553 unsigned CCP1AS0 :1;
4554 unsigned CCP1AS1 :1;
4555 unsigned CCP1AS2 :1;
4556 unsigned CCP1ASE :1;
4557 };
4558 struct {
4559 unsigned PSS1BD :2;
4560 unsigned PSS1AC :2;
4561 unsigned CCP1AS :3;
4562 };
4563 } ECCP1ASbits_t;
4564 extern volatile ECCP1ASbits_t ECCP1ASbits @ 0x295;
4565
4566 # 3951
4567 extern volatile unsigned char PSTR1CON @ 0x296;
4568
4569 asm("PSTR1CON equ 0296h");
4570
4571
4572 typedef union {
4573 struct {
4574 unsigned STR1A :1;
4575 unsigned STR1B :1;
4576 unsigned :1;
4577 unsigned :1;
4578 unsigned STR1SYNC :1;
4579 };
4580 } PSTR1CONbits_t;
4581 extern volatile PSTR1CONbits_t PSTR1CONbits @ 0x296;
4582
4583 # 3984
4584 extern volatile unsigned char IOCAP @ 0x391;
4585
4586 asm("IOCAP equ 0391h");
4587
4588
4589 typedef union {
4590 struct {
4591 unsigned IOCAP0 :1;
4592 unsigned IOCAP1 :1;
4593 unsigned IOCAP2 :1;
4594 unsigned IOCAP3 :1;
4595 unsigned IOCAP4 :1;
4596 unsigned IOCAP5 :1;
4597 };
4598 struct {
4599 unsigned IOCAP :6;
4600 };
4601 } IOCAPbits_t;
4602 extern volatile IOCAPbits_t IOCAPbits @ 0x391;
4603
4604 # 4041
4605 extern volatile unsigned char IOCAN @ 0x392;
4606
4607 asm("IOCAN equ 0392h");
4608
4609
4610 typedef union {
4611 struct {
4612 unsigned IOCAN0 :1;
4613 unsigned IOCAN1 :1;
4614 unsigned IOCAN2 :1;
4615 unsigned IOCAN3 :1;
4616 unsigned IOCAN4 :1;
4617 unsigned IOCAN5 :1;
4618 };
4619 struct {
4620 unsigned IOCAN :6;
4621 };
4622 } IOCANbits_t;
4623 extern volatile IOCANbits_t IOCANbits @ 0x392;
4624
4625 # 4098
4626 extern volatile unsigned char IOCAF @ 0x393;
4627
4628 asm("IOCAF equ 0393h");
4629
4630
4631 typedef union {
4632 struct {
4633 unsigned IOCAF0 :1;
4634 unsigned IOCAF1 :1;
4635 unsigned IOCAF2 :1;
4636 unsigned IOCAF3 :1;
4637 unsigned IOCAF4 :1;
4638 unsigned IOCAF5 :1;
4639 };
4640 struct {
4641 unsigned IOCAF :6;
4642 };
4643 } IOCAFbits_t;
4644 extern volatile IOCAFbits_t IOCAFbits @ 0x393;
4645
4646 # 4155
4647 extern volatile unsigned char CLKRCON @ 0x39A;
4648
4649 asm("CLKRCON equ 039Ah");
4650
4651
4652 typedef union {
4653 struct {
4654 unsigned CLKRDIV0 :1;
4655 unsigned CLKRDIV1 :1;
4656 unsigned CLKRDIV2 :1;
4657 unsigned CLKRDC0 :1;
4658 unsigned CLKRDC1 :1;
4659 unsigned CLKRSLR :1;
4660 unsigned CLKROE :1;
4661 unsigned CLKREN :1;
4662 };
4663 struct {
4664 unsigned CLKRDIV :3;
4665 unsigned CLKRDC :2;
4666 };
4667 } CLKRCONbits_t;
4668 extern volatile CLKRCONbits_t CLKRCONbits @ 0x39A;
4669
4670 # 4230
4671 extern volatile unsigned char MDCON @ 0x39C;
4672
4673 asm("MDCON equ 039Ch");
4674
4675
4676 typedef union {
4677 struct {
4678 unsigned MDBIT :1;
4679 unsigned :2;
4680 unsigned MDOUT :1;
4681 unsigned MDOPOL :1;
4682 unsigned MDSLR :1;
4683 unsigned MDOE :1;
4684 unsigned MDEN :1;
4685 };
4686 } MDCONbits_t;
4687 extern volatile MDCONbits_t MDCONbits @ 0x39C;
4688
4689 # 4280
4690 extern volatile unsigned char MDSRC @ 0x39D;
4691
4692 asm("MDSRC equ 039Dh");
4693
4694
4695 typedef union {
4696 struct {
4697 unsigned MDMS0 :1;
4698 unsigned MDMS1 :1;
4699 unsigned MDMS2 :1;
4700 unsigned MDMS3 :1;
4701 unsigned :3;
4702 unsigned MDMSODIS :1;
4703 };
4704 struct {
4705 unsigned MDMS :4;
4706 };
4707 } MDSRCbits_t;
4708 extern volatile MDSRCbits_t MDSRCbits @ 0x39D;
4709
4710 # 4332
4711 extern volatile unsigned char MDCARL @ 0x39E;
4712
4713 asm("MDCARL equ 039Eh");
4714
4715
4716 typedef union {
4717 struct {
4718 unsigned MDCL0 :1;
4719 unsigned MDCL1 :1;
4720 unsigned MDCL2 :1;
4721 unsigned MDCL3 :1;
4722 unsigned :1;
4723 unsigned MDCLSYNC :1;
4724 unsigned MDCLPOL :1;
4725 unsigned MDCLODIS :1;
4726 };
4727 struct {
4728 unsigned MDCL :4;
4729 };
4730 } MDCARLbits_t;
4731 extern volatile MDCARLbits_t MDCARLbits @ 0x39E;
4732
4733 # 4396
4734 extern volatile unsigned char MDCARH @ 0x39F;
4735
4736 asm("MDCARH equ 039Fh");
4737
4738
4739 typedef union {
4740 struct {
4741 unsigned MDCH0 :1;
4742 unsigned MDCH1 :1;
4743 unsigned MDCH2 :1;
4744 unsigned MDCH3 :1;
4745 unsigned :1;
4746 unsigned MDCHSYNC :1;
4747 unsigned MDCHPOL :1;
4748 unsigned MDCHODIS :1;
4749 };
4750 struct {
4751 unsigned MDCH :4;
4752 };
4753 } MDCARHbits_t;
4754 extern volatile MDCARHbits_t MDCARHbits @ 0x39F;
4755
4756 # 4460
4757 extern volatile unsigned char STATUS_SHAD @ 0xFE4;
4758
4759 asm("STATUS_SHAD equ 0FE4h");
4760
4761
4762 typedef union {
4763 struct {
4764 unsigned C_SHAD :1;
4765 unsigned DC_SHAD :1;
4766 unsigned Z_SHAD :1;
4767 };
4768 } STATUS_SHADbits_t;
4769 extern volatile STATUS_SHADbits_t STATUS_SHADbits @ 0xFE4;
4770
4771 # 4491
4772 extern volatile unsigned char WREG_SHAD @ 0xFE5;
4773
4774 asm("WREG_SHAD equ 0FE5h");
4775
4776
4777 typedef union {
4778 struct {
4779 unsigned WREG_SHAD :8;
4780 };
4781 } WREG_SHADbits_t;
4782 extern volatile WREG_SHADbits_t WREG_SHADbits @ 0xFE5;
4783
4784 # 4510
4785 extern volatile unsigned char BSR_SHAD @ 0xFE6;
4786
4787 asm("BSR_SHAD equ 0FE6h");
4788
4789
4790 typedef union {
4791 struct {
4792 unsigned BSR_SHAD :5;
4793 };
4794 } BSR_SHADbits_t;
4795 extern volatile BSR_SHADbits_t BSR_SHADbits @ 0xFE6;
4796
4797 # 4529
4798 extern volatile unsigned char PCLATH_SHAD @ 0xFE7;
4799
4800 asm("PCLATH_SHAD equ 0FE7h");
4801
4802
4803 typedef union {
4804 struct {
4805 unsigned PCLATH_SHAD :7;
4806 };
4807 } PCLATH_SHADbits_t;
4808 extern volatile PCLATH_SHADbits_t PCLATH_SHADbits @ 0xFE7;
4809
4810 # 4548
4811 extern volatile unsigned char FSR0L_SHAD @ 0xFE8;
4812
4813 asm("FSR0L_SHAD equ 0FE8h");
4814
4815
4816 typedef union {
4817 struct {
4818 unsigned FSR0L_SHAD :8;
4819 };
4820 } FSR0L_SHADbits_t;
4821 extern volatile FSR0L_SHADbits_t FSR0L_SHADbits @ 0xFE8;
4822
4823 # 4567
4824 extern volatile unsigned char FSR0H_SHAD @ 0xFE9;
4825
4826 asm("FSR0H_SHAD equ 0FE9h");
4827
4828
4829 typedef union {
4830 struct {
4831 unsigned FSR0H_SHAD :8;
4832 };
4833 } FSR0H_SHADbits_t;
4834 extern volatile FSR0H_SHADbits_t FSR0H_SHADbits @ 0xFE9;
4835
4836 # 4586
4837 extern volatile unsigned char FSR1L_SHAD @ 0xFEA;
4838
4839 asm("FSR1L_SHAD equ 0FEAh");
4840
4841
4842 typedef union {
4843 struct {
4844 unsigned FSR1L_SHAD :8;
4845 };
4846 } FSR1L_SHADbits_t;
4847 extern volatile FSR1L_SHADbits_t FSR1L_SHADbits @ 0xFEA;
4848
4849 # 4605
4850 extern volatile unsigned char FSR1H_SHAD @ 0xFEB;
4851
4852 asm("FSR1H_SHAD equ 0FEBh");
4853
4854
4855 typedef union {
4856 struct {
4857 unsigned FSR1H_SHAD :8;
4858 };
4859 } FSR1H_SHADbits_t;
4860 extern volatile FSR1H_SHADbits_t FSR1H_SHADbits @ 0xFEB;
4861
4862 # 4624
4863 extern volatile unsigned char STKPTR @ 0xFED;
4864
4865 asm("STKPTR equ 0FEDh");
4866
4867
4868 typedef union {
4869 struct {
4870 unsigned STKPTR :5;
4871 };
4872 } STKPTRbits_t;
4873 extern volatile STKPTRbits_t STKPTRbits @ 0xFED;
4874
4875 # 4643
4876 extern volatile unsigned char TOSL @ 0xFEE;
4877
4878 asm("TOSL equ 0FEEh");
4879
4880
4881 typedef union {
4882 struct {
4883 unsigned TOSL :8;
4884 };
4885 } TOSLbits_t;
4886 extern volatile TOSLbits_t TOSLbits @ 0xFEE;
4887
4888 # 4662
4889 extern volatile unsigned char TOSH @ 0xFEF;
4890
4891 asm("TOSH equ 0FEFh");
4892
4893
4894 typedef union {
4895 struct {
4896 unsigned TOSH :7;
4897 };
4898 } TOSHbits_t;
4899 extern volatile TOSHbits_t TOSHbits @ 0xFEF;
4900
4901 # 4687
4902 extern volatile __bit ABDEN @ (((unsigned) &BAUDCON)*8) + 0;
4903
4904 extern volatile __bit ABDOVF @ (((unsigned) &BAUDCON)*8) + 7;
4905
4906 extern volatile __bit ACKDT @ (((unsigned) &SSP1CON2)*8) + 5;
4907
4908 extern volatile __bit ACKEN @ (((unsigned) &SSP1CON2)*8) + 4;
4909
4910 extern volatile __bit ACKSTAT @ (((unsigned) &SSP1CON2)*8) + 6;
4911
4912 extern volatile __bit ACKTIM @ (((unsigned) &SSP1CON3)*8) + 7;
4913
4914 extern volatile __bit ADCS0 @ (((unsigned) &ADCON1)*8) + 4;
4915
4916 extern volatile __bit ADCS1 @ (((unsigned) &ADCON1)*8) + 5;
4917
4918 extern volatile __bit ADCS2 @ (((unsigned) &ADCON1)*8) + 6;
4919
4920 extern volatile __bit ADDEN @ (((unsigned) &RCSTA)*8) + 3;
4921
4922 extern volatile __bit ADFM @ (((unsigned) &ADCON1)*8) + 7;
4923
4924 extern volatile __bit ADFVR0 @ (((unsigned) &FVRCON)*8) + 0;
4925
4926 extern volatile __bit ADFVR1 @ (((unsigned) &FVRCON)*8) + 1;
4927
4928 extern volatile __bit ADGO @ (((unsigned) &ADCON0)*8) + 1;
4929
4930 extern volatile __bit ADIE @ (((unsigned) &PIE1)*8) + 6;
4931
4932 extern volatile __bit ADIF @ (((unsigned) &PIR1)*8) + 6;
4933
4934 extern volatile __bit ADON @ (((unsigned) &ADCON0)*8) + 0;
4935
4936 extern volatile __bit ADPREF0 @ (((unsigned) &ADCON1)*8) + 0;
4937
4938 extern volatile __bit ADPREF1 @ (((unsigned) &ADCON1)*8) + 1;
4939
4940 extern volatile __bit AHEN @ (((unsigned) &SSP1CON3)*8) + 1;
4941
4942 extern volatile __bit ANSA0 @ (((unsigned) &ANSELA)*8) + 0;
4943
4944 extern volatile __bit ANSA1 @ (((unsigned) &ANSELA)*8) + 1;
4945
4946 extern volatile __bit ANSA2 @ (((unsigned) &ANSELA)*8) + 2;
4947
4948 extern volatile __bit ANSA4 @ (((unsigned) &ANSELA)*8) + 4;
4949
4950 extern volatile __bit BCL1IE @ (((unsigned) &PIE2)*8) + 3;
4951
4952 extern volatile __bit BCL1IF @ (((unsigned) &PIR2)*8) + 3;
4953
4954 extern volatile __bit BF @ (((unsigned) &SSP1STAT)*8) + 0;
4955
4956 extern volatile __bit BOEN @ (((unsigned) &SSP1CON3)*8) + 4;
4957
4958 extern volatile __bit BORFS @ (((unsigned) &BORCON)*8) + 6;
4959
4960 extern volatile __bit BORRDY @ (((unsigned) &BORCON)*8) + 0;
4961
4962 extern volatile __bit BRG16 @ (((unsigned) &BAUDCON)*8) + 3;
4963
4964 extern volatile __bit BRGH @ (((unsigned) &TXSTA)*8) + 2;
4965
4966 extern volatile __bit BSR0 @ (((unsigned) &BSR)*8) + 0;
4967
4968 extern volatile __bit BSR1 @ (((unsigned) &BSR)*8) + 1;
4969
4970 extern volatile __bit BSR2 @ (((unsigned) &BSR)*8) + 2;
4971
4972 extern volatile __bit BSR3 @ (((unsigned) &BSR)*8) + 3;
4973
4974 extern volatile __bit BSR4 @ (((unsigned) &BSR)*8) + 4;
4975
4976 extern volatile __bit C1HYS @ (((unsigned) &CM1CON0)*8) + 1;
4977
4978 extern volatile __bit C1IE @ (((unsigned) &PIE2)*8) + 5;
4979
4980 extern volatile __bit C1IF @ (((unsigned) &PIR2)*8) + 5;
4981
4982 extern volatile __bit C1INTN @ (((unsigned) &CM1CON1)*8) + 6;
4983
4984 extern volatile __bit C1INTP @ (((unsigned) &CM1CON1)*8) + 7;
4985
4986 extern volatile __bit C1NCH @ (((unsigned) &CM1CON1)*8) + 0;
4987
4988 extern volatile __bit C1NCH0 @ (((unsigned) &CM1CON1)*8) + 0;
4989
4990 extern volatile __bit C1OE @ (((unsigned) &CM1CON0)*8) + 5;
4991
4992 extern volatile __bit C1ON @ (((unsigned) &CM1CON0)*8) + 7;
4993
4994 extern volatile __bit C1OUT @ (((unsigned) &CM1CON0)*8) + 6;
4995
4996 extern volatile __bit C1PCH0 @ (((unsigned) &CM1CON1)*8) + 4;
4997
4998 extern volatile __bit C1PCH1 @ (((unsigned) &CM1CON1)*8) + 5;
4999
5000 extern volatile __bit C1POL @ (((unsigned) &CM1CON0)*8) + 4;
5001
5002 extern volatile __bit C1SP @ (((unsigned) &CM1CON0)*8) + 2;
5003
5004 extern volatile __bit C1SYNC @ (((unsigned) &CM1CON0)*8) + 0;
5005
5006 extern volatile __bit CARRY @ (((unsigned) &STATUS)*8) + 0;
5007
5008 extern volatile __bit CCP1AS0 @ (((unsigned) &CCP1AS)*8) + 4;
5009
5010 extern volatile __bit CCP1AS1 @ (((unsigned) &CCP1AS)*8) + 5;
5011
5012 extern volatile __bit CCP1AS2 @ (((unsigned) &CCP1AS)*8) + 6;
5013
5014 extern volatile __bit CCP1ASE @ (((unsigned) &CCP1AS)*8) + 7;
5015
5016 extern volatile __bit CCP1IE @ (((unsigned) &PIE1)*8) + 2;
5017
5018 extern volatile __bit CCP1IF @ (((unsigned) &PIR1)*8) + 2;
5019
5020 extern volatile __bit CCP1M0 @ (((unsigned) &CCP1CON)*8) + 0;
5021
5022 extern volatile __bit CCP1M1 @ (((unsigned) &CCP1CON)*8) + 1;
5023
5024 extern volatile __bit CCP1M2 @ (((unsigned) &CCP1CON)*8) + 2;
5025
5026 extern volatile __bit CCP1M3 @ (((unsigned) &CCP1CON)*8) + 3;
5027
5028 extern volatile __bit CCP1SEL @ (((unsigned) &APFCON)*8) + 0;
5029
5030 extern volatile __bit CDAFVR0 @ (((unsigned) &FVRCON)*8) + 2;
5031
5032 extern volatile __bit CDAFVR1 @ (((unsigned) &FVRCON)*8) + 3;
5033
5034 extern volatile __bit CFGS @ (((unsigned) &EECON1)*8) + 6;
5035
5036 extern volatile __bit CHS0 @ (((unsigned) &ADCON0)*8) + 2;
5037
5038 extern volatile __bit CHS1 @ (((unsigned) &ADCON0)*8) + 3;
5039
5040 extern volatile __bit CHS2 @ (((unsigned) &ADCON0)*8) + 4;
5041
5042 extern volatile __bit CHS3 @ (((unsigned) &ADCON0)*8) + 5;
5043
5044 extern volatile __bit CHS4 @ (((unsigned) &ADCON0)*8) + 6;
5045
5046 extern volatile __bit CKE @ (((unsigned) &SSP1STAT)*8) + 6;
5047
5048 extern volatile __bit CKP @ (((unsigned) &SSP1CON1)*8) + 4;
5049
5050 extern volatile __bit CLKRDC0 @ (((unsigned) &CLKRCON)*8) + 3;
5051
5052 extern volatile __bit CLKRDC1 @ (((unsigned) &CLKRCON)*8) + 4;
5053
5054 extern volatile __bit CLKRDIV0 @ (((unsigned) &CLKRCON)*8) + 0;
5055
5056 extern volatile __bit CLKRDIV1 @ (((unsigned) &CLKRCON)*8) + 1;
5057
5058 extern volatile __bit CLKRDIV2 @ (((unsigned) &CLKRCON)*8) + 2;
5059
5060 extern volatile __bit CLKREN @ (((unsigned) &CLKRCON)*8) + 7;
5061
5062 extern volatile __bit CLKROE @ (((unsigned) &CLKRCON)*8) + 6;
5063
5064 extern volatile __bit CLKRSLR @ (((unsigned) &CLKRCON)*8) + 5;
5065
5066 extern volatile __bit CPSCH0 @ (((unsigned) &CPSCON1)*8) + 0;
5067
5068 extern volatile __bit CPSCH1 @ (((unsigned) &CPSCON1)*8) + 1;
5069
5070 extern volatile __bit CPSON @ (((unsigned) &CPSCON0)*8) + 7;
5071
5072 extern volatile __bit CPSOUT @ (((unsigned) &CPSCON0)*8) + 1;
5073
5074 extern volatile __bit CPSRM @ (((unsigned) &CPSCON0)*8) + 6;
5075
5076 extern volatile __bit CPSRNG0 @ (((unsigned) &CPSCON0)*8) + 2;
5077
5078 extern volatile __bit CPSRNG1 @ (((unsigned) &CPSCON0)*8) + 3;
5079
5080 extern volatile __bit CREN @ (((unsigned) &RCSTA)*8) + 4;
5081
5082 extern volatile __bit CSRC @ (((unsigned) &TXSTA)*8) + 7;
5083
5084 extern volatile __bit C_SHAD @ (((unsigned) &STATUS_SHAD)*8) + 0;
5085
5086 extern volatile __bit DACEN @ (((unsigned) &DACCON0)*8) + 7;
5087
5088 extern volatile __bit DACLPS @ (((unsigned) &DACCON0)*8) + 6;
5089
5090 extern volatile __bit DACOE @ (((unsigned) &DACCON0)*8) + 5;
5091
5092 extern volatile __bit DACPSS0 @ (((unsigned) &DACCON0)*8) + 2;
5093
5094 extern volatile __bit DACPSS1 @ (((unsigned) &DACCON0)*8) + 3;
5095
5096 extern volatile __bit DACR0 @ (((unsigned) &DACCON1)*8) + 0;
5097
5098 extern volatile __bit DACR1 @ (((unsigned) &DACCON1)*8) + 1;
5099
5100 extern volatile __bit DACR2 @ (((unsigned) &DACCON1)*8) + 2;
5101
5102 extern volatile __bit DACR3 @ (((unsigned) &DACCON1)*8) + 3;
5103
5104 extern volatile __bit DACR4 @ (((unsigned) &DACCON1)*8) + 4;
5105
5106 extern volatile __bit DC @ (((unsigned) &STATUS)*8) + 1;
5107
5108 extern volatile __bit DC1B0 @ (((unsigned) &CCP1CON)*8) + 4;
5109
5110 extern volatile __bit DC1B1 @ (((unsigned) &CCP1CON)*8) + 5;
5111
5112 extern volatile __bit DC_SHAD @ (((unsigned) &STATUS_SHAD)*8) + 1;
5113
5114 extern volatile __bit DHEN @ (((unsigned) &SSP1CON3)*8) + 0;
5115
5116 extern volatile __bit D_nA @ (((unsigned) &SSP1STAT)*8) + 5;
5117
5118 extern volatile __bit EEIE @ (((unsigned) &PIE2)*8) + 4;
5119
5120 extern volatile __bit EEIF @ (((unsigned) &PIR2)*8) + 4;
5121
5122 extern volatile __bit EEPGD @ (((unsigned) &EECON1)*8) + 7;
5123
5124 extern volatile __bit FERR @ (((unsigned) &RCSTA)*8) + 2;
5125
5126 extern volatile __bit FREE @ (((unsigned) &EECON1)*8) + 4;
5127
5128 extern volatile __bit FVREN @ (((unsigned) &FVRCON)*8) + 7;
5129
5130 extern volatile __bit FVRRDY @ (((unsigned) &FVRCON)*8) + 6;
5131
5132 extern volatile __bit GCEN @ (((unsigned) &SSP1CON2)*8) + 7;
5133
5134 extern volatile __bit GIE @ (((unsigned) &INTCON)*8) + 7;
5135
5136 extern volatile __bit GO @ (((unsigned) &ADCON0)*8) + 1;
5137
5138 extern volatile __bit GO_nDONE @ (((unsigned) &ADCON0)*8) + 1;
5139
5140 extern volatile __bit HFIOFL @ (((unsigned) &OSCSTAT)*8) + 3;
5141
5142 extern volatile __bit HFIOFR @ (((unsigned) &OSCSTAT)*8) + 4;
5143
5144 extern volatile __bit HFIOFS @ (((unsigned) &OSCSTAT)*8) + 0;
5145
5146 extern volatile __bit INTE @ (((unsigned) &INTCON)*8) + 4;
5147
5148 extern volatile __bit INTEDG @ (((unsigned) &OPTION_REG)*8) + 6;
5149
5150 extern volatile __bit INTF @ (((unsigned) &INTCON)*8) + 1;
5151
5152 extern volatile __bit IOCAF0 @ (((unsigned) &IOCAF)*8) + 0;
5153
5154 extern volatile __bit IOCAF1 @ (((unsigned) &IOCAF)*8) + 1;
5155
5156 extern volatile __bit IOCAF2 @ (((unsigned) &IOCAF)*8) + 2;
5157
5158 extern volatile __bit IOCAF3 @ (((unsigned) &IOCAF)*8) + 3;
5159
5160 extern volatile __bit IOCAF4 @ (((unsigned) &IOCAF)*8) + 4;
5161
5162 extern volatile __bit IOCAF5 @ (((unsigned) &IOCAF)*8) + 5;
5163
5164 extern volatile __bit IOCAN0 @ (((unsigned) &IOCAN)*8) + 0;
5165
5166 extern volatile __bit IOCAN1 @ (((unsigned) &IOCAN)*8) + 1;
5167
5168 extern volatile __bit IOCAN2 @ (((unsigned) &IOCAN)*8) + 2;
5169
5170 extern volatile __bit IOCAN3 @ (((unsigned) &IOCAN)*8) + 3;
5171
5172 extern volatile __bit IOCAN4 @ (((unsigned) &IOCAN)*8) + 4;
5173
5174 extern volatile __bit IOCAN5 @ (((unsigned) &IOCAN)*8) + 5;
5175
5176 extern volatile __bit IOCAP0 @ (((unsigned) &IOCAP)*8) + 0;
5177
5178 extern volatile __bit IOCAP1 @ (((unsigned) &IOCAP)*8) + 1;
5179
5180 extern volatile __bit IOCAP2 @ (((unsigned) &IOCAP)*8) + 2;
5181
5182 extern volatile __bit IOCAP3 @ (((unsigned) &IOCAP)*8) + 3;
5183
5184 extern volatile __bit IOCAP4 @ (((unsigned) &IOCAP)*8) + 4;
5185
5186 extern volatile __bit IOCAP5 @ (((unsigned) &IOCAP)*8) + 5;
5187
5188 extern volatile __bit IOCIE @ (((unsigned) &INTCON)*8) + 3;
5189
5190 extern volatile __bit IOCIF @ (((unsigned) &INTCON)*8) + 0;
5191
5192 extern volatile __bit IRCF0 @ (((unsigned) &OSCCON)*8) + 3;
5193
5194 extern volatile __bit IRCF1 @ (((unsigned) &OSCCON)*8) + 4;
5195
5196 extern volatile __bit IRCF2 @ (((unsigned) &OSCCON)*8) + 5;
5197
5198 extern volatile __bit IRCF3 @ (((unsigned) &OSCCON)*8) + 6;
5199
5200 extern volatile __bit LATA0 @ (((unsigned) &LATA)*8) + 0;
5201
5202 extern volatile __bit LATA1 @ (((unsigned) &LATA)*8) + 1;
5203
5204 extern volatile __bit LATA2 @ (((unsigned) &LATA)*8) + 2;
5205
5206 extern volatile __bit LATA4 @ (((unsigned) &LATA)*8) + 4;
5207
5208 extern volatile __bit LATA5 @ (((unsigned) &LATA)*8) + 5;
5209
5210 extern volatile __bit LFIOFR @ (((unsigned) &OSCSTAT)*8) + 1;
5211
5212 extern volatile __bit LWLO @ (((unsigned) &EECON1)*8) + 5;
5213
5214 extern volatile __bit MC1OUT @ (((unsigned) &CMOUT)*8) + 0;
5215
5216 extern volatile __bit MDBIT @ (((unsigned) &MDCON)*8) + 0;
5217
5218 extern volatile __bit MDCH0 @ (((unsigned) &MDCARH)*8) + 0;
5219
5220 extern volatile __bit MDCH1 @ (((unsigned) &MDCARH)*8) + 1;
5221
5222 extern volatile __bit MDCH2 @ (((unsigned) &MDCARH)*8) + 2;
5223
5224 extern volatile __bit MDCH3 @ (((unsigned) &MDCARH)*8) + 3;
5225
5226 extern volatile __bit MDCHODIS @ (((unsigned) &MDCARH)*8) + 7;
5227
5228 extern volatile __bit MDCHPOL @ (((unsigned) &MDCARH)*8) + 6;
5229
5230 extern volatile __bit MDCHSYNC @ (((unsigned) &MDCARH)*8) + 5;
5231
5232 extern volatile __bit MDCL0 @ (((unsigned) &MDCARL)*8) + 0;
5233
5234 extern volatile __bit MDCL1 @ (((unsigned) &MDCARL)*8) + 1;
5235
5236 extern volatile __bit MDCL2 @ (((unsigned) &MDCARL)*8) + 2;
5237
5238 extern volatile __bit MDCL3 @ (((unsigned) &MDCARL)*8) + 3;
5239
5240 extern volatile __bit MDCLODIS @ (((unsigned) &MDCARL)*8) + 7;
5241
5242 extern volatile __bit MDCLPOL @ (((unsigned) &MDCARL)*8) + 6;
5243
5244 extern volatile __bit MDCLSYNC @ (((unsigned) &MDCARL)*8) + 5;
5245
5246 extern volatile __bit MDEN @ (((unsigned) &MDCON)*8) + 7;
5247
5248 extern volatile __bit MDMS0 @ (((unsigned) &MDSRC)*8) + 0;
5249
5250 extern volatile __bit MDMS1 @ (((unsigned) &MDSRC)*8) + 1;
5251
5252 extern volatile __bit MDMS2 @ (((unsigned) &MDSRC)*8) + 2;
5253
5254 extern volatile __bit MDMS3 @ (((unsigned) &MDSRC)*8) + 3;
5255
5256 extern volatile __bit MDMSODIS @ (((unsigned) &MDSRC)*8) + 7;
5257
5258 extern volatile __bit MDOE @ (((unsigned) &MDCON)*8) + 6;
5259
5260 extern volatile __bit MDOPOL @ (((unsigned) &MDCON)*8) + 4;
5261
5262 extern volatile __bit MDOUT @ (((unsigned) &MDCON)*8) + 3;
5263
5264 extern volatile __bit MDSLR @ (((unsigned) &MDCON)*8) + 5;
5265
5266 extern volatile __bit MFIOFR @ (((unsigned) &OSCSTAT)*8) + 2;
5267
5268 extern volatile __bit OERR @ (((unsigned) &RCSTA)*8) + 1;
5269
5270 extern volatile __bit OSFIE @ (((unsigned) &PIE2)*8) + 7;
5271
5272 extern volatile __bit OSFIF @ (((unsigned) &PIR2)*8) + 7;
5273
5274 extern volatile __bit OSTS @ (((unsigned) &OSCSTAT)*8) + 5;
5275
5276 extern volatile __bit P1BSEL @ (((unsigned) &APFCON)*8) + 1;
5277
5278 extern volatile __bit P1DC0 @ (((unsigned) &PWM1CON)*8) + 0;
5279
5280 extern volatile __bit P1DC1 @ (((unsigned) &PWM1CON)*8) + 1;
5281
5282 extern volatile __bit P1DC2 @ (((unsigned) &PWM1CON)*8) + 2;
5283
5284 extern volatile __bit P1DC3 @ (((unsigned) &PWM1CON)*8) + 3;
5285
5286 extern volatile __bit P1DC4 @ (((unsigned) &PWM1CON)*8) + 4;
5287
5288 extern volatile __bit P1DC5 @ (((unsigned) &PWM1CON)*8) + 5;
5289
5290 extern volatile __bit P1DC6 @ (((unsigned) &PWM1CON)*8) + 6;
5291
5292 extern volatile __bit P1M0 @ (((unsigned) &CCP1CON)*8) + 6;
5293
5294 extern volatile __bit P1M1 @ (((unsigned) &CCP1CON)*8) + 7;
5295
5296 extern volatile __bit P1RSEN @ (((unsigned) &PWM1CON)*8) + 7;
5297
5298 extern volatile __bit PCIE @ (((unsigned) &SSP1CON3)*8) + 6;
5299
5300 extern volatile __bit PEIE @ (((unsigned) &INTCON)*8) + 6;
5301
5302 extern volatile __bit PEN @ (((unsigned) &SSP1CON2)*8) + 2;
5303
5304 extern volatile __bit PLLR @ (((unsigned) &OSCSTAT)*8) + 6;
5305
5306 extern volatile __bit PS0 @ (((unsigned) &OPTION_REG)*8) + 0;
5307
5308 extern volatile __bit PS1 @ (((unsigned) &OPTION_REG)*8) + 1;
5309
5310 extern volatile __bit PS2 @ (((unsigned) &OPTION_REG)*8) + 2;
5311
5312 extern volatile __bit PSA @ (((unsigned) &OPTION_REG)*8) + 3;
5313
5314 extern volatile __bit PSS1AC0 @ (((unsigned) &CCP1AS)*8) + 2;
5315
5316 extern volatile __bit PSS1AC1 @ (((unsigned) &CCP1AS)*8) + 3;
5317
5318 extern volatile __bit PSS1BD0 @ (((unsigned) &CCP1AS)*8) + 0;
5319
5320 extern volatile __bit PSS1BD1 @ (((unsigned) &CCP1AS)*8) + 1;
5321
5322 extern volatile __bit RA0 @ (((unsigned) &PORTA)*8) + 0;
5323
5324 extern volatile __bit RA1 @ (((unsigned) &PORTA)*8) + 1;
5325
5326 extern volatile __bit RA2 @ (((unsigned) &PORTA)*8) + 2;
5327
5328 extern volatile __bit RA3 @ (((unsigned) &PORTA)*8) + 3;
5329
5330 extern volatile __bit RA4 @ (((unsigned) &PORTA)*8) + 4;
5331
5332 extern volatile __bit RA5 @ (((unsigned) &PORTA)*8) + 5;
5333
5334 extern volatile __bit RCEN @ (((unsigned) &SSP1CON2)*8) + 3;
5335
5336 extern volatile __bit RCIDL @ (((unsigned) &BAUDCON)*8) + 6;
5337
5338 extern volatile __bit RCIE @ (((unsigned) &PIE1)*8) + 5;
5339
5340 extern volatile __bit RCIF @ (((unsigned) &PIR1)*8) + 5;
5341
5342 extern volatile __bit RD @ (((unsigned) &EECON1)*8) + 0;
5343
5344 extern volatile __bit RSEN @ (((unsigned) &SSP1CON2)*8) + 1;
5345
5346 extern volatile __bit RX9 @ (((unsigned) &RCSTA)*8) + 6;
5347
5348 extern volatile __bit RX9D @ (((unsigned) &RCSTA)*8) + 0;
5349
5350 extern volatile __bit RXDTSEL @ (((unsigned) &APFCON)*8) + 7;
5351
5352 extern volatile __bit R_nW @ (((unsigned) &SSP1STAT)*8) + 2;
5353
5354 extern volatile __bit SBCDE @ (((unsigned) &SSP1CON3)*8) + 2;
5355
5356 extern volatile __bit SBOREN @ (((unsigned) &BORCON)*8) + 7;
5357
5358 extern volatile __bit SCIE @ (((unsigned) &SSP1CON3)*8) + 5;
5359
5360 extern volatile __bit SCKP @ (((unsigned) &BAUDCON)*8) + 4;
5361
5362 extern volatile __bit SCS0 @ (((unsigned) &OSCCON)*8) + 0;
5363
5364 extern volatile __bit SCS1 @ (((unsigned) &OSCCON)*8) + 1;
5365
5366 extern volatile __bit SDAHT @ (((unsigned) &SSP1CON3)*8) + 3;
5367
5368 extern volatile __bit SDO1SEL @ (((unsigned) &APFCON)*8) + 6;
5369
5370 extern volatile __bit SDOSEL @ (((unsigned) &APFCON)*8) + 6;
5371
5372 extern volatile __bit SEN @ (((unsigned) &SSP1CON2)*8) + 0;
5373
5374 extern volatile __bit SENDB @ (((unsigned) &TXSTA)*8) + 3;
5375
5376 extern volatile __bit SMP @ (((unsigned) &SSP1STAT)*8) + 7;
5377
5378 extern volatile __bit SPEN @ (((unsigned) &RCSTA)*8) + 7;
5379
5380 extern volatile __bit SPLLEN @ (((unsigned) &OSCCON)*8) + 7;
5381
5382 extern volatile __bit SRCLK0 @ (((unsigned) &SRCON0)*8) + 4;
5383
5384 extern volatile __bit SRCLK1 @ (((unsigned) &SRCON0)*8) + 5;
5385
5386 extern volatile __bit SRCLK2 @ (((unsigned) &SRCON0)*8) + 6;
5387
5388 extern volatile __bit SREN @ (((unsigned) &RCSTA)*8) + 5;
5389
5390 extern volatile __bit SRLEN @ (((unsigned) &SRCON0)*8) + 7;
5391
5392 extern volatile __bit SRNQEN @ (((unsigned) &SRCON0)*8) + 2;
5393
5394 extern volatile __bit SRPR @ (((unsigned) &SRCON0)*8) + 0;
5395
5396 extern volatile __bit SRPS @ (((unsigned) &SRCON0)*8) + 1;
5397
5398 extern volatile __bit SRQEN @ (((unsigned) &SRCON0)*8) + 3;
5399
5400 extern volatile __bit SRRC1E @ (((unsigned) &SRCON1)*8) + 0;
5401
5402 extern volatile __bit SRRCKE @ (((unsigned) &SRCON1)*8) + 2;
5403
5404 extern volatile __bit SRRPE @ (((unsigned) &SRCON1)*8) + 3;
5405
5406 extern volatile __bit SRSC1E @ (((unsigned) &SRCON1)*8) + 4;
5407
5408 extern volatile __bit SRSCKE @ (((unsigned) &SRCON1)*8) + 6;
5409
5410 extern volatile __bit SRSPE @ (((unsigned) &SRCON1)*8) + 7;
5411
5412 extern volatile __bit SS1SEL @ (((unsigned) &APFCON)*8) + 5;
5413
5414 extern volatile __bit SSP1IE @ (((unsigned) &PIE1)*8) + 3;
5415
5416 extern volatile __bit SSP1IF @ (((unsigned) &PIR1)*8) + 3;
5417
5418 extern volatile __bit SSPEN @ (((unsigned) &SSP1CON1)*8) + 5;
5419
5420 extern volatile __bit SSPM0 @ (((unsigned) &SSP1CON1)*8) + 0;
5421
5422 extern volatile __bit SSPM1 @ (((unsigned) &SSP1CON1)*8) + 1;
5423
5424 extern volatile __bit SSPM2 @ (((unsigned) &SSP1CON1)*8) + 2;
5425
5426 extern volatile __bit SSPM3 @ (((unsigned) &SSP1CON1)*8) + 3;
5427
5428 extern volatile __bit SSPOV @ (((unsigned) &SSP1CON1)*8) + 6;
5429
5430 extern volatile __bit SSSEL @ (((unsigned) &APFCON)*8) + 5;
5431
5432 extern volatile __bit STKOVF @ (((unsigned) &PCON)*8) + 7;
5433
5434 extern volatile __bit STKUNF @ (((unsigned) &PCON)*8) + 6;
5435
5436 extern volatile __bit STR1A @ (((unsigned) &PSTR1CON)*8) + 0;
5437
5438 extern volatile __bit STR1B @ (((unsigned) &PSTR1CON)*8) + 1;
5439
5440 extern volatile __bit STR1SYNC @ (((unsigned) &PSTR1CON)*8) + 4;
5441
5442 extern volatile __bit SWDTEN @ (((unsigned) &WDTCON)*8) + 0;
5443
5444 extern volatile __bit SYNC @ (((unsigned) &TXSTA)*8) + 4;
5445
5446 extern volatile __bit T0CS @ (((unsigned) &OPTION_REG)*8) + 5;
5447
5448 extern volatile __bit T0IE @ (((unsigned) &INTCON)*8) + 5;
5449
5450 extern volatile __bit T0IF @ (((unsigned) &INTCON)*8) + 2;
5451
5452 extern volatile __bit T0SE @ (((unsigned) &OPTION_REG)*8) + 4;
5453
5454 extern volatile __bit T0XCS @ (((unsigned) &CPSCON0)*8) + 0;
5455
5456 extern volatile __bit T1CKPS0 @ (((unsigned) &T1CON)*8) + 4;
5457
5458 extern volatile __bit T1CKPS1 @ (((unsigned) &T1CON)*8) + 5;
5459
5460 extern volatile __bit T1GGO @ (((unsigned) &T1GCON)*8) + 3;
5461
5462 extern volatile __bit T1GGO_nDONE @ (((unsigned) &T1GCON)*8) + 3;
5463
5464 extern volatile __bit T1GPOL @ (((unsigned) &T1GCON)*8) + 6;
5465
5466 extern volatile __bit T1GSEL @ (((unsigned) &APFCON)*8) + 3;
5467
5468 extern volatile __bit T1GSPM @ (((unsigned) &T1GCON)*8) + 4;
5469
5470 extern volatile __bit T1GSS0 @ (((unsigned) &T1GCON)*8) + 0;
5471
5472 extern volatile __bit T1GSS1 @ (((unsigned) &T1GCON)*8) + 1;
5473
5474 extern volatile __bit T1GTM @ (((unsigned) &T1GCON)*8) + 5;
5475
5476 extern volatile __bit T1GVAL @ (((unsigned) &T1GCON)*8) + 2;
5477
5478 extern volatile __bit T1OSCEN @ (((unsigned) &T1CON)*8) + 3;
5479
5480 extern volatile __bit T1OSCR @ (((unsigned) &OSCSTAT)*8) + 7;
5481
5482 extern volatile __bit T2CKPS0 @ (((unsigned) &T2CON)*8) + 0;
5483
5484 extern volatile __bit T2CKPS1 @ (((unsigned) &T2CON)*8) + 1;
5485
5486 extern volatile __bit T2OUTPS0 @ (((unsigned) &T2CON)*8) + 3;
5487
5488 extern volatile __bit T2OUTPS1 @ (((unsigned) &T2CON)*8) + 4;
5489
5490 extern volatile __bit T2OUTPS2 @ (((unsigned) &T2CON)*8) + 5;
5491
5492 extern volatile __bit T2OUTPS3 @ (((unsigned) &T2CON)*8) + 6;
5493
5494 extern volatile __bit TMR0CS @ (((unsigned) &OPTION_REG)*8) + 5;
5495
5496 extern volatile __bit TMR0IE @ (((unsigned) &INTCON)*8) + 5;
5497
5498 extern volatile __bit TMR0IF @ (((unsigned) &INTCON)*8) + 2;
5499
5500 extern volatile __bit TMR0SE @ (((unsigned) &OPTION_REG)*8) + 4;
5501
5502 extern volatile __bit TMR1CS0 @ (((unsigned) &T1CON)*8) + 6;
5503
5504 extern volatile __bit TMR1CS1 @ (((unsigned) &T1CON)*8) + 7;
5505
5506 extern volatile __bit TMR1GE @ (((unsigned) &T1GCON)*8) + 7;
5507
5508 extern volatile __bit TMR1GIE @ (((unsigned) &PIE1)*8) + 7;
5509
5510 extern volatile __bit TMR1GIF @ (((unsigned) &PIR1)*8) + 7;
5511
5512 extern volatile __bit TMR1IE @ (((unsigned) &PIE1)*8) + 0;
5513
5514 extern volatile __bit TMR1IF @ (((unsigned) &PIR1)*8) + 0;
5515
5516 extern volatile __bit TMR1ON @ (((unsigned) &T1CON)*8) + 0;
5517
5518 extern volatile __bit TMR2IE @ (((unsigned) &PIE1)*8) + 1;
5519
5520 extern volatile __bit TMR2IF @ (((unsigned) &PIR1)*8) + 1;
5521
5522 extern volatile __bit TMR2ON @ (((unsigned) &T2CON)*8) + 2;
5523
5524 extern volatile __bit TRISA0 @ (((unsigned) &TRISA)*8) + 0;
5525
5526 extern volatile __bit TRISA1 @ (((unsigned) &TRISA)*8) + 1;
5527
5528 extern volatile __bit TRISA2 @ (((unsigned) &TRISA)*8) + 2;
5529
5530 extern volatile __bit TRISA3 @ (((unsigned) &TRISA)*8) + 3;
5531
5532 extern volatile __bit TRISA4 @ (((unsigned) &TRISA)*8) + 4;
5533
5534 extern volatile __bit TRISA5 @ (((unsigned) &TRISA)*8) + 5;
5535
5536 extern volatile __bit TRMT @ (((unsigned) &TXSTA)*8) + 1;
5537
5538 extern volatile __bit TSEN @ (((unsigned) &FVRCON)*8) + 5;
5539
5540 extern volatile __bit TSRNG @ (((unsigned) &FVRCON)*8) + 4;
5541
5542 extern volatile __bit TUN0 @ (((unsigned) &OSCTUNE)*8) + 0;
5543
5544 extern volatile __bit TUN1 @ (((unsigned) &OSCTUNE)*8) + 1;
5545
5546 extern volatile __bit TUN2 @ (((unsigned) &OSCTUNE)*8) + 2;
5547
5548 extern volatile __bit TUN3 @ (((unsigned) &OSCTUNE)*8) + 3;
5549
5550 extern volatile __bit TUN4 @ (((unsigned) &OSCTUNE)*8) + 4;
5551
5552 extern volatile __bit TUN5 @ (((unsigned) &OSCTUNE)*8) + 5;
5553
5554 extern volatile __bit TX9 @ (((unsigned) &TXSTA)*8) + 6;
5555
5556 extern volatile __bit TX9D @ (((unsigned) &TXSTA)*8) + 0;
5557
5558 extern volatile __bit TXCKSEL @ (((unsigned) &APFCON)*8) + 2;
5559
5560 extern volatile __bit TXEN @ (((unsigned) &TXSTA)*8) + 5;
5561
5562 extern volatile __bit TXIE @ (((unsigned) &PIE1)*8) + 4;
5563
5564 extern volatile __bit TXIF @ (((unsigned) &PIR1)*8) + 4;
5565
5566 extern volatile __bit UA @ (((unsigned) &SSP1STAT)*8) + 1;
5567
5568 extern volatile __bit VREGPM0 @ (((unsigned) &VREGCON)*8) + 0;
5569
5570 extern volatile __bit VREGPM1 @ (((unsigned) &VREGCON)*8) + 1;
5571
5572 extern volatile __bit WCOL @ (((unsigned) &SSP1CON1)*8) + 7;
5573
5574 extern volatile __bit WDTPS0 @ (((unsigned) &WDTCON)*8) + 1;
5575
5576 extern volatile __bit WDTPS1 @ (((unsigned) &WDTCON)*8) + 2;
5577
5578 extern volatile __bit WDTPS2 @ (((unsigned) &WDTCON)*8) + 3;
5579
5580 extern volatile __bit WDTPS3 @ (((unsigned) &WDTCON)*8) + 4;
5581
5582 extern volatile __bit WDTPS4 @ (((unsigned) &WDTCON)*8) + 5;
5583
5584 extern volatile __bit WPUA0 @ (((unsigned) &WPUA)*8) + 0;
5585
5586 extern volatile __bit WPUA1 @ (((unsigned) &WPUA)*8) + 1;
5587
5588 extern volatile __bit WPUA2 @ (((unsigned) &WPUA)*8) + 2;
5589
5590 extern volatile __bit WPUA3 @ (((unsigned) &WPUA)*8) + 3;
5591
5592 extern volatile __bit WPUA4 @ (((unsigned) &WPUA)*8) + 4;
5593
5594 extern volatile __bit WPUA5 @ (((unsigned) &WPUA)*8) + 5;
5595
5596 extern volatile __bit WR @ (((unsigned) &EECON1)*8) + 1;
5597
5598 extern volatile __bit WREN @ (((unsigned) &EECON1)*8) + 2;
5599
5600 extern volatile __bit WRERR @ (((unsigned) &EECON1)*8) + 3;
5601
5602 extern volatile __bit WUE @ (((unsigned) &BAUDCON)*8) + 1;
5603
5604 extern volatile __bit ZERO @ (((unsigned) &STATUS)*8) + 2;
5605
5606 extern volatile __bit Z_SHAD @ (((unsigned) &STATUS_SHAD)*8) + 2;
5607
5608 extern volatile __bit nBOR @ (((unsigned) &PCON)*8) + 0;
5609
5610 extern volatile __bit nPD @ (((unsigned) &STATUS)*8) + 3;
5611
5612 extern volatile __bit nPOR @ (((unsigned) &PCON)*8) + 1;
5613
5614 extern volatile __bit nRI @ (((unsigned) &PCON)*8) + 2;
5615
5616 extern volatile __bit nRMCLR @ (((unsigned) &PCON)*8) + 3;
5617
5618 extern volatile __bit nT1SYNC @ (((unsigned) &T1CON)*8) + 2;
5619
5620 extern volatile __bit nTO @ (((unsigned) &STATUS)*8) + 4;
5621
5622 extern volatile __bit nWPUEN @ (((unsigned) &OPTION_REG)*8) + 7;
5623
5624 # 31 "system.h"
5625 void ConfigureOscillator(void);
5626
5627 # 13 "user.h"
5628 void InitApp(void);
5629 bool msg_empty(void);
5630 void msg_write(const char *msg);
5631 void msg_writebyte(const char msg);
5632 void msg_sendnext(void);
5633 void tohex(char val[3], char i);
5634 void msg_recvnext(void);
5635 bool msg_recvready(void);
5636 char msg_recv(void);
5637 void putch(char);
5638
5639 void int_disable(void);
5640 void int_enable(void);
5641
5642 # 11 "onewire.h"
5643 bool OW_reset(void);
5644 void OW_write_bit(bool val);
5645 bool OW_read_bit();
5646 void OW_write_byte(unsigned char byte);
5647 unsigned char OW_read_byte(void);
5648
5649 void OW_search_init();
5650 bool OW_search(void);
5651 void OW_start(void);
5652
5653 void OW_identify();
5654 bool OW_parasite(void);
5655 void OW_read_block(uint8_t code, uint8_t * data, uint8_t len);
5656 void OW_convert();
5657
5658
5659 inline void drive_OW_low(void);
5660 inline void drive_OW_high(void);
5661 inline void float_OW(void);
5662 inline bool read_OW(void);
5663
5664 extern unsigned char romid[8];
5665
5666 # 24 "onewire.c"
5667 inline void drive_OW_low(void)
5668 {
5669 PORTAbits.RA5 = 0;
5670 TRISAbits.TRISA5 = 0;
5671 }
5672
5673 inline void drive_OW_high(void)
5674 {
5675 PORTAbits.RA5 = 1;
5676 TRISAbits.TRISA5 = 0;
5677 }
5678
5679 inline void float_OW(void)
5680 {
5681 TRISAbits.TRISA5 = 1;
5682 }
5683
5684 inline bool read_OW(void)
5685 {
5686 TRISAbits.TRISA5 = 1;
5687 return PORTAbits.RA5;
5688 }
5689
5690 # 51
5691 void OW_start(void)
5692 {
5693
5694 float_OW();
5695 }
5696
5697
5698 bool OW_reset(void)
5699 {
5700 bool presence = 0;
5701
5702 { PORTAbits.RA5 = 0; TRISAbits.TRISA5 = 0; };
5703 _delay(250);
5704 _delay(250);
5705 { TRISAbits.TRISA5 = 1; };
5706 _delay(70);
5707 presence = (PORTAbits.RA5);
5708 _delay(215);
5709 _delay(215);
5710
5711 return ! presence;
5712 }
5713
5714 void OW_write_bit(bool val)
5715 {
5716
5717 # 84
5718 { PORTAbits.RA5 = 0; TRISAbits.TRISA5 = 0; };
5719 _nop();
5720 _nop();
5721
5722 if (val) { TRISAbits.TRISA5 = 1; };
5723 _delay(60);
5724 { TRISAbits.TRISA5 = 1; };
5725 _nop();
5726 _nop();
5727
5728 }
5729
5730 bool OW_read_bit()
5731 {
5732 bool val;
5733
5734 # 107
5735 { PORTAbits.RA5 = 0; TRISAbits.TRISA5 = 0; };
5736
5737 _nop();
5738 _nop();
5739 _nop();
5740 _nop();
5741 _nop();
5742 { TRISAbits.TRISA5 = 1; };
5743
5744 _nop();
5745 _nop();
5746 _nop();
5747 val = read_OW();
5748 _delay(50);
5749
5750
5751 return val;
5752 }
5753
5754 void OW_write_byte(unsigned char byte)
5755 {
5756 for (char i=8; i!=0; i--)
5757 {
5758 OW_write_bit( byte & 0x01 );
5759 byte >>= 1;
5760 }
5761 }
5762
5763 unsigned char OW_read_byte(void)
5764 {
5765 unsigned char byte = 0;
5766 for (char i=8; i!=0; i--)
5767 {
5768 byte >>= 1;
5769 if (OW_read_bit())
5770 byte |= 0x80;
5771
5772 }
5773 return byte;
5774 }
5775
5776 static const unsigned char dscrc_table[] = {
5777 0, 94,188,226, 97, 63,221,131,194,156,126, 32,163,253, 31, 65,
5778 157,195, 33,127,252,162, 64, 30, 95, 1,227,189, 62, 96,130,220,
5779 35,125,159,193, 66, 28,254,160,225,191, 93, 3,128,222, 60, 98,
5780 190,224, 2, 92,223,129, 99, 61,124, 34,192,158, 29, 67,161,255,
5781 70, 24,250,164, 39,121,155,197,132,218, 56,102,229,187, 89, 7,
5782 219,133,103, 57,186,228, 6, 88, 25, 71,165,251,120, 38,196,154,
5783 101, 59,217,135, 4, 90,184,230,167,249, 27, 69,198,152,122, 36,
5784 248,166, 68, 26,153,199, 37,123, 58,100,134,216, 91, 5,231,185,
5785 140,210, 48,110,237,179, 81, 15, 78, 16,242,172, 47,113,147,205,
5786 17, 79,173,243,112, 46,204,146,211,141,111, 49,178,236, 14, 80,
5787 175,241, 19, 77,206,144,114, 44,109, 51,209,143, 12, 82,176,238,
5788 50,108,142,208, 83, 13,239,177,240,174, 76, 18,145,207, 45,115,
5789 202,148,118, 40,171,245, 23, 73, 8, 86,180,234,105, 55,213,139,
5790 87, 9,235,181, 54,104,138,212,149,203, 41,119,244,170, 72, 22,
5791 233,183, 85, 11,136,214, 52,106, 43,117,151,201, 74, 20,246,168,
5792 116, 42,200,150, 21, 75,169,247,182,232, 10, 84,215,137,107, 53
5793 };
5794
5795 unsigned char romid[8];
5796 char LastDiscrepancy = 0;
5797 char LastFamilyDiscrepancy = 0;
5798 char LastDeviceFlag = 0;
5799 unsigned char crc8;
5800
5801 static unsigned char docrc8(unsigned char value)
5802 {
5803 crc8 = dscrc_table[crc8 ^ value];
5804 return crc8;
5805 }
5806
5807
5808 bool OW_search()
5809 {
5810 char id_bit_number = 1;
5811 char last_zero = 0;
5812 char rom_byte_number = 0;
5813 char search_result = 0;
5814 unsigned char rom_byte_mask = 1;
5815 unsigned char search_direction;
5816
5817 crc8 = 0;
5818
5819
5820 int_disable();
5821
5822
5823 if (!LastDeviceFlag) {
5824 if (!OW_reset())
5825 {
5826 msg_write("Reset said nothing there.\r\n");
5827
5828 LastDiscrepancy = 0;
5829 LastDeviceFlag = 0;
5830 LastFamilyDiscrepancy = 0;
5831 int_enable();
5832 return 0;
5833 }
5834
5835
5836 OW_write_byte(0xF0);
5837
5838
5839 do {
5840
5841 bool id_bit = OW_read_bit();
5842 _delay(6);
5843 bool cmp_id_bit = OW_read_bit();
5844
5845
5846 if (id_bit && cmp_id_bit) {
5847 break;
5848 }
5849
5850 if (id_bit != cmp_id_bit) {
5851
5852 search_direction = id_bit;
5853 } else {
5854
5855
5856
5857
5858 if (id_bit_number < LastDiscrepancy) {
5859 search_direction = ((romid[rom_byte_number] & rom_byte_mask) > 0);
5860 } else {
5861
5862 search_direction = (id_bit_number == LastDiscrepancy);
5863 }
5864
5865
5866 if (search_direction == 0)
5867 {
5868 last_zero = id_bit_number;
5869
5870 if (last_zero < 9)
5871 LastFamilyDiscrepancy = last_zero;
5872 }
5873 }
5874
5875
5876
5877 if (search_direction == 1)
5878 romid[rom_byte_number] |= rom_byte_mask;
5879 else
5880 romid[rom_byte_number] &= ~rom_byte_mask;
5881
5882
5883 OW_write_bit(search_direction);
5884
5885
5886
5887 id_bit_number++;
5888 rom_byte_mask <<= 1;
5889
5890
5891 if (rom_byte_mask == 0)
5892 {
5893 docrc8(romid[rom_byte_number]);
5894 rom_byte_number++;
5895 rom_byte_mask = 1;
5896 }
5897 } while (rom_byte_number < 8);
5898 }
5899
5900
5901 if (!(id_bit_number < 65 || crc8 != 0))
5902 {
5903
5904 LastDiscrepancy = last_zero;
5905
5906
5907 if (LastDiscrepancy == 0)
5908 LastDeviceFlag = 1;
5909
5910 search_result = 1;
5911 }
5912
5913 if (!search_result || !romid[0])
5914 {
5915 LastDiscrepancy = 0;
5916 LastDeviceFlag = 0;
5917 LastFamilyDiscrepancy = 0;
5918 search_result = 0;
5919 }
5920
5921 int_enable();
5922 return search_result;
5923 }
5924
5925
5926 void OW_search_init()
5927 {
5928 LastDiscrepancy = 0;
5929 LastDeviceFlag = 0;
5930 LastFamilyDiscrepancy = 0;
5931
5932 for (int j=0; j<8; j++) romid[j]=0;
5933 }
5934
5935
5936
5937 void OW_identify()
5938 {
5939 int_disable();
5940 OW_reset();
5941
5942 OW_write_byte(0x33);
5943 for (int j=0; j<8; j++)
5944 romid[j] = OW_read_byte();
5945 int_enable();
5946 }
5947
5948
5949 bool OW_parasite(void)
5950 {
5951 int_disable();
5952 OW_reset();
5953 OW_write_byte(0xCC);
5954 OW_write_byte(0xB4);
5955 bool no = OW_read_bit();
5956 int_enable();
5957 return !no;
5958 }
5959
5960 # 335
5961 static void OW_select_id(void)
5962 {
5963 if (romid[0] == 0) {
5964 OW_write_byte(0xCC);
5965 } else {
5966 OW_write_byte(0x55);
5967 for (int8_t j=0; j<8; j++) {
5968 OW_write_byte(romid[j]);
5969 }
5970 }
5971 }
5972
5973
5974
5975 void OW_read_block(uint8_t code, uint8_t * data, uint8_t len)
5976 {
5977 int_disable();
5978 OW_reset();
5979 OW_select_id();
5980 OW_write_byte(code);
5981 for (int8_t j=0; j<len; j++)
5982 data[j] = OW_read_byte();
5983 int_enable();
5984 }
5985
5986
5987 void OW_write_block(uint8_t code, uint8_t * data, uint8_t len)
5988 {
5989 int_disable();
5990 OW_reset();
5991 OW_select_id();
5992 OW_write_byte(code);
5993 for (int8_t j=0; j<len; j++) {
5994 OW_write_byte(data[j]);
5995 }
5996 int_enable();
5997 }
5998
5999
6000
6001 void OW_convert()
6002 {
6003
6004 bool para = OW_parasite();
6005
6006 int_disable();
6007 OW_reset();
6008 OW_select_id();
6009
6010 OW_write_byte(0x44);
6011 if (para) {
6012
6013 { PORTAbits.RA5 = 1; TRISAbits.TRISA5 = 0; };
6014 _delay(250000);
6015 _delay(250000);
6016 _delay(250000);
6017 _delay(250000);
6018 } else {
6019
6020
6021 do {
6022 _delay(1000);
6023 } while (!OW_read_bit());
6024 }
6025 int_enable();
6026 }
6027