2
; P16F876.INC Standard Header File, Version 1.00 Microchip Technology, Inc.
5
; This header file defines configurations, registers, and other useful bits of
6
; information for the PIC16F876 microcontroller. These names are taken to match
7
; the data sheets as closely as possible.
9
; Note that the processor must be selected before this file is
10
; included. The processor may be selected the following ways:
12
; 1. Command line switch:
13
; C:\ MPASM MYFILE.ASM /PIC16F876
14
; 2. LIST directive in the source file
16
; 3. Processor Type entry in the MPASM full-screen interface
18
;==========================================================================
22
;==========================================================================
26
;1.12 01/12/00 Changed some bit names, a register name, configuration bits
27
; to match datasheet (DS30292B)
28
;1.00 08/07/98 Initial Release
30
;==========================================================================
34
;==========================================================================
37
MESSG "Processor-header file mismatch. Verify selected processor."
40
;==========================================================================
42
; Register Definitions
44
;==========================================================================
49
;----- Register Files------------------------------------------------------
83
OPTION_REG EQU H'0081'
107
;----- STATUS Bits --------------------------------------------------------
118
;----- INTCON Bits --------------------------------------------------------
129
;----- PIR1 Bits ----------------------------------------------------------
139
;----- PIR2 Bits ----------------------------------------------------------
145
;----- T1CON Bits ---------------------------------------------------------
150
NOT_T1SYNC EQU H'0002'
151
T1INSYNC EQU H'0002' ; Backward compatibility only
156
;----- T2CON Bits ---------------------------------------------------------
166
;----- SSPCON Bits --------------------------------------------------------
177
;----- CCP1CON Bits -------------------------------------------------------
186
;----- RCSTA Bits ---------------------------------------------------------
190
RC9 EQU H'0006' ; Backward compatibility only
191
NOT_RC8 EQU H'0006' ; Backward compatibility only
192
RC8_9 EQU H'0006' ; Backward compatibility only
199
RCD8 EQU H'0000' ; Backward compatibility only
201
;----- CCP2CON Bits -------------------------------------------------------
210
;----- ADCON0 Bits --------------------------------------------------------
222
;----- OPTION_REG Bits ----------------------------------------------------
233
;----- PIE1 Bits ----------------------------------------------------------
243
;----- PIE2 Bits ----------------------------------------------------------
249
;----- PCON Bits ----------------------------------------------------------
255
;----- SSPCON2 Bits --------------------------------------------------------
266
;----- SSPSTAT Bits -------------------------------------------------------
273
NOT_ADDRESS EQU H'0005'
275
DATA_ADDRESS EQU H'0005'
279
I2C_START EQU H'0003'
283
NOT_WRITE EQU H'0002'
285
READ_WRITE EQU H'0002'
289
;----- TXSTA Bits ---------------------------------------------------------
293
NOT_TX8 EQU H'0006' ; Backward compatibility only
294
TX8_9 EQU H'0006' ; Backward compatibility only
300
TXD8 EQU H'0000' ; Backward compatibility only
302
;----- ADCON1 Bits --------------------------------------------------------
310
;----- EECON1 Bits --------------------------------------------------------
318
;==========================================================================
322
;==========================================================================
326
__BADRAM H'88'-H'89', H'8F'-H'90', H'95'-H'97', H'9A'-H'9D'
327
__BADRAM H'105', H'107'-H'109'
328
__BADRAM H'185', H'187'-H'189', H'18E'-H'18F'
330
;==========================================================================
334
;==========================================================================
338
_CP_UPPER_256 EQU H'2FEF'
340
_DEBUG_ON EQU H'37FF'
341
_DEBUG_OFF EQU H'3FFF'
342
_WRT_ENABLE_ON EQU H'3FFF'
343
_WRT_ENABLE_OFF EQU H'3DFF'
348
_BODEN_ON EQU H'3FFF'
349
_BODEN_OFF EQU H'3FBF'
350
_PWRTE_OFF EQU H'3FFF'
351
_PWRTE_ON EQU H'3FF7'