pymammotion 0.2.33__py3-none-any.whl → 0.2.35__py3-none-any.whl
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.
- pymammotion/aliyun/dataclass/session_by_authcode_response.py +3 -3
- pymammotion/data/model/device_config.py +2 -2
- pymammotion/data/model/hash_list.py +2 -1
- pymammotion/data/mqtt/event.py +2 -5
- pymammotion/data/state_manager.py +2 -3
- pymammotion/event/event.py +1 -1
- pymammotion/mammotion/devices/base.py +3 -5
- pymammotion/mammotion/devices/mammotion.py +0 -1
- pymammotion/mammotion/devices/mammotion_cloud.py +0 -1
- {pymammotion-0.2.33.dist-info → pymammotion-0.2.35.dist-info}/METADATA +1 -1
- {pymammotion-0.2.33.dist-info → pymammotion-0.2.35.dist-info}/RECORD +13 -13
- {pymammotion-0.2.33.dist-info → pymammotion-0.2.35.dist-info}/LICENSE +0 -0
- {pymammotion-0.2.33.dist-info → pymammotion-0.2.35.dist-info}/WHEEL +0 -0
@@ -1,5 +1,5 @@
|
|
1
|
-
from dataclasses import dataclass
|
2
|
-
from
|
1
|
+
from dataclasses import dataclass
|
2
|
+
from typing import Optional
|
3
3
|
|
4
4
|
from mashumaro.mixins.orjson import DataClassORJSONMixin
|
5
5
|
|
@@ -16,4 +16,4 @@ class SessionOauthToken(DataClassORJSONMixin):
|
|
16
16
|
@dataclass
|
17
17
|
class SessionByAuthCodeResponse(DataClassORJSONMixin):
|
18
18
|
code: int
|
19
|
-
data: SessionOauthToken
|
19
|
+
data: Optional[SessionOauthToken]
|
@@ -43,7 +43,7 @@ def create_path_order(operation_mode: OperationSettings, device_name: str) -> st
|
|
43
43
|
bArr = bytearray(8)
|
44
44
|
bArr[0] = operation_mode.border_mode
|
45
45
|
bArr[1] = operation_mode.obstacle_laps
|
46
|
-
bArr[3] = operation_mode.start_progress
|
46
|
+
bArr[3] = int(operation_mode.start_progress)
|
47
47
|
bArr[2] = 0
|
48
48
|
|
49
49
|
if not DeviceType.is_luba1(device_name):
|
@@ -54,7 +54,7 @@ def create_path_order(operation_mode: OperationSettings, device_name: str) -> st
|
|
54
54
|
i = 0
|
55
55
|
bArr[5] = i
|
56
56
|
if operation_mode.is_dump:
|
57
|
-
b = operation_mode.collect_grass_frequency
|
57
|
+
b = int(operation_mode.collect_grass_frequency)
|
58
58
|
else:
|
59
59
|
b = 10
|
60
60
|
bArr[6] = b
|
@@ -1,7 +1,7 @@
|
|
1
1
|
from dataclasses import dataclass, field
|
2
2
|
from enum import IntEnum
|
3
3
|
|
4
|
-
from pymammotion.proto.mctrl_nav import
|
4
|
+
from pymammotion.proto.mctrl_nav import AreaHashName, NavGetCommDataAck
|
5
5
|
|
6
6
|
|
7
7
|
class PathType(IntEnum):
|
@@ -24,6 +24,7 @@ class HashList:
|
|
24
24
|
[hashID, FrameList].
|
25
25
|
hashlist for all our hashIDs for verification
|
26
26
|
"""
|
27
|
+
|
27
28
|
area: dict # type 0
|
28
29
|
path: dict # type 2
|
29
30
|
obstacle: dict # type 1
|
pymammotion/data/mqtt/event.py
CHANGED
@@ -1,7 +1,6 @@
|
|
1
|
-
import base64
|
2
1
|
from base64 import b64decode
|
3
2
|
from dataclasses import dataclass
|
4
|
-
from typing import Any, Literal, Optional, Union
|
3
|
+
from typing import Any, Literal, Optional, Union
|
5
4
|
|
6
5
|
from google.protobuf import json_format
|
7
6
|
from mashumaro.mixins.orjson import DataClassORJSONMixin
|
@@ -40,8 +39,6 @@ class DeviceProtobufMsgEventValue(DataClassORJSONMixin):
|
|
40
39
|
content: str
|
41
40
|
|
42
41
|
|
43
|
-
|
44
|
-
|
45
42
|
@dataclass
|
46
43
|
class DeviceWarningEventValue(DataClassORJSONMixin):
|
47
44
|
# TODO: enum for error codes
|
@@ -64,7 +61,7 @@ class DeviceNotificationEventCode(DataClassORJSONMixin):
|
|
64
61
|
|
65
62
|
@dataclass
|
66
63
|
class DeviceNotificationEventValue(DataClassORJSONMixin):
|
67
|
-
data: str
|
64
|
+
data: str # parsed to DeviceNotificationEventCode
|
68
65
|
|
69
66
|
|
70
67
|
@dataclass
|
@@ -1,12 +1,12 @@
|
|
1
1
|
"""Manage state from notifications into MowingDevice."""
|
2
2
|
|
3
|
-
from typing import
|
3
|
+
from typing import Awaitable, Callable, Optional
|
4
4
|
|
5
5
|
import betterproto
|
6
6
|
|
7
7
|
from pymammotion.data.model.device import MowingDevice
|
8
8
|
from pymammotion.proto.luba_msg import LubaMsg
|
9
|
-
from pymammotion.proto.mctrl_nav import NavGetCommDataAck, NavGetHashListAck
|
9
|
+
from pymammotion.proto.mctrl_nav import AppGetAllAreaHashName, NavGetCommDataAck, NavGetHashListAck
|
10
10
|
|
11
11
|
|
12
12
|
class StateManager:
|
@@ -66,7 +66,6 @@ class StateManager:
|
|
66
66
|
hash_names: AppGetAllAreaHashName = nav_msg[1]
|
67
67
|
self._device.map.area_name = hash_names.hashnames
|
68
68
|
|
69
|
-
|
70
69
|
def _update_sys_data(self, message) -> None:
|
71
70
|
"""Update system."""
|
72
71
|
sys_msg = betterproto.which_one_of(message.sys, "SubSysMsg")
|
pymammotion/event/event.py
CHANGED
@@ -206,8 +206,9 @@ class MammotionBaseDevice:
|
|
206
206
|
await self.queue_command("get_area_name_list", device_id=self._cloud_device.deviceName)
|
207
207
|
if has_field(self._mower.net.toapp_wifi_iot_status):
|
208
208
|
if not DeviceType.is_luba1(self._mower.net.toapp_wifi_iot_status.devicename):
|
209
|
-
await self.queue_command(
|
210
|
-
|
209
|
+
await self.queue_command(
|
210
|
+
"get_area_name_list", device_id=self._mower.net.toapp_wifi_iot_status.devicename
|
211
|
+
)
|
211
212
|
except Exception:
|
212
213
|
"""Do nothing for now."""
|
213
214
|
|
@@ -220,9 +221,6 @@ class MammotionBaseDevice:
|
|
220
221
|
for data_hash in self.mower.nav.toapp_gethash_ack.data_couple:
|
221
222
|
await self.queue_command("synchronize_hash_data", hash_num=data_hash)
|
222
223
|
|
223
|
-
|
224
|
-
|
225
|
-
|
226
224
|
# sub_cmd 3 is job hashes??
|
227
225
|
# sub_cmd 4 is dump location (yuka)
|
228
226
|
# jobs list
|
@@ -186,7 +186,6 @@ class MammotionBaseCloudDevice(MammotionBaseDevice):
|
|
186
186
|
160, lambda: asyncio.ensure_future(self.run_periodic_sync_task())
|
187
187
|
)
|
188
188
|
|
189
|
-
|
190
189
|
async def queue_command(self, key: str, **kwargs: Any) -> bytes:
|
191
190
|
# Create a future to hold the result
|
192
191
|
_LOGGER.debug("Queueing command: %s", key)
|
@@ -7,7 +7,7 @@ pymammotion/aliyun/dataclass/connect_response.py,sha256=Yz-fEbDzgGPTo5Of2oAjmFkS
|
|
7
7
|
pymammotion/aliyun/dataclass/dev_by_account_response.py,sha256=gskum11h9HPf4lKjLJKVrsxRl5BHaHJP2TPrI09SUYs,1032
|
8
8
|
pymammotion/aliyun/dataclass/login_by_oauth_response.py,sha256=IXSLZ6XnOliOnyXo5Bh0ErqFjA11puACh_9NH0sSJGQ,1262
|
9
9
|
pymammotion/aliyun/dataclass/regions_response.py,sha256=CVPpdFhDD6_emWHyLRzOdp2j3HLPtP8tlNyzGnr8AcI,690
|
10
|
-
pymammotion/aliyun/dataclass/session_by_authcode_response.py,sha256=
|
10
|
+
pymammotion/aliyun/dataclass/session_by_authcode_response.py,sha256=FVqT2EmePt4ze83sndkw45GHtMsx12nsMU7Nljd35RM,412
|
11
11
|
pymammotion/aliyun/tmp_constant.py,sha256=M4Hq_lrGB3LZdX6R2XohRPFoK1NDnNV-pTJwJcJ9838,6650
|
12
12
|
pymammotion/bluetooth/__init__.py,sha256=LAl8jqZ1fPh-3mLmViNQsP3s814C1vsocYUa6oSaXt0,36
|
13
13
|
pymammotion/bluetooth/ble.py,sha256=YfkfEK3TLJ8BaidjAXfUVFv8reLCu6U_lYa3Bo0pddw,2449
|
@@ -22,12 +22,12 @@ pymammotion/data/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,
|
|
22
22
|
pymammotion/data/model/__init__.py,sha256=aSyroxYQQS-WMRi6WmWm2js4wLa9nmsi160gx9tts4o,323
|
23
23
|
pymammotion/data/model/account.py,sha256=vJM-KTf2q6eBfVC-UlNHBSmJvqHiCawZ40vnuhXhaz8,140
|
24
24
|
pymammotion/data/model/device.py,sha256=ejIMloTHlJcBi-qNFewTDt1K0pPJYpgjtJqqqhUqR1g,11182
|
25
|
-
pymammotion/data/model/device_config.py,sha256=
|
25
|
+
pymammotion/data/model/device_config.py,sha256=Ez55DiYV7QTxgSk6R6XjUSZ7XdTGf8w38VaFsAOBNv8,2637
|
26
26
|
pymammotion/data/model/enums.py,sha256=EpKmO8yVUZyEnTY4yH0DMMVKYNQM42zpW1maUu0i3IE,1582
|
27
27
|
pymammotion/data/model/excute_boarder_params.py,sha256=9CpUqrygcle1C_1hDW-riLmm4map4ZbE842NXjcomEI,1394
|
28
28
|
pymammotion/data/model/execute_boarder.py,sha256=9rd_h4fbcsXxgnLOd2rO2hWyD1abnTGc47QTEpp8DD0,1103
|
29
29
|
pymammotion/data/model/generate_route_information.py,sha256=MkUBoqGtCAKmiVQ4Q1pEoDVHZs5uLIo7vhfWT4nGbtY,801
|
30
|
-
pymammotion/data/model/hash_list.py,sha256=
|
30
|
+
pymammotion/data/model/hash_list.py,sha256=fszjpbt0e7DNqibQnPaYCTiuK39gwtNVjBF0hUyMeeE,3025
|
31
31
|
pymammotion/data/model/location.py,sha256=H1h4Rhr0z_mDplNf1CP_ZCA3zM4_FJ_nMqzkbaoh7To,787
|
32
32
|
pymammotion/data/model/mowing_modes.py,sha256=5TrHSijUyPtIDWpNtgzx_vFQukRJWRz4gIrUaXggKPw,827
|
33
33
|
pymammotion/data/model/plan.py,sha256=mcadkSL7fQXy0iJ0q786I3GEQY4i6kmQXfW6Ri69lcQ,2906
|
@@ -35,12 +35,12 @@ pymammotion/data/model/rapid_state.py,sha256=BdJFD_DlhrVneg-PqEruqCoMty-CR7q_9Qn
|
|
35
35
|
pymammotion/data/model/region_data.py,sha256=FLuL6kA7lbbh_idRh1eT9EosDqh4SpAqzpqHuQRDM88,2888
|
36
36
|
pymammotion/data/model/report_info.py,sha256=gBSOmylSUdsYyIDsRms0L0nhQBx4V4LO-4tERvFpqXU,4475
|
37
37
|
pymammotion/data/mqtt/__init__.py,sha256=AbpHGcgLb-kRsJGnwFEktk7uzpZOCcBY74-YBdrKVGs,1
|
38
|
-
pymammotion/data/mqtt/event.py,sha256=
|
38
|
+
pymammotion/data/mqtt/event.py,sha256=GKh4NdcaeeaG5pPktzy-eguFKK74Mfxpl0eIAkKU1Vc,4567
|
39
39
|
pymammotion/data/mqtt/properties.py,sha256=HkBPghr26L9_b4QaOi1DtPgb0UoPIOGSe9wb3kgnM6Y,2815
|
40
40
|
pymammotion/data/mqtt/status.py,sha256=zqnlo-MzejEQZszl0i0Wucoc3E76x6UtI9JLxoBnu54,1067
|
41
|
-
pymammotion/data/state_manager.py,sha256=
|
41
|
+
pymammotion/data/state_manager.py,sha256=GpVQM78JTFNtjpym2ykFR-Ng7iMXRhfunyAbL-QpENs,3363
|
42
42
|
pymammotion/event/__init__.py,sha256=mgATR6vPHACNQ-0zH5fi7NdzeTCDV1CZyaWPmtUusi8,115
|
43
|
-
pymammotion/event/event.py,sha256=
|
43
|
+
pymammotion/event/event.py,sha256=UzYnxV5DfvMDK3E06UvSzvzuBbaXOOUwO6xYt_zn9To,2034
|
44
44
|
pymammotion/http/_init_.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
45
45
|
pymammotion/http/http.py,sha256=OZHjQY9ZLdlsKK6MDqqV79JIH9WYWJe3-ey-WWbe2z4,2642
|
46
46
|
pymammotion/http/model/http.py,sha256=_aVrtZZyR4EdR6GcuqMP9vH8qBLN7nKu0U2OeraCcG0,1607
|
@@ -59,10 +59,10 @@ pymammotion/mammotion/commands/messages/video.py,sha256=_8lJsU4sLm2CGnc7RDkueA0A
|
|
59
59
|
pymammotion/mammotion/control/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
60
60
|
pymammotion/mammotion/control/joystick.py,sha256=QfBVxM_gxpWsZAGO90whtgxCI2tIZ3TTad9wHIPsU9s,5640
|
61
61
|
pymammotion/mammotion/devices/__init__.py,sha256=f2qQFPgLGmV85W2hSlMUh5BYuht9o_Ar_JEAAMD4fsE,102
|
62
|
-
pymammotion/mammotion/devices/base.py,sha256=
|
63
|
-
pymammotion/mammotion/devices/mammotion.py,sha256=
|
62
|
+
pymammotion/mammotion/devices/base.py,sha256=zbPpGLP9-0dKZFDt2zgGWtuHwy1h2cXHlR8S2EnpTps,11348
|
63
|
+
pymammotion/mammotion/devices/mammotion.py,sha256=mPD8ECsW5AwJdvzuVQBp9QYXjo3YhUxgtP-N8ptthmU,9726
|
64
64
|
pymammotion/mammotion/devices/mammotion_bluetooth.py,sha256=3XUjhE2sb_2aZnJlevmwxd99zR_4qZOfaK86h6hKV5E,17303
|
65
|
-
pymammotion/mammotion/devices/mammotion_cloud.py,sha256=
|
65
|
+
pymammotion/mammotion/devices/mammotion_cloud.py,sha256=W0gTdTvqofsL4QxjsVPHcBFYXTlgnzpLwIOAgR2yJA0,9914
|
66
66
|
pymammotion/mqtt/__init__.py,sha256=Ocs5e-HLJvTuDpVXyECEsWIvwsUaxzj7lZ9mSYutNDY,105
|
67
67
|
pymammotion/mqtt/mammotion_future.py,sha256=_OWqKOlUGl2yT1xOsXFQYpGd-1zQ63OxqXgy7KRQgYc,710
|
68
68
|
pymammotion/mqtt/mammotion_mqtt.py,sha256=QZuqp2G5nywCFSwGNSayPI5JVL789yOxyr0UM0G7wzg,8295
|
@@ -117,7 +117,7 @@ pymammotion/utility/map.py,sha256=GYscVMg2cX3IPlNpCBNHDW0S55yS1WGRf1iHnNZ7TfQ,22
|
|
117
117
|
pymammotion/utility/movement.py,sha256=N75oAoAgFydqoaOedYIxGUHmuTCtPzAOtb-d_29tpfI,615
|
118
118
|
pymammotion/utility/periodic.py,sha256=MbeSb9cfhxzYmdT_RiE0dZe3H9IfbQW_zSqhmSX2RUc,3321
|
119
119
|
pymammotion/utility/rocker_util.py,sha256=6tX7sS87qoQC_tsxbx3NLL-HgS08wtzXiZkhDiz7uo0,7179
|
120
|
-
pymammotion-0.2.
|
121
|
-
pymammotion-0.2.
|
122
|
-
pymammotion-0.2.
|
123
|
-
pymammotion-0.2.
|
120
|
+
pymammotion-0.2.35.dist-info/LICENSE,sha256=OXLcl0T2SZ8Pmy2_dmlvKuetivmyPd5m1q-Gyd-zaYY,35149
|
121
|
+
pymammotion-0.2.35.dist-info/METADATA,sha256=_VXu85qe7SUTm01E2s-9VVwcoKOZc9cDOuiasv7lUuc,4052
|
122
|
+
pymammotion-0.2.35.dist-info/WHEEL,sha256=sP946D7jFCHeNz5Iq4fL4Lu-PrWrFsgfLXbbkciIZwg,88
|
123
|
+
pymammotion-0.2.35.dist-info/RECORD,,
|
File without changes
|
File without changes
|