How to Install Cleanflight On a Sparky Board With a USB Cable

How to Install Cleanflight On a Sparky Board With a USB Cable

There are many ways to flash Sparky, but one of the easiest ways is via the USB connection. It requires no additional hardware, or soldering. All you need to do is short the Sparky board’s bootloader pins momentarily as you plug in the USB cable to your PC. This will run a Pre-installed routine that will place the Sparky Board in DFU mode, allowing you to push up a .DFU file the main processor directly.

First off, in order to load the CleanFlight to the Sparky Board, you need to start with a clean copy of the binary file (.hex file). I suggest you create your own .hex file directly from the Cleanflight Repository located at here. What you are looking for is a file called cleanflight_SPARKY.hex, it’s in the OBJ folder. Once you find the proper .hex file on git, just double click it to open it, and then click on the RAW button to open the binary in a new window stripped of all the HTML. Now, select all (ctrl+a) of the binary, then copy (ctrl+c) and paste it (ctrl+v) into a simple text editor such as new notepad on your PC. Then save this code as a .hex, it’s easy. Just choose, “Save As”, then type cleanflight_Sparky.hex and save it to a location on your PC that you can easily find. Now we are ready to convert the .hex to .dfu

For DFU conversion and uploading of the CleanFlight binary to the Sparky Boards processor, we will use a utility from STMicroelectronics (STM) called DfuSe Demonstrator. Located in the download package there are two separate programs, DfuFileMgr, and DfuSeDemo. DfuFileMgr converts the .hex to .dfu files, and DfuSeDemo loads the .dfu file to the main processor of the Sparky Board. In summary use DfuFileMgr.exe to convert the cleanflight_Sparky Binary file (.hex) file to a .dfu, and upload it directly to the STM32F303 processor on Sparky via USB cable with DfuSeDemo.

To insure you have a path for communication to your Sparky Board, you need to know where Sparky is actually installed. You can find this information via the Device Manager (Windows). However, there’s a problem, when the Sparky Board is when it’s plugged into a PC via the USB we won’t be able to talk to it. Sparky will most likely be seen as a standard USB device, or it will be placed in the system as a, “Other Devices” with no driver installed. Our goal is to load Sparky with CleanFlight and to control it via CleanFlight Configurator (the set up gui). To do that, we need Sparky to communicate via a COM port. In order for that to happen, we have to install a special STM driver that will create a, VCP for us to communicate with Sparky via the USB cable. VCP is a, Virtual Com Port, and in this case it’s the STM32 Virtual COM Port Driver that we will need to download from STMicroelectronic (STM).

