feat: add QV 35A dock type code (21) to RoborockDockTypeCode#865
Closed
epinethrone wants to merge 1 commit into
Closed
feat: add QV 35A dock type code (21) to RoborockDockTypeCode#865epinethrone wants to merge 1 commit into
epinethrone wants to merge 1 commit into
Conversation
The Roborock QV 35A (roborock.vacuum.a168) ships a wash/fill/dry dock that reports dock_type 21, which was missing from RoborockDockTypeCode. It therefore resolved to unknown, is_wash_n_fill_dock() returned False, and the wash_towel_mode trait was skipped - leaving the clean-water, dirty-water and strainer entities unavailable in downstream consumers despite the device reporting the data (dss, strainer_work_times). Mirrors Python-roborock#829 (Qrevo S5V, 22). Fixes Python-roborock#864.
Collaborator
|
Thank you for this PR! This has been something on my TODO list for a while now as we handle dock types a little poorly and rigidly. Inspired by this PR, I have actually made a PR that will solve a bit more of the problem at once and add a number of new dock types: I'm going to close out this PR as mine will handle a bit more, but I sincerely appreciate you making this PR! |
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
Adds dock type
21— the wash/fill/dry dock shipped with the Roborock QV 35A (roborock.vacuum.a168) — toRoborockDockTypeCodeand toWASH_N_FILL_DOCK_TYPES.This mirrors #829 (which added the Qrevo S5V,
22).Fixes #864.
Why
The QV 35A's dock reports
dock_type: 21, which had no enum member, soRoborockDockTypeCode(21)fell back tounknown. That madeis_wash_n_fill_dock()returnFalse, which skips thewash_towel_modetrait at setup (Trait 'wash_towel_mode' not supported, skipping). Downstream in Home Assistant, the clean-water-box, dirty-water-box and strainer entities are gated onwash_towel_mode is not None, so they were permanentlyunavailable— even though the device reports the underlying data (dssfor the tank statuses,strainer_work_timesin the consumables payload).Verified on a real QV 35A (firmware
02.36.38): after adding the dock type,is_wash_n_fill_dockisTrueand the trait is set up as expected. Clean-fluid delivery is not supported on this dock (is_clean_fluid_delivery_supported = False), so theclean_fluid_emptyentity correctly remains absent.Changes
roborock/data/v1/v1_code_mappings.py: addqv_35a_dock = 21.roborock/device_features.py: addRoborockDockTypeCode.qv_35a_docktoWASH_N_FILL_DOCK_TYPES.test_qv_35a_dock_type, plus the new dock type added to thewash_towel_mode/dust_collection_mode/smart_wash_paramstrait parametrizations — same coverage feat: add Qrevo S5V dock type code (22) to RoborockDockTypeCode #829 added.Testing
All pass (snapshots unchanged).