quad.playercontrol
Player Control and Status Info, for Squeezebox, Infrared control, etc.
Parameters
{{ quad.playercontrol(id, linetext, item_previous, item_play, item_pause, item_stop, item_next, item_power, item_eject, item_repeat, item_shuffle, source, item_mute, item_volume, item_volumeup, item_volumedown, volume_min, volume_max, volume_step, volume_min_display, volume_max_display, volume_threshold, item_album, item_artist, item_title, item_time, item_duration, item_speaker, item_uzsu, uzsu_attribs, item_plot, icon_plot, item_auto, extpopup, coverUrl, place1, place2, column_order) }}
id
unique id for this widget
linetext
text for the whole line
item_previous
a gad/item for the previous title
item_play
a gad/item for play command
item_pause
a gad/item for pause command
item_stop
a gad/item for stopping
item_next
a gad/item for the next title
item_power
a gad/item for turning power on/off
item_eject
a gad/item to eject
item_repeat
a gad/item to repeat. 0 = off. 1 = song. 2 = playlist
item_shuffle
a gad/item to shuffle. 0 = off. 1 = song. 2 = album
source
array providing these information: [item to change source/playlist, select-type, [value1, icon1, text1], [value2, icon2, text2], etc.]
item_mute
a gad/item to set mute
item_volume
a gad/item to set the volume
item_volumeup
a gad/item to increase volume
item_volumedown
a gad/item to decrease volume
volume_min
minimum value for volume
volume_max
maximum value for volume
volume_step
step for volume slider
volume_min_display
minimum value shown on slider
volume_max_display
maximum value shown on slider
volume_threshold
change volume color to red when above threshold
item_album
a gad/item for current album. To show album art, add a subitem called currentalbumarturl
for squeezebox put this in the item: value: 'http://IP:PORT/music/current/cover.jpg?player=MACADDRESS'
item_artist
a gad/item for current artist
item_title
a gad/item for current title
item_time
a gad/item for current time
item_duration
a gad/item for duration of current title
item_speaker
(array of) gad/item for setting speakers A/B
item_uzsu
a gad/item for UZSU
uzsu_attribs
Array with standard UZSU parameters: pic_on, pic_off, valueType, valueParameterList, color_on, color_off. (optional)
item_plot
array with all plot.period attributes to show a plot in popup. Alternatively just the item to be plotted.
icon_plot
icon triggering the plot popup
item_auto
"root item" which holds stateengine information. show current state of stateengine/stateengine item. Adjust icons and states below accordingly
extpopup
Array of arrays for extended popup window. Use this to create an icon to open a popup with switches, sliders, flips or select menues.
First entry can either be "stateengine" to make the stateengine plugin icon the trigger for the popup or an icon (e.g. time_automatic).
After that you have to create an array for each line of the popup. In this array you first define the elements like switch, text, etc.,
followed by the attributes for each element as you would for the basic widget.
Possible elements are: header, text, slider, flip, switch, select
Example: ['stateengine', ['header', 'Suspendzeit'], [['switch', 'slider'], [switch_item, 'icon', [0,1], ['secur_open','secur_locked']],
[slider_item, slider_min, slider_max, slider_step, '', 'handle']]
coverUrl
the path/url or item to the image. For squeezebox create an item with the following value: 'http://IP:PORT/music/current/cover.jpg?player=MACADDRESS'
place1
placeholder attributes for future features, etc.
place2
placeholder attributes for future features, etc.
column_order
array with element description: Reorder elements to your liking (esp. relevant for smartphones as several columns might be too much)
possible elements are: 'previous', 'play', 'pause', 'stop', 'next', 'power', 'eject', 'mute', 'volume_slider', 'cover',
'volume_popup', 'volume_up', 'volume_down', 'song_position', 'uzsu', 'plot', 'stateengine', 'repeat', 'source', 'speaker', 'playpause', 'playstop', 'playpausestop', 'shuffle', 'source_popup'
For empty columns either use ' ' or a number to define the column width (e.g. '40' = 40 pixels width)
Combine elements in one column by putting them in arrays.
Example
Volume Control with the following columns: ['uzsu','plot',['volume_up','volume_down'],'volume_slider']
{{ quad.playercontrol('volume', 'Volume Slider, UZSU and Plot', '', '', '', '', '', '', '', '', '', '', 'Mute', 'Volume', 'VolumeUp', 'VolumeDown', 0, 100, 1, 0, 100, 80, '', '', '', '', '', 'speakerAB', 'uzsu', ['', '', 'uzsu_value', '', 'icon1', 'icon0'], 'Volume.Plot', '', '', '', '', '', '', ['uzsu','plot',['volume_up','volume_down'],'volume_slider']) }}
-
Player Control with standard columns
{{ quad.playercontrol('player', 'Squeezebox', 'Previous', '', 'Pause', 'Stop', 'Next', '', 'Eject', 'Repeat', 'Shuffle', '', 'Mute', 'Volume', 'VolumeUp', 'VolumeDown', 0, 100, 1, 0, 100, 80, 'Album', 'Artist', 'Title', 'Time', 'Duration', '', 'uzsu', '', 'Plot') }}
Player Control with ['uzsu','plot',['volume_down','volume_up','power'], 'source']
{{ quad.playercontrol('player2', 'Source as Icons', 'Previous', 'Play', 'Pause', 'Stop', 'Next', 'Power', 'Eject', 'Repeat', 'Shuffle', ['Source', 'icon', ['10', 'edit_numeric_1.svg'], ['13', 'edit_numeric_2.svg']], 'Mute', 'Volume', 'Volume_Up', 'Volume_Down', 0, 100, 1, 0, 100, 80, 'Album', 'Artist', 'Title', 'Time', 'Duration', 'speakerAB', 'uzsu', '', 'Plot', '', '', '', '', '', '', ['uzsu','plot',['volume_down','volume_up','power'], 'source']) }}
-
Player Control with [['pause', 'stop'], ['cover', 'album'], 'shuffle', 'song_position']
{{ quad.playercontrol('player3', 'With Album Art', 'Previous', 'Play', 'Pause', 'Stop', 'Next', 'Power', 'Eject', 'Repeat', 'Shuffle', ['Source', 'menu', ['10', '', '10'], ['13', '', '13']], 'Mute', 'Volume', 'Volume_Up', 'Volume_Down', 0, 100, 1, 0, 100, 80, 'Album', 'Artist', 'Title', 'Time', 'Duration', '', 'uzsu', '', 'Plot', '', '', '', '', '', '', [['pause', 'stop'], ['cover', 'album'], 'shuffle', 'song_position']) }}