Showing results for 
Search instead for 
Did you mean: 

STM32VLDiscovery with KEIL µVision4 IDE crash on load/debug

Associate II
Posted on April 02, 2011 at 06:26

Hey everyone!

This is my first time here and a complete novice with this microprocessor.

We are using it (STM32VLDiscovery) for our Senior Design Project in Electrical/Computer Engineering. We just switched from another board to this one. We are using the KEIL µVision4 IDE. The problem only occurs on 2 of our laptops out of 4. When we try to Load the Built project to the Microcontroller the software crashes. Down in the Build Output Frame it says: 


Load ''C:\\Keil\\ARM\\Boards\\ST\\STM32-Discovery\\Blinky\\Flash\\Blinky.AXF''''</span></div>

right before it crashes. It displays the standard windows msg saying ''µVIsion4 IDE has stopped working... Windows is checking for a solution.''

In the details of that msg box it says the fault module is 


I tried contacting KEIL about the issue and they referred me to contact ST about it. I have submitted an online help request but I thought I would post it here as well since its obviously an issue for more people than just myself. 

In the Debug & Utilities tabs I have ST-Link Debugger accepted. Also in the Utilities I have ''update target before debugging'' checkbox checked. I am setup as the administrator on my system and I have even tried rightclicking the app and selecting run as administrator just to be sure. I've tried redownloading and reinstalling the IDE about a half dozen times now and becoming very frustrated with it. 

I am running Windows 7 Home Premium 64bit with a AMD dual core processor. 

If I have left anything out please let me know and I will be sure to include it!

Thanks in advance!


Associate II
Posted on April 02, 2011 at 17:02

I think the problem is that the ST-Link driver doesn't work on a 64bit machine

There has been some discussion about this in the forum some time ago

Associate II
Posted on April 02, 2011 at 17:43

Thats strange because the other two computers that my classmates are using are 64 bit machines as well and they work fine.
Associate II
Posted on April 02, 2011 at 18:33

Are they using 32 bit libraries?

The USB mass storage emulation on the STLink is very buggy.  It appears that they watched the USB and filesystem message exchange with a 32MB USB flash stick when plugged into a 32 bit Windows machine, and just play back those responses.  Even though they aren't correct for any other OS.

It was a real PITA to get to work in Linux.  Even with setting a bunch of ''quirks'' flags ('ignore this type of bug') in the blacklist, it still takes many seconds before the kernel stops retrying.  They STM guys don't care about Linux users, but they should understand that saying ''it works under Windows''  sometimes means ''it only works with this version of Windows''.

Associate II
Posted on April 04, 2011 at 05:46

Hi Donald, thanks for your reply. Sorry I'm so late getting back to you on it, I've just returned from being out of town.

Which libraries are you referring to? The libraries included in the example code? Or the STlinkUSBdriver.dll dynamic library?

I thought about trying to do it in Linux since I have an Ubuntu virtual machine on my laptop, but after reading the discussion about how much of a ''PITA'' it is, I declined.

On the positive side I did get it working! My classmate sent me his version of the STlinkUSBdriver.dll and I replaced the one in the directory and Vóila! it works! I'm so happy after spending countless hours trying to get it to this point.



Associate II
Posted on April 09, 2011 at 19:47

By ''PITA'', I meant that it was difficult to write the stlink-download code with essentially no documentation and the many bugs in the STLink firmware.

Now that it's written, it's not especially difficult to get it to work in your own workflow -- I designed it work with scripts and Makefiles