User Tools

Site Tools


Sidebar

Table of contents

keilbug

Since Keil MDK 5.25 does not have the bug anymore, we recommend to update (see Downloads section)

Keil-Bug workaround (needed for almost all boards except H101/H8S or H8mini_green )

As this question is being asked from time to time in H8 mini thread, I'll write a short answer here:

  1. Install (if not already) STLink Utilities
  2. Connect (if not already) STLink to USB port
  3. Connect quad to STLink (step 3 & 4 not needed, but you'll get a connect error then)
  4. Power the quad using a battery
  5. Click on “target”–>“connect”, some blue writing should be displayed. If not, check Wires, check if the board is powered, are STLink drivers installed correctly?
  6. Click on “target”–>“disconnect”
  7. Open Keil
  8. Unplug & plug quad's battery (if flashed for the first time, otherwise continue step 10)
  9. Click “flash”–>“erase” (if flashed for the first time, otherwise continue step 10)
  10. Click “flash”–>“download”
  11. Finished

Note: If you're trying to erase a “fresh” board, the time between battery plug-in and erase is limited, be aware of that and do it as fast as you can / repeat if it didn't work!

Here is how krillex does it: Link to post

Regarding flashing the blue board for the first time I also have some problems but this is what I do:
1. Connect usb-programmer and battery to fc.
2. Run the “st-link upgrade tool” and update firmware (even if it's already updated). Close the upgrade software.
3. Erase memory from within Keil.
4. Disconnect usb-programmer from PC and battery from fc.
5. Reconnect programmer to PC and battery to fc.
6. Run the “upgrade tool” again. Close upgrade tool.
7. Download software from within Keil.

Any flashings after that, just use download in Keil (use “upgrade tool” first).
It's the first time with a new blue board that is problematic.
I'm sure there are other ways to get it working but that procedure works good for me.

Another version from Ian444: Link to post

Yet another recipe. Must be carried out in this order. Keil can be open, but minimised on the PC.
1. Open the ST-Link Utility program.
2. Connect ST-Link to USB port. Do not connect ST-Link to quad yet.
3. Click “connect” in ST-Link Utility program.
4. You get a “cannot connect” message.
5. Close the message and close the ST-Link Utility program. Now the ST-Link is “initialised”.
6. Open (or maximise) Keil, connect the quad, connect the quad's battery and flash it.

Note for first erase and flash - usually it is needed to disconnect and then reconnect the battery after the erase and before the flash. No need to disconnect the quad or the ST-Link (or do anything in Keil) when doing this.

This website uses cookies. By using the website, you agree with storing cookies on your computer. Also you acknowledge that you have read and understand our Privacy Policy. If you do not agree leave the website.More information about cookies
keilbug.txt · Last modified: 2018/06/20 13:02 by sirdomsen