Closed elliotstokes closed 8 years ago
Hi, yes, the closest I can think of is the say commands from the http-api:
https://github.com/jishi/node-sonos-http-api/blob/master/lib/actions/say.js
basically, check getState() of the player and store the different parameters, then invoking it later on. I have used the preset function to simplify things, although it is still a bit messy.
I'll take a look. Thanks
Also, remember that all actions are asynchronous, and the players becomes very unhappy if you send parallell requests (they only have 4 threads available for http requests), so you need to make sure to run them i series.
So I have managed to get a simple example up and running using your api but I was wondering if I can grab a players state. Basically I want to cut out what is playing, play a specific playlist then stop it at some point in time and then resume what was playing on the device before I interrupted (could have been off or playing something else)
So far I have this basic module
Do you have any examples where you are doing this in the other clients?
Cheers