SageTV Community

SageTV Community (http://forums.sagetv.com/forums/index.php)
-   SageTV v9 Customizations (http://forums.sagetv.com/forums/forumdisplay.php?f=57)
-   -   Echo Skill (http://forums.sagetv.com/forums/showthread.php?t=63281)

tmiranda 06-18-2016 04:54 PM

Echo Skill
 
Latest installation instructions:
- Send me a PM with the email address used to register your Echo.
- Install the "Sage for Echo" UI Mod plugin.
- Follow the instruction here: https://github.com/tmiranda1962/Echo/wiki

*******************************************************

I started messing around with writing a skill for the Amazon Echo to communicate with SageTV. I have the basic plumbing working and will start to flesh out the functionality.

For those unfamiliar with the Echo, it's Amazon's home automation product. You speak to it in plain English and it does what you tell it to do (theoretically anyway). You add functionality to the Echo by writing "Skills". I am writing a Skill that will allow you to speak to your Sage server and ask things like "When will the next episode of The Kardashians be recorded" and "Did the last formula1 race get recorded?". The Echo will then speak the answer to you.

The device is actually very good and has a lot of Skills available. (One of my favorite is "The stupid cat joke of the day", but that is another subject. :D)

I'm looking for some help in the following areas, please let me know if you are interested:

- I need to create a few icons, and I know nothing about icon editors. A while back there were some prototypes done by one of the forum members and I'm hoping to use that as a basis. (I'm assuming the "official" Sage logo and icon are copyrighted.)

- I need to write a web based (simple) database to hold user information such as the URL to their Sage machine and the Jetty userID and password. Amazon provides a free service that can be used and integrates with the Echo very well. The first time the user install the Skill and uses it they will need to create an account and enter this required information.

jonnydeath 06-21-2016 08:48 PM

I already posted one. I had to hardcode too many variables (like user name, password, etc). I wish i could figure out a better way to do it, but I could not figure out the dynmo database and I am a very bad programmer. Hopefully, functionality I wrote can be integrated into your version.

http://forums.sagetv.com/forums/showthread.php?t=63164

tmiranda 06-23-2016 06:26 AM

Quote:

Originally Posted by jonnydeath (Post 589965)
I already posted one. I had to hardcode too many variables (like user name, password, etc). I wish i could figure out a better way to do it, but I could not figure out the dynmo database and I am a very bad programmer. Hopefully, functionality I wrote can be integrated into your version.

http://forums.sagetv.com/forums/showthread.php?t=63164

Doh, guess I'm late to the party. :)

Mine is pretty far along and does some things that yours does not. Yours also does things that mine does not. Maybe we can roll them up into one?

Right now I also have the jetty user:password hard coded pending getting a better grip on dynamo.

jonnydeath 06-24-2016 04:04 AM

please use any of the code you want. playing shows and youtube is the most popular function with my kids.

i found this xbmc alexa skill where he has the skill send a key to the alexa app to configure. i'm not sure how it works, but looks intriguing
http://forum.kodi.tv/showthread.php?tid=258165

tmiranda 06-24-2016 07:21 AM

Quote:

Originally Posted by jonnydeath (Post 590041)
please use any of the code you want. playing shows and youtube is the most popular function with my kids.

i found this xbmc alexa skill where he has the skill send a key to the alexa app to configure. i'm not sure how it works, but looks intriguing
http://forum.kodi.tv/showthread.php?tid=258165

Thanks. I will look into how you implemented searching for spoken literals. I am reading that Alexa isn't very good at deciphering words that are not within a certain restricted set of words.

tmiranda 07-25-2016 02:01 PM

I'm making decent progress on this. If anybody else is interested please let me know. My plan at this point is to not release it as an official skill but I will share it with anybody interested in using it.

Brent94Z 08-18-2016 05:30 PM

I'd be interested! I have an Echo in the main living room and have another Echo and two Dots to get setup when I get some free time away from work.

I love my Echo and will install this once you get it up and running and give it a shot! :)

Will this be able to do things like "Alexa, tell Sage TV to show all my movies with Anthony Hopkins" or "Alexa, tell Sage TV to show all my action movies"

I'm not a programmer so not sure how hard it would be to do this but one thing I notice that I always want to do is watch a trailer of one of my movies. I have a couple thousand or so movies in my Videos section of SageTV. If I have the window up where I would hit "Play" to watch the DVD/Movie, it would be bad ass to be able to say "Alexa, tell Sage TV to play trailer for current movie" and it would open a browser window and play the trailer then close the browser window. At that point I could either hit "Watch now" or find another movie. It seems like there used to be a "Play Trailer" but I don't seem to have it as an option any longer... besides, having it be voice controlled would be pretty cool :)

All that may be too complicated. I have no idea but it sounds like a nice feature. LOL

Thanks for making this!

tmiranda 08-19-2016 07:09 AM

Quote:

Originally Posted by Brent94Z (Post 591594)
I'd be interested! I have an Echo in the main living room and have another Echo and two Dots to get setup when I get some free time away from work.

I love my Echo and will install this once you get it up and running and give it a shot! :)

Will this be able to do things like "Alexa, tell Sage TV to show all my movies with Anthony Hopkins" or "Alexa, tell Sage TV to show all my action movies"

I'm not a programmer so not sure how hard it would be to do this but one thing I notice that I always want to do is watch a trailer of one of my movies. I have a couple thousand or so movies in my Videos section of SageTV. If I have the window up where I would hit "Play" to watch the DVD/Movie, it would be bad ass to be able to say "Alexa, tell Sage TV to play trailer for current movie" and it would open a browser window and play the trailer then close the browser window. At that point I could either hit "Watch now" or find another movie. It seems like there used to be a "Play Trailer" but I don't seem to have it as an option any longer... besides, having it be voice controlled would be pretty cool :)

