stcgal icon indicating copy to clipboard operation
stcgal copied to clipboard

Stuck on Writing Flash:

Open hwiguna opened this issue 6 years ago • 1 comments

I'm sure this is user error, but I do not know how to correct it. I've tried two different hex files and one gets stuck at 75% the other at 92%. I've tried specifying 9600 baud. No difference. stuck at same spots. Please advise. Thank you!

C:\Users\hwiguna\AppData\Local\Programs\Python\Python37-32\Scripts>stcgal -p COM4 -b 9600 "C:\Users\hwiguna\Documents\Projects\Arduino\CubeKitCode\888-Light-Cube-Files_Translated\888-Files\program\Free open source program\7_stc8x8x8.hex" Waiting for MCU, please cycle power: done Protocol detected: stc12 Target model: Name: STC12C5A60S2 Magic: D17E Code flash: 60.0 KB EEPROM flash: 2.0 KB Target frequency: 23.645 MHz Target BSL version: 7.1I Target options: reset_pin_enabled=True low_voltage_reset=False oscillator_stable_delay=32768 por_reset_delay=long clock_gain=high clock_source=external watchdog_por_enabled=False watchdog_stop_idle=True watchdog_prescale=256 eeprom_erase_enabled=False bsl_pindetect_enabled=False Loading flash: 1427 bytes (Intel HEX) Switching to 9600 baud: testing setting done Erasing 6 blocks: done Writing flash: 92%|█████████████████████████████████████████████████████▏ | 1408/1536 [00:19<00:00, 663.74 Bytes/s]

hwiguna avatar Nov 29 '18 01:11 hwiguna

Please try again with proper MAX232-based serial interface/s if any available. Also checkout carefully the VCC level, 5V vs 3V3, I had similar problems and they were really caused by that, see e.g.: Trivial solution to "bricked" STC15s

Kind regards and good luck!

mosagepa avatar Sep 08 '21 07:09 mosagepa

It would be worth testing different protocols (stc12 / stc12a / stc12b) and reopen issue if needed.

area-8051 avatar Jun 13 '23 13:06 area-8051