•   
  • 1
  • 11
  • 12
  • 13
  • 14
  • 15(current)
Squeezebox for Kodi
(2020-04-20, 23:40)Tronette Wrote:
(2020-04-20, 07:38)acheron Wrote:
(2020-04-20, 01:33)Tronette Wrote: I'm a total noob - how do I do this? I have ssh access, so can anybody tell me step by step how to make this change?  

1. ssh to your kodi
2. Get to the plugin's lib directory (from your home "cd .kodi/addons/plugin.audio.squeezebox/resource/lib")
3. Open the mentioned file in any console text editor you got - usually sth vi-like - vi player_monitor.py
4. Make the adjustments in the code. Should be around line 88. (If yousing vi editor, you need to press "i" inside the editor to insert mode)
5. Save the file (If using vi, then press escape (this quits the editor's insert mode), then type ":wq" (should appear in the bottom line of the editor) and hit enter)   
Great! Thank you.  

Fyi, I'm using LibreElec too and it doesn't come with vi for some reason (at least my install didn't). The best alternative editor that's already on it is nano. It's much more beginner friendly as it works mostly like how you'd expect notepad to work in a terminal, and most commands needed are listed at the bottom of the screen ('^' mean Ctrl).

Once you make edits to the file with nano just do ^X (Ctrl+X), then it will ask if you want to "Save modified Buffer" (meaning save your changes), hit 'Y'. It will ask where you want to save it but it will have the current file's path there as default, so just hit enter.
Reply
"Now Playing" data/controls on Android?

Anyone have any experience or tips for this?  I've got KODI and SqueezeBox for Kodi running almost perfectly across many LibreELEC devices, and am now trying the same on Android.  KODI itself=perfect.  SBPlayer app for audio playback=perfect.  Kodi  for Squeezebox=almost perfect.  I can browse the Squeezebox Server content, start playback with sound, etc., but never get the "Now Playing" interaction via Kodi, so cant see the metadata nor control the player.  I've tried the usual things, ensuring both SBPlayer and SqueezeBox for KODI settings are all sharing the same MAC address, as well as ensuring the KODI system name matches the SBPlayer name (all things seemingly necessary on LibreELEC) to no avail.  Wondering if anyone has seen this work on Android and/or has any ideas or suggestions? 

One device is a Lenovo Tablet running Android 7.1.1 and the other is FireTV Stick 4K, which appears to be Android 7.1.  KODI is 18.7 on each device, 32-bit on FireTV, 64-bit on Lenovo.    

Thanks in-advance.
Reply
(2020-05-22, 18:06)hokie-bird Wrote: "Now Playing" data/controls on Android?

Anyone have any experience or tips for this?  I've got KODI and SqueezeBox for Kodi running almost perfectly across many LibreELEC devices, and am now trying the same on Android.  KODI itself=perfect.  SBPlayer app for audio playback=perfect.  Kodi  for Squeezebox=almost perfect.  I can browse the Squeezebox Server content, start playback with sound, etc., but never get the "Now Playing" interaction via Kodi, so cant see the metadata nor control the player.  I've tried the usual things, ensuring both SBPlayer and SqueezeBox for KODI settings are all sharing the same MAC address, as well as ensuring the KODI system name matches the SBPlayer name (all things seemingly necessary on LibreELEC) to no avail.  Wondering if anyone has seen this work on Android and/or has any ideas or suggestions? 

One device is a Lenovo Tablet running Android 7.1.1 and the other is FireTV Stick 4K, which appears to be Android 7.1.  KODI is 18.7 on each device, 32-bit on FireTV, 64-bit on Lenovo.    

Thanks in-advance.

I use the Android app "Squeezer" and haven't had any problems with it controlling any of my devices.
Reply
(2020-05-22, 18:44)HebrewHammer Wrote:
(2020-05-22, 18:06)hokie-bird Wrote: "Now Playing" data/controls on Android?

Anyone have any experience or tips for this?  I've got KODI and SqueezeBox for Kodi running almost perfectly across many LibreELEC devices, and am now trying the same on Android.  KODI itself=perfect.  SBPlayer app for audio playback=perfect.  Kodi  for Squeezebox=almost perfect.  I can browse the Squeezebox Server content, start playback with sound, etc., but never get the "Now Playing" interaction via Kodi, so cant see the metadata nor control the player.  I've tried the usual things, ensuring both SBPlayer and SqueezeBox for KODI settings are all sharing the same MAC address, as well as ensuring the KODI system name matches the SBPlayer name (all things seemingly necessary on LibreELEC) to no avail.  Wondering if anyone has seen this work on Android and/or has any ideas or suggestions? 

One device is a Lenovo Tablet running Android 7.1.1 and the other is FireTV Stick 4K, which appears to be Android 7.1.  KODI is 18.7 on each device, 32-bit on FireTV, 64-bit on Lenovo.    

Thanks in-advance.

I use the Android app "Squeezer" and haven't had any problems with it controlling any of my devices. 

Thanks for the reply and yes, me too re:  Squeezer.  However, what I'm really trying to accomplish is to get a single unified KODI front-end experience across all my TVs; historically have used all Pi's, but experimenting with FireTV now.
Reply
(2020-05-22, 19:32)hokie-bird Wrote:
(2020-05-22, 18:44)HebrewHammer Wrote:
(2020-05-22, 18:06)hokie-bird Wrote: "Now Playing" data/controls on Android?

Anyone have any experience or tips for this?  I've got KODI and SqueezeBox for Kodi running almost perfectly across many LibreELEC devices, and am now trying the same on Android.  KODI itself=perfect.  SBPlayer app for audio playback=perfect.  Kodi  for Squeezebox=almost perfect.  I can browse the Squeezebox Server content, start playback with sound, etc., but never get the "Now Playing" interaction via Kodi, so cant see the metadata nor control the player.  I've tried the usual things, ensuring both SBPlayer and SqueezeBox for KODI settings are all sharing the same MAC address, as well as ensuring the KODI system name matches the SBPlayer name (all things seemingly necessary on LibreELEC) to no avail.  Wondering if anyone has seen this work on Android and/or has any ideas or suggestions? 

One device is a Lenovo Tablet running Android 7.1.1 and the other is FireTV Stick 4K, which appears to be Android 7.1.  KODI is 18.7 on each device, 32-bit on FireTV, 64-bit on Lenovo.    

Thanks in-advance.

I use the Android app "Squeezer" and haven't had any problems with it controlling any of my devices.  

Thanks for the reply and yes, me too re:  Squeezer.  However, what I'm really trying to accomplish is to get a single unified KODI front-end experience across all my TVs; historically have used all Pi's, but experimenting with FireTV now. 

Ok, re-read your original post and I think I understand your issue now. I mostly use my players "headless" so controlling them from Squeezer is all I do. You could try XSqueeze but it hasn't been updated in at least 3 years, so I don't know how well it's going to work.
Reply
Hi,

thanks for this addon! 
I've got a problem when running it on LibreELEC (official): 9.0.2 (RPi2.arm).
When I start the stream over LMS or even the plugin, the stream stops after 2 seconds.
In kodi.log i've got this:

2020-05-24 17:15:06.804 T:1609253744  NOTICE: plugin.audio.squeezebox --> play started by lms server
2020-05-24 17:15:06.999 T:1155478384   ERROR: Init: Error creating demuxer
2020-05-24 17:15:07.161 T:1155478384  NOTICE: CDVDAudioCodecFFmpeg::Open() Successful opened audio decoder pcm_s16le
2020-05-24 17:15:08.071 T:1609253744  NOTICE: plugin.audio.squeezebox --> playlist changed on lms server
2020-05-24 17:15:08.243 T:1609253744  NOTICE: plugin.audio.squeezebox --> clearing playlist...
2020-05-24 17:15:08.428 T:1084146544   ERROR: CFileCache:Tonguerocess - Error 0 seeking. Seek returned -1
2020-05-24 17:15:08.429 T:1163871088   ERROR: Init: Error creating demuxer
2020-05-24 17:15:08.532 T:1163871088  NOTICE: CDVDAudioCodecFFmpeg::Open() Successful opened audio decoder pcm_s16le
2020-05-24 17:15:09.730 T:1609253744  NOTICE: plugin.audio.squeezebox --> playback stopped
 

it seems that libreelec cannot play the empty pcm stream which is produced by the plugin. 
I already found the right section to change that in httpproxy.py but I don't know much about the parameters to set for an e.g. MP3 stream.

        # always add 2 seconds of additional duration to solve crossfade issues
        duration += 2
        numsamples = 44100 * duration
        channels = 2
        samplerate = 44100
        bitspersample = 16

        # Generate format chunk
        format_chunk_spec = "<4sLHHLLHH"
        format_chunk = struct.pack(
            format_chunk_spec,
            "fmt ",  # Chunk id
            16,  # Size of this chunk (excluding chunk id and this field)
            1,  # Audio format, 1 for PCM
            channels,  # Number of channels
            samplerate,  # Samplerate, 44100, 48000, etc.
            samplerate * channels * (bitspersample / 8),  # Byterate
            channels * (bitspersample / 8),  # Blockalign
            bitspersample,  # 16 bits for two byte samples, etc.
        )
        # Generate data chunk
        data_chunk_spec = "<4sL"
        datasize = numsamples * channels * (bitspersample / 8)
        data_chunk = struct.pack(
            data_chunk_spec,
            "data",  # Chunk id
            int(datasize),  # Chunk size (excluding chunk id and this field)
        )
        sum_items = [
            #"WAVE" string following size field
            4,
            #"fmt " + chunk size field + chunk size
            struct.calcsize(format_chunk_spec),
            # Size of data chunk spec + data size
            struct.calcsize(data_chunk_spec) + datasize
        ]
        # Generate main header
        all_cunks_size = int(sum(sum_items))
        main_header_spec = "<4sL4s"
        main_header = struct.pack(
            main_header_spec,
            "RIFF",
            all_cunks_size,
            "WAVE"
        )

can someone help me with this parameters (header, chuck etc). it should send out an mp3 stream.

Thanks 
Börny
Reply
(2020-05-24, 17:24)bmberni Wrote: Hi,

thanks for this addon! 
I've got a problem when running it on LibreELEC (official): 9.0.2 (RPi2.arm).
When I start the stream over LMS or even the plugin, the stream stops after 2 seconds.
In kodi.log i've got this:

2020-05-24 17:15:06.804 T:1609253744  NOTICE: plugin.audio.squeezebox --> play started by lms server
2020-05-24 17:15:06.999 T:1155478384   ERROR: Init: Error creating demuxer
2020-05-24 17:15:07.161 T:1155478384  NOTICE: CDVDAudioCodecFFmpeg::Open() Successful opened audio decoder pcm_s16le
2020-05-24 17:15:08.071 T:1609253744  NOTICE: plugin.audio.squeezebox --> playlist changed on lms server
2020-05-24 17:15:08.243 T:1609253744  NOTICE: plugin.audio.squeezebox --> clearing playlist...
2020-05-24 17:15:08.428 T:1084146544   ERROR: CFileCache:Tonguerocess - Error 0 seeking. Seek returned -1
2020-05-24 17:15:08.429 T:1163871088   ERROR: Init: Error creating demuxer
2020-05-24 17:15:08.532 T:1163871088  NOTICE: CDVDAudioCodecFFmpeg::Open() Successful opened audio decoder pcm_s16le
2020-05-24 17:15:09.730 T:1609253744  NOTICE: plugin.audio.squeezebox --> playback stopped
 

it seems that libreelec cannot play the empty pcm stream which is produced by the plugin. 
I already found the right section to change that in httpproxy.py but I don't know much about the parameters to set for an e.g. MP3 stream.

        # always add 2 seconds of additional duration to solve crossfade issues
        duration += 2
        numsamples = 44100 * duration
        channels = 2
        samplerate = 44100
        bitspersample = 16

        # Generate format chunk
        format_chunk_spec = "<4sLHHLLHH"
        format_chunk = struct.pack(
            format_chunk_spec,
            "fmt ",  # Chunk id
            16,  # Size of this chunk (excluding chunk id and this field)
            1,  # Audio format, 1 for PCM
            channels,  # Number of channels
            samplerate,  # Samplerate, 44100, 48000, etc.
            samplerate * channels * (bitspersample / 8),  # Byterate
            channels * (bitspersample / 8),  # Blockalign
            bitspersample,  # 16 bits for two byte samples, etc.
        )
        # Generate data chunk
        data_chunk_spec = "<4sL"
        datasize = numsamples * channels * (bitspersample / 8)
        data_chunk = struct.pack(
            data_chunk_spec,
            "data",  # Chunk id
            int(datasize),  # Chunk size (excluding chunk id and this field)
        )
        sum_items = [
            #"WAVE" string following size field
            4,
            #"fmt " + chunk size field + chunk size
            struct.calcsize(format_chunk_spec),
            # Size of data chunk spec + data size
            struct.calcsize(data_chunk_spec) + datasize
        ]
        # Generate main header
        all_cunks_size = int(sum(sum_items))
        main_header_spec = "<4sL4s"
        main_header = struct.pack(
            main_header_spec,
            "RIFF",
            all_cunks_size,
            "WAVE"
        )

can someone help me with this parameters (header, chuck etc). it should send out an mp3 stream.

Thanks 
Börny

I get a lot of demuxer errors too and it still works for me. I'm not really sure what's cause them but it doesn't seem to break the plugin.

It sounds like you may be running into the "onPlayBackStopped" issue, have you tried that fix?
Quote:Just for future reference -

I do not know what is actually causing the issue nor have I really looked or tracked Kodi's messaging, but commenting out:


def onPlayBackStopped(self):
        '''Kodi event fired when playback is stopped'''
        if self.is_playing:
            self.lmsserver.stop()
            log_msg("playback stopped")
        self.is_playing = False

from the plugin's player_monitor.py corrected my afore mentioned issue of the playback being forced stopped.
Reply
  •   
  • 1
  • 11
  • 12
  • 13
  • 14
  • 15(current)
 
Thread Rating:
  • 2 Vote(s) - 4.5 Average



Logout Mark Read Team Forum Stats Members Help
Squeezebox for Kodi4.52
This forum uses Lukasz Tkacz MyBB addons.