We have moved at community.getvera.com

Author Topic: siriproxy-vera plugin for using Siri to control Vera  (Read 20511 times)

Offline andrewgarfield

  • Full Member
  • ***
  • Posts: 108
  • Karma: +11/-1
siriproxy-vera plugin for using Siri to control Vera
« on: August 13, 2013, 11:15:29 pm »
Hey all,

I had seen a few threads on the boards about trying to get SiriProxy to work with their vera units, but I had yet to see any actual plugins created that did this.  So I decided to create one.

I have only worked on it for one day, so at the moment it only allows the controlling of scenes, dimmable lights, and binary lights.  But more can be added pretty quickly.

It should be as close to "drag and drop" as this kind of thing can be and it gets all of its information right from your Vera, so you don't need to customize anything (past the config.yml file).

Anyway, just thought there might be some interest in it.

Here's the link to the plugin with installation instructions:

https://github.com/andrewgarfield/siriproxy-vera

Questions, comments, forks, and commits are welcome!

Andrew

Offline Quinten

  • Sr. Member
  • ****
  • Posts: 273
  • Karma: +2/-0
Re: siriproxy-vera plugin for using Siri to control Vera
« Reply #1 on: August 14, 2013, 04:16:03 am »
How does it compare to http://forum.micasaverde.com/index.php/topic,15417.0/topicseen.html ?  Is your version based on that?

Looking forward to giving it a go though...
VeraLite - UI7 1.7.947 | 8x Fibaro FGD211 | 2x Fibaro FGS221 | 1x Fibaro FGBS321 | 3x Fibaro FGRGBW | 1x Everspring SP814 | 2x Everspring AN157-3 | 2x Heatmiser PRT-TS WiFi | 1x Logitech Harmony Hub | 1x Philips LivingColour

Offline andrewgarfield

  • Full Member
  • ***
  • Posts: 108
  • Karma: +11/-1
Re: siriproxy-vera plugin for using Siri to control Vera
« Reply #2 on: August 14, 2013, 11:42:47 am »
Hey Quinten,

This plugin is not based on the code from that other thread, I wrote it myself a few nights ago.

How does it compare?  Here's a brief summary.

The biggest advantage the other script has is that it is (at the moment) more functional than this plugin. That one does things with thermostats and some other devices that this plugin simply doesn't yet do because it's so new.  It also seems to have more alternative word phrasings built in.  I have started to add more alternative phrasings into this plugin, but it just takes time as I learn how I, and others, want to talk to Siri, and also in how Siri parses speech.

Here's some of the positive things that this plugin has going for it:

  • It's in plugin form.  Though I didn't read through the entire thread that you linked to, it seemed likes that code was never turned into a plugin and was intended to be copy and pasted from the forum to the into the existing example plugin.  Using a plugin has a few advantages:
    • Easy Install. Just copy and paste the info into your config.yml file and run siriproxy update and it takes care of the rest.
    • Easy Updates.  As I, and other contributors (if there are any) work on it, people can easy get the latest updated versions just by running the update command.
    • It's Centralized.  If additional contributors wanted to help, they easily could.
  • It's a bit more dynamic.  The way the other solution is written would likely require stopping and restarting the server update scenes and devices it knows about.  With this plugin, updating devices and scenes could be done with a voice command through Siri. Though this isn't implemented yet, it's somewhat trivial to do.
  • It might be faster and or take up smaller amounts of memory.  I haven't tested the other one, but just comparing the way in which the two are implemented, it's possible that this plugin will take up less memory and be a bit faster.  Whether it takes up significantly less space and is significantly faster, I don't know.

Both seem like good solutions, so if you're using the other one there may not need to be a reason to switch.

Andrew

Offline parkerc

  • Beta Testers
  • Sr. Hero Member
  • *****
  • Posts: 2479
  • Karma: +35/-48
  • Life Moves Pretty Fast....
Re: siriproxy-vera plugin for using Siri to control Vera
« Reply #3 on: August 24, 2013, 03:46:09 am »
Hi Andrew

Thanks for sharing this, I've been looking for another (simpler) way to allow Siri/Sir-Proxy work with Vera.

There are a number of posts on this and I tries hard to make the Raspberry Pi/Siri-Proxy combo work http://forum.micasaverde.com/index.php/topic,13324.45.html. So I'll aim to give yours a go.

It'll be great to have a single consolidated approach to using Siri with Vera. I also like the idea (maybe a dream :)) of having a device icon on the dashboard for this functionality, that shows a) I am connected via Siri (Ping sensor) b) the ability to add the words & actions c) show the status of the Sir-Proxy responce to a command and d) what command was last auctioned

