cancel
Showing results for 
Search instead for 
Did you mean: 

STM32F4 Resetting itself (Nucleo 64)

Andres Cao
Associate III
Posted on April 14, 2017 at 00:58

Hi!

I have a Nucleo64-446RE and every 5/10 minutes the board resets itself.

I'm using the Virtual COM to send data to my PC and plot it (among many other things), and when the board resets I lose the Serial connection. I need to re-open it in order to plot again. If after this reset I want to program the microcontroller I get the ''Unable to reset target'' message for which I need to unplug and replug the USB(which is also powering the board). I'm using the System Workbench for STM32.

Here's an oscilloscope picture of the NRST pin (blue), which confirms the reset. The red trace is a 3.3V pin, which shows there are no power issues. 

0690X00000606kYQAQ.png

Can you please help me debug this reset?

As I understand, it can't be a Hard Fault because (I think) in that case the system wouldn't reset but end up in an infinite loop. I haven't implemented any of the error handlers, but I think they're implemented by default with weak attributes.

Watching the following image:

0690X00000606llQAA.png

From external sources:

  • Definitely I'm not pressing the reset button
  • The ST-LINK could be resetting. How likely is this, why would it? Given that Virtual Com connection is lost it could be the case, since if I press the reset button the Virtual Com connection is not lost.

From internal sources:

  • WWDG is not activated
  • IWDG is not activated
  • Red trace would prove it's not a power reset
  • There's no lower-power mode being used.
  • Software reset, this would be the only option. What causes a software reset?

Thank you very much in advance for all your input!

Cheers,

Andrés

51 REPLIES 51
Posted on April 24, 2017 at 20:44

http://www.file.net/process/iastorf.sys.html

 

Intel file, most likely probing the media or writing a test file, hopefully that'll give the ST/mbed guys something to look at more specifically.

Tips, Buy me a coffee, or three.. PayPal Venmo
Up vote any posts that you find helpful, it shows what's working..
Posted on April 25, 2017 at 01:47

Disabling the driver seems to fix the problem.  However since it re-installs the driver everything I reconnect to the board, this seems to be only good for a temporary solution.

Posted on April 25, 2017 at 03:15

It should be possible to use RegEdit to edit it out of the filter list under HKLM CurrentControlSet for the USBSTOR node.

Tips, Buy me a coffee, or three.. PayPal Venmo
Up vote any posts that you find helpful, it shows what's working..
Posted on April 25, 2017 at 17:20

I tried that yesterday.  I removed iaStorF from the registry.  Verified it was not listed in the driver.  Rebooted the PC.  And the problem still occurred.

EDIT:

Because this is the last message, any casual reader could be lead to believe that the problem was never fixed.

After I uninstalled Dell SupportAssist and Dell SupportAssistAgent the disconnect problem stopped happening.

Posted on April 26, 2017 at 18:34

First I uninstalled 'Dell SupportAssist' and the problem still occurred.

I then uninstalled 'Dell SupportAssistAgent' and the problem went away.

I am not sure if it was the combination of uninstalling the two programs or just that last one.
Dilbert K
Senior
Posted on May 17, 2017 at 20:35

I am using Nucleo-F411RE board and running AC6 (SystemWorkbench) on Dell Laptop (Window 10).

Once every ~10 mins the Openocd will have following message, then STM32F4 will RESET.

Examination failed, GDB will be halted. Polling again in 100ms

Info : Previous state query failed, trying to reconnect

Polling target stm32f4x.cpu failed, trying to reexamine

Seems like issue is similar or the same.... Just wonder this is the on board STlink problem or not.

I don't want to buy a stand alone STlink V2 and end up same issue.

Posted on May 17, 2017 at 21:38

Instrument your code to indicate a reset, or count them, and run from a USB charger, if this doesn't fail, then it's something stupid your Dell is doing. People throughout the history of time have installed stupid and broken filter drivers onto the Microsoft storage driver stack. Usually because someone at DELL, HP or TOSHIBA want some dumb tray icon to animate or otherwise 'enhance' your experience.

Tips, Buy me a coffee, or three.. PayPal Venmo
Up vote any posts that you find helpful, it shows what's working..
Posted on May 18, 2017 at 12:44

Dilbert, 

To be honest it looks a little bit different. 

Uninstall Dell SupportAssist and Dell SupportAssistAgent, this seems to fix the problem for the ones with the issue discussed.

At least I get no message on AC6, just a reset and if I try to program it again it says 'unable to reset target'

Posted on May 18, 2017 at 22:22

If this is Dell (Laptop) issue, should there be a way to install the STLink - USB driver to resolve this ??

During the debugger loading, it has the Error, but it continue to load/run code, I did not pay attention.

Anyone know how to remove this error ?  See this could resolve my issue.

Info : clock speed 1800 kHz

Error: libusb_open() failed with LIBUSB_ERROR_NOT_SUPPORTED

Info : STLINK v2 JTAG v28 API v2 M v18 VID 0x0483 PID 0x374B

Info : using stlink api v2

Info : Target voltage: 3.241334

Info : stm32f4x.cpu: hardware has 6 breakpoints, 4 watchpoints

Info : accepting 'gdb' connection on tcp/3333

Posted on May 28, 2017 at 20:08

Thanks.

Uninstalled both Dell SupportAssist and system much more stable.

So far, ran over 30 minutes without an error.