0
\$\begingroup\$

I am working on a project/PCB that contains the STM8S003F3 microcontroller. Every time I do the following steps, the microcontroller gets burned. The steps are:

  1. I program the STM8S003F3 by using the ST-LINK found in STM8S-DISCOVERY Board (this step i do without any external power supply and it works perfectly);
  2. I unplug the programmer and connect the board to an external 28V power supply (hardware and firmware here are perfectly working);
  3. There are some components that need 28V to run, and, for debbuging the firmware, I need the 28V power supply connected to the circuit;
  4. When my board is connected to this 28V power supply, i plug in the programmer (for programming and debbuging);
  5. In step 4, the STM8S003F3 stops working. Actually, if I measure the reset pin, it oscilattes at a frequency of about 10kHz.
  6. From here, I can't program anymore. I have to exchange the microcontroller.

I thinking about some issues that can be the causes of this problem:

  1. When I was doing this same procedure at my company, there was no problem at all. Now, I am at home and there is no grounding in the power plugs. On the other hand, there is grounding at my company. Is this the problem? Does my USB port have any to do with it?
  2. There is a switching mode power supply (SMPP) on the project board. Maybe when I plug the programmer into it, the SMPP drives more current and burns the microcontroller? How I said before, none of this problems were going on at my company.
\$\endgroup\$

1 Answer 1

0
\$\begingroup\$

Probably a grounding issue, with current flowing back through the USB port. If the 28V supply is left connected and the AC input switched it may be okay, but maybe not if my guess is wrong.

There are a number of sure ways around it, one is to use a USB isolator module, which is probably a good idea for most development work that involves power circuits.

What I think may be happening is that the 28V PSU Y safety cap is charging through the USB ground.

\$\endgroup\$
1
  • \$\begingroup\$ Thanks! Probably that's it. And the USB isolator module is a good idea. \$\endgroup\$ Commented Mar 24, 2020 at 14:36

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.