python-roborock 2.61.0__tar.gz → 3.1.2__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {python_roborock-2.61.0 → python_roborock-3.1.2}/PKG-INFO +1 -1
- {python_roborock-2.61.0 → python_roborock-3.1.2}/pyproject.toml +16 -9
- {python_roborock-2.61.0 → python_roborock-3.1.2}/roborock/__init__.py +3 -11
- {python_roborock-2.61.0 → python_roborock-3.1.2}/roborock/api.py +1 -1
- {python_roborock-2.61.0 → python_roborock-3.1.2}/roborock/broadcast_protocol.py +1 -1
- {python_roborock-2.61.0 → python_roborock-3.1.2}/roborock/cli.py +12 -1
- {python_roborock-2.61.0 → python_roborock-3.1.2}/roborock/cloud_api.py +1 -1
- python_roborock-3.1.2/roborock/data/__init__.py +9 -0
- python_roborock-3.1.2/roborock/data/b01_q10/__init__.py +2 -0
- python_roborock-3.1.2/roborock/data/b01_q10/b01_q10_code_mappings.py +213 -0
- python_roborock-3.1.2/roborock/data/b01_q10/b01_q10_containers.py +53 -0
- python_roborock-3.1.2/roborock/data/b01_q7/__init__.py +2 -0
- python_roborock-2.61.0/roborock/b01_containers.py → python_roborock-3.1.2/roborock/data/b01_q7/b01_q7_code_mappings.py +1 -130
- python_roborock-3.1.2/roborock/data/b01_q7/b01_q7_containers.py +130 -0
- python_roborock-3.1.2/roborock/data/code_mappings.py +146 -0
- python_roborock-3.1.2/roborock/data/containers.py +436 -0
- python_roborock-3.1.2/roborock/data/dyad/__init__.py +2 -0
- python_roborock-3.1.2/roborock/data/dyad/dyad_code_mappings.py +102 -0
- python_roborock-3.1.2/roborock/data/dyad/dyad_containers.py +28 -0
- python_roborock-3.1.2/roborock/data/v1/__init__.py +3 -0
- python_roborock-2.61.0/roborock/clean_modes.py → python_roborock-3.1.2/roborock/data/v1/v1_clean_modes.py +6 -2
- python_roborock-2.61.0/roborock/code_mappings.py → python_roborock-3.1.2/roborock/data/v1/v1_code_mappings.py +147 -528
- python_roborock-2.61.0/roborock/containers.py → python_roborock-3.1.2/roborock/data/v1/v1_containers.py +50 -494
- python_roborock-3.1.2/roborock/data/zeo/__init__.py +2 -0
- python_roborock-3.1.2/roborock/data/zeo/zeo_code_mappings.py +136 -0
- {python_roborock-2.61.0 → python_roborock-3.1.2}/roborock/device_features.py +3 -2
- {python_roborock-2.61.0 → python_roborock-3.1.2}/roborock/devices/cache.py +1 -1
- {python_roborock-2.61.0 → python_roborock-3.1.2}/roborock/devices/device.py +1 -1
- {python_roborock-2.61.0 → python_roborock-3.1.2}/roborock/devices/device_manager.py +2 -1
- {python_roborock-2.61.0 → python_roborock-3.1.2}/roborock/devices/mqtt_channel.py +1 -1
- {python_roborock-2.61.0 → python_roborock-3.1.2}/roborock/devices/traits/a01/__init__.py +1 -1
- {python_roborock-2.61.0 → python_roborock-3.1.2}/roborock/devices/traits/v1/__init__.py +19 -8
- {python_roborock-2.61.0 → python_roborock-3.1.2}/roborock/devices/traits/v1/child_lock.py +1 -1
- python_roborock-2.61.0/roborock/devices/traits/v1/clean_record.py → python_roborock-3.1.2/roborock/devices/traits/v1/clean_summary.py +34 -21
- {python_roborock-2.61.0 → python_roborock-3.1.2}/roborock/devices/traits/v1/common.py +1 -1
- {python_roborock-2.61.0 → python_roborock-3.1.2}/roborock/devices/traits/v1/consumeable.py +1 -1
- {python_roborock-2.61.0 → python_roborock-3.1.2}/roborock/devices/traits/v1/device_features.py +1 -1
- {python_roborock-2.61.0 → python_roborock-3.1.2}/roborock/devices/traits/v1/do_not_disturb.py +1 -1
- {python_roborock-2.61.0 → python_roborock-3.1.2}/roborock/devices/traits/v1/dust_collection_mode.py +1 -1
- {python_roborock-2.61.0 → python_roborock-3.1.2}/roborock/devices/traits/v1/flow_led_status.py +1 -1
- {python_roborock-2.61.0 → python_roborock-3.1.2}/roborock/devices/traits/v1/home.py +2 -2
- {python_roborock-2.61.0 → python_roborock-3.1.2}/roborock/devices/traits/v1/led_status.py +1 -1
- {python_roborock-2.61.0 → python_roborock-3.1.2}/roborock/devices/traits/v1/map_content.py +1 -1
- {python_roborock-2.61.0 → python_roborock-3.1.2}/roborock/devices/traits/v1/maps.py +1 -1
- python_roborock-3.1.2/roborock/devices/traits/v1/network_info.py +56 -0
- {python_roborock-2.61.0 → python_roborock-3.1.2}/roborock/devices/traits/v1/rooms.py +1 -1
- {python_roborock-2.61.0 → python_roborock-3.1.2}/roborock/devices/traits/v1/smart_wash_params.py +1 -1
- {python_roborock-2.61.0 → python_roborock-3.1.2}/roborock/devices/traits/v1/status.py +1 -1
- {python_roborock-2.61.0 → python_roborock-3.1.2}/roborock/devices/traits/v1/valley_electricity_timer.py +1 -1
- {python_roborock-2.61.0 → python_roborock-3.1.2}/roborock/devices/traits/v1/wash_towel_mode.py +1 -1
- {python_roborock-2.61.0 → python_roborock-3.1.2}/roborock/devices/v1_channel.py +1 -1
- {python_roborock-2.61.0 → python_roborock-3.1.2}/roborock/devices/v1_rpc_channel.py +1 -1
- {python_roborock-2.61.0 → python_roborock-3.1.2}/roborock/protocol.py +1 -1
- {python_roborock-2.61.0 → python_roborock-3.1.2}/roborock/protocols/v1_protocol.py +1 -1
- python_roborock-3.1.2/roborock/py.typed +0 -0
- {python_roborock-2.61.0 → python_roborock-3.1.2}/roborock/roborock_typing.py +1 -1
- {python_roborock-2.61.0 → python_roborock-3.1.2}/roborock/version_1_apis/roborock_client_v1.py +2 -2
- {python_roborock-2.61.0 → python_roborock-3.1.2}/roborock/version_1_apis/roborock_mqtt_client_v1.py +1 -1
- {python_roborock-2.61.0 → python_roborock-3.1.2}/roborock/version_a01_apis/roborock_client_a01.py +4 -2
- {python_roborock-2.61.0 → python_roborock-3.1.2}/roborock/version_a01_apis/roborock_mqtt_client_a01.py +1 -1
- {python_roborock-2.61.0 → python_roborock-3.1.2}/roborock/web_api.py +1 -1
- python_roborock-2.61.0/roborock/devices/traits/v1/clean_summary.py +0 -29
- {python_roborock-2.61.0 → python_roborock-3.1.2}/.gitignore +0 -0
- {python_roborock-2.61.0 → python_roborock-3.1.2}/LICENSE +0 -0
- {python_roborock-2.61.0 → python_roborock-3.1.2}/README.md +0 -0
- {python_roborock-2.61.0 → python_roborock-3.1.2}/roborock/callbacks.py +0 -0
- {python_roborock-2.61.0 → python_roborock-3.1.2}/roborock/command_cache.py +0 -0
- {python_roborock-2.61.0 → python_roborock-3.1.2}/roborock/const.py +0 -0
- /python_roborock-2.61.0/roborock/py.typed → /python_roborock-3.1.2/roborock/data/zeo/zeo_containers.py +0 -0
- {python_roborock-2.61.0 → python_roborock-3.1.2}/roborock/devices/README.md +0 -0
- {python_roborock-2.61.0 → python_roborock-3.1.2}/roborock/devices/__init__.py +0 -0
- {python_roborock-2.61.0 → python_roborock-3.1.2}/roborock/devices/a01_channel.py +0 -0
- {python_roborock-2.61.0 → python_roborock-3.1.2}/roborock/devices/b01_channel.py +0 -0
- {python_roborock-2.61.0 → python_roborock-3.1.2}/roborock/devices/channel.py +0 -0
- {python_roborock-2.61.0 → python_roborock-3.1.2}/roborock/devices/local_channel.py +0 -0
- {python_roborock-2.61.0 → python_roborock-3.1.2}/roborock/devices/traits/__init__.py +0 -0
- {python_roborock-2.61.0 → python_roborock-3.1.2}/roborock/devices/traits/b01/__init__.py +0 -0
- {python_roborock-2.61.0 → python_roborock-3.1.2}/roborock/devices/traits/traits_mixin.py +0 -0
- {python_roborock-2.61.0 → python_roborock-3.1.2}/roborock/devices/traits/v1/command.py +0 -0
- {python_roborock-2.61.0 → python_roborock-3.1.2}/roborock/devices/traits/v1/volume.py +0 -0
- {python_roborock-2.61.0 → python_roborock-3.1.2}/roborock/exceptions.py +0 -0
- {python_roborock-2.61.0 → python_roborock-3.1.2}/roborock/map/__init__.py +0 -0
- {python_roborock-2.61.0 → python_roborock-3.1.2}/roborock/map/map_parser.py +0 -0
- {python_roborock-2.61.0 → python_roborock-3.1.2}/roborock/mqtt/__init__.py +0 -0
- {python_roborock-2.61.0 → python_roborock-3.1.2}/roborock/mqtt/roborock_session.py +0 -0
- {python_roborock-2.61.0 → python_roborock-3.1.2}/roborock/mqtt/session.py +0 -0
- {python_roborock-2.61.0 → python_roborock-3.1.2}/roborock/protocols/a01_protocol.py +0 -0
- {python_roborock-2.61.0 → python_roborock-3.1.2}/roborock/protocols/b01_protocol.py +0 -0
- {python_roborock-2.61.0 → python_roborock-3.1.2}/roborock/roborock_future.py +0 -0
- {python_roborock-2.61.0 → python_roborock-3.1.2}/roborock/roborock_message.py +0 -0
- {python_roborock-2.61.0 → python_roborock-3.1.2}/roborock/util.py +0 -0
- {python_roborock-2.61.0 → python_roborock-3.1.2}/roborock/version_1_apis/__init__.py +0 -0
- {python_roborock-2.61.0 → python_roborock-3.1.2}/roborock/version_1_apis/roborock_local_client_v1.py +0 -0
- {python_roborock-2.61.0 → python_roborock-3.1.2}/roborock/version_a01_apis/__init__.py +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: python-roborock
|
|
3
|
-
Version:
|
|
3
|
+
Version: 3.1.2
|
|
4
4
|
Summary: A package to control Roborock vacuums.
|
|
5
5
|
Project-URL: Repository, https://github.com/humbertogontijo/python-roborock
|
|
6
6
|
Project-URL: Documentation, https://python-roborock.readthedocs.io/
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
[project]
|
|
2
2
|
name = "python-roborock"
|
|
3
|
-
version = "
|
|
3
|
+
version = "3.1.2"
|
|
4
4
|
description = "A package to control Roborock vacuums."
|
|
5
5
|
authors = [{ name = "humbertogontijo", email = "humbertogontijo@users.noreply.github.com" }, {name="Lash-L"}, {name="allenporter"}]
|
|
6
6
|
requires-python = ">=3.11, <4"
|
|
@@ -44,7 +44,7 @@ dev = [
|
|
|
44
44
|
"pytest",
|
|
45
45
|
"pre-commit>=3.5,<5.0",
|
|
46
46
|
"mypy",
|
|
47
|
-
"ruff==0.14.
|
|
47
|
+
"ruff==0.14.1",
|
|
48
48
|
"codespell",
|
|
49
49
|
"pyshark>=0.6,<0.7",
|
|
50
50
|
"aioresponses>=0.7.7,<0.8",
|
|
@@ -52,6 +52,8 @@ dev = [
|
|
|
52
52
|
"pytest-timeout>=2.3.1,<3",
|
|
53
53
|
"syrupy>=4.9.1,<5",
|
|
54
54
|
"pdoc>=15.0.4,<16",
|
|
55
|
+
"pyyaml>=6.0.3",
|
|
56
|
+
"pyshark>=0.6",
|
|
55
57
|
]
|
|
56
58
|
|
|
57
59
|
[tool.hatch.build.targets.sdist]
|
|
@@ -67,7 +69,18 @@ build-backend = "hatchling.build"
|
|
|
67
69
|
[tool.semantic_release]
|
|
68
70
|
branch = "main"
|
|
69
71
|
version_toml = ["pyproject.toml:project.version"]
|
|
70
|
-
build_command = "pip install uv && uv build"
|
|
72
|
+
build_command = "pip install uv && uv lock --upgrade-package python-roborock && git add uv.lock && uv build"
|
|
73
|
+
changelog_file = 'CHANGELOG.md'
|
|
74
|
+
commit = true
|
|
75
|
+
|
|
76
|
+
[tool.semantic_release.branches.main]
|
|
77
|
+
match = "main"
|
|
78
|
+
prerelease = false
|
|
79
|
+
|
|
80
|
+
[tool.semantic_release.branches.temp-main-branch]
|
|
81
|
+
match = "temp-main-branch"
|
|
82
|
+
prerelease = false
|
|
83
|
+
|
|
71
84
|
|
|
72
85
|
[tool.semantic_release.commit_parser_options]
|
|
73
86
|
allowed_tags = [
|
|
@@ -92,9 +105,3 @@ asyncio_mode = "auto"
|
|
|
92
105
|
asyncio_default_fixture_loop_scope = "function"
|
|
93
106
|
timeout = 30
|
|
94
107
|
log_format = "%(asctime)s.%(msecs)03d %(levelname)s (%(threadName)s) [%(name)s] %(message)s"
|
|
95
|
-
|
|
96
|
-
[tool.uv]
|
|
97
|
-
dev-dependencies = [
|
|
98
|
-
"pyyaml>=6.0.3",
|
|
99
|
-
"pyshark>=0.6",
|
|
100
|
-
]
|
|
@@ -3,19 +3,14 @@
|
|
|
3
3
|
.. include:: ../README.md
|
|
4
4
|
"""
|
|
5
5
|
|
|
6
|
-
from roborock.
|
|
7
|
-
from roborock.code_mappings import *
|
|
8
|
-
from roborock.containers import *
|
|
6
|
+
from roborock.data import *
|
|
9
7
|
from roborock.exceptions import *
|
|
10
8
|
from roborock.roborock_typing import *
|
|
11
9
|
|
|
12
10
|
from . import (
|
|
13
|
-
b01_containers,
|
|
14
|
-
clean_modes,
|
|
15
11
|
cloud_api,
|
|
16
|
-
code_mappings,
|
|
17
12
|
const,
|
|
18
|
-
|
|
13
|
+
data,
|
|
19
14
|
exceptions,
|
|
20
15
|
roborock_typing,
|
|
21
16
|
version_1_apis,
|
|
@@ -27,13 +22,10 @@ __all__ = [
|
|
|
27
22
|
"web_api",
|
|
28
23
|
"version_1_apis",
|
|
29
24
|
"version_a01_apis",
|
|
30
|
-
"containers",
|
|
31
|
-
"b01_containers",
|
|
32
25
|
"const",
|
|
33
26
|
"cloud_api",
|
|
34
|
-
"clean_modes",
|
|
35
|
-
"code_mappings",
|
|
36
27
|
"roborock_typing",
|
|
37
28
|
"exceptions",
|
|
29
|
+
"data",
|
|
38
30
|
# Add new APIs here in the future when they are public e.g. devices/
|
|
39
31
|
]
|
|
@@ -19,7 +19,7 @@ from construct import ( # type: ignore
|
|
|
19
19
|
from Crypto.Cipher import AES
|
|
20
20
|
|
|
21
21
|
from roborock import RoborockException
|
|
22
|
-
from roborock.
|
|
22
|
+
from roborock.data import BroadcastMessage
|
|
23
23
|
from roborock.protocol import EncryptionAdapter, Utils, _Parser
|
|
24
24
|
|
|
25
25
|
_LOGGER = logging.getLogger(__name__)
|
|
@@ -42,7 +42,7 @@ from pyshark.capture.live_capture import LiveCapture, UnknownInterfaceException
|
|
|
42
42
|
from pyshark.packet.packet import Packet # type: ignore
|
|
43
43
|
|
|
44
44
|
from roborock import SHORT_MODEL_TO_ENUM, RoborockCommand
|
|
45
|
-
from roborock.
|
|
45
|
+
from roborock.data import CombinedMapInfo, DeviceData, HomeData, NetworkInfo, RoborockBase, UserData
|
|
46
46
|
from roborock.device_features import DeviceFeatures
|
|
47
47
|
from roborock.devices.cache import Cache, CacheData
|
|
48
48
|
from roborock.devices.device import RoborockDevice
|
|
@@ -731,6 +731,16 @@ async def home(ctx, device_id: str, refresh: bool):
|
|
|
731
731
|
click.echo("No maps discovered")
|
|
732
732
|
|
|
733
733
|
|
|
734
|
+
@session.command()
|
|
735
|
+
@click.option("--device_id", required=True)
|
|
736
|
+
@click.pass_context
|
|
737
|
+
@async_command
|
|
738
|
+
async def network_info(ctx, device_id: str):
|
|
739
|
+
"""Get device network information."""
|
|
740
|
+
context: RoborockContext = ctx.obj
|
|
741
|
+
await _display_v1_trait(context, device_id, lambda v1: v1.network_info)
|
|
742
|
+
|
|
743
|
+
|
|
734
744
|
@click.command()
|
|
735
745
|
@click.option("--device_id", required=True)
|
|
736
746
|
@click.option("--cmd", required=True)
|
|
@@ -979,6 +989,7 @@ cli.add_command(child_lock)
|
|
|
979
989
|
cli.add_command(dnd)
|
|
980
990
|
cli.add_command(flow_led_status)
|
|
981
991
|
cli.add_command(led_status)
|
|
992
|
+
cli.add_command(network_info)
|
|
982
993
|
|
|
983
994
|
|
|
984
995
|
def main():
|
|
@@ -14,7 +14,7 @@ from paho.mqtt.enums import MQTTErrorCode
|
|
|
14
14
|
from paho.mqtt.reasoncodes import ReasonCode # type: ignore
|
|
15
15
|
|
|
16
16
|
from .api import KEEPALIVE, RoborockClient
|
|
17
|
-
from .
|
|
17
|
+
from .data import DeviceData, UserData
|
|
18
18
|
from .exceptions import RoborockException, VacuumError
|
|
19
19
|
from .protocol import (
|
|
20
20
|
Decoder,
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
"""This module is meant to hold dataclasses and codemappings for various devices and protocols."""
|
|
2
|
+
|
|
3
|
+
from .b01_q7 import *
|
|
4
|
+
from .b01_q10 import *
|
|
5
|
+
from .code_mappings import *
|
|
6
|
+
from .containers import *
|
|
7
|
+
from .dyad import *
|
|
8
|
+
from .v1 import *
|
|
9
|
+
from .zeo import *
|
|
@@ -0,0 +1,213 @@
|
|
|
1
|
+
from ..code_mappings import RoborockModeEnum
|
|
2
|
+
|
|
3
|
+
|
|
4
|
+
class B01_Q10_DP(RoborockModeEnum):
|
|
5
|
+
CLEAN_TIME = ("dpCleanTime", 6)
|
|
6
|
+
CLEAN_AREA = ("dpCleanArea", 7)
|
|
7
|
+
SEEK = ("dpSeek", 11)
|
|
8
|
+
REMOTE = ("dpRemote", 12)
|
|
9
|
+
MAP_RESET = ("dpMapReset", 13)
|
|
10
|
+
REQUEST = ("dpRequest", 16)
|
|
11
|
+
RESET_SIDE_BRUSH = ("dpResetSideBrush", 18)
|
|
12
|
+
RESET_MAIN_BRUSH = ("dpResetMainBrush", 20)
|
|
13
|
+
RESET_FILTER = ("dpResetFilter", 22)
|
|
14
|
+
RAG_LIFE = ("dpRagLife", 23)
|
|
15
|
+
RESET_RAG_LIFE = ("dpResetRagLife", 24)
|
|
16
|
+
NOT_DISTURB = ("dpNotDisturb", 25)
|
|
17
|
+
VOLUME = ("dpVolume", 26)
|
|
18
|
+
BEAK_CLEAN = ("dpBeakClean", 27)
|
|
19
|
+
TOTAL_CLEAN_AREA = ("dpTotalCleanArea", 29)
|
|
20
|
+
TOTAL_CLEAN_COUNT = ("dpTotalCleanCount", 30)
|
|
21
|
+
TOTAL_CLEAN_TIME = ("dpTotalCleanTime", 31)
|
|
22
|
+
TIMER = ("dpTimer", 32)
|
|
23
|
+
NOT_DISTURB_DATA = ("dpNotDisturbData", 33)
|
|
24
|
+
DEVICE_INFO = ("dpDeviceInfo", 34)
|
|
25
|
+
VOICE_PACKAGE = ("dpVoicePackage", 35)
|
|
26
|
+
VOICE_LANGUAGE = ("dpVoiceLanguage", 36)
|
|
27
|
+
DUST_SWITCH = ("dpDustSwitch", 37)
|
|
28
|
+
CUSTOM_MODE = ("dpCustomMode", 39)
|
|
29
|
+
MOP_STATE = ("dpMopState", 40)
|
|
30
|
+
UNIT = ("dpUnit", 42)
|
|
31
|
+
CARPET_CLEAN_PREFER = ("dpCarpetCleanPrefer", 44)
|
|
32
|
+
AUTO_BOOST = ("dpAutoBoost", 45)
|
|
33
|
+
CHILD_LOCK = ("dpChildLock", 47)
|
|
34
|
+
DUST_SETTING = ("dpDustSetting", 50)
|
|
35
|
+
MAP_SAVE_SWITCH = ("dpMapSaveSwitch", 51)
|
|
36
|
+
CLEAN_RECORD = ("dpCleanRecord", 52)
|
|
37
|
+
RECEND_CLEAN_RECORD = ("dpRecendCleanRecord", 53)
|
|
38
|
+
RESTRICTED_ZONE = ("dpRestrictedZone", 54)
|
|
39
|
+
RESTRICTED_ZONE_UP = ("dpRestrictedZoneUp", 55)
|
|
40
|
+
VIRTUAL_WALL = ("dpVirtualWall", 56)
|
|
41
|
+
VIRTUAL_WALL_UP = ("dpVirtualWallUp", 57)
|
|
42
|
+
ZONED = ("dpZoned", 58)
|
|
43
|
+
ZONED_UP = ("dpZonedUp", 59)
|
|
44
|
+
MULTI_MAP_SWITCH = ("dpMultiMapSwitch", 60)
|
|
45
|
+
MULTI_MAP = ("dpMultiMap", 61)
|
|
46
|
+
CUSTOMER_CLEAN = ("dpCustomerClean", 62)
|
|
47
|
+
CUSTOMER_CLEAN_REQUEST = ("dpCustomerCleanRequest", 63)
|
|
48
|
+
GET_CARPET = ("dpGetCarpet", 64)
|
|
49
|
+
CARPET_UP = ("dpCarpetUp", 65)
|
|
50
|
+
SELF_IDENTIFYING_CARPET = ("dpSelfIdentifyingCarpet", 66)
|
|
51
|
+
SENSOR_LIFE = ("dpSensorLife", 67)
|
|
52
|
+
RESET_SENSOR = ("dpResetSensor", 68)
|
|
53
|
+
REQUEST_TIMER = ("dpRequestTimer", 69)
|
|
54
|
+
REMOVE_ZONED = ("dpRemoveZoned", 70)
|
|
55
|
+
REMOVE_ZONED_UP = ("dpRemoveZonedUp", 71)
|
|
56
|
+
ROOM_MERGE = ("dpRoomMerge", 72)
|
|
57
|
+
ROOM_SPLIT = ("dpRoomSplit", 73)
|
|
58
|
+
RESET_ROOM_NAME = ("dpResetRoomName", 74)
|
|
59
|
+
REQUSET_NOT_DISTURB_DATA = ("dpRequsetNotDisturbData", 75)
|
|
60
|
+
CARPET_CLEAN_TYPE = ("dpCarpetCleanType", 76)
|
|
61
|
+
BUTTON_LIGHT_SWITCH = ("dpButtonLightSwitch", 77)
|
|
62
|
+
CLEAN_LINE = ("dpCleanLine", 78)
|
|
63
|
+
TIME_ZONE = ("dpTimeZone", 79)
|
|
64
|
+
AREA_UNIT = ("dpAreaUnit", 80)
|
|
65
|
+
NET_INFO = ("dpNetInfo", 81)
|
|
66
|
+
CLEAN_ORDER = ("dpCleanOrder", 82)
|
|
67
|
+
ROBOT_TYPE = ("dpRobotType", 83)
|
|
68
|
+
LOG_SWITCH = ("dpLogSwitch", 84)
|
|
69
|
+
FLOOR_MATERIAL = ("dpFloorMaterial", 85)
|
|
70
|
+
LINE_LASER_OBSTACLE_AVOIDANCE = ("dpLineLaserObstacleAvoidance", 86)
|
|
71
|
+
CLEAN_PROGESS = ("dpCleanProgess", 87)
|
|
72
|
+
GROUND_CLEAN = ("dpGroundClean", 88)
|
|
73
|
+
IGNORE_OBSTACLE = ("dpIgnoreObstacle", 89)
|
|
74
|
+
FAULT = ("dpFault", 90)
|
|
75
|
+
CLEAN_EXPAND = ("dpCleanExpand", 91)
|
|
76
|
+
NOT_DISTURB_EXPAND = ("dpNotDisturbExpand", 92)
|
|
77
|
+
TIMER_TYPE = ("dpTimerType", 93)
|
|
78
|
+
CREATE_MAP_FINISHED = ("dpCreateMapFinished", 94)
|
|
79
|
+
ADD_CLEAN_AREA = ("dpAddCleanArea", 95)
|
|
80
|
+
ADD_CLEAN_STATE = ("dpAddCleanState", 96)
|
|
81
|
+
RESTRICTED_AREA = ("dpRestrictedArea", 97)
|
|
82
|
+
RESTRICTED_AREA_UP = ("dpRestrictedAreaUp", 98)
|
|
83
|
+
SUSPECTED_THRESHOLD = ("dpSuspectedThreshold", 99)
|
|
84
|
+
SUSPECTED_THRESHOLD_UP = ("dpSuspectedThresholdUp", 100)
|
|
85
|
+
COMMON = ("dpCommon", 101)
|
|
86
|
+
JUMP_SCAN = ("dpJumpScan", 101)
|
|
87
|
+
REQUETDPS = ("dpRequetdps", 102) # NOTE: THIS TYPO IS FOUND IN SOURCE CODE
|
|
88
|
+
CLIFF_RESTRICTED_AREA = ("dpCliffRestrictedArea", 102)
|
|
89
|
+
CLIFF_RESTRICTED_AREA_UP = ("dpCliffRestrictedAreaUp", 103)
|
|
90
|
+
BREAKPOINT_CLEAN = ("dpBreakpointClean", 104)
|
|
91
|
+
VALLEY_POINT_CHARGING = ("dpValleyPointCharging", 105)
|
|
92
|
+
VALLEY_POINT_CHARGING_DATA_UP = ("dpValleyPointChargingDataUp", 106)
|
|
93
|
+
VALLEY_POINT_CHARGING_DATA = ("dpValleyPointChargingData", 107)
|
|
94
|
+
VOICE_VERSION = ("dpVoiceVersion", 108)
|
|
95
|
+
ROBOT_COUNTRY_CODE = ("dpRobotCountryCode", 109)
|
|
96
|
+
HEARTBEAT = ("dpHeartbeat", 110)
|
|
97
|
+
STATUS = ("dpStatus", 121)
|
|
98
|
+
BATTERY = ("dpBattery", 122)
|
|
99
|
+
FUN_LEVEL = ("dpfunLevel", 123)
|
|
100
|
+
WATER_LEVEL = ("dpWaterLevel", 124)
|
|
101
|
+
MAIN_BRUSH_LIFE = ("dpMainBrushLife", 125)
|
|
102
|
+
SIDE_BRUSH_LIFE = ("dpSideBrushLife", 126)
|
|
103
|
+
FILTER_LIFE = ("dpFilterLife", 127)
|
|
104
|
+
TASK_CANCEL_IN_MOTION = ("dpTaskCancelInMotion", 132)
|
|
105
|
+
OFFLINE = ("dpOffline", 135)
|
|
106
|
+
CLEAN_COUNT = ("dpCleanCount", 136)
|
|
107
|
+
CLEAN_MODE = ("dpCleanMode", 137)
|
|
108
|
+
CLEAN_TASK_TYPE = ("dpCleanTaskType", 138)
|
|
109
|
+
BACK_TYPE = ("dpBackType", 139)
|
|
110
|
+
CLEANING_PROGRESS = ("dpCleaningProgress", 141)
|
|
111
|
+
FLEEING_GOODS = ("dpFleeingGoods", 142)
|
|
112
|
+
START_CLEAN = ("dpStartClean", 201)
|
|
113
|
+
START_BACK = ("dpStartBack", 202)
|
|
114
|
+
START_DOCK_TASK = ("dpStartDockTask", 203)
|
|
115
|
+
PAUSE = ("dpPause", 204)
|
|
116
|
+
RESUME = ("dpResume", 205)
|
|
117
|
+
STOP = ("dpStop", 206)
|
|
118
|
+
USER_PLAN = ("dpUserPlan", 207)
|
|
119
|
+
|
|
120
|
+
|
|
121
|
+
class YXFanLevel(RoborockModeEnum):
|
|
122
|
+
UNKNOWN = "unknown", -1
|
|
123
|
+
CLOSE = "close", 0
|
|
124
|
+
QUITE = "quite", 1
|
|
125
|
+
NORMAL = "normal", 2
|
|
126
|
+
STRONG = "strong", 3
|
|
127
|
+
MAX = "max", 4
|
|
128
|
+
SUPER = "super", 5
|
|
129
|
+
|
|
130
|
+
|
|
131
|
+
class YXWaterLevel(RoborockModeEnum):
|
|
132
|
+
UNKNOWN = "unknown", -1
|
|
133
|
+
CLOSE = "close", 0
|
|
134
|
+
LOW = "low", 1
|
|
135
|
+
MIDDLE = "middle", 2
|
|
136
|
+
HIGH = "high", 3
|
|
137
|
+
|
|
138
|
+
|
|
139
|
+
class YXCleanLine(RoborockModeEnum):
|
|
140
|
+
FAST = "fast", 0
|
|
141
|
+
DAILY = "daily", 1
|
|
142
|
+
FINE = "fine", 2
|
|
143
|
+
|
|
144
|
+
|
|
145
|
+
class YXRoomMaterial(RoborockModeEnum):
|
|
146
|
+
HORIZONTAL_FLOOR_BOARD = "horizontalfloorboard", 0
|
|
147
|
+
VERTICAL_FLOOR_BOARD = "verticalfloorboard", 1
|
|
148
|
+
CERAMIC_TILE = "ceramictile", 2
|
|
149
|
+
OTHER = "other", 255
|
|
150
|
+
|
|
151
|
+
|
|
152
|
+
class YXCleanType(RoborockModeEnum):
|
|
153
|
+
UNKNOWN = "unknown", -1
|
|
154
|
+
BOTH_WORK = "bothwork", 1
|
|
155
|
+
ONLY_SWEEP = "onlysweep", 2
|
|
156
|
+
ONLY_MOP = "onlymop", 3
|
|
157
|
+
|
|
158
|
+
|
|
159
|
+
class YXDeviceState(RoborockModeEnum):
|
|
160
|
+
UNKNOWN = "unknown", -1
|
|
161
|
+
SLEEP_STATE = "sleepstate", 2
|
|
162
|
+
STANDBY_STATE = "standbystate", 3
|
|
163
|
+
CLEANING_STATE = "cleaningstate", 5
|
|
164
|
+
TO_CHARGE_STATE = "tochargestate", 6
|
|
165
|
+
REMOTEING_STATE = "remoteingstate", 7
|
|
166
|
+
CHARGING_STATE = "chargingstate", 8
|
|
167
|
+
PAUSE_STATE = "pausestate", 10
|
|
168
|
+
FAULT_STATE = "faultstate", 12
|
|
169
|
+
UPGRADE_STATE = "upgradestate", 14
|
|
170
|
+
DUSTING = "dusting", 22
|
|
171
|
+
CREATING_MAP_STATE = "creatingmapstate", 29
|
|
172
|
+
MAP_SAVE_STATE = "mapsavestate", 99
|
|
173
|
+
RE_LOCATION_STATE = "relocationstate", 101
|
|
174
|
+
ROBOT_SWEEPING = "robotsweeping", 102
|
|
175
|
+
ROBOT_MOPING = "robotmoping", 103
|
|
176
|
+
ROBOT_SWEEP_AND_MOPING = "robotsweepandmoping", 104
|
|
177
|
+
ROBOT_TRANSITIONING = "robottransitioning", 105
|
|
178
|
+
ROBOT_WAIT_CHARGE = "robotwaitcharge", 108
|
|
179
|
+
|
|
180
|
+
|
|
181
|
+
class YXBackType(RoborockModeEnum):
|
|
182
|
+
UNKNOWN = "unknown", -1
|
|
183
|
+
IDLE = "idle", 0
|
|
184
|
+
BACK_DUSTING = "backdusting", 4
|
|
185
|
+
BACK_CHARGING = "backcharging", 5
|
|
186
|
+
|
|
187
|
+
|
|
188
|
+
class YXDeviceWorkMode(RoborockModeEnum):
|
|
189
|
+
UNKNOWN = "unknown", -1
|
|
190
|
+
BOTH_WORK = "bothwork", 1
|
|
191
|
+
ONLY_SWEEP = "onlysweep", 2
|
|
192
|
+
ONLY_MOP = "onlymop", 3
|
|
193
|
+
CUSTOMIZED = "customized", 4
|
|
194
|
+
SAVE_WORRY = "saveworry", 5
|
|
195
|
+
SWEEP_MOP = "sweepmop", 6
|
|
196
|
+
|
|
197
|
+
|
|
198
|
+
class YXDeviceCleanTask(RoborockModeEnum):
|
|
199
|
+
UNKNOWN = "unknown", -1
|
|
200
|
+
IDLE = "idle", 0
|
|
201
|
+
SMART = "smart", 1
|
|
202
|
+
ELECTORAL = "electoral", 2
|
|
203
|
+
DIVIDE_AREAS = "divideareas", 3
|
|
204
|
+
CREATING_MAP = "creatingmap", 4
|
|
205
|
+
PART = "part", 5
|
|
206
|
+
|
|
207
|
+
|
|
208
|
+
class YXDeviceDustCollectionFrequency(RoborockModeEnum):
|
|
209
|
+
DAILY = "daily", 0
|
|
210
|
+
INTERVAL_15 = "interval_15", 15
|
|
211
|
+
INTERVAL_30 = "interval_30", 30
|
|
212
|
+
INTERVAL_45 = "interval_45", 45
|
|
213
|
+
INTERVAL_60 = "interval_60", 60
|
|
@@ -0,0 +1,53 @@
|
|
|
1
|
+
from ..containers import RoborockBase
|
|
2
|
+
|
|
3
|
+
|
|
4
|
+
class dpCleanRecord(RoborockBase):
|
|
5
|
+
op: str
|
|
6
|
+
result: int
|
|
7
|
+
id: str
|
|
8
|
+
data: list
|
|
9
|
+
|
|
10
|
+
|
|
11
|
+
class dpMultiMap(RoborockBase):
|
|
12
|
+
op: str
|
|
13
|
+
result: int
|
|
14
|
+
data: list
|
|
15
|
+
|
|
16
|
+
|
|
17
|
+
class dpGetCarpet(RoborockBase):
|
|
18
|
+
op: str
|
|
19
|
+
result: int
|
|
20
|
+
data: str
|
|
21
|
+
|
|
22
|
+
|
|
23
|
+
class dpSelfIdentifyingCarpet(RoborockBase):
|
|
24
|
+
op: str
|
|
25
|
+
result: int
|
|
26
|
+
data: str
|
|
27
|
+
|
|
28
|
+
|
|
29
|
+
class dpNetInfo(RoborockBase):
|
|
30
|
+
wifiName: str
|
|
31
|
+
ipAdress: str
|
|
32
|
+
mac: str
|
|
33
|
+
signal: int
|
|
34
|
+
|
|
35
|
+
|
|
36
|
+
class dpNotDisturbExpand(RoborockBase):
|
|
37
|
+
disturb_dust_enable: int
|
|
38
|
+
disturb_light: int
|
|
39
|
+
disturb_resume_clean: int
|
|
40
|
+
disturb_voice: int
|
|
41
|
+
|
|
42
|
+
|
|
43
|
+
class dpCurrentCleanRoomIds(RoborockBase):
|
|
44
|
+
room_id_list: list
|
|
45
|
+
|
|
46
|
+
|
|
47
|
+
class dpVoiceVersion(RoborockBase):
|
|
48
|
+
version: int
|
|
49
|
+
|
|
50
|
+
|
|
51
|
+
class dpTimeZone(RoborockBase):
|
|
52
|
+
timeZoneCity: str
|
|
53
|
+
timeZoneSec: int
|
|
@@ -1,7 +1,4 @@
|
|
|
1
|
-
from
|
|
2
|
-
|
|
3
|
-
from .code_mappings import RoborockModeEnum
|
|
4
|
-
from .containers import RoborockBase
|
|
1
|
+
from ..code_mappings import RoborockModeEnum
|
|
5
2
|
|
|
6
3
|
|
|
7
4
|
class WorkStatusMapping(RoborockModeEnum):
|
|
@@ -125,64 +122,6 @@ class CarpetModeMapping(RoborockModeEnum):
|
|
|
125
122
|
OFF = ("off", 2)
|
|
126
123
|
|
|
127
124
|
|
|
128
|
-
@dataclass
|
|
129
|
-
class NetStatus(RoborockBase):
|
|
130
|
-
"""Represents the network status of the device."""
|
|
131
|
-
|
|
132
|
-
rssi: str
|
|
133
|
-
loss: int
|
|
134
|
-
ping: int
|
|
135
|
-
ip: str
|
|
136
|
-
mac: str
|
|
137
|
-
ssid: str
|
|
138
|
-
frequency: int
|
|
139
|
-
bssid: str
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
@dataclass
|
|
143
|
-
class OrderTotal(RoborockBase):
|
|
144
|
-
"""Represents the order total information."""
|
|
145
|
-
|
|
146
|
-
total: int
|
|
147
|
-
enable: int
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
@dataclass
|
|
151
|
-
class Privacy(RoborockBase):
|
|
152
|
-
"""Represents the privacy settings of the device."""
|
|
153
|
-
|
|
154
|
-
ai_recognize: int
|
|
155
|
-
dirt_recognize: int
|
|
156
|
-
pet_recognize: int
|
|
157
|
-
carpet_turbo: int
|
|
158
|
-
carpet_avoid: int
|
|
159
|
-
carpet_show: int
|
|
160
|
-
map_uploads: int
|
|
161
|
-
ai_agent: int
|
|
162
|
-
ai_avoidance: int
|
|
163
|
-
record_uploads: int
|
|
164
|
-
along_floor: int
|
|
165
|
-
auto_upgrade: int
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
@dataclass
|
|
169
|
-
class PvCharging(RoborockBase):
|
|
170
|
-
"""Represents the photovoltaic charging status."""
|
|
171
|
-
|
|
172
|
-
status: int
|
|
173
|
-
begin_time: int
|
|
174
|
-
end_time: int
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
@dataclass
|
|
178
|
-
class Recommend(RoborockBase):
|
|
179
|
-
"""Represents cleaning recommendations."""
|
|
180
|
-
|
|
181
|
-
sill: int
|
|
182
|
-
wall: int
|
|
183
|
-
room_id: list[int] = field(default_factory=list)
|
|
184
|
-
|
|
185
|
-
|
|
186
125
|
class B01Fault(RoborockModeEnum):
|
|
187
126
|
"""B01 fault codes and their descriptions."""
|
|
188
127
|
|
|
@@ -347,71 +286,3 @@ class B01Fault(RoborockModeEnum):
|
|
|
347
286
|
F_2113 = ("fault_2113", 2113)
|
|
348
287
|
F_2114 = ("fault_2114", 2114)
|
|
349
288
|
F_2115 = ("fault_2115", 2115)
|
|
350
|
-
|
|
351
|
-
|
|
352
|
-
@dataclass
|
|
353
|
-
class B01Props(RoborockBase):
|
|
354
|
-
"""
|
|
355
|
-
Represents the complete properties and status for a Roborock B01 model.
|
|
356
|
-
This dataclass is generated based on the device's status JSON object.
|
|
357
|
-
"""
|
|
358
|
-
|
|
359
|
-
status: WorkStatusMapping
|
|
360
|
-
fault: B01Fault
|
|
361
|
-
wind: SCWindMapping
|
|
362
|
-
water: int
|
|
363
|
-
mode: int
|
|
364
|
-
quantity: int
|
|
365
|
-
alarm: int
|
|
366
|
-
volume: int
|
|
367
|
-
hypa: int
|
|
368
|
-
main_brush: int
|
|
369
|
-
side_brush: int
|
|
370
|
-
mop_life: int
|
|
371
|
-
main_sensor: int
|
|
372
|
-
net_status: NetStatus
|
|
373
|
-
repeat_state: int
|
|
374
|
-
tank_state: int
|
|
375
|
-
sweep_type: int
|
|
376
|
-
clean_path_preference: int
|
|
377
|
-
cloth_state: int
|
|
378
|
-
time_zone: int
|
|
379
|
-
time_zone_info: str
|
|
380
|
-
language: int
|
|
381
|
-
cleaning_time: int
|
|
382
|
-
real_clean_time: int
|
|
383
|
-
cleaning_area: int
|
|
384
|
-
custom_type: int
|
|
385
|
-
sound: int
|
|
386
|
-
work_mode: WorkModeMapping
|
|
387
|
-
station_act: int
|
|
388
|
-
charge_state: int
|
|
389
|
-
current_map_id: int
|
|
390
|
-
map_num: int
|
|
391
|
-
dust_action: int
|
|
392
|
-
quiet_is_open: int
|
|
393
|
-
quiet_begin_time: int
|
|
394
|
-
quiet_end_time: int
|
|
395
|
-
clean_finish: int
|
|
396
|
-
voice_type: int
|
|
397
|
-
voice_type_version: int
|
|
398
|
-
order_total: OrderTotal
|
|
399
|
-
build_map: int
|
|
400
|
-
privacy: Privacy
|
|
401
|
-
dust_auto_state: int
|
|
402
|
-
dust_frequency: int
|
|
403
|
-
child_lock: int
|
|
404
|
-
multi_floor: int
|
|
405
|
-
map_save: int
|
|
406
|
-
light_mode: int
|
|
407
|
-
green_laser: int
|
|
408
|
-
dust_bag_used: int
|
|
409
|
-
order_save_mode: int
|
|
410
|
-
manufacturer: str
|
|
411
|
-
back_to_wash: int
|
|
412
|
-
charge_station_type: int
|
|
413
|
-
pv_cut_charge: int
|
|
414
|
-
pv_charging: PvCharging
|
|
415
|
-
serial_number: str
|
|
416
|
-
recommend: Recommend
|
|
417
|
-
add_sweep_status: int
|