Add MIoT support for Xiaomi Robot Vacuum S40C EU#2060
Open
borsuk85 wants to merge 2 commits intorytilahti:masterfrom
Open
Add MIoT support for Xiaomi Robot Vacuum S40C EU#2060borsuk85 wants to merge 2 commits intorytilahti:masterfrom
borsuk85 wants to merge 2 commits intorytilahti:masterfrom
Conversation
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## master #2060 +/- ##
==========================================
+ Coverage 82.26% 82.55% +0.29%
==========================================
Files 197 200 +3
Lines 19145 19466 +321
Branches 1052 1064 +12
==========================================
+ Hits 15750 16071 +321
Misses 3218 3218
Partials 177 177 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
Document Xiaomi Robot Vacuum S40C EU support Fix Xiaomi S40C CI issues Increase Xiaomi S40C test coverage
Breaks long lines in test assertions and dictionary comprehensions. This improves code clarity and adherence to style conventions.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Add a dedicated MIoT integration for
xiaomi.vacuum.e101gb(Xiaomi Robot Vacuum S40C EU).This model does not work correctly through the legacy
RoborockVacuumpath, but it is locally controllable through MIoT. This change adds a dedicatedMiotDevice-based implementation instead of relying onGenericMiot.What is included
XiaomiVacuumE101GBintegrationstatus()implementation using smallget_propertiesbatchesstartstoppauseresumehomefindstart_room_sweepstart_zone_sweeproom_informationroom_idszone_idsget_room_configsget_zone_configsImplementation detail
The device does not always echo the request
didin property responses and may return the device id instead. Because of that, the integration maps status responses by(siid, piid)instead of relying ondid.The generic MIoT status query is also too wide for this device and may time out, so
status()intentionally reads a smaller, stable subset of properties in batches.Verified on real hardware
Tested locally against:
xiaomi.vacuum.e101gb4.5.6_0127Verified:
home()worksstart_room_sweep("3")starts cleaninghome()returns the vacuum to the dock afterwardsTests
Added unit tests for:
did