STM happens to make not only the processor for Sparky (STM32F303), but the VCP drivers, the conversion as well as uploading software. Ahhh….but Houston we have a problem. The latest version of DfuSE 3.0.4 has a bug in the DfuFileMgr. It will not convert a .hex file, you will get an error “Unable to create image From this file…” (see image directly below). The latest version 3.0.4 had me scratching my head for a solid day. There seems to be a bug only in DfuFileMgr.exe (the .hex to .dfu converter) portion of the DfuSe Demonstrator package. The uploader, “DfuSeDemo.exe” works exactly as it should. I have a friend working on a Bug fix for 3.0.4, but for now you can grab an older version (3.0.2) from the link below, it’s safe, and it works. The reason I offer an alternative link vs an actual STM one is because they do not archive older versions of DfuSe Demonstrator for download :( . Have no fear. Again, the older version (3.0.2) works great.

The dreaded DfuSeFileMgr 3.0.4 error message Dfu_file_manager_4.0.3_Error

Below are the links that you will need for for the Conversion & Uploading Software, as well as the VCP driver.

Link to DfuSE 3.0.4
Link to (safe older version) DfuSe 3.0.2
Link to STM32 Virtual COM Port Driver
Link to VCP driver here.

To get started, download and install DfuSe, and the VCP driver. as I said before, inside of the DfuSe Demonstrator install package there are two utilities that are needed to convert and upload the CleanFlight_Sparky Binary. The first utility is the DfuFileMgr.exe on my machine it’s located in C:\Program Files (x86)\STMicroelectronics\Software\DfuSe v3.0.4\Bin. You can try the latest version of DfuFileMgr.exe, but if you get the error, remember to use 3.0.2 to avoid the error. Launch DfuFileMgr.exe, and a pop up window will appear with two options. Select the top option where it says, “I want to Generate a DFU file from s19, HEX or BIN files” and click ok. Now the main dialog box will appear. To the left it has the Device options, to the right on top, you will see a box called Images, and under that you have a box called, “Injection”. In the Injection box, click on the box that says, “S19 or Hex”. That is the browser button that allows you to navigate to the cleanflight_Sparky.hex that we made earlier, so we can convert it. Be sure to click the drop down menu (s19 Files(*.19) next to, or under the File name box. Now change s19 Files(*.19) it to hex Files (*.hex), or the cleanflight_SPARKY.hex file will not be visible to select. Now double click the .hex file to load it into DfuFileMgr. Now click on Generate at the bottom of the program window, this will pop up a, “Save As” window allowing you to save the cleanflight_SPARKY.hex as a cleanflight_SPARKY.dfu. Navigate where you want to save the .dfu file, and click save. This will convert the hex. to a .dfu file that can be directly pushed to the STM32F3 processor via the USB using DfuSeDemo.exe.

To upload the .dfu file we just created to the STM32F303 processor on the Sparky board, you need to run the DfuSeDemo.exe program. Mine is located at “C:\Program Files (x86)\STMicroelectronics\Software\DfuSe v3.0.4\Bin\DfuSeDemo.exe”. When you launch the program, it will automatically detect any device that is connected and in DFU mode. Most likely the Sparky will be the only device you have in DFU mode, but you can browse and select any DFU connected device via the, “Available DFU Devices” drop down menu.


In order for Sparky to be detected in DFU mode, you have to short the bootloader pads marked SBL located just behind the USB socket but before the STM32F3 processor (see top image). Use some tweezers to momentarily bridge (short) the bootloader pads (marked SBL) on the Sparky Board while you plug in the USB cable to the PC. I always watch my devices populate the system via the Device Manager. However as soon as Sparky connects in DFU mode, you will be able to find it in the DfuSeDemo’s “Available DFU Devices” drop down menu. Once you have the Sparky Board selected in the Connected DUF Devices drop down, next click, “Choose” and this will allow to browse and load the cleanflight_SPARKY.dfu file you created into DfuSeDemo for uploading. (see image directly above)


Now its time to upload the .dfu file to Sparky (see image directly above). You need to look for the button marked Upgrade, and click it. A warning box will pop up will pop up saying,”You are in DFU mode, and it’s impossible to to make sure the file is correct for this device”. Just click, “Yes” and cleanflight_Sparky.dfu will be pushed to the Sparky Board. You will see a green progress bar and it will tell you when the, “Upgrade is Successful”. Next you click. “Quit” and your new Sparky Board is loaded with Cleanflight. You will be able to talk to Cleanflight Configurator, and upload the latest firmware from there.

Below is a video showing the process. I hope you find this helpful, if you have any questions, you can post them here, but a better place is via IRC on the #cleanflight channel. Good luck and happy flying.

Hey You Guys. It’s Been A While

Hey You Guys. It’s Been A While

I want to let everyone that follows me know that I am going to work my way back into doing at least weekly blog posts. I just retired from working and am now doing Photography full time. Recently I have also been doing posts at Photofocus, and am soon going to be a regular writer for them. Here is a post I just did for them.

Today post is just to let everyone know that I am back, and to look forward to at least four posts a month. If you have any questions or comments, please send me an email and I will be happy to help.

How to Quickly Deal With Dark Eye Sockets In Photoshop

How to Quickly Deal With Dark Eye Sockets In Photoshop
How to Fix Dark Sockets by Thomas Shue 2013 Lilsamedia (1 of 2)
How to Fix Dark Sockets by Thomas Shue 2013 Lilsamedia (2 of 2)
Have you ever had to do a shoot in a room where the lights are all over head, and they are causing nasty shadows? Let me let you in on a little secret, you do it all of the time and you just don’t know it. That’s right when you shoot outside, the sun is the overhead light source. You might be saying but I shoot my clients in the shade, so the sun really isn’t a factor. Well I am here to tell you that even when you shoot in open shade (shade where the open sky is above your subject’s head), you are still dealing with the problems caused by an overhead light source… This problem is shadows, and in particular shadows in the eye sockets, that just look terrible.

Lets face it, sometimes you just can’t use flash or a reflector to open up the shadows. Sometimes you can’t direct your subjects to face this way or that. Sometimes you just have to shoot and get what you can and fix it in post. Yeah, I said it…”Fix It In Post”. Not every image is meant for the cover of Vogue, or destined to be a master print. Lets face it, social networking displays billions of images a year that are just terrible. Have you ever been given a job where the client says, ” I am hiring you to do a shoot for Facebook”? Well I have, they didn’t say it exactly like that, but they did say I need you to cover this event and give me the files for social networking and a press/media kit. These types of images don’t have a really high artistic value. What matters most, is that these images help to support the clients story, event, or news.

I have to say, as a photographer, these types of images aren’t so much fun to make, but they do pay the bills. I really want to use all of my professional tools to deliver the best work I can, but as I said earlier, some images just aren’t ever going to be art, but they are still very valuable, none the less. When you are forced to make images with one hand tied behind your back (no flash or light making aids), it’s important for you to deliver images that are better than everyone else that happens to be covering the same event. This is where today’s tutorial comes in to play. If learn this simple technique, you can quickly fix those dark eye sockets, shadows caused by bangs, or any other unwanted shadows in a matter of just a few seconds.

Spend a few minutes watching the video below, and thanks for taking time to visit today, Sincerely, Thomas Shue

Batch Processing Selected Images in Capture One Pro 7

Batch Processing Selected Images in Capture One Pro 7


Hey guys, it’s good to be back! I feel extremely refreshed and ready to kick some serious hind parts. Anyways, today I have a member requested tutorials for ya. The request comes from a nice young lady named Paula Pollock. You see Paula is trying very hard to work with Capture One Pro 7. This software is not only one of the best image processing pieces of software on the market, but it’s one of the toughest to learn.

There are many tutorials available online showing you how to work with Capture One. However most of the ones that I found from the manufacturer will tend to overwhelm you, at least they did me. They cover way too much information and they seem to last forever. Combine that an elder British accent, it’s all I can do to stay awake every time I watch one. The information is there, I just have difficulty absorbing it. Never the less, I have struggled through and paid my dues by mostly playing with the software. Today it’s my honor to help a fellow photographer in need.

The question Paula asked is how do you process your selected images when you are making your edits. Everything in Capture One works in a folder system. This folder system is one you have to create. Unlike Lightroom where everything is automatically done for you upon import. Capture One requires that you define various parameters at various stages of the workflow. You set up a folder at import called a, “Session” then you define a folder at output called “Process”.

I can’t do into great detail here in this post, however I did make a video that will explain the process and get you headed in the right direction when you are ready to batch process your selected images. Thanks for taking time to stop by today, I hope your day is wonderful. Sincerely, Thomas Shue

On Vacation 9-12 thru 9-17 2013

On Vacation 9-12 thru 9-17 2013

Hey guys, I know you are used to a daily blog post from me, but I am on Vacation until 9-17. During the time away I will be refueling my jets, and spending time with my family. I know it’s an odd time for a vacation, but in my life you have to take them when you can. I hope everyone understands and will rejoin me when I return. With that said, if I find some time to break free I just might post a little somthing.

See you guys real soon, Sincerely Thomas Shue

Thomas Shue Photography Blog