Skip to main content
pwt
Virtuoso
Jan 22, 2021 2:49 PM UTC

Version 0.3 of the SoCo-CLI Sonos Command Line Controller Released

Version 0.3 of SoCo-CLI, the open source Sonos command line controller for Windows, macOS and Linux, is now available:

https://github.com/avantrec/soco-cli/blob/v0.3.5/README.md

This release adds an Interactive Shell Mode, and also provides an API to allow the use of SoCo-CLI as a simple, high level library for inclusion in other Python programs.

For those of us who enjoy using the command line to get things done, the interactive shell is fast and convenient to use. The shell is started using sonos -i, then just type ? for available commands. Most of the huge range of SoCo-CLI control commands are available:

https://github.com/avantrec/soco-cli/blob/v0.3.5/README.md#interactive-shell-mode

    This topic has been closed for further comments. You can use the search bar to find a similar topic, or create a new one by clicking Create Topic at the top of the page.

    3 replies

    Lyricist I
    Jan 27, 2021 2:56 AM UTC

    That’s really brilliant. Thank you so much.

    For Windows, I had to comment out the line where it tries to import the termios module in keystroke_capture.py (as windows doesn’t have this). Everything seems to work as expected.

    Translate
    pwt
    pwtAuthor
    Virtuoso
    Jan 28, 2021 9:44 PM UTC

    That’s really brilliant. Thank you so much.

    For Windows, I had to comment out the line where it tries to import the termios module in keystroke_capture.py (as windows doesn’t have this). Everything seems to work as expected.

    Thanks for the feedback. I’ll fix the termios import — thanks for reporting it.

    Translate
    4 x P:5 | Sub | 4 x P:1 | 3 x Connect | 2 x Boost | Connect:Amp | 2 x One | Amp | Move | Port | Era 300
    pwt
    pwtAuthor
    Virtuoso
    Feb 2, 2021 10:36 AM UTC

    Thanks for the feedback. I’ll fix the termios import — thanks for reporting it.

    Just FYI: the ‘single keystroke’ shell feature (that requires termios on Unix-y systems) is now also supported under Windows, in v0.3.19 upwards.

    https://github.com/avantrec/soco-cli/tree/v0.3.19#single-keystroke-mode

    As the name implies, it’s handy for controlling Sonos with just a single touch of the keyboard. For example, I can assign a one-character alias to an action or series of actions, then invoke with a single keypress.

    Translate
    4 x P:5 | Sub | 4 x P:1 | 3 x Connect | 2 x Boost | Connect:Amp | 2 x One | Amp | Move | Port | Era 300