diff --git a/docs/templates/tasshackDreameVacuum.md b/docs/templates/tasshackDreameVacuum.md index 3f896606..d1a709f7 100644 --- a/docs/templates/tasshackDreameVacuum.md +++ b/docs/templates/tasshackDreameVacuum.md @@ -209,3 +209,93 @@ This platform can be used to control vacuums connected to Home Assistant using D https://user-images.githubusercontent.com/6118709/141666923-965679e9-25fb-44cd-be08-fc63e5c85ce0.mp4 + + +* ### Going to a specified point (`vacuum_goto`) + + Uses a pair of coordinates for vacuum to get to a user-specified point. + + Used service: `dreame_vacuum.vacuum_goto` + +
+ Example configuration + + ```yaml + map_modes: + - template: vacuum_goto + ``` + +
+
+ Example video + + https://user-images.githubusercontent.com/6118709/141666921-2f3d66da-6ffc-492a-8439-625da97651bd.mp4 + +
+ +* ### Going to a predefined point (`vacuum_goto_predefined`) + + Uses a pair of coordinates for vacuum to go to a point that has been defined in the configuration. Requires `predefined_selections` to be provided. + + [Getting coordinates](/docs/templates/setup.md#getting-coordinates) + + Used service: `dreame_vacuum.vacuum_goto` + +
+ Example configuration + + ```yaml + map_modes: + - template: vacuum_goto_predefined + predefined_selections: + - position: [ 2800, 2036 ] + label: + text: "Emptying" + x: 2800 + y: 2803 + offset_y: 35 + icon: + name: "mdi:broom" + x: 2800 + y: 2803 + - position: [ 3214, 2628 ] + label: + text: "Sofa" + x: 3214 + y: 2628 + offset_y: 35 + icon: + name: "mdi:sofa" + x: 3214 + y: 2628 + ``` + +
+
+ Example video + + https://user-images.githubusercontent.com/6118709/141666923-965679e9-25fb-44cd-be08-fc63e5c85ce0.mp4 + +
+ +* ### Following a specified path (`vacuum_follow_path`) + + Uses a list of points to make a vacuum follow a user-defined path. + + Used service: `dreame_vacuum.vacuum_follow_path` + +
+ Example configuration + + ```yaml + map_modes: + - template: vacuum_follow_path + ``` + +
+
+ Example video + + https://user-images.githubusercontent.com/6118709/141666931-48d1717f-96d0-461d-84f4-788c071f3a78.mp4 + +
diff --git a/src/model/generators/platform_templates/Tasshack_dreame-vacuum.json b/src/model/generators/platform_templates/Tasshack_dreame-vacuum.json index 99fe9a62..feb156e1 100644 --- a/src/model/generators/platform_templates/Tasshack_dreame-vacuum.json +++ b/src/model/generators/platform_templates/Tasshack_dreame-vacuum.json @@ -2,7 +2,8 @@ "map_modes": { "default_templates": [ "vacuum_clean_zone", - "vacuum_clean_point" + "vacuum_clean_point", + "vacuum_goto" ], "templates": { "vacuum_clean_segment": { @@ -91,6 +92,59 @@ "entity_id": "[[entity_id]]" } } + }, + "vacuum_goto": { + "name": "map_mode.vacuum_goto", + "icon": "mdi:map-marker-radius", + "selection_type": "MANUAL_POINT", + "coordinates_rounding": true, + "coordinates_to_meters_divider": 1000, + "repeats_type": "NONE", + "max_repeats": 0, + "max_selections": 1, + "service_call_schema": { + "service": "dreame_vacuum.vacuum_goto", + "service_data": { + "x": "[[point_x]]", + "y": "[[point_y]]", + "entity_id": "[[entity_id]]" + } + } + }, + "vacuum_goto_predefined": { + "name": "map_mode.vacuum_goto_predefined", + "icon": "mdi:map-marker-multiple", + "selection_type": "PREDEFINED_POINT", + "coordinates_rounding": true, + "coordinates_to_meters_divider": 1000, + "repeats_type": "NONE", + "max_repeats": 0, + "max_selections": 1, + "service_call_schema": { + "service": "dreame_vacuum.vacuum_goto", + "service_data": { + "x": "[[point_x]]", + "y": "[[point_y]]", + "entity_id": "[[entity_id]]" + } + } + }, + "vacuum_follow_path": { + "name": "map_mode.vacuum_follow_path", + "icon": "mdi:map-marker-path", + "selection_type": "MANUAL_PATH", + "coordinates_rounding": true, + "coordinates_to_meters_divider": 1000, + "repeats_type": "NONE", + "max_repeats": 0, + "max_selections": 20, + "service_call_schema": { + "service": "dreame_vacuum.vacuum_follow_path", + "service_data": { + "points": "[[selection]]", + "entity_id": "[[entity_id]]" + } + } } } },