summaryrefslogtreecommitdiffstats
path: root/libtoprammer/chips/microchip16/pic24f16kl402dip28.py
blob: 5739ed137ca9c4066455227cf35579a82115bf51 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
"""
#    TOP2049 Open Source programming suite
#
#   Microchip PIC24F16KL402 DIP28
#
#    Copyright (c) 2014 Pavel Stemberk <stemberk@gmail.com>
#
#    This program is free software; you can redistribute it and/or modify
#    it under the terms of the GNU General Public License as published by
#    the Free Software Foundation; either version 2 of the License, or
#    (at your option) any later version.
#
#    This program is distributed in the hope that it will be useful,
#    but WITHOUT ANY WARRANTY; without even the implied warranty of
#    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
#    GNU General Public License for more details.
#
#    You should have received a copy of the GNU General Public License along
#    with this program; if not, write to the Free Software Foundation, Inc.,
#    51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
"""

from microchip16_common import *
from configWords import klx0x_fuseDesc

class Chip_Pic24f16kl402dip28(Chip_Microchip16_common):
	
	voltageVDD = 3.3
	voltageVPP = 8
	
	logicalFlashProgramMemorySize = 0x800000
	logicalFlashConfigurationMemorySize = 0x800000
	
	def __init__(self):
	 	Chip_Microchip16_common.__init__(self,
		chipPackage="DIP28",
		chipPinVCC=28,
		chipPinsVPP=1,
		chipPinGND=27,
		signature="\x14\x4b",
		# flashPageSize (in number of 24bit words)
		flashPageSize=0x2bfe / 2 + 2,
		# flashPageSize=0x40,
		flashPages=1,
		# eepromPageSize (in 16bit words)
		eepromPageSize=0x100,
		eepromPages=1,
		# all 7 words uses lowest byte only
		fuseBytes=2 * 9
		)
		self.configWordAddr = 0xF80000
		# self.osccalBackupAddr = self.userIDLocationAddr + self.userIDLocationSize

fuseDesc = klx0x_fuseDesc

ChipDescription(
	Chip_Pic24f16kl402dip28,
	bitfile="microchip16dip28",
	chipID="pic24f16kl402dip28",
	runtimeID=(0xDF02, 0x01),
	chipVendors="Microchip",
	description="PIC24F16KL402",
	packages=(("DIP28", ""),),
	fuseDesc=fuseDesc, 	
	maintainer="Pavel Stemberk <stemberk@gmail.com>",
)
bues.ch cgit interface