Skip to content

A WiFi enabled GPIO physical volume knob for Chromecasts

License

Notifications You must be signed in to change notification settings

mrjones-plip/Cattrotar

Repository files navigation

Cattrotar

Use a Raspbery Pi, a GPIO rotary encoder and optionally a screen to control the volume of your chromecast. This a port of Cattmate to use GPIO devices instead of USB devices.

Status

This project is considered stable and working except mute. See #3.

Hardware

Install

These steps assume you have your Pi set up with Raspbian, that it's booted up, connected to the same WiFi as your Chromecast. If your Chromecast is on a different network, but you can get to it by IP, the config supports IPs instead of Chromecast names. It also assumes you're using the pi default user with a home directory of /home/pi and that you have python3, pip3 and optionally virtualenv installed:

  1. Clone this repo and cd into it: git clone https://github.com/Ths2-9Y-LqJt6/cattrotar.git /home/pi/cattrotar; cd /home/pi/cattmate
  2. Create your own virtualenv and activate it python3 -m venv venv;. venv/bin/activate (optional)
  3. Install all the python prerequisites with pip3 install -r requirements.txt
  4. Connect your rotary encoder to these GPIO pins. You're welcome to use different ones, but be sure to update your config.py on the next step. See this diagram to help get you started (thx Pi Hut):
    clk = 17
    dt = 18
    sw = 23
    + = 3.3
    GND = Ground 
  5. Create your own config file cp config.dist.py config.dist and edit config.dist if needed:
    1. names or IPs of the chromecasts you want to use (ony first one supported right now ;)
    2. whether you want to use an external I2C screen or not
    3. the pins you'll use for the rotary encoder
  6. Copy the systemd file into place, reload systemd, start and enable it:
    sudo cp cattrotar.service /etc/systemd/system/
    sudo systemctl daemon-reload
    sudo systemctl enable cattrotar
    sudo systemctl start cattrotar

You should be good to go!

Troubleshooting

You can debug the system in syslog with sudo tail -f /var/log/syslog. I try to do a lot of testing and have except errors that explicitly tell you what went wrong and how to fix it. If all else fails, open an issue and I'l try and help ya!

Orange Pi Support

I've added experimental support for Orange Pi Zero boards. The screen doesn't work and I've had problems getting around details as seen in #4, but it does work if you do some hand holding!

Releases

  • 3 mar 2020 v0.2 - All working except mute (see #3). Fixed #1
  • 24 Feb 2020 v0.1 - First Post!

About

A WiFi enabled GPIO physical volume knob for Chromecasts

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages