Programming error after first time
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
‎2021-11-23 6:09 AM
Hi,
I have a problem with my STM8AF6213PDU custom board.
The first time, I programmed sucessfully the board using ST Visual Programmer. The procedure was succesfully because I loaded a "blink firmware" and it's always working (ever with power on/off)
Now I want to update my firmware but I'm not allowed to do it. I cannot estabilish connection neither with ST Visual Develop nor ST Visual Programmer.
It's like a read/write protection but I can't disable it. I can not think about the "one shot possibility" because sounds to me impossible.
Could someone help me? Is there a procedure that I'm missing?
Thanks,
Marco.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
‎2021-12-15 4:31 AM
Hello,
Are you reconfiguring PD1 pin (shared with SWIM interface line) in your application ?
Could you please try to hold MCU in reset just before trying to connect to it, please? The reason for that operation would be to perform "connect under reset" scenario which would allow you to connect with the debugger before your code will be executed.
Could you please share with me part of the schematics related to VCAP, SWIM and NRST connections.
Could you please check those points on your side?
In case you do not want to share those data on this forum, please insert a question using online support system.
Thank you in advance
Best Regards,
Artur
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
‎2021-12-15 8:01 AM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
‎2021-12-16 2:46 AM
Hello Marco,
Are you using SWIM pin (or reconfiguring within the code) or low power modes (like halt) in your application ? It could be the reason of the issue.
Next points worth to check are related to hardware part of the application:
- the length of the wires between your board and the debugger. Its max length is 20cm.
- capacitor value at VCAP pin (it should be at least 470nF)
- capacitor at NRST line (100nF) as close as possible to the MCU
Could you please check it on your side?
Best Regards,
Artur
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
‎2021-12-16 3:30 AM
Hello Artur,
I'm using the original SWIM pin. Not sure what you mean by low power mode. I believe that I'm using normal mode because I don't know about low power mode.
The length of the wire is ok according to your suggests
The capacitor value at VCAP pin is ok according to your suggests
The capacitor on the NRST is 100nF, but I'll try to get it closer to the CPU.
I'll be back to you when I test again the board and I'll provide a screen of the debugging session. hopefully could help.
Thanks,
Marco.