« Last Edit: August 24, 2013, 03:51:51 am by parkerc »

Offline andrewgarfield

  • Full Member
  • ***
  • Posts: 108
  • Karma: +11/-1
Re: siriproxy-vera plugin for using Siri to control Vera
« Reply #4 on: August 24, 2013, 06:27:48 pm »
parkerc,

Happy to hear you're going to try plugin out.  Please let me know how the installation goes.  Though I've written up instructions on how to install I've never actually installed it (past my initial development) so i'm not 100% that everything will go smooth.  Keep in mind that when I did do the install, I built a fresh siriproxy virtual machine from scratch with the latest versions of ruby, and SiriProxy.  I am not sure how earlier installs will interact with the plugin, but my gut says it should probably work fine.  But if things don't work and your installation is an older one, you might want to try reinstalling to get you to the latest.

I definitely share your vision on having this thing but much much much more plug-in play through the dashboard.  Maybe one day we'll get there.  Right now there's a decent amount of hurdles to cross to make that happen.

Andrew

Offline parkerc

  • Beta Testers
  • Sr. Hero Member
  • *****
  • Posts: 2479
  • Karma: +35/-48
  • Life Moves Pretty Fast....
Re: siriproxy-vera plugin for using Siri to control Vera
« Reply #5 on: August 25, 2013, 03:14:36 am »
Hi Andrew

Thanks for responding, as i alluded to earlier I'm on a quest now to find the best SiriProxy Vera integration, and while my earlier attempts proved very frustrating I'm currently testing out @autotoronto's script (http://forum.micasaverde.com/index.php/topic,15417.msg123887.html#msg123887) which i know you've seen and commented on.

As I'm not a programmer, I'd like something that I could easily customise, and looking at your code (which I will hopefully get round to trying soon) the siriproxy-Vera.rb seems less intuitive to update than the other script. but i should stress it's still early days, and as you'll see from my latest post in the link above, I've hit a hurdle already.  :(

I'm running the latest SirPrixy image for the Pi (http://sourceforge.net/p/siriproxyrpi/wiki/Home/) which I'm assuming will be able to run your add-on too?

Offline andrewgarfield

  • Full Member
  • ***
  • Posts: 108
  • Karma: +11/-1
Re: siriproxy-vera plugin for using Siri to control Vera
« Reply #6 on: August 26, 2013, 11:48:14 am »
parkerc,

I agree at this point that my siriproxy-vera plugin is probably less intuitive to modify than the other script you mentioned.  At least it is at this point (and likely will continue to be).  My goal for this so far has been more of a drag-and-drop kind of approach to allow people to get siriproxy running and just install this thing without having to modify.

That being said, I do see a need for customizations, too.  Just as everyone's home is different, so too is everyone's vera installations, and desired functionality.  Even for myself i'm coming up with ideas on things I want the script to do that's a bit more specific to my own installation than a general one.  So i'm toying with the idea of allowing people to create customization files to extend the functionality of the plugin.  This way we might be able to have our cake and eat it to (keep it drag and drop, but also make it customizable and extensible).

I haven't fully fleshed it out in my head yet, so don't have any word on that beyond this.

As for the plugin working on the Raspberry pi... the best I can say is that I THINK it will.  I'm not familiar enough with it or the siriproxypi project to say with any kind of certainty.  In the end though, it's all just ruby code.  I don't think I used any specialized coding that wouldn't run on different versions of ruby and/or on SiriProxy.

Andrew

Offline andrewgarfield

  • Full Member
  • ***
  • Posts: 108
  • Karma: +11/-1
Re: siriproxy-vera plugin for using Siri to control Vera
« Reply #7 on: September 04, 2013, 01:09:27 am »
Just wanted to let everyone know that I have added a bit of functionality to siriproxy-vera.

First, I hastily created the ability to reload device information on the fly.  So no when you do things like add/remove devices, change scene names, or change device names on your vera you no longer have to restart siriproxy to take advantage of the changes.  Just tell siriproxy-vera to reload the information.

Simply do the following:

**To reload the configuration changes from Vera (such as if you change the name of a scene or device).**
You: "Reload device information"
Siri: "Okay, I have reloaded the configuration from Vera."

I have also added limited functionality to interface with your alarm panel in order to arm your alarm into either "Away" or "Stay" states.  I purposefully left out the ability to disarm alarm systems for security purposes.  Please keep in mind that I tried to write to the standard but I could only test on the alarm system I have (a Honeywell Ademco Vista system).  So while I think it should work for any systems out there, your mileage may vary.  I'd love feedback if it does or doesn't work with your system.

