Skip to content

Commit

Permalink
[squeezebox] Add some examples to the .items file example (openhab#7925)
Browse files Browse the repository at this point in the history
* Add some example for the .items file

As I struggled to sort out exactly how to set up the .items file for the item type 'image' and define the album art channel I though the documentation could be clarified with an example or 3.

* Update README.md
  • Loading branch information
LeeC77 authored and andrewfg committed Aug 31, 2020
1 parent f620d2c commit d7fb82b
Showing 1 changed file with 11 additions and 1 deletion.
12 changes: 11 additions & 1 deletion bundles/org.openhab.binding.squeezebox/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -115,6 +115,16 @@ All devices support some of the following channels:
| numberPlaylistTracks | Number | Number of playlist tracks |
| playFavorite | String | ID of Favorite to play (channel's state options contains available favorites) |

## Example .Items File

Add the items you want to the .items file. A few examples are shown below, the power, volume and album art channels are connected here to the items by copying across the channel discriptions from the Paper UI. Make suure each channel is linked for your needs See [openHAB New User Configuration documentation](https://www.openhab.org/docs/tutorial/configuration.html) for further details on linking and channels.

```
Switch YourPlayer_Power "Squeezebox Power" {channel="squeezebox:squeezeboxplayer:736549a3:00042016e7a0:power"}
Dimmer YourPlayer_Volume "Squeezebox Volume" {channel="squeezebox:squeezeboxplayer:736549a3:00042016e7a0:volume"}
Image YourPlayer_AlbumArt "Squeezebox Cover" {channel="squeezebox:squeezeboxplayer:736549a3:00042016e7a0:coverartdata"}
```

## Playing Favorites

Using the **playFavorite** channel, you can play a favorite from the *Favorites* list on the Logitech Media Server (LMS).
Expand All @@ -128,7 +138,7 @@ Currently, only favorites from the root level of the LMS favorites list are expo
- Add some favorites to your favorites list in LMS (local music playlists, Pandora, Slacker, Internet radio, etc.).
Keep all favorites at the root level (i.e. favorites in sub-folders will be ignored).

- If you're on an older openHAB build, you may need to delete and readd your squeezebox server and player things to pick up the new channels.
- If you're on an older openHAB build, you may need to delete and re-add your squeezebox server and player things to pick up the new channels.

- Create a new item on each player

Expand Down

0 comments on commit d7fb82b

Please sign in to comment.