Rockbox Technical Forums

Third Party => Repairing and Upgrading Rockbox Capable Players => Topic started by: vitt13 on November 28, 2021, 03:36:54 PM

Title: Flashing and restoring factory firmware FiiO M3K / M5 players using Ingenic USB
Post by: vitt13 on November 28, 2021, 03:36:54 PM
Step 1 For M3K player make sure you have the stored serial number of the device (usually on package box), you can also find it in the Settings section player "About device" / "About M3"

For M5 player, write down the current Bluetooth MAC-address of the player and the serial number of the device in a notebook, you can see them in the section "About the device" / "About M5"

Step 2 Install USB drivers for the device from the directory "\cloner-win32-driver"
Disable driver signature enforcement in the Windows boot parameters before that step. It takes effect only once until the next reboot.
Alternatively you can try to install WinUSB driver with Zadig https://forums.rockbox.org/index.php/topic,53858.0.html (need to confirm)
Installing driver guide is not major topic of this recovery guide so here are few pictures just for reference.
(https://i.ibb.co/g6P1Vp0/driver-signature-check-off-windows-10.png) (http://ibb.co/g6P1Vp0) (https://i.ibb.co/02xg6DZ/devices.png) (http://ibb.co/02xg6DZ) (https://i.ibb.co/7jS0wQ0/devices-drv1.png) (http://ibb.co/7jS0wQ0) (https://i.ibb.co/yBnBGCc/devices-drv2.png) (http://ibb.co/yBnBGCc) (https://i.ibb.co/zXJmf7M/devices-drv3.png) (http://ibb.co/zXJmf7M) (https://i.ibb.co/Tm89Gdy/devices-drv4.png) (http://ibb.co/Tm89Gdy) (https://i.ibb.co/Gkn3GGk/devices-drv5.png) (http://ibb.co/Gkn3GGk) (https://i.ibb.co/QQp9Fv4/devices-drv6.png) (http://ibb.co/QQp9Fv4)

Step 3 Run application "USB Cloner Tool" on the path "\cloner-2.5.0-windows_release\cloner.exe"

Step 4 Press on Config button
(https://i.ibb.co/gvT8rTH/main-wnd.png) (http://ibb.co/gvT8rTH)

Step 5 In "INFO" tab choose "x1000" in "Platform" field and specific configuration file in "Boad" field.
FiiO M3K device needs "M3K_x1000_sfc_nand_lpddr_recovery.cfg"
(https://i.ibb.co/sFDWqKd/cfg-M3k.png) (http://ibb.co/sFDWqKd)
FiiO M5 device needs "M5_x1000_sfc_nand_lpddr_recovery.cfg"
(https://i.ibb.co/M6YqLdk/cfg-M5.png) (http://ibb.co/M6YqLdk)

Step 6 Go to "POLICY" tab and set the paths to every firmware part files.
You may find the needed parts of full firmware version 1.2 on "\M3K_firmware_1.2" and "\M5_firmware_1.2" directories.
for example
Code: [Select]
uboot = ...\x-loader-pad-with-sleep-lib.bin
xImage = ...\xImage
recovery = ...\recovery
system = ...\system.ubi
data = ...\data.ubi

Generally you do not need to choose all of parts and can set and choose only that you need to flash/update.
I.e. if you have extracted parts from "ota update" firmware v1.4.5 it provides only bootloader, kernel image and system partition image.
Here are example of configuration that will flash/update all selected parts
for M3K
(https://i.ibb.co/2h7qSPd/cfg-part-m3k.png) (http://ibb.co/2h7qSPd)
and M5 player device
(https://i.ibb.co/3zqdg4Z/cfg-part-m5.png) (http://ibb.co/3zqdg4Z)

Attention! It's very important to note that there is the check box "Erase All" that sets by default in "SFC" tab. It allows to erase all internal FLASH memory.
So if you do not need to erase all of internal memory content unset that checkbox.
(https://i.ibb.co/rH7zZ8k/check.png) (http://ibb.co/rH7zZ8k)

Step 7 You may save tool's settings but make sure that path to configuration file should not contain the spaces.

Step 8 Make sure that player does not connected to PC and press "Start" button in the tool.
Now make sure that player powered off then press "Volume-" button on the player and connect the player to PC with USB cable. The firmware flashing starts.
(https://i.ibb.co/k4ChQCH/start.png) (http://ibb.co/k4ChQCH)

After successful firmware update the player will reboot automatically.

---
Here are USB driver, "USB cloner tool" and firmware v1.2 for FiiO M3K and M5 players.
Download link: https://www.mediafire.com/file/exzvvxjp4l3ai8u/M3K_M5_USB_cloner_tool.zip/file
Title: Re: Flashing and restoring factory firmware FiiO M3K / M5 players using Ingenic USB
Post by: 7o9 on November 29, 2021, 01:42:16 AM
Thanks for this guide.

Good to note that besides the required software, the archive also contains the images from this post in a more readable resolution.

One thing: What is step 1 for? Is the serial number needed for this process?
Title: Re: Flashing and restoring factory firmware FiiO M3K / M5 players using Ingenic USB
Post by: vitt13 on November 29, 2021, 03:52:03 AM
One thing: What is step 1 for? Is the serial number needed for this process?
No, but it stored in data.ubi partition image as text file "/data/userfs/sn.txt" (also "/data/userfs/nb.txt") inside UBIFS. It may be lost in reflashing 'factory' data partition image from v1.2 FW. I have not the guide how to repack data.ubi and rewrite serial number inside it. But it can be made with "Kitchen" https://forums.rockbox.org/index.php/topic,52917.msg248737.html#msg248737 on Windows or with https://github.com/jrspruitt/ubi_reader and mkfs.ubifs on Linux.
the archive also contains the images from this post in a more readable resolution.
fixed links to hi-res pics in the fist post
Title: Re: Flashing and restoring factory firmware FiiO M3K / M5 players using Ingenic USB
Post by: amachronic on November 29, 2021, 03:49:07 PM
Wow.. I came across the 'cloner' before, but I could never figure out how to make it work properly. Nice work.
Title: Re: Flashing and restoring factory firmware FiiO M3K / M5 players using Ingenic USB
Post by: vitt13 on November 30, 2021, 08:16:59 AM
I requested the tools to recover M3K and M5 when there was problem with freezing on boot screen on 1.4.3 OF for a year ago.
I got the tool with configuration files and full FW v1.2 from FiiO support with remark "The only problem is it's only Chinese version". Sorry for not reveal the guide early.