How To Debug Firmware Update on Windows

So I tried this on a whim as this is very similar to issues I get with the com port for my STM32 drone flight controllers and it worked like a charm. After plugging in the device I ran the impulseRC driver fixer (found here) it errored out, but it fixed my com port issues.

1 Like

I’m having an issue where reinstalling doesn’t fix the DFU detection in Device Manager. The device seems to be behaving properly, but Windows 10 won’t see it, neither will qflipper 1.0.1 or 1.0.2.

Here are the logs:

206095 [RPC] Attempting to unload protobuf plugin…
206095 [RPC] Unloaded protobuf plugin.
206095 [RPC] RPC session stopped successfully.
206215 [REG] Device went offline: VID_0x483:PID_0x5740
208424 [REG] Detected new device: VID_0x483:PID_0xdf11
208426 [DBG] Failed to initialise WinUsb device
208426 [REG] Device initialization failed: Failed to initiate transaction
326210 [UTL] Start Recovery Mode @Unc1n4 ERROR: Failed to start recovery mode: operation timeout
326210 [DEV] Full Update @Unc1n4 ERROR: Failed to start recovery mode: operation timeout
326210 [BKD] Current operation finished with error: “Failed to start recovery mode: operation timeout”

My problem is that this post and the debug guide don’t provide guidance on actual debugging. They just tell you to check the driver versions. That’s not really helpful when there’s an error and the flipper isn’t showing up at all. Anyone find anything? Installing the impulse driver did not help.

This is usb 3 and 2, tried different ports for both. Win 10 fully updated. Device is also not showing up when I show hidden devices in Dev Man.

Please use the “OPEN FULL LOG” button in qFlipper just below the log screen to attach logs

Here you go. I had to pull some URLs out because I wasn’t able to post this w/ more than 2 links.

qflipper itself says “can’t find DFU device”. I found some STM32 drivers in another post, but I can’t install them. Windows says “the best driver for your device is already installed”. I also did a factory reset and reformatted the sd card between reinstalling qflipper. None of that helped. It still hangs trying to detect it in DFU mode, not showing up in dev man.

849 [APP] qFlipper version 1.0.2 commit 9284d92a 2022-04-27T09:52:33
850 [APP] OS info: Windows 10 Version 2009 10 10.0.19044
1156 [UPD] Fetched update information from
1247 [UPD] Fetched update information from
4206 [REG] Detected new device: VID_0x483:PID_0x5740
4208 [RPC] Starting RPC session…
4292 [RPC] RPC session started successfully.
4293 [RPC] (1) System Device Info START
4385 [RPC] (1) System Device Info SUCCESS
4385 [RPC] (2) Storage Info @/ext START
4436 [RPC] (2) Storage Info @/ext SUCCESS
4436 [RPC] (3) Storage Stat @/ext/Manifest START
4488 [RPC] (3) Storage Stat @/ext/Manifest SUCCESS
4489 [RPC] (4) System Get DateTime START
4539 [DBG] Flipper time skew is 508 milliseconds
4539 [RPC] (4) System Get DateTime SUCCESS
4539 [RPC] (5) System Set DateTime START
4590 [RPC] (5) System Set DateTime SUCCESS
4591 [RPC] Stopping RPC session…
4612 [RPC] Attempting to unload protobuf plugin…
4612 [RPC] Unloaded protobuf plugin.
4612 [RPC] RPC session stopped successfully.
4612 [REG] Registering the device
4612 [DEV] Version: 0.43.1 commit: a4267626 radio: 1.12.1
4612 [BKD] Current device changed to “Unc1n4”
4712 [RPC] Starting RPC session…
4787 [RPC] RPC session started successfully.
4787 [RPC] (1) Gui Start SreenStream START
4839 [RPC] (1) Gui Start SreenStream SUCCESS
12561 [RPC] (2) Gui Start VirtualDisplay START
12619 [RPC] (2) Gui Start VirtualDisplay SUCCESS
13081 [UPD] Fetched update information from https://update.flipperzero.one/firmware/directory.json
13140 [DEV] Full Update @Unc1n4 START
14362 [ZIP] Uncompressing file with size of 168696 bytes…
14364 [ZIP] Uncompression finished : No Error
14788 [ZIP] Uncompressing file with size of 26143 bytes…
14789 [ZIP] Uncompression finished : No Error
15437 [UTL] Backup /int @Unc1n4 START
15439 [RPC] (3) Storage List @/int START
15501 [RPC] (3) Storage List @/int SUCCESS
15503 [RPC] (4) Storage List @/int/ibutton START
15557 [RPC] (4) Storage List @/int/ibutton SUCCESS
15557 [RPC] (5) Storage List @/int/nfc START
15612 [RPC] (5) Storage List @/int/nfc SUCCESS
15612 [RPC] (6) Storage Read @/int/bt.keys START
15683 [RPC] (6) Storage Read @/int/bt.keys SUCCESS
15683 [RPC] (7) Storage Read @/int/bt.settings START
15737 [RPC] (7) Storage Read @/int/bt.settings SUCCESS
15737 [RPC] (8) Storage Read @/int/desktop.settings START
15791 [RPC] (8) Storage Read @/int/desktop.settings SUCCESS
15792 [RPC] (9) Storage Read @/int/dolphin.state START
15845 [RPC] (9) Storage Read @/int/dolphin.state SUCCESS
15845 [RPC] (10) Storage Read @/int/notification.settings START
15898 [RPC] (10) Storage Read @/int/notification.settings SUCCESS
15899 [RPC] (11) Storage Read @/int/nfc/Amex.nfc START
15955 [UTL] Backup /int @Unc1n4 SUCCESS
15955 [RPC] (11) Storage Read @/int/nfc/Amex.nfc SUCCESS
15955 [UTL] Start Recovery Mode @Unc1n4 START
15956 [RPC] (12) System Reboot START
15956 [RPC] (12) System Reboot SUCCESS
16009 [RPC] Serial connection was lost.
16009 [RPC] Stopping RPC session…
16009 [RPC] Attempting to unload protobuf plugin…
16009 [RPC] Unloaded protobuf plugin.
16009 [RPC] RPC session stopped successfully.
16156 [REG] Device went offline: VID_0x483:PID_0x5740
18381 [REG] Detected new device: VID_0x483:PID_0xdf11
18383 [DBG] Failed to initialise WinUsb device
18383 [REG] Device initialization failed: Failed to initiate transaction
136143 [UTL] Start Recovery Mode @Unc1n4 ERROR: Failed to start recovery mode: operation timeout
136143 [DEV] Full Update @Unc1n4 ERROR: Failed to start recovery mode: operation timeout

