#
# Specification of devices supported by the PIC16 target of the
# Small Devices C Compiler (SDCC).
#
# Lines starting with a hash '#' are ignored.
# A new device specification must begin with a 'name' command.
# Numbers can be given in any way acceptable for scanf's %d,
# i.e., octal (0[0-7]*), decimal ([1-9][0-9]*), or hexadecimal
# (0[xX][0-9a-fA-F]+).
# Strings must not be quoted and may not contain whitespace!
#
# Valid commands are:
# name <name>
#       Begin specification of device type <name>, e.g. 18f6720.
#       Aliases 'p<name>' and 'pic<name>' will be recognized as well.
# using <name>
#       Import specification from the named entry, which must be defined
#       earlier. Later commands overrule imported ones.
# ramsize <size>
#       This device has <size> bytes of RAM.
# split <offset>
#       Addresses below <offset> refer to bank 0, addresses above <offset>
#       refer to SFRs in bank 15 for references via the access bank.
# configrange <first> <last>
#       Configuration registers occupy addresses <first> to <last> (both
#       included).
# configword <address> <mask> <value> [<and-mask>]
#       The config word at address <address> only implements the bits
#       indicated via <mask> (all others will be forced to 0 by the
#       compiler).
#       Unless overridden in C code, use the given default <value>.
#       The optional <and-mask> will be applied to the value just before
#       emitting it into the .asm file (used to disable XINST by default).
# idlocrange <first> <last>
#       ID locations occupy addresses <first> to <last> (both included).
# idword <address> <value>
#       Unless overridden in C code, use the given default <value>.
#

name        18f1220
ramsize     256
split       0x80
configrange 0x300001 0x30000d
configword  0x300001 0xcf 0xff
configword  0x300002 0x0f 0xff
configword  0x300003 0x1f 0xff
configword  0x300005 0x80 0xff
configword  0x300006 0x85 0xff
configword  0x300008 0x03 0xff
configword  0x300009 0xc0 0xff
configword  0x30000a 0x03 0xff
configword  0x30000b 0xe0 0xff
configword  0x30000c 0x03 0xff
configword  0x30000d 0x40 0xff
idlocrange  0x200000 0x200007


name        18f1320
using       18f1220


name        18f13k50
ramsize     512
split       0x60
configrange 0x300000 0x30000d
configword  0x300000 0x38 0xc7
configword  0x300001 0xff 0x27
configword  0x300002 0x1f 0xff
configword  0x300003 0x1f 0xff
configword  0x300005 0x88 0xff
configword  0x300006 0x4d 0xb7 0xbf
configword  0x300008 0x03 0xff
configword  0x300009 0xc0 0xff
configword  0x30000a 0x03 0xff
configword  0x30000b 0xe0 0xff
configword  0x30000c 0x03 0xff
configword  0x30000d 0x40 0xff
idlocrange  0x200000 0x200007


name        18f14k50
using       18f13k50
ramsize     768


name        18f2220
ramsize     512
split       0x80
configrange 0x300001 0x30000d
configword  0x300001 0xcf 0xff
configword  0x300002 0x0f 0xff
configword  0x300003 0x1f 0xff
configword  0x300005 0x83 0xff
configword  0x300006 0x85 0xff
configword  0x300008 0x0f 0xff
configword  0x300009 0xc0 0xff
configword  0x30000a 0x0f 0xff
configword  0x30000b 0xe0 0xff
configword  0x30000c 0x0f 0xff
configword  0x30000d 0x40 0xff
idlocrange  0x200000 0x200007


name        18f2221
ramsize     512
split       0x80
configrange 0x300001 0x30000d
configword  0x300001 0xcf 0x37
configword  0x300002 0x1f 0xff
configword  0x300003 0x1f 0xff
configword  0x300005 0x87 0xfb
configword  0x300006 0xf5 0x8f 0xbf
configword  0x300008 0x03 0xff
configword  0x300009 0xc0 0xff
configword  0x30000a 0x03 0xff
configword  0x30000b 0xe0 0xff
configword  0x30000c 0x03 0xff
configword  0x30000d 0x40 0xff
idlocrange  0x200000 0x200007


name        18f2320
using       18f2220


name        18f2321
using       18f2221


