Skip to content

Commit 78ba503

Browse files
authored
Move SetAreaParameter to commands module
1 parent ac62266 commit 78ba503

1 file changed

Lines changed: 29 additions & 0 deletions

File tree

Lines changed: 29 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,29 @@
1+
"""Area parameter command module."""
2+
3+
from __future__ import annotations
4+
5+
from .common import ExecuteCommand
6+
7+
8+
class SetAreaParameter(ExecuteCommand):
9+
"""Set parameters for a mower area."""
10+
11+
NAME = "setAreaParameter"
12+
13+
def __init__(
14+
self,
15+
area_id: str | int,
16+
angle: int,
17+
mow_height_level: int,
18+
cut_mode: int = 7,
19+
obstacle_height: int = 1,
20+
) -> None:
21+
super().__init__(
22+
{
23+
"areaID": str(area_id),
24+
"mowHeightLevel": mow_height_level,
25+
"cutMode": cut_mode,
26+
"obstacleHeight": obstacle_height,
27+
"angle": angle,
28+
}
29+
)

0 commit comments

Comments
 (0)