;
; This file defines SFR names and bit names for Microchip's PIC12 processors.
;
; This file can be configured for different devices.
; At the beginning of the file there are definitions common for all devices
; Device-specific definitions are introduced by
;
;       .devicename
;
; line. Also an optional directive
;
;       .default=devicename
;
; designates the default device name.
;
;
; It is allowed to have several mappings for the same port. For example:
;
; STATUS     0x03
; STATUS     0x23
;
; In this case IDA will redirect all memory references to the first definition.
; (all references to 0x23 will be rerouted to 0x03)
;



.default=12C508

INDF       0x00
TMR0       0x01
PCL        0x02
STATUS     0x03
STATUS.GPWUF          7  ; GPIO reset
STATUS.PA0            5  ; program page preselect
STATUS.TO             4  ; time-out
STATUS.PD             3  ; power-down
STATUS.Z              2  ; zero
STATUS.DC             1  ; digit carry
STATUS.C              0  : carry
FSR        0x04
OSCCAL     0x05
GPIO       0x06
GPIO.GP5              5
GPIO.GP4              4
GPIO.GP3              3
GPIO.GP2              2
GPIO.GP1              1
GPIO.GP0              0

;-------------------------------
; Device specific definitions

.12C508

OSCCAL.CAL3           7
OSCCAL.CAL2           6
OSCCAL.CAL1           5
OSCCAL.CAL0           4

.12C508A

OSCCAL.CAL5           7
OSCCAL.CAL4           6
OSCCAL.CAL3           5
OSCCAL.CAL2           4
OSCCAL.CAL1           3
OSCCAL.CAL0           2

.12CE518

OSCCAL.CAL5           7
OSCCAL.CAL4           6
OSCCAL.CAL3           5
OSCCAL.CAL2           4
OSCCAL.CAL1           3
OSCCAL.CAL0           2
GPIO.SCL              7
GPIO.SDA              6

.12C509

OSCCAL.CAL3           7
OSCCAL.CAL2           6
OSCCAL.CAL1           5
OSCCAL.CAL0           4

INDF       0x20
TMR0       0x21
PCL        0x22
STATUS     0x23
FSR        0x24
OSCCAL     0x25
GPIO       0x26

.12C509A

OSCCAL.CAL5           7
OSCCAL.CAL4           6
OSCCAL.CAL3           5
OSCCAL.CAL2           4
OSCCAL.CAL1           3
OSCCAL.CAL0           2

INDF       0x20
TMR0       0x21
PCL        0x22
STATUS     0x23
FSR        0x24
OSCCAL     0x25
GPIO       0x26

.12CE519

OSCCAL.CAL5           7
OSCCAL.CAL4           6
OSCCAL.CAL3           5
OSCCAL.CAL2           4
OSCCAL.CAL1           3
OSCCAL.CAL0           2
GPIO.SCL              7
GPIO.SDA              6

INDF       0x20
TMR0       0x21
PCL        0x22
STATUS     0x23
FSR        0x24
OSCCAL     0x25
GPIO       0x26

.12CR509A

OSCCAL.CAL5           7
OSCCAL.CAL4           6
OSCCAL.CAL3           5
OSCCAL.CAL2           4
OSCCAL.CAL1           3
OSCCAL.CAL0           2

INDF       0x20
TMR0       0x21
PCL        0x22
STATUS     0x23
FSR        0x24
OSCCAL     0x25
GPIO       0x26

; insert definitions here
