Ankündigung

Einklappen
Keine Ankündigung bisher.

- √ - Neues Plugin: Logitech Squeezebox - Anregungen?

Einklappen
X
 
  • Filter
  • Zeit
  • Anzeigen
Alles löschen
neue Beiträge

  • Orion
    antwortet
    Hallo macflei,

    vielen Dank, funktioniert. Es hat etwas gedauert, bis ich den Pfad wirklich gefunden hatte. Es geht auch komplett mit der HTML Autogenerierung, man verliert die Stations Ions. Aber sonst funktioniert dort alles !

    Grüße

    Michel

    Einen Kommentar schreiben:


  • macflei
    antwortet
    Zitat von Orion Beitrag anzeigen
    .... bzw. muss ich den bei meinem Logitech Medien Server irgendwie anpassen ?
    Du muß Playlists erstellen/abspeichern.
    Wenn Du eine Playlist erstellt hast (zum Besipiel ein Album geladen und dann als Playlist abgespeichert), mußt Du den Pfad zum Speicherort dieser Playlist dann in die Codezeile einfügen. Für jedem Radiosender erstellst Du ebenfalls eine Playlist.

    Code:
    squeezebox_send = <playerid> playlist play /pfad/zur/playlsit.m3u

    Einen Kommentar schreiben:


  • Orion
    antwortet
    Hallo macflei,

    vielen Dank, werde ich ausprobieren. Kannst Du mir noch sagen, wie der Befehl

    Code:
        squeezebox_send = <playerid> playlist play /mnt/hd1/media/playlists/Bocelli.m3u
    Entstanden ist bzw. muss ich den bei meinem Logitech Medien Server irgendwie anpassen ?

    Danke Dir

    Michel

    Einen Kommentar schreiben:


  • macflei
    antwortet
    Zitat von Orion Beitrag anzeigen
    Hallo macflei,
    ....ich warte auf Deine Codeschnipsel.
    Wie versprochen die Codebeispiele.
    Es ist ein Beispiel für einen Player inkl. Playlisten.
    Bei mir sind verschiedene Bedienfunktionen zusätzlich auf Tastsensoren gelegt oder in Szenen eingebunden. Deshalb die GA`s im Code.
    Die Album-Cover hab ich via Gimp angepasst (abgerundete Ecken, skalieren)

    Auszug aus /usr/smarthome/items/squeezebox.conf
    Code:
    [Squeezebox_Bad]
      squeezebox_playerid = 00:04:20:2a:87:b7
      [[Name]]
        type = str
        visu_acl = rw
        squeezebox_send = <playerid> name {}   
        squeezebox_recv = <playerid> name  
      [[IP]]
        type = str
        visu_acl = rw
        squeezebox_recv = player ip <playerid>   
      [[Signal_Strength]]
        type = str
        visu_acl = rw
        squeezebox_recv = <playerid> signalstrength
      [[Power]]
        type = bool
        visu_acl = rw
        knx_dpt = 1
        knx_listen = 3/0/0
        squeezebox_send = <playerid> power {}
        squeezebox_recv = <playerid> prefset server power
        squeezebox_init = <playerid> power    
        
      [[Mute]]
        type = bool
        visu_acl = rw
        knx_dpt = 1
        knx_listen = 3/0/5
        knx_send = 3/0/5
        squeezebox_send = <playerid> mixer muting {}
        squeezebox_recv = <playerid> prefset server mute
        squeezebox_init = <playerid> mixer muting
      [[Volume]]
        type = num
        visu_acl = rw
        knx_dpt = 5
        knx_listen = 3/0/4
        knx_send = 3/0/4
        squeezebox_send = <playerid> mixer volume {}
        squeezebox_recv = <playerid> prefset server volume
        squeezebox_init = <playerid> mixer volume    
      [[Volume_Up]]
        type = bool
        enforce_updates = true
        visu_acl = rw
        squeezebox_send = <playerid> button volup
      [[Volume_Down]]
        type = bool
        enforce_updates = true
        visu_acl = rw
        squeezebox_send = <playerid> button voldown
        
      [[Play]]
        type = bool
        visu_acl = rw
        knx_dpt = 1
        knx_listen = 3/0/1
        knx_send = 3/0/1
        squeezebox_send = <playerid> play
        squeezebox_recv = <playerid> play
        squeezebox_init = <playerid> mode
      [[Stop]]
        type = bool
        visu_acl = rw
        knx_dpt = 1
        knx_listen = 3/0/3
        knx_send = 3/0/3
        squeezebox_send = <playerid> stop
        squeezebox_recv = <playerid> stop
        squeezebox_init = <playerid> mode
      [[Pause]]
        type = bool
        visu_acl = rw
        knx_dpt = 1
        knx_listen = 3/0/2
        knx_send = 3/0/2
        squeezebox_send = <playerid> pause {}
        squeezebox_recv = <playerid> pause
        squeezebox_init = <playerid> mode
      [[Repeat]]
        type = num
        visu_acl = rw
        enforce_updates = yes
        squeezebox_send = <playerid> playlist repeat {}
        squeezebox_recv = <playerid> playlist repeat
      [[Repeat_Song]]
        type = bool
        visu_acl = rw
        enforce_updates = yes
        squeezebox_send = <playerid> playlist repeat 1
      [[Repeat_Playlist]]
        type = bool
        visu_acl = rw
        enforce_updates = yes
        squeezebox_send = <playerid> playlist repeat 2
      [[Repeat_None]]
        type = bool
        visu_acl = rw
        enforce_updates = yes
        squeezebox_send = <playerid> playlist repeat 0
      [[Current_Title]]
        type = str
        visu_acl = rw
        squeezebox_recv = <playerid> playlist newsong
        squeezebox_init = <playerid> current_title
      [[Genre]]
        type = str
        visu_acl = rw
        squeezebox_recv = <playerid> genre
      [[Artist]]
        type = str
        visu_acl = rw
        squeezebox_recv = <playerid> artist
      [[Album]]
        type = str
        visu_acl = rw
        squeezebox_recv = <playerid> album
      [[Title]]
        type = str
        visu_acl = rw
        squeezebox_recv = <playerid> title
      [[Duration]]
        type = num
        visu_acl = rw
        squeezebox_recv = <playerid> duration
      [[Time]]
        type = num
        visu_acl = rw
        squeezebox_recv = <playerid> playlist time
      [[TimePlus]]
        type = num
        visu_acl = rw
        enforce_updates = true
        squeezebox_recv = <playerid> time
        squeezebox_send = <playerid> time +10
      [[TimeMinus]]
        type = num
        visu_acl = rw
        enforce_updates = true
        squeezebox_recv = <playerid> time
        squeezebox_send = <playerid> time -10
      [[Playlist_Index]]
        type = num
        visu_acl = rw
        squeezebox_send = <playerid> playlist index {}
        squeezebox_recv = <playerid> playlist index
      [[Playlist_Forward]]
        type = bool
        enforce_updates = true
        visu_acl = rw
        knx_dpt = 1
        knx_listen = 3/0/6
        squeezebox_send = <playerid> playlist index +1
      [[Playlist_Backward]]
        type = bool
        enforce_updates = true
        visu_acl = rw
        knx_dpt = 1
        knx_listen = 3/0/7
        squeezebox_send = <playerid> playlist index -1
        
      [[Playlist_Name]]
        type = str
        visu_acl = rw
        squeezebox_send = <playerid> playlist name {}
        squeezebox_recv = <playerid> playlist name
      [[Playlist_Save]]
        type = str
        visu_acl = rw
        squeezebox_send = <playerid> playlist save {}   
      [[Playlist_Load]]
        type = str
        enforce_updates = true
        visu_acl = rw
        squeezebox_send = <playerid> playlist play {}
    
      [[Playlist_Load_Bayern3]]
        type = bool
        enforce_updates = true
        visu_acl = rw
        squeezebox_send = <playerid> playlist play /mnt/hd1/media/playlists/Bayern3.m3u
    
      [[Playlist_Load_AntenneBayern]]
        type = bool
        enforce_updates = true
        visu_acl = rw
        squeezebox_send = <playerid> playlist play /mnt/hd1/media/playlists/AntenneBayern.m3u
    
      [[Playlist_Load_Cafe80s]]
        type = bool
        enforce_updates = true
        visu_acl = rw
        squeezebox_send = <playerid> playlist play /mnt/hd1/media/playlists/Cafe80s.m3u
    
      [[Playlist_Load_Bayern1]]
        type = bool
        enforce_updates = true
        visu_acl = rw
        squeezebox_send = <playerid> playlist play /mnt/hd1/media/playlists/Bayern1.m3u
    
      [[Playlist_Load_RadiArabella]]
        type = bool
        enforce_updates = true
        visu_acl = rw
        squeezebox_send = <playerid> playlist play /mnt/hd1/media/playlists/RadioArabelle.m3u
    
      [[Playlist_Load_Radio80s]]
        type = bool
        enforce_updates = true
        visu_acl = rw
        squeezebox_send = <playerid> playlist play /mnt/hd1/media/playlists/Radio80s.m3u
    
      [[Playlist_Load_RockAntenne]]
        type = bool
        enforce_updates = true
        visu_acl = rw
        squeezebox_send = <playerid> playlist play /mnt/hd1/media/playlists/RockAntenne.m3u
    
      [[Playlist_Load_AntenneBayern80s]]
        type = bool
        enforce_updates = true
        visu_acl = rw
        squeezebox_send = <playerid> playlist play /mnt/hd1/media/playlists/AntenneBayern80s.m3u
    
      [[Playlist_Load_antennemv]]
        type = bool
        enforce_updates = true
        visu_acl = rw
        squeezebox_send = <playerid> playlist play /mnt/hd1/media/playlists/antennemv.m3u
    
      [[Playlist_Load_Bocelli]]
        type = bool
        enforce_updates = true
        visu_acl = rw
        squeezebox_send = <playerid> playlist play /mnt/hd1/media/playlists/Bocelli.m3u
    
    
      [[Playlist_Load_helloween]]
        type = bool
        enforce_updates = true
        visu_acl = rw
        squeezebox_send = <playerid> playlist play /mnt/hd1/media/playlists/helloween.m3u
    
    
      [[Playlist_Load_pogues]]
        type = bool
        enforce_updates = true
        visu_acl = rw
        squeezebox_send = <playerid> playlist play /mnt/hd1/media/playlists/pogues.m3u
    
    
      [[Playlist_Load_ami]]
        type = bool
        enforce_updates = true
        visu_acl = rw
        squeezebox_send = <playerid> playlist play /mnt/hd1/media/playlists/ami.m3u
    
    
      [[Playlist_Load_eav]]
        type = bool
        enforce_updates = true
        visu_acl = rw
        squeezebox_send = <playerid> playlist play /mnt/hd1/media/playlists/eav.m3u
    
    
      [[Playlist_Load_edguy]]
        type = bool
        enforce_updates = true
        visu_acl = rw
        squeezebox_send = <playerid> playlist play /mnt/hd1/media/playlists/edguy.m3u
    
    
      [[Playlist_Load_freedomcall]]
        type = bool
        enforce_updates = true
        visu_acl = rw
        squeezebox_send = <playerid> playlist play /mnt/hd1/media/playlists/freedomcall.m3u
    
    
      [[Playlist_Load_manowar]]
        type = bool
        enforce_updates = true
        visu_acl = rw
        squeezebox_send = <playerid> playlist play /mnt/hd1/media/playlists/manowar.m3u
    
      [[Playlist_Load_Gong]]
        type = bool
        enforce_updates = true
        visu_acl = rw
        knx_dpt = 1
        knx_listen = 3/0/16
        knx_send = 3/0/16
        squeezebox_send = <playerid> playlist play /mnt/hd1/media/playlists/gong.m3u
    
      [[Playlist_Load_OMD]]
        type = bool
        enforce_updates = true
        visu_acl = rw
        knx_dpt = 1
        knx_listen = 3/0/17
        knx_send = 3/0/17
        squeezebox_send = <playerid> playlist play /mnt/hd1/media/playlists/OMD.m3u
    
      [[Playlist_Load_Playlist1]]
        type = bool
        enforce_updates = true
        visu_acl = rw
        knx_dpt = 1
        knx_listen = 3/0/13
        knx_send = 3/0/13
        squeezebox_send = <playerid> playlist play /mnt/hd1/media/playlists/PlaylistParty.m3u
      [[Playlist_Load_Playlist2]]
        type = bool
        enforce_updates = true
        visu_acl = rw
        knx_dpt = 1
        knx_listen = 3/0/14
        knx_send = 3/0/14
        squeezebox_send = <playerid> playlist play /mnt/hd1/media/playlists/PlaylistTV.m3u
      [[Playlist_Load_Playlist3]]
        type = bool
        enforce_updates = true
        visu_acl = rw
        knx_dpt = 1
        knx_listen = 3/0/15
        knx_send = 3/0/15
        squeezebox_send = <playerid> playlist play /mnt/hd1/media/playlists/PlaylistEssen.m3u
    Auszug aus /var/www/smartvisu/pages/mac/page.squeeze.html
    Code:
    {% extends "rooms.html" %}
    
    {% block content %}
    
            <div class="block">
        <div class="set-2" data-role="collapsible-set" data-theme="c" data-content-theme="a" data-mini="true">
            <div data-role="collapsible" data-collapsed="false" >
                <h3>{{ basic.value('Name1', 'Squeezebox_Bad.Name') }}-{{ basic.value('IP1', 'Squeezebox_Bad.IP') }}-{{ basic.value('Signal1', 'Squeezebox_Bad.Signal_Strength', '%') }}</h3>
                {% import "widget_squeezebox.html" as squeezebox %}
                 {{ squeezebox.control('music2', 'Squeezebox_Bad.Power', 'Squeezebox_Bad.Play', 'Squeezebox_Bad.Pause', 'Squeezebox_Bad.Stop', 'Squeezebox_Bad.Playlist_Forward', 'Squeezebox_Bad.Playlist_Backward', 'Squeezebox_Bad.TimePlus', 'Squeezebox_Bad.TimeMinus', 'Squeezebox_Bad.Volume', 'Squeezebox_Bad.Mute', 'Squeezebox_Bad.Title', 'Squeezebox_Bad.Artist', 'Squeezebox_Bad.Repeat', 'Squeezebox_Bad.Repeat_Playlist', '', 'Squeezebox_Bad.Duration', '') }}    
            
        </div>    
        <div data-role="collapsible">
          <h3>Playlisten</h3>
                ------ Radio ------
    {% import "multimedia.html" as multimedia %}
        <table width="100%">
            <tr>
            <td align="middle" width="100%">
                    {{ multimedia.station('CH1', 'Squeezebox_Bad.Playlist_Load_AntenneBayern', 'pics/station/Radio/antennebayern.png', 1, 'midi') }}
                    {{ multimedia.station('CH2', 'Squeezebox_Bad.Playlist_Load_Bayern1', 'pics/station/Radio/s24854q.png', 1, 'midi') }}
                    {{ multimedia.station('CH3', 'Squeezebox_Bad.Playlist_Load_Bayern3', 'pics/station/Radio/Bayern3.png', 1, 'midi') }}
                    {{ multimedia.station('CH4', 'Squeezebox_Bad.Playlist_Load_antennemv', 'pics/station/Radio/antennemv.png', 1, 'midi') }}
            </td>
            </tr>
        </table><br>
                ----- Alben -----
        <table width="100%">
            <tr>
            <td align="middle" width="100%">
                     {{ multimedia.station('CH5', 'Squeezebox_Bad.Playlist_Load_pogues','pics/station/Playlists/pogues12.png', 1, 'midi') }}
                     {{ multimedia.station('CH6', 'Squeezebox_Bad.Playlist_Load_manowar','pics/station/Playlists/manowar.png', 1, 'midi') }}
                     {{ multimedia.station('CH7', 'Squeezebox_Bad.Playlist_Load_freedomcall','pics/station/Playlists/freedomcall.png', 1, 'midi') }}
                     {{ multimedia.station('CH8', 'Squeezebox_Bad.Playlist_Load_edguy','pics/station/Playlists/edguy.png', 1, 'midi') }}
            </td>
            </tr>
        </table>
        <table width="100%">
            <tr>
            <td align="middle" width="100%">
                     {{ multimedia.station('CH9', 'Squeezebox_Bad.Playlist_Load_helloween','pics/station/Playlists/helloween.png', 1, 'midi') }}
                     {{ multimedia.station('CH10', 'Squeezebox_Bad.Playlist_Load_eav','pics/station/Playlists/eav.png', 1, 'midi') }}
                     {{ multimedia.station('CH11', 'Squeezebox_Bad.Playlist_Load_ami','pics/station/Playlists/ami1.png', 1, 'midi') }}
                     {{ multimedia.station('CH12', 'Squeezebox_Bad.Playlist_Load_Bocelli','pics/station/Playlists/bocelli.png', 1, 'midi') }}
            </td>
            </tr>
        </table>
    
        </div>
    
        </div>
        </div>
    {% endblock %}
    /var/www/smartvisu/pages/mac/widget_squeezebox.html
    Code:
    /**
     * -----------------------------------------------------------------------------
     * @package     smartVISU
     * @author      Martin Gleiß
     * @copyright   2012
     * @license     GPL <http://www.gnu.de>
     * -----------------------------------------------------------------------------
     */
    
    /**
     * Squeezebox Multimedia Player
     * 
     * @param       unique id for this widget
     * @param       the gad/item for play
     * @param       the gad/item for pause
     * @param       the gad/item for stop (optional)
     * @param       the gad/item for playlist forward
     * @param       the gad/item for playlist backward
     * @param       the gad/item for playlist fastforward (opuional)
     * @param       the gad/item for playlist fastbackward (opuional)
     * @param       the gad/item for the volume (optional)
     * @param       the gad/item to mute the music (optional)
     * @param       the gad/item for the song title (optional)
     * @param       the gad/item for the song artist (optional)
     * @param       the gad/item for repeat (optional)
     * @param       the gad/item to repeat all (optional)
     * @param       the gad/item for the duration (optional)
     * @param       the gad/item for the time/position (optional)
     * @param       the gad/item for the playlist index (optional)
     * @param       the gad/item for the playlist total (optional)
     *
     * @author      Robert Budde
     * derived from "multimedia" by Axel Otterstätter - thanks!
     */
    {% macro control(id, gad_power, gad_play, gad_pause, gad_stop, gad_playlistforward, gad_playlistbackward, gad_playlistfastforward, gad_playlistfastbackward, gad_vol, gad_mute, gad_title, gad_artist, gad_repeat, gad_repeatall, gad_defaultplaylist, gad_duration, gad_time) %}
        {% import "basic.html" as basic %}
        {% import "widget_my.html" as my %}
        {% set uid = uid(page, id) %}
    
        <div id="{{ uid }}" class="music">
            
            {% if gad_vol %}
            <div class="vol">
                <img class="slider-bottomup-scale" src="pages/base/pics/scale_buttomup.png">
                {{ basic.slider(id~'vol', gad_vol, 0, 100, 5, 'bottomup') }}
            </div>
            {% endif %}
    
    
            <div class="control">
            {% if gad_power %} {{ basic.dual(id~'power', gad_power, icon1~'control_standby.png', icon0~'control_standby.png') }} {% endif %}
            {% if gad_mute %} {{ basic.dual(id~'mute', gad_mute, icon1~'audio_volume_mute.png', icon0~'audio_volume_mute.png', 1, 0) }} {% endif %}
            {% if gad_repeat %} {{ basic.dual(id~'repeat', gad_repeat, icon1~'control_return.png', icon0~'control_return.png', 1, 0) }} {% endif %}
            {% if gad_repeatall %} {{ basic.dual(id~'repeatall', gad_repeatall, icon1~'audio_repeat.png', icon0~'audio_repeat.png') }} {% endif %}
            {% if gad_defaultplaylist %} {{ basic.button(id~'defaultplaylist', gad_defaultplaylist, 'Default Playlist', icon0~'audio_playlist.png', 1) }} {% endif %}
            </div>
    
            <div class="title">
              {% if gad_artist %}
              {{ basic.value(id~'artist', gad_artist) }}
              <br />
              {% endif %}
              {% if gad_title %}
              {{ basic.value(id~'title', gad_title) }}
              {% endif %}
              <br />
              {% if gad_playlistist %}
              {% if gad_playlisttotal %}
              {{ basic.value(id~'playlistist', gad_playlistist) }} von {{ basic.value(id~'playlisttotal', gad_playlisttotal) }}
              {% endif %}
              {% endif %}
            </div>
    
            <div class="set">
                {% if gad_duration %}
                {% if gad_time %}
                <div class="pos">
                    <div class="scale">&nbsp;</div>
                    {{ my.time_slider(id~'time', gad_time, gad_duration, 1) }}
                </div>
                {% endif %}
                {% endif %}
    
                <div data-role="controlgroup" data-type="horizontal">
                    {{ basic.dual(id~'play', gad_play, icon1~'audio_play.png', icon0~'audio_play.png', 1, 1) }}
                    {{ basic.dual(id~'pause', gad_pause, icon1~'audio_pause.png', icon0~'audio_pause.png') }}
                    {% if gad_stop %} {{ basic.dual(id~'stop', gad_stop, icon1~'audio_stop.png', icon0~'audio_stop.png', 1, 1) }} {% endif %}
               </div>
                <div data-role="controlgroup" data-type="horizontal">
                    {{ basic.button(id~'playlistbackward', gad_playlistbackward, 'backward', icon0~'control_arrow_left.png', 1) }}
                    {% if gad_playlistfastbackward %} {{ basic.button(id~'gad_playlistfastbackward', gad_playlistfastbackward, 'fastbackward', icon0~'control_arrow_leftward.png', 1) }} {% endif %}
                    {% if gad_playlistfastforward %} {{ basic.button(id~'playlistfastforward', gad_playlistfastforward, 'fastforward', icon0~'control_arrow_rightward.png', 1) }} {% endif %}
                    {{ basic.button(id~'playlistforward', gad_playlistforward, 'forward', icon0~'control_arrow_right.png', 1) }}
               </div>
           </div>
        </div>
    {% endmacro %}
    Danke nochmals an Robert für das tolle Plugin.

    Einen Kommentar schreiben:


  • macflei
    antwortet
    Hi Michel,
    komme leider erst am Wochenende dazu.
    Ist aber auch nichts spektakuläres. Wenn Du nicht warten kannst oder willst, kannst Du Dir ja mal multimedia.station anschauen.
    Die Cover hab ich mit GIMP angepasst. Geht sehr fix.
    Zum Autogenerator kann ich nichts sagen, da ich diesen nicht benutze.



    GruSS
    macflei

    mobil gesendet

    Einen Kommentar schreiben:


  • Orion
    antwortet
    Hallo macflei,

    vielen Dank für die Rückmeldung, ich warte auf Deine Codeschnipsel. Mit den Ions zur Auswahl ist genau das, was ich gesucht hatte. Geht das dann auch per Autogegenrierung der sh, oder mach ich da viel manuell im HTML5 code ?

    Grüße

    Michel

    Einen Kommentar schreiben:


  • adm1024
    antwortet
    Alarms notifications ...

    Hello,

    I add alarms notifications in the plugin.
    Two new items are added :
    alarm : set to '1' when an alarm starts and '0' when the alarm stops
    snooze : set to '1' when the alarm is snoozed and '0' at the end of the snooze
    Here the plugin code :
    Code:
                    elif (data[1] == 'stop'):
                        self._update_items_with_data([data[0], 'play', '0'])
                        self._update_items_with_data([data[0], 'stop', '1'])
                        self._update_items_with_data([data[0], 'pause', '0'])
                        return
    [B]                elif (data[1] == 'alarm'):
                        if (data[2] == 'sound'):
                            self._update_items_with_data([data[0], 'alarm', '1'])
                        if (data[2] == 'end'):
                            self._update_items_with_data([data[0], 'alarm', '0'])
                        if (data[2] == 'snooze'):
                            self._update_items_with_data([data[0], 'snooze', '1'])
                        if (data[2] == 'snooze_end'):
                            self._update_items_with_data([data[0], 'snooze', '0'])
                        return[/B]
                    elif (data[1] == 'pause'):
    and for items side :
    Code:
      [[Alarm]]
        type = bool
        visu = yes
        squeezebox_recv = <playerid> alarm
    
      [[Snooze]]
        type = bool
        visu = yes
        squeezebox_recv = <playerid> snooze
    Robert, you can commit this change if you want.

    Thanks for feedback.

    Regards

    Einen Kommentar schreiben:


  • adm1024
    antwortet
    thanks Robert.
    I will try it.

    Regards

    Einen Kommentar schreiben:


  • Robert
    antwortet
    Zitat von adm1024 Beitrag anzeigen
    I have a question for Robert : is it possible to send or receive order to the LMS server via the plugin on Logics side ?
    Hi.

    Please elaborate more.

    I just checked in 'squeezebox_recv' logic trigger - you should be able to use multiple "recv-strings" in the attribute - also you can use 'squeezebox_playerid' like with the items.

    BR
    Robert

    Einen Kommentar schreiben:


  • adm1024
    antwortet
    Autoplay Logics script

    Hello and thanks for your feedback.
    The behaviour need is to have a autoplay everywhere you push the power button, physical on the box, on smartvisu or via knx GA. It always start to play the current song. The Logics script can be modified to test if play is not already on for example when the alarm starts. I working on it ...
    I made a similar config on linknx and now I try to rebuild it on smarthome.py to learn and understand to product.

    I have a question for Robert : is it possible to send or receive order to the LMS server via the plugin on Logics side ?

    Regards

    Einen Kommentar schreiben:


  • JuMi2006
    antwortet
    Nice contribution, someone tested to send just the "play" string while Squeezebox is powered off? As far i remember from my perl code Squeezebox starts to play last playlist also.

    Edit:
    Tested just now with a Boom, this might also work with favorites.

    Einen Kommentar schreiben:


  • adm1024
    antwortet
    Autoplay on 'Power On' event

    Hello,
    I wrote a small logics script to start to play song directly when a squeezebox is powered on.
    Here the sq_autoplay.py file placed in logics dir :
    Code:
    #!/usr/bin/env python
    #*************************************************
    #* sq_autoplay : logics for SmartHome.py to play *
    #* the song directly when the power turn on      *
    #* You need to add the logic.conf bloc to active *
    #* it on Power event from all the squeezeboxes   *
    #*************************************************
    #* [sq_autoplay]                                 *
    #*     filename = sq_autoplay.py                 *
    #*     watch_item = *.Power                      *
    #*************************************************
    if trigger['value']:
        # source format : item path <squeezebox>.Power
        item = sh.return_item(trigger['source'])
        # get parent to have all the squeezebox functions
        parent = item.return_parent()
        # change the Play value to start 
        parent.Play('True');
    As said in the sccript you need to add a bloc in logic.conf file to activate it :
    Code:
    [sq_autoplay]
        filename = sq_autoplay.py
        watch_item = *.Power
    This is my first contribution. I hope that I used smarthome.py objects as we do.

    Thanks for your feedback.

    Regards

    Einen Kommentar schreiben:


  • macflei
    antwortet
    Zitat von Orion Beitrag anzeigen
    da wäre es super, wenn es einen Taste 1...6 gäbe, um die programmierten Sender auszuwählen.
    Ich habe das bei mir z.B. für den Player im Bad so gelöst ...... s.unten
    Beispielcodes etc. kann ich jedoch erst morgen posten.

    Zitat von Orion Beitrag anzeigen
    Was mir noch aufgefallen ist: Mute funktioniert bei mir nicht, das An/Aus habe ich auch nicht gefunden.
    Gehen aber beide. Beispielcodes leider frühestens morgen.

    Zitat von Orion Beitrag anzeigen
    Geht denn prinzipiell jeder Befehl, den der Server kann ?
    Ich hab das Plugin bereits "extrem" getestet. Bisher ging jeder Befehl den ich gebraucht habe. Gehört "teilweise" etwas Zeit dazu.
    Angehängte Dateien

    Einen Kommentar schreiben:


  • JuMi2006
    antwortet
    Sollte eigentlich alles gehen.
    Favoriten sollte (ungetestet) so gehen:

    Code:
    <playerid> favorites playlist play item_id:{}

    Einen Kommentar schreiben:


  • Orion
    antwortet
    Hallo Robert,

    vielen Dank für das Plugin. Ich habe es seit einige Tages mit einem Squeezebox Radio in betrieb. Im Wesentlichen zum Radio hören. Was mir im Moment fehlt (wahrscheinlich nur an Wissen) sind die Bedienung der Buttons auf dem Radio per Visu. Hier sind Die Sender abgelegt, das kennt hie jeder in der Familie, da wäre es super, wenn es einen Taste 1...6 gäbe, um die programmierten Sender auszuwählen.

    Was mir noch aufgefallen ist: Mute funktioniert bei mir nicht, das An/Aus habe ich auch nicht gefunden. Geht denn prinzipiell jeder Befehl, den der Server kann ?

    Grüße

    Michel

    Einen Kommentar schreiben:

Lädt...
X