All that may be too complicated. I have no idea but it sounds like a nice feature. LOL

Thanks for making this!

I've only been working on it in dribs and drabs and it's not ready for prime time yet. When it gets there I'll let you know. You will probably have to install it in "developer mode" because I doubt it will get past Amazon's certification process at this point :(

As for what it can and can't do; that's all up in the air since it's not fully developed :) I can tell you that the first example you gave is something that will probably not be done. The way the Echo works is that you must give it a list of possible responses, meaning I'd have to give it a list of every actor which is not possible. The second example however is already done :)

Brent94Z 08-19-2016 01:34 PM

Ahhh... I see what you are talking about and how actors won't be possible :)

I'm also still on V7 and I'm guessing this probably won't work on that. I probably should make the move to V9 at some point but V7 has been working so well for me that I'm a little scared to mess with it. hahahaa

tmiranda 08-19-2016 05:52 PM

Quote:

Originally Posted by Brent94Z (Post 591620)
Ahhh... I see what you are talking about and how actors won't be possible :)

I'm also still on V7 and I'm guessing this probably won't work on that. I probably should make the move to V9 at some point but V7 has been working so well for me that I'm a little scared to mess with it. hahahaa

Unless stuckless makes sagex V9 only, this will work fine with v7.

Brent94Z 08-22-2016 02:46 PM

Quote:

Originally Posted by tmiranda (Post 591626)
Unless stuckless makes sagex V9 only, this will work fine with v7.

Excellent! Thanks for that bit of info!

wayner 08-25-2016 08:04 AM

FYI - I believe that you can use the Echo with the web based Harmony remotes - I think it involves using IFTTT. It wouldn't give all of the capabilities discussed in this thread but it will let you do the basics like turn on the TV and go to Sage and replicate some/all of the remote control functionality.

https://ifttt.com/connect/harmony/amazon_alexa

tmiranda 09-19-2016 07:47 AM

Alpha
 
I think in a few weeks I'll be to the point where I have something worthy of Alpha testing. If you are interested in trying it out let me know.

The skill will not be available in the store, you will need to create an Amazon developer account, link your echo to it, and then setup the skill in developer mode. I can help you with some of the mechanics. I say this to warn you that installation will not (initially) be "plug and play". :)

You will be able to do some basic things like:

- Get all of the recordings.
- Group and sort (on limited fields such as title and date.)
- Filter (by watched, Favorite, Don't Like, Archived.)
- Save the view so the next time you ask about the recordings they will be grouped and sorted in the same way.
- Set/Clear Watched, Don't Like, Favorite, Archive.
- Watch. You will be able to name your extenders and then say things like "play it in the living room".
- Get system status (heap used, disk space available, what's currently recording, what will be recorded, etc)
- Give commands directly to an extender. (i.e. verbally issue commands that would normally come from the remote like play, stop, pause, right, left, enter, etc.)

It's not very polished at the moment and I've been playing with alternate ways to navigate.

It is kind of cool to be able to talk to my Sage server :)

psklenar 09-19-2016 02:19 PM

Neat! I just recently bought an Echo and this really sounds neat! :o

pat----

wayner 09-19-2016 02:49 PM

Once they start shipping the Echo Dots I will get one of those as they also interface well with my HA system. I least I hope they do since the Echo isn't technically supported in Canada but most things seem to work anyhow.

KarylFStein 09-19-2016 04:03 PM

I'm looking to get one of these for Christmas :). What HA system do you have? I was thinking of trying OpenHAB. It seems to support Echo and the Harmony hub, and not need a cloud connection.

wayner 09-19-2016 05:19 PM

I have a Control4 system that I first had installed when I had some renos done on my house nine years ago. It is a good system except Control4's model is that everything must be sold through a dealer, but you can do most of the programming on your own. It isn't cheap but it is less expensive than the highest end stuff like Crestron. I use it for lighting, blinds, HVAC, security, fireplace, etc. You can use it to control your AV system, and most people do, but I am happy with using Harmony remotes for that.

And the people that have these often have video distribution systems with matrix switches, etc. I don't understand why you would have something like that when something like SageTV, with extenders, is far better and way cheaper.

tmiranda 09-20-2016 07:21 AM

Quote:

Originally Posted by KarylFStein (Post 592878)
I'm looking to get one of these for Christmas :). What HA system do you have? I was thinking of trying OpenHAB. It seems to support Echo and the Harmony hub, and not need a cloud connection.

I don't use mine for HA, yet. I have to say I am very impressed with the device. I use it all the time to add keep track of my shopping list and To Do list. It's just so convenient to say "Alexa, add peanut butter to my shopping list".

I also use it to read books to me while I am puttering around the house. My son uses it all the time to play music.

tmiranda 09-25-2016 07:21 AM

Wiki
 
I started on a wiki that explains how to use the skill I am developing. The wiki (and the skill) is not complete, but this will give you an idea of the direction I am going in.

Comments and suggestions are welcome.

https://github.com/tmiranda1962/Echo/wiki

wayner 09-25-2016 09:59 AM

This sounds awesome - another reason to buy a six pack of the new Echo Dots when they are available in a month or so.


All times are GMT -6. The time now is 09:51 PM.

Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2018, vBulletin Solutions, Inc.
Copyright 2003-2005 SageTV, LLC. All rights reserved.