I have written a native Amazon Echo integration for the Vera - i.e. it gets added as a Device Link, and the devices can be controlled just by saying “Alexa, turn Living Room on”, “Alexa increase the temperature in the living room” and so on. It doesn’t require you to be running any local server like the bridge solution - it all runs from the Amazon cloud. There’s a video of it in action here;
The list of commands that you can use is documented by Amazon here;
Can you do more than just simulate a switch (on/off). For example, can you ask what the temperature of a thermostat is or if a door is locked? I’m pretty happy right now with by bridge, but it would be nice to get full intergration.
At the moment the Echo only understands on, off and dim, which code fully supports. The code also supports running scenes by asking Alexa to turn the scenes on (e.g. Alexa, turn on the Watch Movie Scene). If Amazon expand the vocabulary to allow thermostats, locks, pulling back current conditions and so on, then the code can very easily be updated to support that.
OK, added Amazon Echo to my ‘Check for pricing on Black Friday’ list.
Which Oauth server are you using and what platform? I can run one on either BSD or WHS2011 as I have both already deployed 24/7 with other functions and have spare cycles
[quote=“BOFH, post:5, topic:189448”]OK, added Amazon Echo to my ‘Check for pricing on Black Friday’ list.
Which Oauth server are you using and what platform? I can run one on either BSD or WHS2011 as I have both already deployed 24/7 with other functions and have spare cycles[/quote]
I used oauth2-server-php (GitHub - bshaffer/oauth2-server-php: A library for implementing an OAuth2 Server in php), but there’s nothing unique about it - just have an auth page which accepts your vera credentials and stores the username and the hashed password that you need for remote authentication of your vera, and allow that to be retrieved by an access_token. I have the steps for deploying it documented on the project github page (GitHub - mmillmor/AmazonEcho-to-Vera: Native Echo to Vera integration).
If somebody has the bridge running, can you help share your thoughts about the practical benefits of using this solution instead? What does “full integration” get us?
Some I can think of.
PROS
Don’t have to run the bridge service.
Uses the more “official” way of integrating with echo
Is more future proof, in case Amazon decides to disallow use of the bridge hack.
CONS
Need to find or run an oauth server
Need to send commands to Amazon for processing. (I’m not positive, but believe the bridge runs the commands locally without requiring a trip to Amazon)
I have had this setup for about a month. I also have the hamony hub so now my daughter (4/6) can turn on the Wii or TV just by saying “Alexa turn on the the Wii”. The bridge is running on Rasberry Pi B with Raspbian since it also have Java pre-installed. The webpage shows your vera and will automatically pull all devices and scenes so it only takes a minute or 2 to setup up few commands. There is also a guy on youtube, Ellery Coffman, that uses his own SDK with amazon to send commands to an older HA software. It’s neat, but like Richard said, I want AUTOMATION not REMOTE CONTROL. There are other solutions out there, however the Echo has great voice recognition and an array of microphones, so I find that it picks voice command well. I bought my echo early for only 100 dollars. So if you can get it for that I recommend it. 170 is too much depending on what you use it for.
I use the bridge on a PI, it works great and the same bridge lets my Harmony Home Remote turn on and off lights via the harmony remote. I think this will not add any extras and will remove my remote control of the lights.
I’m curious to see what others say but at this time I don’t see an advantage of this over the Bridge.
The code uses the new login technique that was introduced in UI6. But UI5 was very much easier to authenticate, and 75% of the code could be removed - most of it is about the authentication. Just change the code to switch lights with the code for UI5 which has the username and password in the URL, and don’t call the code to get the Vera Session.
The way UI7 authentication works needs 6 web service calls just to log in. In total a call to turn on a light takes about 3.5s once the code is initiated. There is also the time for the Echo to hear the speech and understand it. It takes about 5s after you say something for the light to actually switch - more if your Vera is being sluggish.
The way UI7 authentication works needs 6 web service calls just to log in. In total a call to turn on a light takes about 3.5s once the code is initiated. There is also the time for the Echo to hear the speech and understand it. It takes about 5s after you say something for the light to actually switch - more if your Vera is being sluggish.
Martin[/quote]
That seems exceedingly slow. Is this an authentication issue? I use the bridge software on a raspberry pi and my lights come on almost instantaneously. Certainly no more than a second or so.
I have been following along and thinking the same thing. Haven’t found that advantage yet.[/quote]
The bridge solution allows a local connection which cuts out the authentication. But it requires installation of a bridge on a local machine. If you use Amazon OAuth with the native solution, it’s all in the Amazon cloud.
I don’t find the delay noticeable on top of the delay in the Echo understanding you. But if it is an issue for anyone, I’m not here to try to make you use this solution - I’m just sharing my code for free if anyone wants to use it.
I have been following along and thinking the same thing. Haven’t found that advantage yet.[/quote]
The bridge solution allows a local connection which cuts out the authentication. But it requires installation of a bridge on a local machine. If you use Amazon OAuth with the native solution, it’s all in the Amazon cloud.
I don’t find the delay noticeable on top of the delay in the Echo understanding you. But if it is an issue for anyone, I’m not here to try to make you use this solution - I’m just sharing my code for free if anyone wants to use it.
Martin[/quote]
Martin-
Don’t get me wrong - I am grateful for your (and other’s) work to come up with integration solutions for Vera and the Echo. I apologize if my post came across as overly critical.
Don’t get me wrong - I am grateful for your (and other’s) work to come up with integration solutions for Vera and the Echo. I apologize if my post came across as overly critical.
Tad[/quote]
Sure - not a problem. The same issues you and others talk about frustrate me too - I wish that the Vera had a simpler (and faster) authentication model. I wish that Amazon had a simpler way of integrating. I wish that the Echo had more sophisticated integration, like setting thermostats and so on. Until Vera and Amazon get better, it’s down to people like us to plug the gaps as best we can.
The way UI7 authentication works needs 6 web service calls just to log in. In total a call to turn on a light takes about 3.5s once the code is initiated. There is also the time for the Echo to hear the speech and understand it. It takes about 5s after you say something for the light to actually switch - more if your Vera is being sluggish.
Martin[/quote]
That seems exceedingly slow. Is this an authentication issue? I use the bridge software on a raspberry pi and my lights come on almost instantaneously. Certainly no more than a second or so.[/quote]
Same here. I’ll stick with the bridge for now as it’s very responsive.