name        18f2331
ramsize     768
split       0x60
configrange 0x300001 0x30000d
configword  0x300001 0xcf 0xff
configword  0x300002 0x0f 0xff
configword  0x300003 0x3f 0xff
configword  0x300004 0x3c 0xff
configword  0x300005 0x9d 0xff
configword  0x300006 0x85 0xff
configword  0x300008 0x0f 0xff
configword  0x300009 0xc0 0xff
configword  0x30000a 0x0f 0xff
configword  0x30000b 0xe0 0xff
configword  0x30000c 0x0f 0xff
configword  0x30000d 0x40 0xff
idlocrange  0x200000 0x200007


name        18f23k20
ramsize     512
split       0x60
configrange 0x300001 0x30000d
configword  0x300001 0xcf 0x37
configword  0x300002 0x1f 0xff
configword  0x300003 0x1f 0xff
configword  0x300005 0x8f 0xfb
configword  0x300006 0xc5 0xbf 0xbf
configword  0x300008 0x0f 0xff
configword  0x300009 0xc0 0xff
configword  0x30000a 0x0f 0xff
configword  0x30000b 0xe0 0xff
configword  0x30000c 0x0f 0xff
configword  0x30000d 0x40 0xff
idlocrange  0x200000 0x200007


name        18f2410
ramsize     768
split       0x80
configrange 0x300001 0x30000d
configword  0x300001 0xcf 0x37
configword  0x300002 0x1f 0xff
configword  0x300003 0x1f 0xfb
configword  0x300005 0x87 0xfb
configword  0x300006 0xc5 0xbf 0xbf
configword  0x300008 0x0f 0xff
configword  0x300009 0x40 0xff
configword  0x30000a 0x0f 0xff
configword  0x30000b 0x60 0xff
configword  0x30000c 0x0f 0xff
configword  0x30000d 0x40 0xff
idlocrange  0x200000 0x200007


name        18f242
ramsize     768
split       0x80
configrange 0x300001 0x30000d
configword  0x300001 0x27 0xff
configword  0x300002 0x0f 0xff
configword  0x300003 0x0f 0xff
configword  0x300005 0x01 0xff
configword  0x300006 0x85 0xff
configword  0x300008 0x0f 0xff
configword  0x300009 0xc0 0xff
configword  0x30000a 0x0f 0xff
configword  0x30000b 0xe0 0xff
configword  0x30000c 0x0f 0xff
configword  0x30000d 0x40 0xff
idlocrange  0x200000 0x200007


name        18f2420
ramsize     768
split       0x80
configrange 0x300001 0x30000d
configword  0x300001 0xcf 0x07
configword  0x300002 0x1f 0xff
configword  0x300003 0x1f 0xff
configword  0x300005 0x87 0xfb
configword  0x300006 0xc5 0xbf 0xbf
configword  0x300008 0x0f 0xff
configword  0x300009 0xc0 0xff
configword  0x30000a 0x0f 0xff
configword  0x30000b 0xe0 0xff
configword  0x30000c 0x0f 0xff
configword  0x30000d 0x40 0xff
idlocrange  0x200000 0x200007


name        18f2423
ramsize     768
split       0x80
configrange 0x300001 0x30000d
configword  0x300001 0xcf 0x07
configword  0x300002 0x1f 0xff
configword  0x300003 0x1f 0xff
configword  0x300005 0x87 0xfb
configword  0x300006 0xc5 0xbf 0xbf
configword  0x300008 0x0f 0xff
configword  0x300009 0xc0 0xff
configword  0x30000a 0x0f 0xff
configword  0x30000b 0xe0 0xff
configword  0x30000c 0x0f 0xff
configword  0x30000d 0x40 0xff
idlocrange  0x200000 0x200007


name        18f2431
using       18f2331


name        18f2450
# 0x200..0x3FF is not implemented, but we leave that to the linker ;-)
ramsize     0x500
split       0x60
configrange 0x300000 0x30000d
configword  0x300000 0x3f 0xc7
configword  0x300001 0xcf 0x37
configword  0x300002 0x3f 0xdf
configword  0x300003 0x1f 0xff
configword  0x300005 0x86 0xfb
configword  0x300006 0xed 0x97 0xbf
configword  0x300008 0x03 0xff
configword  0x300009 0x40 0xff
configword  0x30000a 0x03 0xff
configword  0x30000b 0x60 0xff
configword  0x30000c 0x03 0xff
configword  0x30000d 0x40 0xff
idlocrange  0x200000 0x200007


