move neato service to neato domain (#29148)
This commit is contained in:
parent
975ee0ea7f
commit
b8f03aa3be
4 changed files with 22 additions and 23 deletions
|
@ -11,6 +11,8 @@ NEATO_ROBOTS = "neato_robots"
|
|||
|
||||
SCAN_INTERVAL_MINUTES = 5
|
||||
|
||||
SERVICE_NEATO_CUSTOM_CLEANING = "custom_cleaning"
|
||||
|
||||
VALID_VENDORS = ["neato", "vorwerk"]
|
||||
|
||||
MODE = {1: "Eco", 2: "Turbo"}
|
||||
|
|
|
@ -0,0 +1,18 @@
|
|||
custom_cleaning:
|
||||
description: Zone Cleaning service call specific to Neato Botvacs.
|
||||
fields:
|
||||
entity_id:
|
||||
description: Name of the vacuum entity. [Required]
|
||||
example: 'vacuum.neato'
|
||||
mode:
|
||||
description: "Set the cleaning mode: 1 for eco and 2 for turbo. Defaults to turbo if not set."
|
||||
example: 2
|
||||
navigation:
|
||||
description: "Set the navigation mode: 1 for normal, 2 for extra care, 3 for deep. Defaults to normal if not set."
|
||||
example: 1
|
||||
category:
|
||||
description: "Whether to use a persistent map or not for cleaning (i.e. No go lines): 2 for no map, 4 for map. Default to using map if not set (and fallback to no map if no map is found)."
|
||||
example: 2
|
||||
zone:
|
||||
description: Only supported on the Botvac D7. Name of the zone to clean. Defaults to no zone i.e. complete house cleanup.
|
||||
example: "Kitchen"
|
|
@ -7,7 +7,6 @@ import voluptuous as vol
|
|||
|
||||
from homeassistant.components.vacuum import (
|
||||
ATTR_STATUS,
|
||||
DOMAIN,
|
||||
STATE_CLEANING,
|
||||
STATE_DOCKED,
|
||||
STATE_ERROR,
|
||||
|
@ -40,6 +39,7 @@ from .const import (
|
|||
NEATO_PERSISTENT_MAPS,
|
||||
NEATO_ROBOTS,
|
||||
SCAN_INTERVAL_MINUTES,
|
||||
SERVICE_NEATO_CUSTOM_CLEANING,
|
||||
)
|
||||
|
||||
_LOGGER = logging.getLogger(__name__)
|
||||
|
@ -73,8 +73,6 @@ ATTR_NAVIGATION = "navigation"
|
|||
ATTR_CATEGORY = "category"
|
||||
ATTR_ZONE = "zone"
|
||||
|
||||
SERVICE_NEATO_CUSTOM_CLEANING = "neato_custom_cleaning"
|
||||
|
||||
SERVICE_NEATO_CUSTOM_CLEANING_SCHEMA = vol.Schema(
|
||||
{
|
||||
vol.Required(ATTR_ENTITY_ID): cv.entity_ids,
|
||||
|
@ -126,7 +124,7 @@ async def async_setup_entry(hass, entry, async_add_entities):
|
|||
return entities
|
||||
|
||||
hass.services.async_register(
|
||||
DOMAIN,
|
||||
NEATO_DOMAIN,
|
||||
SERVICE_NEATO_CUSTOM_CLEANING,
|
||||
neato_custom_cleaning_service,
|
||||
schema=SERVICE_NEATO_CUSTOM_CLEANING_SCHEMA,
|
||||
|
|
|
@ -144,22 +144,3 @@ xiaomi_clean_zone:
|
|||
repeats:
|
||||
description: Number of cleaning repeats for each zone between 1 and 3.
|
||||
example: '1'
|
||||
|
||||
neato_custom_cleaning:
|
||||
description: Zone Cleaning service call specific to Neato Botvacs.
|
||||
fields:
|
||||
entity_id:
|
||||
description: Name of the vacuum entity. [Required]
|
||||
example: 'vacuum.neato'
|
||||
mode:
|
||||
description: "Set the cleaning mode: 1 for eco and 2 for turbo. Defaults to turbo if not set."
|
||||
example: 2
|
||||
navigation:
|
||||
description: "Set the navigation mode: 1 for normal, 2 for extra care, 3 for deep. Defaults to normal if not set."
|
||||
example: 1
|
||||
category:
|
||||
description: "Whether to use a persistent map or not for cleaning (i.e. No go lines): 2 for no map, 4 for map. Default to using map if not set (and fallback to no map if no map is found)."
|
||||
example: 2
|
||||
zone:
|
||||
description: Only supported on the Botvac D7. Name of the zone to clean. Defaults to no zone i.e. complete house cleanup.
|
||||
example: "Kitchen"
|
||||
|
|
Loading…
Add table
Reference in a new issue