Please just attach the .txt file that it opens

qFlipper-20220503-081449.txt (3.2 KB)

1 Like

Please try the procedure described in this post, looks like forcing the driver manually would work in your case.

2 Likes

For some reason Windows 10 wouldn’t see a DFU device to install the driver. I installed Mint on my laptop and it immediately saw the flipper needed repair, then went through with the update. That’s what I get for using Windoze, I guess.

Thanks for all your help. Hopefully all this helps someone else if they stumble on it.

I ran into an issue where the update would hang every time at the co-processor firmware step. When I went to check the forums (here) I found they were IP blocked. So, on a hunch, I switched to a different VPN exit IP and the update runs immediately (and I have forum access again, obviously). So there’s got to be something in that step calling a different server somewhere that refuses connections from some IP addresses which causes the update to hang.

So, yay, another place I have to play VPN whack-a-mole with. Always fun.

Hi! We’ve identified that issue and it should be fixed now

image
When I try to run qflipper program it states a file is missing.
What am I doing wrong?

You need to download Microsoft Visual C++ Redistributable

qFlipper installer checks the Visual C++ runtime installation here. If it’s not installed, this means, that you have broken registry entry about this. Try to reinstall qFlipper again.

If you still get this error: The program can't start because vcruntime140_1.dll is missing from your computer. Try reinstalling the program to fix this problem.

You can try to install Visual C++ runtimes manually:

  1. Visual C++ 2010 x64 Redistributable
  2. Visual C++ 2019 x64 Redistributable

I have Visual C++ Redistributable. I just updated visual studios to be sure. It still is giving same error. I have also unistalled and reinstalled program 4 time.

The files you provided did it apparently I didnt have 2019. Thank you!!!

1 Like

Thank-you! This solved my DFU driver difficulties on Windows 10.

I did this:

  1. Run “impulseRC driver fixer” (link in PRD’s post)
  2. Put Flipper Zero (mine arrived today) in DFU mode (hold LEFT + BACK, release BACK, wait for DFU mode)
  3. Watch while “impulseRC driver fixer” detects the FZ and installs the DFU driver
  4. Run qFlipper. Gaze in awe at the happy message!

(also note, if you have access to a Linux box, it will play nice with qFlipper, too).

1 Like

thanks this worked

Dear Forum,

I just bricked my Flippper :frowning: - hope you can help.
After the installation of the update (0.69) via qFlipper 1.2.1 on Windows, the update process fails with
Current operation finished with error: “Failed to fetch the files: Failed to read radio manifest: JSON text is empty” if I select the update file to be downloaded
or with
Device went offline: XYZ
Exit Recovery Mode @XYZ ERROR: Failed to exit recovery: Operation timeout
Firmware install from file @XYZ ERROR: Failed to exit recovery: Operation timeout
Current operation finished with error: “Failed to exit recovery: Operation timeout”
if I select to update from a local file.

So far, I could not find this error in the discussion - can you please help ?

Many thanks
Flip_the_flop

Hello all,

Is this the most update tutorial to debug the flipper?

I was able to debug the flipper using an slink and connecting using the SWD pins, I can make a tutorial if no one did it yet.

Is there a way to debug with the USB connection directly on the Flipper?

Best regards,

This one is NOT for debugging the Flipper. It is for solving update problems.

Not sure, but the official docs seem to miss that.

Not easily I think. USB is normally occupied by CLI.