Closed orzel closed 1 year ago
Having similar issues with an STC15W204S. stcgal is able to communicate with the device and display the chip information, but then when 'Trimming frequency:' stcgal errors out with an 'incorrect frame start', and the existing unaltered program in the chip then runs.
Linux Mint 20.3 Una base: Ubuntu 20.04 focal Python 3.8.10 stcgal 1.6
Using a genuine FTDI interface that works fine for uploading to other STC chips: STC8, STC89, etc. Also tried a CP2102 interface with the same result.
stcgal -P stc15a -a -D hourglass.ihx Cycling power: done Waiting for MCU: <- Packet data: 46 B9 68 00 34 50 8F 43 7A 9E F7 BA 9F 00 A8 87 C0 FD 27 4B 00 00 72 54 00 F5 14 05 06 70 9E 02 1A 20 21 23 20 00 14 10 04 EA EC 77 BF FF FF 21 11 11 11 11 92 16 done Target model: Name: STC15W204S Magic: F514 Code flash: 4.0 KB EEPROM flash: 1.0 KB Target frequency: 177.107 MHz Target BSL version: 7.2T Target options: reset_pin_enabled=False watchdog_por_enabled=True watchdog_stop_idle=False watchdog_prescale=128 low_voltage_reset=True low_voltage_threshold=0 eeprom_lvd_inhibit=False eeprom_erase_enabled=True bsl_pindetect_enabled=True Loading flash: 1574 bytes (Intel HEX) Trimming frequency: -> Packet data: 46 B9 6A 00 0D 50 00 00 36 01 F5 14 02 07 16 <- Packet data: BF Protocol error: incorrect frame start -> Packet data: 46 B9 6A 00 07 82 00 F3 16 Disconnected!
It kinda works now. -P auto wont, but -P stc15 is ok.
I think the original problem lied with the power supply. The MCU is 5V, and at least one of the usb-serial I tried is 5V, but checking with a multimeter, the voltage was more like ~4V once reaching the MCU.
Try this stc8prog
Did. And it works wonderfully. It autodetects my mcu, while stcgal fails with -P auto (works ok with -P stc15). Also, I didn't had to specify any 'trimming' parameter, but I guess (?) that maybe that was required only for the first (few) flash burns ?
For the record:
Tested, confirm -P auto uses stc15 protocol.
Hello. I can't manage to upload a file to my STC15W408AS.
I'm using
I tried:
I have three usb-ttl devices, the result is the same with all of them:
In all cases, i manage to get the information, but not to send firmware. The mcu otherwise seems to work ok.
Here's a typical test:
So basically, it seems my setup is at least partially ok, stcgal kinda manages to establish a communication with the MCU. I dont get the trimming thinguy (can't even understand what it does). I'm ready to test whatever you might think worth trying.. But by mysefl, i'm stuck on what to do next.