STM8S103 Code Upload / Execution Issue
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
‎2025-01-21 12:22 PM - edited ‎2025-01-21 12:33 PM
Issue with STM8S103 Code Uploading on Identical PCB Boards
I have two identical PCB boards, both equipped with the STM8S103 microcontroller. One board functions perfectly, with code uploading and running as expected, while the other does not.
Observations
Voltage Measurements
- On the non-working board:
- NRST pin: 1.6V
- SWIM pin: 3.2V
- On the working board:
- NRST pin: 3.2V
- SWIM pin: Floating around 200mV
- On the non-working board:
Microcontroller Replacement
- Suspecting a defective STM8S103 on the non-working board, I desoldered it and placed it on a functioning development board (See the attachement).
- To my surprise, the board started working perfectly—code uploaded and executed without issues.
- I measured the voltage on the NRST and the SWIM pins. which were same as in the working board mentioned above.
- This indicates that the microcontroller on the non-working board is not faulty.
Setup
- Development Tools:
- SDUINO
- Arduino IDE
- ST LINK V2
I would greatly appreciate any insights or suggestions to identify the root cause of this issue
Thank you!
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
‎2025-01-21 1:00 PM
Welcome @SuwinManudewa, to the community!
As you have already described, there was either a problem with the board where you soldered down the apparently faulty STM8S, or the programming went wrong beforehand. I suspect the former, as I've seen quite a few boards with invisible shorts and other issues.
In this context: is your ST-LINK/V2 one of those fakes in a colourful tin can?
Regards
/Peter
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
‎2025-01-23 8:21 AM
is there perticular reason the STM8S103's NRST pin goes to 1.6V and the SWIM pin to 3.2V???
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
‎2025-01-23 12:43 PM
I am not aware of any reason for this.
Will you also answer my question?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
‎2025-01-23 1:04 PM
Badly soldered, improper orientation. If the parts Ok on a simpler board, review your PCB, check nets and components placed.
Two drivers attempting to drive in different states? Anything programmed on to the IC?
Is this a DC voltage, or oscillating level?
Up vote any posts that you find helpful, it shows what's working..