**Setting alarm system into away mode.**
You: "I am leaving" or "We are leaving"
Siri: "Okay, I'll prepare the house for you."

**Setting alarm system into home mode.**
You: "I am staying in" or "We are staying in"
Siri: "Okay, I will arm the house for you."

I have updated all of the readme information on the github page.  If you have questions, many of them will be answered there.

Andrew

Offline Piwtorak

  • Hero Member
  • *****
  • Posts: 988
  • Karma: +4/-0
Re: siriproxy-vera plugin for using Siri to control Vera
« Reply #8 on: September 04, 2013, 10:23:53 am »
Hi andrewgarfield,
for runs with your plugin I must have a separate machine with linux and siriproxy ?
can not be installed in vera3 ?

thanks...
Vera3 (1), Airport Extreme (2), Apple TV (3), Sqblaster (1), GE Switch (3), GE Dimmer (1), Leviton VRCSZ2 (2), GE 45601 (1), Intermatic HA03 (2), GE Zwave Outlet (1), Remote Control Curtain (1) and growing.

Offline andrewgarfield

  • Full Member
  • ***
  • Posts: 108
  • Karma: +11/-1
Re: siriproxy-vera plugin for using Siri to control Vera
« Reply #9 on: September 04, 2013, 10:47:32 am »
Piwtorak,

The main requirement of this plugin is the "SiriProxy" software.  Wherever that software can run, this plugin can most likely run as well.

I know that a lot of people run it on a box separate from their Vera devices such as on a raspberry pi or on a virtual machine (as I do).  But I thought I remembered reading in a thread on these forums that some have gotten it to work on a Vera box.  You'd have to do a search of the forums to see if that is indeed possible.

I hope this helps.

Andrew

Offline Piwtorak

  • Hero Member
  • *****
  • Posts: 988
  • Karma: +4/-0
Vera3 (1), Airport Extreme (2), Apple TV (3), Sqblaster (1), GE Switch (3), GE Dimmer (1), Leviton VRCSZ2 (2), GE 45601 (1), Intermatic HA03 (2), GE Zwave Outlet (1), Remote Control Curtain (1) and growing.

Offline andrewgarfield

  • Full Member
  • ***
  • Posts: 108
  • Karma: +11/-1
Re: siriproxy-vera plugin for using Siri to control Vera
« Reply #11 on: September 04, 2013, 02:14:50 pm »
Piwtorak,

I'm sorry to say that I don't know enough about raspberry pi's to give you guidance on it.  But you may want to check the siriproxyrpi project site (which I believe is http://sourceforge.net/p/siriproxyrpi/wiki/Home/) to get more information on what it supports.

Perhaps some forum members who are running siriproxyrpi can give some guidance here?

Andrew

Offline Brientim

  • Sr. Hero Member
  • ******
  • Posts: 2497
  • Karma: +78/-7
Re: siriproxy-vera plugin for using Siri to control Vera
« Reply #12 on: September 04, 2013, 03:40:56 pm »
I tested a version of Siri Proxy on the Raspberry Pi (256mb) and it ran without any issues. They recommend the 512mb for it and yes, that would do the job.

Offline Piwtorak

  • Hero Member
  • *****
  • Posts: 988
  • Karma: +4/-0
Re: siriproxy-vera plugin for using Siri to control Vera
« Reply #13 on: September 04, 2013, 05:50:12 pm »
Ordering one right now...
thanks !
Vera3 (1), Airport Extreme (2), Apple TV (3), Sqblaster (1), GE Switch (3), GE Dimmer (1), Leviton VRCSZ2 (2), GE 45601 (1), Intermatic HA03 (2), GE Zwave Outlet (1), Remote Control Curtain (1) and growing.

Offline Piwtorak

  • Hero Member
  • *****
  • Posts: 988
  • Karma: +4/-0
Re: siriproxy-vera plugin for using Siri to control Vera
« Reply #14 on: September 16, 2013, 08:16:02 am »
Hi Brientim,

My raspberry pi arrives last saturday,
and now I am wanting install siri-proxy,

can you help me saying what guide do you follow to install siri-proxy in your system ?

My commands will be all in english ? or another language is accepted ?

thanks in advance,

I'm curious to see this working...
Vera3 (1), Airport Extreme (2), Apple TV (3), Sqblaster (1), GE Switch (3), GE Dimmer (1), Leviton VRCSZ2 (2), GE 45601 (1), Intermatic HA03 (2), GE Zwave Outlet (1), Remote Control Curtain (1) and growing.