Home of the Squeezebox™ & Transporter® network music players.
Results 1 to 6 of 6
  1. #1
    Senior Member
    Join Date
    May 2008
    Location
    Canada
    Posts
    4,132

    Google Home / Actions API

    Hi - I'm thinking about trying to develop a solution to control LMS from Google Home. It's still a very remote thought at this point as I had very quick look at this API and how you build "actions". This is very unchartered territory for me, not at all my area of expertise, so I'm seeking for opinion of more experienced folks here to tell me if I'm trying to do something super-complicated or not. I feel familiar enough with Perl and the programming model of LMS now as well as with handling secured connection and auth which I assume are required to build such actions, but I really don't know for the rest.

    I'm now using Google Home constantly and now that I have my Group Player plugin which gave me a big improvement due to the way I'm using multiroom (okay, a bit self-serving ), Goole Home integration is really the next missing piece of my system. I've tried Sonos, Roon, native iXXX or Google solutions, but I always come back to LMS as the most complete and flexible solution for my home audio usage, whether it's local/streaming music or podcast (which I use a lot). All other systems are always missing something and I can't add anything easily where with LMS, I always can

    Anyway, I digress - thoughts?

    [edit]: I know that there are some other attempts through multiple layers, but I have the tendency (probably wrong) to try to do things as natively I possible - I’m old fashion and don’t like to stack and pipe lots of layers. For example, when I started the UPnP and Chromecast plug-ins, many said that instead of modifying squeezelite to make it multi-player/instantiated in the same C application, I should have mostly left the original application and written a high level language wrapper that, for each detected device, would have spawn a squeezelite child that would have piped stdout. But for the worse or the best, that’s not what I like to do.
    Last edited by philippe_44; 2018-03-31 at 21:06.
    LMS 7.7, 7.8 and 7.9 - 5xRadio, 3xBoom, 4xDuet, 1xTouch, 1 SB2. Sonos PLAY:3, PLAY:5, Marantz NR1603, JBL OnBeat, XBoxOne, XBMC, Foobar2000, ShairPortW, JRiver 21, 2xChromecast Audio, Chromecast v1 and v2, , Pi B3, B2, Pi B+, 2xPi A+, Odroid-C1, Odroid-C2, Cubie2, Yamaha WX-010, AppleTV 4, Airport Express, GGMM E5

  2. #2
    Babelfish's Best Boy mherger's Avatar
    Join Date
    Apr 2005
    Location
    Switzerland
    Posts
    20,077

    Google Home / Actions API

    > Anyway, I digress - thoughts?

    I miss the questions in your posting :-).

    I guess you've seen related threads where possible approaches to control
    SB using Google Home are being discussed?

    --

    Michael

  3. #3
    Senior Member
    Join Date
    May 2008
    Location
    Canada
    Posts
    4,132
    Quote Originally Posted by mherger View Post
    > Anyway, I digress - thoughts?

    I miss the questions in your posting :-).

    I guess you've seen related threads where possible approaches to control
    SB using Google Home are being discussed?

    --

    Michael
    No, I’ve not really followed the threads where it has been discussed. My question was to get opinions on feasibility, especially trying to use the api as directly as possble


    Envoyé de mon iPad en utilisant Tapatalk
    LMS 7.7, 7.8 and 7.9 - 5xRadio, 3xBoom, 4xDuet, 1xTouch, 1 SB2. Sonos PLAY:3, PLAY:5, Marantz NR1603, JBL OnBeat, XBoxOne, XBMC, Foobar2000, ShairPortW, JRiver 21, 2xChromecast Audio, Chromecast v1 and v2, , Pi B3, B2, Pi B+, 2xPi A+, Odroid-C1, Odroid-C2, Cubie2, Yamaha WX-010, AppleTV 4, Airport Express, GGMM E5

  4. #4
    formerly known as Fletch
    Join Date
    May 2005
    Posts
    2,246
    I'd love to see some active development around Google Home voice control. Good luck with whatever path you choose and let me know if you need testers.

  5. #5
    Senior Member
    Join Date
    May 2008
    Location
    Canada
    Posts
    4,132
    Quote Originally Posted by mherger View Post
    > Anyway, I digress - thoughts?

    I miss the questions in your posting :-).

    I guess you've seen related threads where possible approaches to control
    SB using Google Home are being discussed?

    --

    Michael
    And typically what I’m wondering is should I use api.ai or actions sdk. The webhook that I need to do, should I build that inside LMS as a Perl plug-in or should I build a C app that will manage secure connection and be a proxy to LMS? I’m looking for something that requires as little user tinkering as possible, is secured and does not interact negatively with LMS callback/loop system. Just thinking out of loud


    Envoyé de mon iPad en utilisant Tapatalk
    LMS 7.7, 7.8 and 7.9 - 5xRadio, 3xBoom, 4xDuet, 1xTouch, 1 SB2. Sonos PLAY:3, PLAY:5, Marantz NR1603, JBL OnBeat, XBoxOne, XBMC, Foobar2000, ShairPortW, JRiver 21, 2xChromecast Audio, Chromecast v1 and v2, , Pi B3, B2, Pi B+, 2xPi A+, Odroid-C1, Odroid-C2, Cubie2, Yamaha WX-010, AppleTV 4, Airport Express, GGMM E5

  6. #6
    Using Google dialog flow and Home assistant, I have managed to make a pretty decent voice command front-end for the LMS system. Currently supported commands include:

    play / add album, song or artist t the current playlist
    play / add playlist
    play radio
    select mediaplayer
    set shuffle, repeat
    set volume
    pause, play, next track
    Supports all defined players in LMS (using sonos, upnp, cast, squeeze players)
    Also Turn on/off lights, plugs, devices and soon dimmer functions
    Uses DuckDNS / let's encrypt for secure internet access


    Current limitations include:
    - no spotty specific commands for search
    - using loadtracks command so compound queries are not available (ie: song money by pink floyd)
    - voice app needs to be called specifically from google home or assistant (ie: hey google, talk to LMS commander)

    Decided to use Home Assistant (HASSIO) as the middle man to handle the webhooks, security, etc as well this approach allows voice access to any other home automation systems I may have in place, regardless of direct compatibility with Google Home.

    Access to your system is available anywhere on any device using google assistant (IOS, Android, Windows, google home, mini, etc..)


    Gave up on the use of IFTTT as it did not support enough variables or have enough flexibility to allow multiple commands or complex queries or provide feedback for missing values.
    Last edited by ynot1234567890; 2018-06-20 at 15:43.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •