I am trying to feed commands from Rhasspy to my home assistant, but I am having issues with the automation.
I am able to read the trigger fine, but the rgb_color seems to be giving me an issue. I have read numerous posts with various examples, but none of them are working for me. I have tried referencing the individual values of rgb_color, parsing to build a list, and many variations with no success. I have even tried to use light.toggle with rgb_color and color_name since color_name is not available for the yeelight service.
I am also not sure how I can check to see what values the automation is actually seeing in the data template when it runsā¦I did not see it in the homeassistant log file.
Here is the error I am getting with rgb_color: Invalid data for call_service at pos 1: expected int for dictionary value @ data[ārgb_colorā]
Here is my current config. Any help would be much appreciated.
I tried your example (even though I have tried this before posting) and get the following error:
[homeassistant.helpers.service] Error rendering data template: UndefinedError: list object has no element 1
I slightly modified your example to specify the delimiter for the split, but it still failed with this error (I already tried this before, but tried again to be thorough):
[homeassistant.components.automation] Error while executing automation automation.rhasspy_lights. Invalid data for call_service at pos 1: None for dictionary value @ data[ārgb_colorā]
Here is an example of the input coming from the trigger. I control the input, so I can make it whatever I want it to be. I have tried using common color names (blue, red, green, etc) as well as rgb values (255,0,0 for redā¦0,255,0 for green, etc).
I believe @123 is correct. I have tried just calling the value directly, but it tells me it is not an integer. It appears to be returning it as a string.
@123 I tried your solution before posting, but it appears my syntax must have been slightly off. You start to lose track of all the things you have tried after a while.
I was able to get the following to work. Thank you so much @123.