Update MCU database

This commit is contained in:
Grigori Goronzy 2014-01-17 12:08:23 +01:00
parent 517af0b6bd
commit 5bcad70d77
3 changed files with 19 additions and 5 deletions

View File

@ -1,13 +1,13 @@
#!/usr/bin/env python3
# This curious script dumps all model info from STC-ISP.
# Data is directly read from the binary.
# Offsets are for STC-ISP 6.63, md5sum 62d465a196de26fa3fb4b22c7be4b882.
# Offsets are for STC-ISP 6.64, md5sum f82bf976e675326433bbfe5cd3fb9d85
MCU_TABLE_OFFSET = 0x0004e270
MCU_TABLE_SIZE = 648
MCU_TABLE_OFFSET = 0x0004f2b0
MCU_TABLE_SIZE = 655
MCU_RECORD_SIZE = 32
MCU_NAMES_OFFSET = 0x00062dc8
MCU_NAMES_PTR_OFFSET = 0x00462dc8
MCU_NAMES_OFFSET = 0x00063dc8
MCU_NAMES_PTR_OFFSET = 0x00463dc8
import struct
import sys

View File

@ -7,6 +7,7 @@ MCUModel(name='STC15F2K48S2', magic=0xf406, total=65536, code=49152, eeprom=1331
MCUModel(name='STC15F2K56S2', magic=0xf407, total=65536, code=57344, eeprom=5120),
MCUModel(name='STC15F2K60S2', magic=0xf408, total=65536, code=61440, eeprom=1024),
MCUModel(name='IAP15F2K61S2', magic=0xf449, total=65536, code=62464, eeprom=0),
MCUModel(name='IRC15F2K63S2', magic=0xf44a, total=65536, code=65024, eeprom=0),
MCUModel(name='STC15L2K08S2', magic=0xf481, total=65536, code=8192, eeprom=54272),
MCUModel(name='STC15L2K16S2', magic=0xf482, total=65536, code=16384, eeprom=46080),
MCUModel(name='STC15L2K24S2', magic=0xf483, total=65536, code=24576, eeprom=37888),
@ -16,6 +17,7 @@ MCUModel(name='STC15L2K48S2', magic=0xf486, total=65536, code=49152, eeprom=1331
MCUModel(name='STC15L2K56S2', magic=0xf487, total=65536, code=57344, eeprom=5120),
MCUModel(name='STC15L2K60S2', magic=0xf488, total=65536, code=61440, eeprom=1024),
MCUModel(name='IAP15L2K61S2', magic=0xf4c9, total=65536, code=62464, eeprom=0),
MCUModel(name='IRC15L2K63S2', magic=0xf4ca, total=65536, code=65024, eeprom=0),
MCUModel(name='STC15F404AD', magic=0xf40a, total=65536, code=4096, eeprom=9216),
MCUModel(name='STC15F408AD', magic=0xf40b, total=65536, code=8192, eeprom=5120),
MCUModel(name='STC15F412AD', magic=0xf40c, total=65536, code=12288, eeprom=1024),
@ -39,6 +41,11 @@ MCUModel(name='STC15W202S', magic=0xf512, total=8192, code=2048, eeprom=3072),
MCUModel(name='STC15W203S', magic=0xf513, total=8192, code=3072, eeprom=2048),
MCUModel(name='STC15W204S', magic=0xf514, total=8192, code=4096, eeprom=1024),
MCUModel(name='IAP15W205S', magic=0xf555, total=8192, code=5120, eeprom=0),
MCUModel(name='IRC15W207S', magic=0xf556, total=8192, code=7680, eeprom=0),
MCUModel(name='STC15W1K16S', magic=0xf516, total=32768, code=16384, eeprom=13312),
MCUModel(name='STC15W1K24S', magic=0xf517, total=32768, code=24576, eeprom=5120),
MCUModel(name='IAP15W1K29S', magic=0xf558, total=32768, code=29696, eeprom=0),
MCUModel(name='IRC15W1K31S', magic=0xf559, total=32768, code=32256, eeprom=0),
MCUModel(name='STC15F100W', magic=0xf290, total=8192, code=512, eeprom=0),
MCUModel(name='STC15F101W', magic=0xf291, total=8192, code=1024, eeprom=4096),
MCUModel(name='STC15F102W', magic=0xf292, total=8192, code=2048, eeprom=3072),

View File

@ -94,6 +94,7 @@ class MCUModelDatabase:
MCUModel(name='STC15F2K56S2', magic=0xf407, total=65536, code=57344, eeprom=5120),
MCUModel(name='STC15F2K60S2', magic=0xf408, total=65536, code=61440, eeprom=1024),
MCUModel(name='IAP15F2K61S2', magic=0xf449, total=65536, code=62464, eeprom=0),
MCUModel(name='IRC15F2K63S2', magic=0xf44a, total=65536, code=65024, eeprom=0),
MCUModel(name='STC15L2K08S2', magic=0xf481, total=65536, code=8192, eeprom=54272),
MCUModel(name='STC15L2K16S2', magic=0xf482, total=65536, code=16384, eeprom=46080),
MCUModel(name='STC15L2K24S2', magic=0xf483, total=65536, code=24576, eeprom=37888),
@ -103,6 +104,7 @@ class MCUModelDatabase:
MCUModel(name='STC15L2K56S2', magic=0xf487, total=65536, code=57344, eeprom=5120),
MCUModel(name='STC15L2K60S2', magic=0xf488, total=65536, code=61440, eeprom=1024),
MCUModel(name='IAP15L2K61S2', magic=0xf4c9, total=65536, code=62464, eeprom=0),
MCUModel(name='IRC15L2K63S2', magic=0xf4ca, total=65536, code=65024, eeprom=0),
MCUModel(name='STC15F404AD', magic=0xf40a, total=65536, code=4096, eeprom=9216),
MCUModel(name='STC15F408AD', magic=0xf40b, total=65536, code=8192, eeprom=5120),
MCUModel(name='STC15F412AD', magic=0xf40c, total=65536, code=12288, eeprom=1024),
@ -126,6 +128,11 @@ class MCUModelDatabase:
MCUModel(name='STC15W203S', magic=0xf513, total=8192, code=3072, eeprom=2048),
MCUModel(name='STC15W204S', magic=0xf514, total=8192, code=4096, eeprom=1024),
MCUModel(name='IAP15W205S', magic=0xf555, total=8192, code=5120, eeprom=0),
MCUModel(name='IRC15W207S', magic=0xf556, total=8192, code=7680, eeprom=0),
MCUModel(name='STC15W1K16S', magic=0xf516, total=32768, code=16384, eeprom=13312),
MCUModel(name='STC15W1K24S', magic=0xf517, total=32768, code=24576, eeprom=5120),
MCUModel(name='IAP15W1K29S', magic=0xf558, total=32768, code=29696, eeprom=0),
MCUModel(name='IRC15W1K31S', magic=0xf559, total=32768, code=32256, eeprom=0),
MCUModel(name='STC15F100W', magic=0xf290, total=8192, code=512, eeprom=0),
MCUModel(name='STC15F101W', magic=0xf291, total=8192, code=1024, eeprom=4096),
MCUModel(name='STC15F102W', magic=0xf292, total=8192, code=2048, eeprom=3072),