name        18f2455
ramsize     2048
split       0x60
configrange 0x300000 0x30000d
configword  0x300000 0x3f 0xc0
configword  0x300001 0xcf 0x35
configword  0x300002 0x3f 0xdf
configword  0x300003 0x1f 0xff
configword  0x300005 0x87 0xfb
configword  0x300006 0xe5 0x9f 0xbf
configword  0x300008 0x0f 0xff
configword  0x300009 0xc0 0xff
configword  0x30000a 0x0f 0xff
configword  0x30000b 0xe0 0xff
configword  0x30000c 0x0f 0xff
configword  0x30000d 0x40 0xff
idlocrange  0x200000 0x200007


name        18f248
ramsize     768
split       0x60
configrange 0x300001 0x30000d
configword  0x300001 0x27 0xff
configword  0x300002 0x0f 0xff
configword  0x300003 0x0f 0xff
configword  0x300006 0x85 0xff
configword  0x300008 0x0f 0xff
configword  0x300009 0xc0 0xff
configword  0x30000a 0x0f 0xff
configword  0x30000b 0xe0 0xff
configword  0x30000c 0x0f 0xff
configword  0x30000d 0x40 0xff
idlocrange  0x200000 0x200007


name        18f2480
ramsize     768
split       0x60
configrange 0x300001 0x30000d
configword  0x300001 0xcf 0x37
configword  0x300002 0x1f 0xff
configword  0x300003 0x1f 0xff
configword  0x300005 0x86 0xfb
configword  0x300006 0xd5 0xaf 0xbf
configword  0x300008 0x0f 0xff
configword  0x300009 0xc0 0xff
configword  0x30000a 0x0f 0xff
configword  0x30000b 0xe0 0xff
configword  0x30000c 0x0f 0xff
configword  0x30000d 0x40 0xff
idlocrange  0x200000 0x200007


name        18f24j10
ramsize     1024
split       0x80
configrange 0x300000 0x300005
configword  0x300000 0xe1 0xff
configword  0x300001 0x04 0xf7
configword  0x300002 0xc7 0xff
configword  0x300003 0x0f 0xff
configword  0x300005 0x01 0xff
idlocrange  0x200000 0x200007


name        18f24j50
ramsize     3776
split       0x60
configrange 0x3ff8 0x3fff
configword  0x3ff8 0xef 0xff 0xbf
configword  0x3ff9 0x07 0xff
configword  0x3ffa 0xdf 0xff
configword  0x3ffb 0x0f 0xff
configword  0x3ffc 0xff 0xff
configword  0x3ffd 0x09 0xff
configword  0x3ffe 0xff 0xff
configword  0x3fff 0x01 0xff


name        18f24k20
using       18f23k20
ramsize     768


name        18f2510
using       18f2410
ramsize     1536


name        18f2515
using       18f2410
ramsize     4096


name        18f252
using       18f242
ramsize     1536


name        18f2520
using       18f2420
ramsize     1536


name        18f2523
using       18f2423
ramsize     1536


name        18f2525
ramsize     4096
split       0x80
configrange 0x300001 0x30000d
configword  0x300001 0xcf 0x37
configword  0x300002 0x1f 0xff
configword  0x300003 0x1f 0xff
configword  0x300005 0x87 0xfb
configword  0x300006 0xc5 0xbf 0xbf
configword  0x300008 0x0f 0xff
configword  0x300009 0xc0 0xff
configword  0x30000a 0x0f 0xff
configword  0x30000b 0xe0 0xff
configword  0x30000c 0x0f 0xff
configword  0x30000d 0x40 0xff
idlocrange  0x200000 0x200007


name        18f2550
using       18f2455


name        18f258
using       18f248
ramsize     1536


name        18f2580
using       18f2480
ramsize     1536


name        18f2585
ramsize     4096
split       0x60
configrange 0x300001 0x30000d
configword  0x300001 0xcf 0x37
configword  0x300002 0x1f 0xff
configword  0x300003 0x1f 0xff
configword  0x300005 0x86 0xfb
configword  0x300006 0xf5 0x8f 0xbf
configword  0x300008 0x0f 0xff
configword  0x300009 0xc0 0xff
configword  0x30000a 0x0f 0xff
configword  0x30000b 0xe0 0xff
configword  0x30000c 0x0f 0xff
configword  0x30000d 0x40 0xff
idlocrange  0x200000 0x200007


name        18f25j10
using       18f24j10


