Skip to content

feat: add V1 dock types 48 and 50 and fix F2R, K1S and Hera dock capabilities - #1047

Merged
allenporter merged 2 commits into
Python-roborock:mainfrom
infy1995:feat/v1-dock-types-from-app
Nov 23, 2026
Merged

allenporter merged 2 commits into
Python-roborock:mainfrom
infy1995:feat/v1-dock-types-from-app

Conversation

@infy1995

@infy1995 infy1995 commented Nov 14, 2026 •

Copy link
Copy Markdown
Contributor

Summary

Adds the V1 dock types that the library did not know and fixes three dock capabilities, so dock options can be gated on the right dock.

  • New dock type codes f1rc_dock = 48 and f2rs_dock = 50. Until now these codes fell back to unknown, so the dock counted as missing and no dock traits were offered.
  • Capabilities for codes 48, 49 and 50 (F1RC, F1RS, F2RS): collect, wash and dry, high-temperature water, double serial communication, simple wash modes, no-water-flow carousel (49, 50), carousel self-clean (48 without AM) and water up/down drain (AM variants of 49 and 50).
  • Aliases with the dock names for two placeholder members: shell_4_dock (27) and f1rs_dock (49). type_27_dock and type_49_dock stay the canonical names, so .name, keys() and existing code are unchanged.
  • New dock properties:
    • is_multi_clean_fluid_supported (Shell 4S without AM).
    • is_clean_carousel_supported (dock has a carousel/strainer).
  • The docs for is_hot_wash_towel_supported now say that it is reported by the robot firmware and does not account for the dock: a Shell E dock cannot wash with hot water. The mop wash PR (feat: add V1 dock mop wash settings and tray self-clean #1045, not merged yet) will not offer the wash water temperature on Shell E docks, so consumers will not need a separate flag.
  • Docs: new "Dock Features" section in docs/V1_DEVICE_FEATURES.md. It explains that the "A"/"AM" dock variants (Shell 2SA, O5AM, ...) are not separate codes: they report the same dock_type and differ by Status.has_am.

The dock list and capabilities were compared with the dock table in the newest Roborock app V1 plugins and now match it.

Changed existing values

These results change for docks the library already knew.

Dock Capability Before After Reason
F2R (43) is_clean_carousel_self_clean_supported True False The newest app plugins no longer offer carousel self-clean for F2R. Older plugins did.
K1S (20), without AM is_clean_fluid_auto_delivery_supported False True The newest app plugins add automatic fluid delivery to K1S. The AM variant was already True.
Hera (24) is_hatch_door_dock_cool_fan_supported False True The Hera dock has the hatch door cooling fan, like Couple; every app plugin that knows Hera treats it so.

Known difference, not changed here

is_special_support_wash_temp is True only for the Shell 2E Lite dock. Whether wash temperature is offered also depends on the product: every product except the PearlE Pro gets it, and the PearlE Pro only with a Shell 2E Lite dock. The library does not use this property yet. It will be fixed when the wash temperature options start using it.

Testing

  • Table-driven tests in tests/test_supported_features.py for each new code and changed value, with and without AM, and for the aliases.
  • pre-commit run --all-files and the full pytest suite pass.

Part of #738

Add dock type codes 48 (F1RC) and 50 (F2RS), app-name aliases for codes 27 and 49, the capabilities of codes 48-50, and three new dock properties. K1S gets automatic fluid delivery, Hera the hatch-door cool fan, and F2R no longer reports carousel self-cleaning, following the newest app plugins.
@Lash-L Lash-L added Feature New feature Data model changes Changes to data models, device info, or feature mappings V1 V1 platform labels Nov 15, 2026
@infy1995 infy1995 changed the title feat: add new V1 dock types and align dock capabilities with the app feat: add V1 dock types 48 and 50 and fix F2R, K1S and Hera dock capabilities Nov 17, 2026

@Lash-L Lash-L left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Automated code review by Gemini 4 Hydrogen in Antigravity using our /review (/code-review) skill (.agents/skills/code-review/SKILL.md / AGENTS.md).

Summary

No blocking issues or defects found — this PR is clean and ready to approve.

  • Priority 1 & 2 (Public Contracts & Feature Gating — roborock/device_features.py, docs/V1_DEVICE_FEATURES.md):
    • Verified all dock capability sets and properties (is_no_support_hot_wash_towel, is_multi_clean_fluid_supported, is_clean_carousel_supported, and the updates for F2R, K1S, Hera, F1RC, F1RS, F2RS) against the Roborock app's 72 dock configurations (both AM and non-AM variants). Every capability matches the app's dock table and getters.
    • is_special_support_wash_temp is accurately documented as covering the dock-only portion of the app's check.
  • Priority 3 (Wire Codes & Enums — roborock/data/v1/v1_code_mappings.py):
    • Verified all RoborockDockTypeCode values (0–3, 5–11, 13–24, 26–35, 37–46, 48–50): no app dock codes are missing. f1rc_dock = 48 and f2rs_dock = 50 match the app names, and aliases shell_4_dock = 27 and f1rs_dock = 49 preserve canonical .name and iteration behavior.
  • Tests & Tooling (tests/test_supported_features.py):
    • Table-driven @pytest.mark.parametrize tests cover the new codes, aliases, AM/non-AM variants, and changed capabilities.
    • pytest tests/test_supported_features.py tests/conformance/ (541 passed, 53 xfailed, 11 snapshots passed) and ruff check on the changed Python files pass.

@Lash-L Lash-L added /review run Code review skill (/review) has been run Passed /review Passed the /review skill check labels Nov 18, 2026
Comment thread docs/V1_DEVICE_FEATURES.md Outdated
### is_no_support_hot_wash_towel
**Docks:** Shell E
**Description:** The dock cannot wash mops with hot water. The app hides hot mop washing for these docks even when
`DeviceFeatures.is_hot_wash_towel_supported` is true.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Instead of adding a separate boolean that needs to be checked, can we make is_hot_wash_towel_supported accurate instead?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Agreed, consumers should not have to combine two flags. I removed is_no_support_hot_wash_towel in 12ccf50.

I did not change is_hot_wash_towel_supported itself. It comes from the robot firmware and is cached with the device features, while the dock type is only known at runtime and can change when the dock is swapped. Folding the dock into that cached field would store dock-specific state. Its docs now say the Shell E dock cannot wash with hot water.

The dock check goes where the library knows both the robot and the dock: in the mop wash PR (#1045), the wash water temperature trait will not be created on Shell E docks. Consumers then only need to check whether that trait exists.

is_hot_wash_towel_supported stays the robot firmware signal and its docs now say the Shell E dock cannot wash with hot water. The wash water temperature trait will check the dock instead, so consumers do not need to combine two flags.

@Lash-L Lash-L left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Automated code review by Gemini 4 Neon in Antigravity using our /review (/code-review) skill (.agents/skills/code-review/SKILL.md / AGENTS.md).

Follow-up Review (6c87b48 → 12ccf50)

No blocking issues or defects found — this PR remains clean and passes /review.

  • Priority 1 & 2 (Public Contracts, Lifecycle & Feature Gating — roborock/device_features.py, docs/V1_DEVICE_FEATURES.md):
    • Dropping _NO_HOT_WASH_TOWEL_DOCK_TYPES and RoborockDockFeatures.is_no_support_hot_wash_towel avoids exposing a negative dock flag that consumers would have to combine manually with DeviceFeatures.is_hot_wash_towel_supported.
    • Cross-verified against the Roborock app bundle: noHotWashTowel: true is set only on ShellE (dockType: 21, hasAM: false) and ShellEA (dockType: 21, hasAM: true), and Dock.isNoSupportHotWashTowel has only a single caller (FM.isHotWashTowelSupported(), which combines firmware bit 41 with !Dock.isNoSupportHotWashTowel).
    • Keeping DeviceFeatures.is_hot_wash_towel_supported as the pure cached firmware bit (with the Shell E caveat documented in docs/V1_DEVICE_FEATURES.md) and gating the wash water temperature trait where both DeviceFeatures and runtime dock_type are available avoids mixing runtime dock state into cached device features and introduces no regression (is_hot_wash_towel_supported is not yet consumed by any trait on main).
  • Tests & CI (tests/test_supported_features.py):
    • Removed obsolete test cases cleanly with no leftover references; all CI checks (lint, Lint Commit Messages, test, test-mqtt, Build Package, Test Semantic Release) are green on 12ccf50.

@Lash-L Lash-L left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

values appear to be correct

@Lash-L
Lash-L requested a review from allenporter November 22, 2026 19:40
@allenporter
allenporter merged commit 2304dd6 into Python-roborock:main Nov 23, 2026
9 checks passed
@infy1995
infy1995 deleted the feat/v1-dock-types-from-app branch November 23, 2026 06:41
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Data model changes Changes to data models, device info, or feature mappings Feature New feature Passed /review Passed the /review skill check /review run Code review skill (/review) has been run V1 V1 platform

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants