npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2024 – Pkg Stats / Ryan Hefner

homebridge-chromecast

v0.5.0

Published

A homebridge plugin to Control Chromecast Devices

Downloads

17

Readme

homebridge-chromecast

This project is an attempt to create a Homebridge plugin for interfacing with Chromecast Audio devices. Rather than rewriting a library to interface with Google Chromecast devices in Node (the spec is kind of complicated and unsupported by Google), it aims to use the popular and well-maintained pychromecast. I would use a native Node library, but none look anywhere near as well-maintained as pychromecast.

It is designed for audio-playback and has been developed with testing on Google Home devices, Chromecast Audio devices, and Google Cast Groups. Whether or not this will ever support non-audio devices is TBD.

🚨 This pre-alpha software!

It is not ready for even a somewhat adventurous enthusiast. If you don't understand what the code is doing, you shouldn't expect this to work for you (yet)!

In addition to being difficult to get working, the configuration details you set now will change in future versions.

Todo

  • [x] Develop interface to communicate between Node and Python
  • [x] Implement bindings for the most important Chromecast commands (play,pause,volume)
  • [x] Get a working Homebridge plugin for a single Chromecast device
  • [ ] Support for multiple devices
  • [ ] Switch support for preset operations (eg. a switch to play your favorite Spotify playlist)
  • [ ] Any support whatsoever for non-Audio devices.

Installation

This package requires both Node 8 and Python 2/3.

  1. pip install --upgrade pip
  2. pip install pychromecast
  3. sudo npm install homebridge-chromecast -g

Usage

Config sample:

"accessories": [
  {
      "accessory": "Chromecast",
      "name": "Whole Home",
      "py_path":"/Users/alex/Dropbox/homebridge-chromecast/chromecast.py"
  }
]

In this example, Whole Home is the name of my Chromecast audio device. py_path is the path to the chromecast.py script included in this plugin. This is a terrible hack but I haven't had the chance to make fix a bug with relative paths.

Once the plugin is up and running, it should add a light with dimmer controls to the Home app.

On/Off map to Play/Pause and the light brightness maps to volume. This is a terrible hack but Apple doesn't support speakers in Home.app.

Contribution

Help is welcome! Issues/PRs are appreciated. If you want to chat about this project, DM me @alexarena.