What vacuum cleaners Xiaomi can reflash: models with open source and instructions

Xiaomiโ€™s vacuum cleaner robots have long since ceased to be just household appliances, becoming a platform for enthusiastic experiments. Firmware flashing (or โ€œcustom firmwareโ€) allows you to unlock hidden features, improve cleaning algorithms, integrate Aliceโ€™s or Google Assistantโ€™s Yandex support, and sometimes even increase suction power. But not all Xiaomi models are amenable to such an upgrade: the manufacturer actively blocks the ability to install unofficial software on new devices.

In this article, we will look at which Xiaomi vacuum cleaners can be refried without the risk of turning them into a brick, which models have open loaders and which require complex manipulation of iron, and you will learn about the key differences between Valetudo, Dustcloud firmware and modified versions of stock software, and most importantly โ€“ which models after 2022 lost support for custom firmware due to hardware changes in chips.

Why Xiaomi vacuum cleaners are overexploited: the main reasons

Xiaomiโ€™s stock firmware often limits the functionality of devices, especially in models for the Chinese market (CN-Here are the main reasons why users decide to reflash the firmware:

  • ๐Ÿ”“ Removing the Mi Home link: Many models require authorization via Chinese servers, which creates privacy and stability issues.
  • ๐Ÿค– Integration with alternative ecosystems: Home Assistant, OpenHab or on-premises management without the cloud.
  • ๐Ÿ”ง Unlock hidden functions: for example, activating the turbo mode on models where it is disabled software.
  • ๐Ÿ“ก Improved mapping: Some custom firmware offers more accurate algorithms for building a room map.

But it's not all that rosy: flashing it over might take you out of warranty, and at worst, it might take your device out of order. RTL8710BN (They are used in Dreame. D9 And newer versions, they have bootload-level protection against writing unofficial software, and try to get around it without any special hardware (JTAG or UART) It almost always ends in failure.

โš ๏ธ Attention: Xiaomi vacuum cleaners with prefix STYJ or STYT In the model number (for example, Mi Robot Vacuum-Mop) 2 Lite STYJ02YM) They use a new type of controller that doesn't currently support flashing through standard methods. STM32 or ESP8266 lead to error FLASH_ERASE_TIMEOUT.

List of Xiaomi vacuum cleaners with confirmed support for flashing

Below are models that have stable custom firmware or unlock methods for bootloaders, and are up to date in 2026, based on reports from the Xiaomi Community and GitHub repositories (such as Valetudo).

ModelChip typeSupported firmwareHardware complexityNotes
Xiaomi Mi Robot Vacuum 1st Gen (rockrobo.vacuum.v1)STM32F103 + ESP8266Valetudo, Dustcloud, OpenMiHomeLow.Requires contact rations to access UART.
Xiaomi Mi Robot Vacuum 2 / 2S (roborock.vacuum.s5)STM32F4 + ESP8266Valetudo, Custom Mi HomeMediumSupports OTA-post-unblock update.
Dreame D9 / F9 (dreame.vacuum.p2008)Realtek RTL8710BNValetudo (limited)Tall.Requires resistor soldering on the board to unlock the loader.
Viomi V2 / V3 (viomi.vacuum.v7/v8)ESP32 + STM32Valetudo, ESPHomeMediumSupports local management through MQTT.
Xiaomi Mi Robot Vacuum-Mop P (roborock.vacuum.a10)STM32H7 + ESP32Valetudo (experimental)Tall.Risk of losing wet cleaning functions after firmware.

Note: Xiaomi models after 2021 (e.g. Mi Robot Vacuum-Mop 2 Pro or Dreame) L10 Pro) use protected Realtek chips RTL8720DN or ESP32-S3, There are no public exploits yet, and you can only flash them through official betas through Mi Home Developer Mode, but that doesn't give you full control of the device.

๐Ÿ“Š What kind of vacuum cleaner Xiaomi you have?
Mi Robot Vacuum 1/2 gen
Dreame D9/F9
Viomi V2/V3
Another Xiaomi
Not Xiaomi.

