How i super-easily set up voice control

project_voice

(John Lord) #1

This setup created an always-listening android device, although you can skip one of the steps and have one-button press for voice control.
apps required: (NO ROOT)
sharptools with the activation of widgets
–allows you to create shortcuts to things, etc.
Commandr
–hooks into OK google, expands functionality.
tasker
– for adding commands to Commandr
autoshortcut (tasker plugin)
–for launching shortcuts. It works even if you don’t activate it.
and most importantly, Voice Shortcuts
–this app allows you to create a custom voice command of your choosing to launch any shortcut you wish. All the shortcuts are stored in the app itself.

So i say “ok google”, google now opens…
i say “control” and commandr takes over, and runs a custom script in tasker that simply launches a shortcut to voice shortcuts app.
i did it this way because if you launch it from a shortcut instead of just running the app, it opens in listening mode.
so now voice shortcuts is open, and i can run any command i have stored in it with one word. I say “lights” and the lights toggle…
this may not be super-easy to set up and it cost me something like $6, but i no longer have to mess with tasker or commandr. to add more voice commands, i simply create new shortcuts in the voice shortcuts app.
incidently, commandr has many other functions that make it useful for smartthings such as the ability to toggle the wifi on and off, bluetooth, etc. Also, due to a bug in tasker, commandr has to be installed AFTER tasker. If you install it first, it works but gives nagging toast notifications and the in-app shortcut to tasker will fail. With vigorous usage of virtual switches or custom modes, you could do anything you wish with your voice now. Just think: Pick up a $49 prepaid android phone for each room. There’s your scene control AND voice control. And if you would rather have one-button press to do all this instead, or have an older phone, just leave voice shortcuts open. Note: there’s a solution for older phones as well: it’s called Open MIc+ for google now, and it actually lets you pick your own activation word.


(Ray) #2

Awesome work. Is this similar to Google voice, sharptools, tasker and autovoice?


(Joshua Lyon (SharpTools.io Dashboard)) #3

Very cool - I love seeing interesting use cases for SharpTools!

@Navat604 it looks pretty similar to the setup you described; Instead of using voice commands to directly control devices, it sounds like @lordorwell is using an initial voice command to open the app Voice Shortcuts which will then listen for his next voice command to control his devices. The difference being that with direct voice commands, he would need to program each voice command in Tasker whereas with his setup he can just add another shortcut to Voice Shortcuts and he doesn’t have to program anything extra.

For reference, here’s the tutorial on how to do direct voice commands:


(mike) #4

When I get to the step to input the tasked variable in sharpstool the apply button is greyed out. The app wontlet me finish

Thanks Mike


(Joshua Lyon (SharpTools.io Dashboard)) #5

@uglyskier when you first open up the ‘A Thing’ plugin in SharpTools, try selecting a device which has control capabilities. If the first device in your list is something that doesn’t have a command available (like a presence sensor), then the Apply button is greyed out until you select something that is controllable.

PS. We may want to use the ‘Reply as linked Topic’ option so we don’t hijack John’s thread. Or feel free to PM or email me directly.


#6

Are there any step-by-step instructions for Lordorwell’s setup?


(Vic Singh) #7

I would like that too…

Is it safe to give Sharptools authorization to Smartthings?


(Joshua Lyon (SharpTools.io Dashboard)) #8

Do you have any particular concerns? I’m the developer of SharpTools and would be happy to address them.

SharpTools asks you to authenticate directly with SmartThings and it never sees your username and password - it only receives a token that allows it to act on your behalf. If at any point you want to revoke access to the token, you can do so by uninstalling the SharpTools SmartApp from your SmartThings mobile app.


(Vic Singh) #9

Thanks for clearing that up for me


(ocpd+adhd+alz+md+hfa+fms+lol=me :)) #10

@lordorwell
Thanks a lot for the work you did in figuring out how to do it this way.
Do you have any sort of detailed, step-by-step instructions?

I see the general layout of what you did in the OP of that thread, but it would be nice to see detailed steps to make sure I get it right.

I see this as a poorman’s Echo, and we will all owe you if it works.
So, where are the instructions, and then, where is the ‘donate’ button/link (which I will definitely use if this pans out in my setup)?


(John Lord) #11

