diff --git a/atom.xml b/atom.xml index 71f9472b65..ff403a6d06 100644 --- a/atom.xml +++ b/atom.xml @@ -4,7 +4,7 @@
This is a simple hello world example to show the basics of registering a service. To use this example, create the file <config dir>/custom_components/hello_service.py
and copy the below example code.
This is a simple “hello world” example to show the basics of registering a service. To use this example, create the file <config dir>/custom_components/hello_service.py
and copy the below example code.
Services can be called from automation and from the service developer tools in the frontend.
+Services can be called from automation and from the service “Developer tools” in the frontend.
# The domain of your component. Should be equal to the name of your component -DOMAIN = "hello_service" +# The domain of your component. Should be equal to the name of your component. +DOMAIN = 'hello_service' ATTR_NAME = 'name' DEFAULT_NAME = 'World' def setup(hass, config): - """ Setup is called when Home Assistant is loading our component. """ + """Setup is called when Home Assistant is loading our component.""" def handle_hello(call): name = call.data.get(ATTR_NAME, DEFAULT_NAME) @@ -135,7 +135,7 @@ DEFAULT_NAME = ''hello', handle_hello) - # return boolean to indicate that initialization was successful + # Return boolean to indicate that initialization was successfully. return True
This is a simple hello world example to show the basics for setting a state. To use this example, create the file <config dir>/custom_components/hello_state.py
and copy the below example code.