How to check if you can re-flash your vacuum cleaner

Before you start firmware, you need to determine the hardware revision of your device, and this can be done in several ways:

  1. Look for a sticker on the bottom: look for lines like Model: XXX or HW: For example, Mi Robot Vacuum 2 may have a revision. HW: 1.1 or HW: 1.3 - this depends on the method of firmware.
  2. Request information via Mi Home: adb shell getprop ro.product.model adb shell getprop ro.hardware (requires enabled) ADB debugging in the developer settings).
  3. Disassemble the vacuum cleaner and inspect the board: on some models, the version of the chip is listed next to the main processor (for example, STM32F103C8T6).

If your model doesnโ€™t make it to the table above, check it for compatibility through the Valetudo database. For example, Xiaomi vacuum cleaners with the roborock prefix in the model code are usually better supported than devices branded Dreame or Viomi.

โš ๏ธ Note: Models with cn suffix (e.g. Mi Robot Vacuum-Mop) E10_cn) They may have hardware limitations even if their "international" versions ( global) support firmware, due to differences in radio module certification.

Make a backup of the current firmware through flash_dump>

Check the chip version (STM32/ESP/Realtek)

Download firmware for a specific model (not universal!)

Prepare. USB-TTL adapter (CP2102/CH340)

Disconnect the vacuum cleaner from Mi Home (if required)

-->

How to reflash Xiaomi Mi Robot Vacuum 2

Consider the process on the example of the most popular model โ€“ Xiaomi Mi Robot Vacuum 2 (roborock.vacuum.s5). This method is also suitable for Viomi. V2, but corrected for contact patterning.

Tools required:

  • ๐Ÿ”ง USB-TTL adapter (3.3V, for example, CP2102).
  • ๐Ÿ”Œ Wires "dad-mama" to connect to the board.
  • ๐Ÿ’ป Flash Tool program (for example, stm32flash or esptool).
  • ๐Ÿ“ Valetudo firmware for your revision (download here).

Steps:

  1. Open the vacuum cleaner case: Remove the top cover by unscrewing 4 screws under the cross screwdriver. Carefully disconnect the battery (required!) to avoid short circuit.

Connect. USB-TTL pay-to-pay

GND โ†’ GND (ground)


TX โ†’ RX (receiver on the board)




RX โ†’ TX (transmitter on the board)




3.3V โ†’ VCC (Power, optional)

On the Mi Robot Vacuum 2 contact UART located near the main chip STM32 (Look for the inscriptions TX/RX board-board).

Run the firmware.

stm32flash -w valetudo.bin -v -g 0x0 /dev/ttyUSB0

If you have a Cannot init device error, check the connection correctly. BOOT0 (It should be in position 1 when the firmware is).

After successful firmware, the vacuum cleaner will restart and you will be able to connect to it via a local network (usually a local network). http://roborock.local). To set up Valetudo, follow the instructions in the documentation.

๐Ÿ’ก

If the vacuum cleaner does not respond to commands after firmware, try resetting settings via holding the Home button. + Spot for 10 seconds.

Risks and Possible Problems in Reflashing

Even if your model is officially supported, the process may not go according to plan.

Problem.Possible causeDecision
The vacuum cleaner does not turn on after firmwareWrong firmware version or recording failureRepeat the firmware with the correct.bin file
Mistake. FLASH_VERIFY_FAILEDPoor contact or flash memory malfunctionCheck the ration, try another. USB-TTL adapter
Wi-Fi does not work after the firmwareIncompatibility of drivers in custom firmwareRecoil on stock firmware or manually set up hostapd
Vacuum moves chaoticallyUncalibrated post-reset sensorsCalibrate the calibration using Valetudo Web Interface

