pacmax beta

Alfred Pac by karimkaylani on GitHub

sonoscontroller

Control playback of your Sonos straight from Alfred!

From their README

Alfred Sonos Controller

Control playback of your Sonos speakers straight from Alfred!

INSERT YOUR GRAPHIC HERE

Installation

Download

  • Download and open the alfredworkflow file to install the workflow

Features

  • Play, Pause, Next, Previous
  • Set/Change Volume
  • View Queue
  • Play Songs from Queue (only tested on Spotify playing through Sonos app)
  • Switch to line-in playback (if supported on device)
  • Control Shuffle/Repeat

Usage

Type soco into Alfred, select or search your device, and then control it on the following screen

INSERT YOUR GRAPHIC HERE

Hotkeys

Hotkeys are added by adding a hotkey trigger on the workflow flowchart (open Alfred Preferences -> Workflows -> Sonos Controller, then right click in the empty space -> Triggers -> Hotkey) and connecting it to the run script block with a text argument that follows the following syntax. You can also edit the preset hotkey triggers by right clicking them and selecting configure object.

(sonosName); (command)

ex:

Bedroom; next

INSERT YOUR GRAPHIC HERE

INSERT YOUR GRAPHIC HERE

Commands:

plpau - Play/Pause Sonos device

play - Play Sonos device

pause - Pause Sonos device

volpcg [value] - Set volume to specified value (ex. Bedroom; volpcg 50)

chvol [value] - Change volume by a specified value

next - Go to the next song

previous - Go to the previous song

linein - Switch playback to line-in

enshuffle - Enable shuffle and disable repeat

disshuffle - Disable shuffle and disable repeat

enrepeat - Enable repeat and disable shuffle

enshuffrep - Enable shuffle and repeat

plque [position in queue] - Play a song in a certain position in queue (only tested on Spotify playing through Sonos app)

Troubleshooting

If you find yourself getting the No Speakers Found error, it may be due to an incorrect interface address. This can be caused by having a VPN active, which unfortunatley Sonos does not support.

If you are still recieving this error, you can try manually setting the interface address to your local IP address on your machine (which can be found under your Network settings) by doing the following:

  1. Open Alfred Preferences -> Workflows -> SonosController and press the [x] button in the top right corner

    This screen should appear:

    INSERT YOUR GRAPHIC HERE

  2. Double click under the value column on interface_address and enter in the address of your local IP

Acknowledgements

This workflow was built using deanishe's Alfred-Workflow

Huge shoutout to the team behind SoCo which this workflow uses heavily


License

This workflow is released under the MIT license

Latest release

  • 1.4.16 years ago, 1.4 MBDownload

    Fixed bug where searching for speakers would prompt action items.

7 earlier releases
  • 1.46 years ago, 1.4 MBDownload

    Added switch to line-in action

    <h3>Whenever the selected speaker is not in line-in mode, a switch to line-in action will appear</h3>

    Other changes:

    • Play Mode submenu now displays the current play mode
    • While in line-in mode, the current track now shows as "Audio from Line-in Device"

    INSERT YOUR GRAPHIC HERE

  • 1.3.16 years ago, 1.4 MBDownload
    • Added interface_address environment variable for those having trouble connecting to their speakers. For more info check out the Troubleshooting section on the README
    • Added some more error handling for scenarios where speakers were not found or the speaker name was missing
    • Added visual indication for when commands are executed by typing directly on the Alfred search bar
  • 1.36 years ago, 1.4 MBDownload

    Added search filtering

    Just begin typing the name of your speaker and relevant results will appear

    Note: You can still view all of your speakers by just typing <code>soco</code>

    INSERT YOUR GRAPHIC HERE

  • 1.26 years ago, 1.4 MBDownload

    Added more song info on titles/subtitles

    • Artist/Album (if applicable) now appear on songs in queue
    • Album/Duration (if applicable) now appear on current track info
  • 1.1.16 years ago, 1.4 MBDownload

    Fixed bug with international characters in speaker names

  • 1.16 years ago, 1.4 MBDownload

    Added a play/pause toggle command - can be activated on the menu or through a hotkey

    Note: The individual play and pause commands previously on the menu are removed, but they are still available as hotkeys

  • 1.06 years ago, 1.4 MBDownload