Giter Site home page Giter Site logo

coxsim / sonos-monitor Goto Github PK

View Code? Open in Web Editor NEW

This project forked from michaelotto/sonos-monitor

0.0 2.0 0.0 180 KB

Automatically turns on a Yamaha Receiver (and switches it to the appropriate input) when a Sonos Connect starts playing.

License: MIT License

Shell 8.80% Python 91.20%

sonos-monitor's Introduction

sonos-monitor

Automatically turns on a Yamaha Receiver (and switches it to the appropriate input) when a Sonos Connect starts playing.

What this does:

Start this as a daemon (sample init.d-script included). It connects to your Sonos Connect and your Yamaha Receiver. Whenever the Sonos Connect starts playing music, radio or whatever, it turns on the Receiver, switches to the appropriate input, sets the volume and changes to the Sound Program you want to (e.g. "5ch Stereo").

If the Receiver is already turned on, it just switches the input and leaves the rest alone.

If you set the standby time of the Receiver to 20 minutes, you'll have a decent instant-on solution for your Sonos Connect - it behaves just like one of Sonos' other players.

Optimized for minimum use of resources. I leave this running on a Raspberry Pi at my place. An A model should suffice. And it would still be bored 99% of the time.

Before installing it as a daemon, try it out first: Adapt the settings in the script below. Then just run the script. It'll auto-discover your Sonos Connect. If that fails (e.g. because you have more than one Connect in your home or for other reasons), you can use the UID of your Sonos Connect as the first and only parameter of the script. The script will output all UIDs neatly for your comfort.

Prerequisites:

  • Your Yamaha Receiver has to be connected to the LAN.
  • Both your Yamaha Receiver and your Sonos Connect have to use fixed IP addresses. You probably have to set this in your router (or whichever device is your DHCP).
  • Your Yamaha Receiver's setting of "Network Standby" has to be "On". Otherwise the Receiver cannot be turned on from standby mode.

Software prerequisites:

  • sudo pip install soco

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.