cancel
Showing results for 
Search instead for 
Did you mean: 

STM8S001J3 Locked After Configuring SWIM Pin as GPIO

shyamparmar
Associate III

Hello STM Community,

I am working with the STM8S001J3 microcontroller and facing an issue with configuring the SWIM pin (PD1) as a GPIO for LED control. 

Here is the problem:

  1. When I configure the SWIM pin as a GPIO, the MCU gets locked, and I am unable to download any code into the microcontroller afterward.
  2. To mitigate this, I tried adding a delay before configuring the SWIM pin as GPIO, but the issue persists — the MCU still gets locked.

Is there a proper way to configure the SWIM pin as GPIO and still retain the ability to program the MCU afterward?

If before the I/O configure disable SWIM mode then I configure SWIM pin as I/O (GPIO) pin and after power reset swim mode enable or disable ?

Thank you in advance.

0 REPLIES 0