name        18f25j50
using       18f24j50
configrange 0x7ff8 0x7fff
configword  0x7ff8 0xef 0xff 0xbf
configword  0x7ff9 0x07 0xff
configword  0x7ffa 0xdf 0xff
configword  0x7ffb 0x0f 0xff
configword  0x7ffc 0xff 0xff
configword  0x7ffd 0x09 0xff
configword  0x7ffe 0xff 0xff
configword  0x7fff 0x01 0xff


name        18f25k20
using       18f23k20
ramsize     1536


name        18f2610
using       18f2410
ramsize     4096


name        18f2620
using       18f2525


name        18f2680
using       18f2585


name        18f2682
ramsize     4096
split       0x60
configrange 0x300001 0x30000d
configword  0x300001 0xcf 0x37
configword  0x300002 0x1f 0xff
configword  0x300003 0x1f 0xff
configword  0x300005 0x86 0xfb
configword  0x300006 0xf5 0x8f 0xbf
configword  0x300008 0x3f 0xff
configword  0x300009 0xc0 0xff
configword  0x30000a 0x3f 0xff
configword  0x30000b 0xe0 0xff
configword  0x30000c 0x3f 0xff
configword  0x30000d 0x40 0xff
idlocrange  0x200000 0x200007


name        18f2685
using       18f2682


name        18f26j50
using       18f24j50
configrange 0xfff8 0xffff
configword  0xfff8 0xef 0xff 0xbf
configword  0xfff9 0x07 0xff
configword  0xfffa 0xdf 0xff
configword  0xfffb 0x0f 0xff
configword  0xfffc 0xff 0xff
configword  0xfffd 0x09 0xff
configword  0xfffe 0xff 0xff
configword  0xffff 0x01 0xff


name        18f26k20
using       18f23k20
ramsize     3936


name        18f4220
using       18f2220


name        18f4221
using       18f2221


name        18f4320
using       18f2220


name        18f4321
using       18f2221


name        18f4331
using       18f2331


name        18f43k20
using       18f23k20


name        18f4410
using       18f2410
ramsize     768


name        18f442
using       18f242


name        18f4420
using       18f2420


name        18f4423
using       18f2423


name        18f4431
using       18f2331


name        18f4450
using       18f2450

name        18f4455
using       18f2455


name        18f448
using       18f248


name        18f4480
using       18f2480


name        18f44j10
using       18f24j10


name        18f44j50
using       18f24j50


name        18f44k20
using       18f23k20
ramsize     768


name        18f4510
using       18f2410
ramsize     1536


name        18f4515
using       18f2410
ramsize     4096


name        18f452
using       18f242
ramsize     1536


name        18f4520
using       18f2420
ramsize     1536


name        18f4523
using       18f2423
ramsize     1536

name        18f4525
using       18f2525


name        18f4550
using       18f2455


name        18f458
using       18f248
ramsize     1536


name        18f4580
using       18f2480
ramsize     1536


name        18f4585
using       18f2585


name        18f45j10
using       18f24j10


name        18f45j50
using       18f25j50


name        18f45k20
using       18f23k20
ramsize     1536


name        18f4610
using       18f2410
ramsize     4096


name        18f4620
using       18f2525


name        18f4680
using       18f2585


name        18f4682
using       18f2682


name        18f4685
using       18f2682


name        18f46j50
using       18f26j50


name        18f46k20
using       18f23k20
ramsize     3936


name        18f6520
ramsize     2048
split       0x60
configrange 0x300001 0x30000d
configword  0x300001 0x27 0xff
configword  0x300002 0x0f 0xff
configword  0x300003 0x0f 0xff
configword  0x300004 0x83 0xff
configword  0x300005 0x03 0xff
configword  0x300006 0x85 0xff
configword  0x300008 0xff 0xff
configword  0x300009 0xc0 0xff
configword  0x30000a 0xff 0xff
configword  0x30000b 0xe0 0xff
configword  0x30000c 0xff 0xff
configword  0x30000d 0x40 0xff
idlocrange  0x200000 0x200007


name        18f6527
ramsize     3936
split       0x60
configrange 0x300001 0x30000d
configword  0x300001 0xcf 0x37
configword  0x300002 0x1f 0xff
configword  0x300003 0x1f 0xff
configword  0x300004 0xf3 0xff
configword  0x300005 0x87 0xfb
configword  0x300006 0xf5 0x8f 0xbf
configword  0x300008 0xff 0xff
configword  0x300009 0xc0 0xff
configword  0x30000a 0xff 0xff
configword  0x30000b 0xe0 0xff
configword  0x30000c 0xff 0xff
configword  0x30000d 0x40 0xff
idlocrange  0x200000 0x200007


