Imported Upstream version 2.9.0
[debian/cc1111] / device / lib / pic16 / libdev / pic18f4220.c
1
2 /*
3  * pic18f4220.c - PIC18F4220 Device Library Source
4  *
5  * This file is part of the GNU PIC Library.
6  *
7  * January, 2004
8  * The GNU PIC Library is maintained by,
9  *      Vangelis Rokas <vrokas@otenet.gr>
10  *
11  * $Id: pic18f4220.c 3835 2005-08-07 20:09:11Z tecodev $
12  *
13  */
14
15 #include <pic18f4220.h>
16
17 __sfr __at (0xf80) PORTA;
18 volatile __PORTAbits_t __at (0xf80) PORTAbits;
19
20 __sfr __at (0xf81) PORTB;
21 volatile __PORTBbits_t __at (0xf81) PORTBbits;
22
23 __sfr __at (0xf82) PORTC;
24 volatile __PORTCbits_t __at (0xf82) PORTCbits;
25
26 __sfr __at (0xf83) PORTD;
27 volatile __PORTDbits_t __at (0xf83) PORTDbits;
28
29 __sfr __at (0xf84) PORTE;
30 volatile __PORTEbits_t __at (0xf84) PORTEbits;
31
32 __sfr __at (0xf89) LATA;
33 volatile __LATAbits_t __at (0xf89) LATAbits;
34
35 __sfr __at (0xf8a) LATB;
36 volatile __LATBbits_t __at (0xf8a) LATBbits;
37
38 __sfr __at (0xf8b) LATC;
39 volatile __LATCbits_t __at (0xf8b) LATCbits;
40
41 __sfr __at (0xf8c) LATD;
42 volatile __LATDbits_t __at (0xf8c) LATDbits;
43
44 __sfr __at (0xf8d) LATE;
45 volatile __LATEbits_t __at (0xf8d) LATEbits;
46
47 __sfr __at (0xf92) TRISA;
48 volatile __TRISAbits_t __at (0xf92) TRISAbits;
49
50 __sfr __at (0xf93) TRISB;
51 volatile __TRISBbits_t __at (0xf93) TRISBbits;
52
53 __sfr __at (0xf94) TRISC;
54 volatile __TRISCbits_t __at (0xf94) TRISCbits;
55
56 __sfr __at (0xf9b) OSCTUNE;
57 volatile __OSCTUNEbits_t __at (0xf9b) OSCTUNEbits;
58
59 __sfr __at (0xf9d) PIE1;
60 volatile __PIE1bits_t __at (0xf9d) PIE1bits;
61
62 __sfr __at (0xf9e) PIR1;
63 volatile __PIR1bits_t __at (0xf9e) PIR1bits;
64
65 __sfr __at (0xf9f) IPR1;
66 volatile __IPR1bits_t __at (0xf9f) IPR1bits;
67
68 __sfr __at (0xfa0) PIE2;
69 volatile __PIE2bits_t __at (0xfa0) PIE2bits;
70
71 __sfr __at (0xfa1) PIR2;
72 volatile __PIR2bits_t __at (0xfa1) PIR2bits;
73
74 __sfr __at (0xfa2) IPR2;
75 volatile __IPR2bits_t __at (0xfa2) IPR2bits;
76
77 __sfr __at (0xfa6) EECON1;
78 volatile __EECON1bits_t __at (0xfa6) EECON1bits;
79
80 __sfr __at (0xfa7) EECON2;
81 __sfr __at (0xfa8) EEDATA;
82 __sfr __at (0xfa9) EEADR;
83 __sfr __at (0xfab) RCSTA;
84 volatile __RCSTAbits_t __at (0xfab) RCSTAbits;
85
86 __sfr __at (0xfac) TXSTA;
87 volatile __TXSTAbits_t __at (0xfac) TXSTAbits;
88
89 __sfr __at (0xfad) TXREG;
90 __sfr __at (0xfae) RCREG;
91 __sfr __at (0xfaf) SPBRG;
92 __sfr __at (0xfb1) T3CON;
93 volatile __T3CONbits_t __at (0xfb1) T3CONbits;
94
95 __sfr __at (0xfb2) TMR3L;
96 __sfr __at (0xfb3) TMR3H;
97 __sfr __at (0xfb4) CMCON;
98 volatile __CMCONbits_t __at (0xfb4) CMCONbits;
99
100 __sfr __at (0xfb5) CVRCON;
101 volatile __CVRCONbits_t __at (0xfb5) CVRCONbits;
102
103 __sfr __at (0xfba) CCP2CON;
104 volatile __CCP2CONbits_t __at (0xfba) CCP2CONbits;
105
106 __sfr __at (0xfb7) PWM1CON;
107 volatile __PWM1CONbits_t __at (0xfb7) PWM1CONbits;
108
109 __sfr __at (0xfb6) ECCPAS;
110 volatile __ECCPASbits_t __at (0xfb6) ECCPASbits;
111
112 __sfr __at (0xfba) CCP2CON;
113 volatile __CCP2CONbits_t __at (0xfba) CCP2CONbits;
114
115 __sfr __at (0xfbb) CCPR2L;
116 __sfr __at (0xfbc) CCPR2H;
117 __sfr __at (0xfbd) CCP1CON;
118 volatile __CCP1CONbits_t __at (0xfbd) CCP1CONbits;
119
120 __sfr __at (0xfbe) CCPR1L;
121 __sfr __at (0xfbf) CCPR1H;
122 __sfr __at (0xfc0) ADCON2;
123 volatile __ADCON2bits_t __at (0xfc0) ADCON2bits;
124
125 __sfr __at (0xfc1) ADCON1;
126 volatile __ADCON1bits_t __at (0xfc1) ADCON1bits;
127
128 __sfr __at (0xfc2) ADCON0;
129 volatile __ADCON0bits_t __at (0xfc2) ADCON0bits;
130
131 __sfr __at (0xfc3) ADRESL;
132 __sfr __at (0xfc4) ADRESH;
133 __sfr __at (0xfc5) SSPCON2;
134 volatile __SSPCON2bits_t __at (0xfc5) SSPCON2bits;
135
136 __sfr __at (0xfc6) SSPCON1;
137 volatile __SSPCON1bits_t __at (0xfc6) SSPCON1bits;
138
139 __sfr __at (0xfc7) SSPSTAT;
140 volatile __SSPSTATbits_t __at (0xfc7) SSPSTATbits;
141
142 __sfr __at (0xfc8) SSPADD;
143 __sfr __at (0xfc9) SSPBUF;
144 __sfr __at (0xfca) T2CON;
145 volatile __T2CONbits_t __at (0xfca) T2CONbits;
146
147 __sfr __at (0xfcb) PR2;
148 __sfr __at (0xfcc) TMR2;
149 __sfr __at (0xfcd) T1CON;
150 volatile __T1CONbits_t __at (0xfcd) T1CONbits;
151
152 __sfr __at (0xfce) TMR1L;
153 __sfr __at (0xfcf) TMR1H;
154 __sfr __at (0xfd0) RCON;
155 volatile __RCONbits_t __at (0xfd0) RCONbits;
156
157 __sfr __at (0xfd1) WDTCON;
158 volatile __WDTCONbits_t __at (0xfd1) WDTCONbits;
159
160 __sfr __at (0xfd2) LVDCON;
161 volatile __LVDCONbits_t __at (0xfd2) LVDCONbits;
162
163 __sfr __at (0xfd3) OSCCON;
164 volatile __OSCCONbits_t __at (0xfd3) OSCCONbits;
165
166 __sfr __at (0xfd5) T0CON;
167 volatile __T0CONbits_t __at (0xfd5) T0CONbits;
168
169 __sfr __at (0xfd6) TMR0L;
170 __sfr __at (0xfd7) TMR0H;
171 __sfr __at (0xfd8) STATUS;
172 volatile __STATUSbits_t __at (0xfd8) STATUSbits;
173
174 __sfr __at (0xfd9) FSR2L;
175 __sfr __at (0xfda) FSR2H;
176 __sfr __at (0xfdb) PLUSW2;
177 __sfr __at (0xfdc) PREINC2;
178 __sfr __at (0xfdd) POSTDEC2;
179 __sfr __at (0xfde) POSTINC2;
180 __sfr __at (0xfdf) INDF2;
181 __sfr __at (0xfe0) BSR;
182 __sfr __at (0xfe1) FSR1L;
183 __sfr __at (0xfe2) FSR1H;
184 __sfr __at (0xfe3) PLUSW1;
185 __sfr __at (0xfe4) PREINC1;
186 __sfr __at (0xfe5) POSTDEC1;
187 __sfr __at (0xfe6) POSTINC1;
188 __sfr __at (0xfe7) INDF1;
189 __sfr __at (0xfe8) WREG;
190 __sfr __at (0xfe9) FSR0L;
191 __sfr __at (0xfea) FSR0H;
192 __sfr __at (0xfeb) PLUSW0;
193 __sfr __at (0xfec) PREINC0;
194 __sfr __at (0xfed) POSTDEC0;
195 __sfr __at (0xfee) POSTINC0;
196 __sfr __at (0xfef) INDF0;
197 __sfr __at (0xff0) INTCON3;
198 volatile __INTCON3bits_t __at (0xff0) INTCON3bits;
199
200 __sfr __at (0xff1) INTCON2;
201 volatile __INTCON2bits_t __at (0xff1) INTCON2bits;
202
203 __sfr __at (0xff2) INTCON;
204 volatile __INTCONbits_t __at (0xff2) INTCONbits;
205
206 __sfr __at (0xff3) PRODL;
207 __sfr __at (0xff4) PRODH;
208 __sfr __at (0xff5) TABLAT;
209 __sfr __at (0xff6) TBLPTRL;
210 __sfr __at (0xff7) TBLPTRH;
211 __sfr __at (0xff8) TBLPTRU;
212 __sfr __at (0xff9) PCL;
213 __sfr __at (0xffa) PCLATH;
214 __sfr __at (0xffb) PCLATU;
215 __sfr __at (0xffc) STKPTR;
216 volatile __STKPTRbits_t __at (0xffc) STKPTRbits;
217
218 __sfr __at (0xffd) TOSL;
219 __sfr __at (0xffe) TOSH;
220 __sfr __at (0xfff) TOSU;
221
222