The biggest problem is a "brick" -- 90 percent of the time, it's because of:

  • ๐Ÿ”Œ Incorrect power connection (for example, supply) 5V instead 3.3V).
  • ๐Ÿ“ฅ Interrupting the firmware process (for example, due to disconnection) USB).
  • ๐Ÿ”„ Incompatibility of the firmware version (for example, trying to flash Valetudo for the STM32F4 on STM32F1).
What to do if the vacuum cleaner has turned into a โ€œbrickโ€?
If the device does not respond to buttons and is not determined by USB, There are two options: 1. JTAG-firmware: requires soldering equipment and OpenOCD program. Detailed instructions are available on the forum 4PDA. 2. Chip replacement: in the service center (cost) ~3000-5000 In both cases, the guarantee is cancelled.

Alternatives to Flashing: What You Can Do Without Risk

If your model doesnโ€™t support custom firmware or youโ€™re not willing to take risks, consider these options:

  • ๐ŸŒ Local management through Mi Home API: Python scripts (the python-miio library) can send commands to a vacuum cleaner without a cloud. Example code for running a cleaning operation: from miio import Vacuum vac = Vacuum(ip="192.168.1.100", token="YOUR_TOKEN") vac.start()
  • ๐Ÿ”„ Update via Mi Home Beta: In the Mi Home app settings, you can turn on developer mode and test new features before they are officially released.
  • ๐Ÿค– Integration with Home Assistant via official plugin: Xiaomi Miio plugin for Home Assistant supports most models without the need for firmware.

For Dreame models (e.g, D9 or L10S Ultra) there is an informal DreameHome software that extends the functionality without making changes to the firmware of the device. MITM-Proxy (intercepting traffic between vacuum cleaner and cloud) that is safer than flashing.

๐Ÿ’ก

Before any firmware manipulation, check if a software solution (such as Home Assistant or Node-RED) solves your problem. Often additional features can be obtained without risk to the device.

Conclusion: should you re-flash the Xiaomi vacuum cleaner?

Reflashing the vacuum cleaner Xiaomi is justified in three cases:

  1. You want to get rid of Mi Home dependency completely (for example, because of problems with Chinese servers).
  2. You need advanced mapping features or integration with other ecosystems (Apple HomeKit, Google Home).
  3. Your model is older than 2020 and has community backing.

In all other cases, the risks outweigh the benefits: Xiaomiโ€™s current models (2022 and later) are almost impossible to flash without specialized hardware, and their stockware already offers most of the necessary features.

If you do decide to go firmware, follow the golden rule: "Backup first, experiment later (flash_dump), And remember, even a successful firmware can take away official support and security updates.

FAQ: Frequent questions about reflashing Xiaomi vacuum cleaners

Can I reflash the Xiaomi Mi Robot Vacuum-Mop 2 Pro?
At the moment (2026) this model does not support flashing due to the protected chip Realtek. RTL8720DN. The only option is to use informal scripts to manage via Mi Home. API, But that won't give you full control of the device.
Which is better: Valetudo or Dustcloud?
Valetudo is a more modern and supported solution with a web interface, whereas Dustcloud inherited code from older versions and may contain vulnerabilities. Valetudo is recommended for most users, especially if you need a Home Assistant or a Home Assistant. MQTT.
How to return stock firmware after a failed flashing?
To do this, you will need the original.bin-file firmware (you can extract from the backup or download on forums like 4PDA). The firmware is executed by the same team: stm32flash -w original_firmware.bin -v -g 0x0 /dev/ttyUSB0 If the device is not detected, it will be required JTAG or assistance from a service center.
Will the vacuum cleaner work without a cloud after the firmware?
Yes, one of the main goals of firmware like Valetudo is to be completely autonomous from Xiaomi servers. Once custom software is installed, the vacuum cleaner will work on the local network, and management is carried out through a web interface or a web interface. MQTT.
Can I use Bluetooth to clean the vacuum cleaner?
No, all known firmware methods require direct access to the board through UART or JTAG. Bluetooth in Xiaomi vacuum cleaners is used only for initial Wi-Fi settings and does not provide low-level memory access.