name        18f6585
ramsize     3328
split       0x60
configrange 0x300001 0x30000d
configword  0x300001 0x2f 0xff
configword  0x300002 0x0f 0xff
configword  0x300003 0x1f 0xff
configword  0x300004 0x83 0xff
configword  0x300005 0x83 0xff
configword  0x300006 0x85 0xff
configword  0x300008 0x0f 0xff
configword  0x300009 0xc0 0xff
configword  0x30000a 0x0f 0xff
configword  0x30000b 0xe0 0xff
configword  0x30000c 0x0f 0xff
configword  0x30000d 0x40 0xff
idlocrange  0x200000 0x200007


name        18f65j50
ramsize     3904
split       0x60
configrange 0x7ff8 0x7ffd
configword  0x7ff8 0xef 0xff 0xbf
configword  0x7ff9 0x07 0xff
configword  0x7ffa 0xc7 0xff
configword  0x7ffb 0x0f 0xff
configword  0x7ffc 0xf8 0xff
configword  0x7ffd 0x0f 0xff


name        18f6620
using       18f6520
ramsize     3840


name        18f6622
using       18f6527


name        18f6627
using       18f6527


name        18f6680
using       18f6585


name        18f66j50
ramsize     3904
split       0x60
configrange 0xfff8 0xfffd
configword  0xfff8 0xef 0xff 0xbf
configword  0xfff9 0x07 0xff
configword  0xfffa 0xc7 0xff
configword  0xfffb 0x0f 0xff
configword  0xfffc 0xf8 0xff
configword  0xfffd 0x0f 0xff


name        18f66j55
ramsize     3904
split       0x60
configrange 0x17ff8 0x17ffd
configword  0x17ff8 0xef 0xff 0xbf
configword  0x17ff9 0x07 0xff
configword  0x17ffa 0xc7 0xff
configword  0x17ffb 0x0f 0xff
configword  0x17ffc 0xf8 0xff
configword  0x17ffd 0x0f 0xff


name        18f6720
using       18f6520
ramsize     3840


name        18f6722
using       18f6527


name        18f67j50
ramsize     3904
split       0x60
configrange 0x1fff8 0x1fffd
configword  0x1fff8 0xef 0xff 0xbf
configword  0x1fff9 0x07 0xff
configword  0x1fffa 0xc7 0xff
configword  0x1fffb 0x0f 0xff
configword  0x1fffc 0xf8 0xff
configword  0x1fffd 0x0f 0xff


name        18f66j60
ramsize     4096
split       0x60
configrange 0xfff8 0xfffd
configword  0xfff8 0xe1 0xdf 0xbf
configword  0xfff9 0x04 0xf7
configword  0xfffa 0xc7 0xff
configword  0xfffb 0x0f 0xff
configword  0xfffc 0xf8 0xff
configword  0xfffd 0x07 0xff


name        18f66j65
ramsize     4096
split       0x60
configrange 0x17ff8 0x17ffd
configword  0x17ff8 0xe1 0xdf 0xbf
configword  0x17ff9 0x04 0xf7
configword  0x17ffa 0xc7 0xff
configword  0x17ffb 0x0f 0xff
configword  0x17ffc 0xf8 0xff
configword  0x17ffd 0x07 0xff


name        18f67j60
ramsize     4096
split       0x60
configrange 0x1fff8 0x1fffd
configword  0x1fff8 0xe1 0xdf 0xbf
configword  0x1fff9 0x04 0xf7
configword  0x1fffa 0xc7 0xff
configword  0x1fffb 0x0f 0xff
configword  0x1fffc 0xf8 0xff
configword  0x1fffd 0x07 0xff


name        18f8520
using       18f6520


name        18f8527
using       18f6527


name        18f8585
using       18f6585


name        18f85j50
using       18f65j50


name        18f8620
using       18f6520
ramsize     3840


name        18f8622
using       18f6527


name        18f8627
using       18f6527


name        18f8680
using       18f6585


name        18f86j50
using       18f66j50


name        18f86j55
using       18f66j55


name        18f86j60
using       18f66j60


name        18f86j65
using       18f66j65


name        18f8720
using       18f6520
ramsize     3840


name        18f8722
using       18f6527


name        18f87j50
using       18f67j50


name        18f87j60
using       18f67j60


name        18f96j60
using       18f66j60


name        18f96j65
using       18f66j65


name        18f97j60
using       18f67j60

