Alexa Reading Variables

Posted on
Fri Jun 18, 2021 12:15 pm
ryanbuckner offline
Posts: 1080
Joined: Oct 08, 2011
Location: Northern Virginia

Alexa Reading Variables

I asked "Alexa, ask Indigo to read isBMWHome" and she replied -- "A variable Named isBMWHome does not exist in your Indigo server"

Here's my variable name:
Code: Select all
isBMWHome


Is there a preferred naming convention for Alexa to be able to recognize device and variable names in Indigo?

Update: Same response for variable "isDaylight"

Posted on
Fri Jun 18, 2021 1:08 pm
jay (support) offline
Site Admin
User avatar
Posts: 18219
Joined: Mar 19, 2008
Location: Austin, Texas

Re: Alexa Reading Variables

https://wiki.indigodomo.com/doku.php?id ... a_variable

Her actual reply was: "A variable named is BMW home does not exist in your Indigo server" :wink:

Jay (Indigo Support)
Twitter | Facebook | LinkedIn

Posted on
Fri Jun 18, 2021 2:25 pm
ryanbuckner offline
Posts: 1080
Joined: Oct 08, 2011
Location: Northern Virginia

Re: Alexa Reading Variables

jay (support) wrote:
https://wiki.indigodomo.com/doku.php?id=indigo_2021.1_documentation:plugins:alexa&#speaking_the_value_of_a_variable

Her actual reply was: "A variable named is BMW home does not exist in your Indigo server" :wink:


Right. So the solution is to rename the variables and use underscores?

I just renamed the variable "is_BMW_in_Garage" and got the response "I'm sorry, a variable named is BMW in garage does not exist in your Indigo server"

Posted on
Fri Jun 18, 2021 2:51 pm
jay (support) offline
Site Admin
User avatar
Posts: 18219
Joined: Mar 19, 2008
Location: Austin, Texas

Re: Alexa Reading Variables

Are there any errors in the event log? Hopefully that will show what alexa is interpreting when you say that phrase.

Jay (Indigo Support)
Twitter | Facebook | LinkedIn

Posted on
Fri Jun 18, 2021 2:58 pm
jay (support) offline
Site Admin
User avatar
Posts: 18219
Joined: Mar 19, 2008
Location: Austin, Texas

Re: Alexa Reading Variables

I just tried it and it works:

Code: Select all
   Alexa                           request the value of variable 'is_BMW_in_garage'


But Alexa has a very hard time getting "BMW" right. Sometimes it thinks I say "is the mwn garage":

Code: Select all
   Alexa                           request the value of variable 'is_the_mwn_garage'
   Alexa Error                     I'm sorry, a variable named is the mwn garage does not exist in your indigo server. Please make sure you are using the exact name for the variable; spaces should be represented in your variable name with underscores.


I'd recommend using variable names that don't have abbreviations - maybe "is_car_in_garage" for instance. I've also noticed that slightly shorter names have less of a chance of being misheard by Alexa, though lots of factors determine what it hears.

Jay (Indigo Support)
Twitter | Facebook | LinkedIn

Posted on
Fri Jun 18, 2021 3:36 pm
FlyingDiver offline
User avatar
Posts: 7215
Joined: Jun 07, 2014
Location: Southwest Florida, USA

Re: Alexa Reading Variables

Case sensitivity issue? Use is_BMW_in_garage not is_BMW_in_Garage.

joe (aka FlyingDiver)
my plugins: http://forums.indigodomo.com/viewforum.php?f=177

Posted on
Fri Jun 18, 2021 4:36 pm
jay (support) offline
Site Admin
User avatar
Posts: 18219
Joined: Mar 19, 2008
Location: Austin, Texas

Re: Alexa Reading Variables

FlyingDiver wrote:
Case sensitivity issue? Use is_BMW_in_garage not is_BMW_in_Garage.


No, we updated the API to do non case sensitive checks specifically for this reason.

Jay (Indigo Support)
Twitter | Facebook | LinkedIn

Posted on
Fri Jun 18, 2021 8:14 pm
ryanbuckner offline
Posts: 1080
Joined: Oct 08, 2011
Location: Northern Virginia

Re: Alexa Reading Variables

Alexa was able to give me the results of the request for [renamed] variable is_BMW_in_garage

but was unable to answer request for variable value of isBMWHome

Code: Select all
Jun 18, 2021 at 10:11:28 PM
   Alexa                           request the value of variable 'is_BMW_home'
   Alexa Error                     I'm sorry, a variable named is BMW home does not exist in your indigo server. Please make sure you are using the exact name for the variable; spaces should be represented in your variable name with underscores.
   Received INSTEON                "Kitchen Motion Sensor" on (button 1)

Posted on
Sat Jun 19, 2021 2:23 pm
jay (support) offline
Site Admin
User avatar
Posts: 18219
Joined: Mar 19, 2008
Location: Austin, Texas

Re: Alexa Reading Variables

I just tried is_BMW_home and it worked, so I'm not sure why it didn't work for you.

Jay (Indigo Support)
Twitter | Facebook | LinkedIn

Posted on
Sat Jun 19, 2021 4:42 pm
matt (support) offline
Site Admin
User avatar
Posts: 21417
Joined: Jan 27, 2003
Location: Texas

Re: Alexa Reading Variables

ryanbuckner wrote:
Alexa was able to give me the results of the request for [renamed] variable is_BMW_in_garage

but was unable to answer request for variable value of isBMWHome

You must use underscores between the words.

Image

Page 1 of 1

Who is online

Users browsing this forum: No registered users and 1 guest