Skip to content

Instantly share code, notes, and snippets.

Last active October 26, 2022 22:41
What would you like to do?
Bash script to toggle the Sonos subwoofer via soco-cli.
# Uses via
# I map this to a HTPC keyboard key via
if [ `soco -l "Front room" sub_enabled` == "on" ]; then
soco -l "Front room" sub_enabled off : "Front room" light off
say -vDaniel "Sub off"
soco -l "Front room" sub_enabled on : "Front room" light on
say -vDaniel "Sub on"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment