2015-11-22 18:23:38 +01:00
|
|
|
STC15 series MCS bytes
|
|
|
|
======================
|
2014-01-11 16:43:37 +01:00
|
|
|
|
2015-11-22 18:23:38 +01:00
|
|
|
MCS3 is like early STC15 MCS1.
|
|
|
|
MCS2 is like early STC15 MCS2.
|
|
|
|
MCS4 is like early STC15 MCS0 but with additions.
|
|
|
|
MCSX is like early STC15 MCS12.
|
2014-01-11 16:43:37 +01:00
|
|
|
|
2015-11-22 18:23:38 +01:00
|
|
|
baseline
|
|
|
|
B5 FF F7 BB 9F
|
2014-01-11 16:43:37 +01:00
|
|
|
|
2015-11-22 18:23:38 +01:00
|
|
|
long por disabled
|
|
|
|
B6 FF F7 BB 1F
|
|
|
|
--> MCS4 bit 7 controls POR delay. low => short, high => long
|
2014-01-11 16:43:37 +01:00
|
|
|
|
2015-11-22 18:23:38 +01:00
|
|
|
reset pin as io disabled
|
|
|
|
B8 FF F7 BB 8F
|
|
|
|
--> MCS4 bit 4 controls reset pin. low => reset is normal, high => reset is io
|
2014-01-11 16:43:37 +01:00
|
|
|
|
2015-11-22 18:23:38 +01:00
|
|
|
low voltage reset disabled
|
|
|
|
B6 FF F7 FB 9F
|
|
|
|
--> MCS3 bit 6 controls low voltage reset. low => lv reset enabled, high => disabled
|
2014-01-11 16:43:37 +01:00
|
|
|
|
2015-11-22 18:23:38 +01:00
|
|
|
lvd threshold 2.61v
|
|
|
|
B8 FF F7 BA 9F
|
|
|
|
lvd threshold 2.82v
|
|
|
|
B5 FF F7 B9 9F
|
|
|
|
lvd threshold 3.08v
|
|
|
|
B6 FF F7 B8 9F
|
2014-01-11 16:43:37 +01:00
|
|
|
|
2015-11-22 18:23:38 +01:00
|
|
|
--> MCS3 bits 0-2 control LVD threshold setting. exact mapping not yet clear.
|
2014-01-11 16:43:37 +01:00
|
|
|
|
2015-11-22 18:23:38 +01:00
|
|
|
eeprom lv inhibit disabled
|
|
|
|
B7 FF F7 3B 9F
|
|
|
|
--> MCS3 bit 7 controls eeprom lv inhibit. high => eeprom lv inhibit enabled, low => disabled
|
2014-01-11 16:43:37 +01:00
|
|
|
|
2015-11-22 18:23:38 +01:00
|
|
|
watchdog after reset enabled
|
|
|
|
B6 FF D7 BB 9F
|
|
|
|
--> MCS2 bit 5 controls watchdog after reset. high => disabled, low => enabled
|
2014-01-11 16:43:37 +01:00
|
|
|
|
2015-11-22 18:23:38 +01:00
|
|
|
watchdog prescaler 128
|
|
|
|
B4 FF F6 BB 9F
|
|
|
|
watchdog prescaler 64
|
|
|
|
B5 FF F5 BB 9F
|
|
|
|
watchdog prescaler 32
|
|
|
|
B5 FF F4 BB 9F
|
|
|
|
watchdog prescaler 2
|
|
|
|
B6 FF F0 BB 9F
|
|
|
|
--> MCS2 bits 0-2 control watchdog prescaler. mapping is similar to early STC15.
|
2014-01-11 16:43:37 +01:00
|
|
|
|
2015-11-22 18:23:38 +01:00
|
|
|
wdt stop in idle disabled
|
|
|
|
B7 FF FF BB 9F
|
2014-01-11 16:43:37 +01:00
|
|
|
|
2015-11-22 18:23:38 +01:00
|
|
|
erase eeprom next programming
|
|
|
|
B4 FF F7 BB 9F
|
|
|
|
--> it's somewhere else! it's bit 1 of the extra MCSX byte that is typically 0xfd. low => erase eeprom disabled, high => erase eeprom enabled
|
2014-01-11 16:43:37 +01:00
|
|
|
|
|
|
|
|
2015-11-22 18:23:38 +01:00
|
|
|
p3.3 por state enabled
|
|
|
|
B9 FF F7 BB 97
|
|
|
|
--> MCS4 bit 3 controls the p3.3 state. high => p3.3 high, low => p3.3 low
|
2014-01-11 16:43:37 +01:00
|
|
|
|
2015-11-22 18:23:38 +01:00
|
|
|
p3.1 passthrough from p3.0 enabled
|
|
|
|
B5 FF F7 BB DF
|
|
|
|
--> MCS4 bit 2 controls the p3.1 passthrough. low => passthrough disabled, high => passthrough enabled
|
2014-01-11 16:43:37 +01:00
|
|
|
|
2015-11-22 18:23:38 +01:00
|
|
|
p3.1 push pull enabled
|
|
|
|
B5 FF F7 BB BF
|
|
|
|
--> MCS4 bit 1 controls p3.1 push pull. low => quasi-bidi, high => push-pull
|
2014-01-11 16:43:37 +01:00
|
|
|
|
2015-11-22 18:23:38 +01:00
|
|
|
bsl pindetect enabled
|
|
|
|
B5 FF F7 BB BF
|
|
|
|
--> somewhere else, MCSX bit 0. low => pindetect enabled, high => pindetect disabled.
|
2014-01-11 16:43:37 +01:00
|
|
|
|
|
|
|
|
2015-11-22 18:23:38 +01:00
|
|
|
external oscillator enabled (IAP15F2K61S2)
|
|
|
|
9C 7F F7 BB 9E
|
|
|
|
--> MCS4 bit 0 controls external oscillator. low => use external crystal, high => use RC.
|
2014-01-11 16:43:37 +01:00
|
|
|
|
2015-11-22 18:23:38 +01:00
|
|
|
external oscillator enabled + clock gain low (IAP15F2K61S2)
|
|
|
|
9C 7F F7 BB 9C
|
|
|
|
--> MCS 4 bit controls clock gain. high => high clock gain, low => low clock gain.
|