latest update: I tested this in Marshmallow, and Commandr does not work properly as an accessibility service even though it shows up as one. However it also installs as a note app, so you can still use it by saying “take a note: turn on kitchen lights” or whatever. Also strangely i noticed that when you go through commandr’s settings, there’s a setting to view tasker commands. It’s not actually letting you launch them though. You have to create a “profile” from the main tasker screen using the commandr 3rd party plugin under “events” and the phrase you enter in the plugin to listen for is actually what you need to say. Now, i didn’t have any luck setting up variables here but i barely use tasker at all so it may have been an error on my part with the language.
I have revisited this because i have purchased an android wear watch (frankly to play with) and i want to see how this compares to the “alexa listens” app i’ve been using from my phone to control my house. The latest update has added many features to make the app even more usable including a separate app icon to launch directly into listen mode (for use with other always-on listeners) and android wear support. This is literally the only way you can get alexa on your wrist! And MOST importantly to me (the one i bought doesn’t have a speaker) it can listen from the wrist and still respond over the phone. That’s the theory anyway.


#12

Tagging @joshua_lyon


(Joshua Lyon (SharpTools.io Dashboard)) #13

AutoVoice still works with Marshmallow and is what the tutorial linked above is based on.


(Neal (www.zebrablinds.com / www.zebrablinds.ca)) #14

And I can confirm that, I just set it up. Works wonderfully (I am using Android N and Marshmallow (2 devices).

Made a few regex that works almost like natural speech… the problem I am having is getting it to work with multiple commands. So for example “Open the Garage will work” but “Open the Garage and run Goodbye” won’t. Should have something working sometime this week and when I do I can share the Regex and config if anyone needs them.


(Mike) #15

I’ve been doing this for a while now through AutoVoice and Tasker. It’s pretty simple really.

After having both apps fully owned, set up a Tasker profile with an Event trigger for whatever word you want (for example: my living room lamps have the word “lamps”, my mantle light has “mantle”(with replacements in the advanced settings for " mental=mantle,Mantel=mantle " in that format (no quotes) to create a more natural voice attribute) , etc.

I use the words as triggers without “exact phrase” checked in the app, and that’s about it (except for the “mantle” replacements, which I found it was easiest to just add through trial and error. Rest are very easy). As long as th re command word is spoken in the phrase, it works.

Another example is my Good Night! Phrase command. With the words “bed time” used as the keywords, if i say that or any combo (“time for bed” works) it runs the app.

I stopped the continuous listening, just because I realized I didn’t use it much and it was more of a hassle (it did work, though), but otherwise it was simple and very natural voice control.

The second part is just to set up SharpTools actions to react to the Events (the easy part - FYI Sharp Tools is probably the best 3rd party purchase you can make on Smartthings), and you have full voice control.

You could get much more advanced, but this setup allows voice control, and I can control multiple commands in a single OK Google voice initiation (with very natural sounding commands - I’ll often say please and ask nicely, just because I can and it’s polite, lol).

Sharp Tools makes this simple and awesome.


(Neal (www.zebrablinds.com / www.zebrablinds.ca)) #16

I’ve been setting up regex filters and so far its pretty great. The only problem I am trying to over come is sending %avnocommfilter back to autovoice to reprocess. Haven’t figured that out yet. If I can get that running with about 4 - 5 different profiles enabled i should have a fairly functioning natural voice enabled version that can accept multiple commands in one go (i.e “Turn off basement lights, open the garage door and arm home.”

It will have a few limitations but it can be rectified by improving on the regex.


(Amauri Viguera) #17

Sharing is caring… don’t hog all the good stuff :slight_smile:

And as far as SharpTools goes, it is absolutely the best app I’ve purchased to augment the capabilities of ST. Even if you don’t have Tasker you can still find it useful even if just to create shortcuts to items.


(Amauri Viguera) #18

BTW the folks at Ultimate Ears have added Google Now support to their speakers, which could make for some interesting integration.

You basically press the button on the speaker and it relays the command to your phone, so you could theoretically add voice commands from any room by having one of these speakers, and the Tasker / AutoVoice / SharpTools setup described above.

I don’t currently have one of these speakers to test but I might have to go grab one today.

Now if Sonos would get on the ball with this too, that would be pretty awesome.


(John Lord) #19

It seems to cost at least as much as an echo. No thanks


(Neal (www.zebrablinds.com / www.zebrablinds.ca)) #20

Will share as soon as I get the final kinks done… I spent a good 6 hours yesterday until I drove myself insane :joy:

At one point I made a mistake in the regex which ended up turning every single “switch” in the house with the word light in it on… needless to say that was not expected :grin: