Fix renderers port / SSDP notification frequency / Home Assistant album launch

47 views
Skip to first unread message

Arnaud et Marie-Pia de Ruffray

unread,
Mar 18, 2024, 10:46:28 PMMar 18
to BubbleUPnP
Hi, thanks for this awesome software that I use daily !

I'm using Rigelian app on iOS / Mac OS as an openhome control point, for various Sonos around the house (wrapped as openhome renderers by BubbleUPnP). Musique is served by Minimserver. I also have a Home Assistant instance running on the network.

Overall, it works well but I have a few troubles for which I seek for help if I may ! 

1. Firstly, Rigelian can take a very long time to discover the Openhome renderers on the network. Is there a way to increase the SSDP notification frequency of BubbleUPnP ? I don't think it's a network issue as it's always working in the end, but can take a very long time.

2. Secondly, BubbleUPnP seem to be randomly changing the renderers ports : is there a reason for that ? Is there a way to fix the port used by the renderers (see point below to understand why I would like to fix the port)

3. Thirdly, I would like Home Assistant to be able to launch an album on an Openhome renderer (an album, not a single track). Is this possible by default ? As per my understanding, Home Assistant can only launch a single track, but I may be wrong. 

Do you confirm that I could circumvent this restriction by sending a http request to Openhome renderers using the Openhome Playlist#Insert protocol ? 

If yes, to create this, it would be much easier if the port could be fixed, otherwise I'll have to create a dedicated service to follow the random port changes and store the port somewhere.

Thanks in advance for the help

Bubblesoft

unread,
Mar 19, 2024, 6:14:05 AMMar 19
to BubbleUPnP
Hi,

1. Looks like this is the classic issue of a Control Point (Rigelian) sending SSDP device search requests on the network and either BubbleUPnP Server not receiving them,
or receiving them but Rigelian not receiving the response. Such issues can be difficult to troubleshoot. Things to try

- on the machine running BubbleUPnP Server make sure LAN trafic on UDP port 1900 is not blocked
- reboot your WiFi router
- make sure your WiFi router is up to date
- go into your WiFi router settings and look for a setting called 'IGMP snooping'. If you find it, disable it

If all of this does not fix it, as a last resort you can enable the frequency at which BubbleUPnP Server advertise on its own the renderers
on the network.

Change or add field blastAliveInterval (in seconds) in configuration.xml:

<blastAliveInterval>30</blastAliveInterval>

The minimum value is 30s.
This is not an ideal solution because it spams you network with SSDP traffic.

You can alternatively use the command-line argument -blastAliveInterval

2. It's not using predetermined port because it is easier and Control Points dynamically discover renderers any (and the port they use).
There is no way to configure it. Adding configuration to it would not be entirely trivial and there is no plan for it

3. You need to call Playlist#Insert for each track of the album and play the first track.

Arnaud et Marie-Pia de Ruffray

unread,
Mar 19, 2024, 7:00:27 AMMar 19
to BubbleUPnP
Many thanks for this very precise and complete answer !

1. I'll indeed debug as per your proposal and eventually tweak the blastAliveInterval using the configuration xml or the CLI argument
2. I understand. I'll create a small script that will regularly scan the renderers to discover their port and store it as a variable for my "album launching" Home Assistant script
3. For this point, I've been trying to use Wireshark to sniff my lan traffic and try to "copy-paste" the Playlist#Insert + Play commands that run each time I launch a new album through Rigelian. For some reasons, I was never able to capture a Playlist#Insert packet. I have captured a lot of Playlist#TransportState, Playlist#Shuffle, Info#, Time#, Volume#... but never Playlist#Insert. Would you have any idea why ? Do I understand well that in theory I should see a packet Playlist#Insert that would have as an argument an url like "10.0.4.2:9790/minimserver...", adding the track to the Openhome renderer playlist ? Or is there a possibility that for some reason Rigelian does it another way such as through the standard UPnP AV protocol ?

Anyway, thanks again for your prompt feedback !

PS: I don't use Android, so I don't use BubbleUPnP app. I didn't find any donate button on the BubbleUPnP server website, but I'd be happy to contribute

Bubblesoft

unread,
Mar 19, 2024, 9:23:08 AMMar 19
to BubbleUPnP
I am not familiar with Rigelian but if you select a OpenHome renderer as current renderer in it, you should see Playlist#Insert requests when you add tracks to the playback queue, as it is the only command to add tracks to it.
Alternatively you can use Linn Kazoo (not the iOS Linn app as it only works with Linn hardware) on a desktop computer to add tracks to the OH renderer managed by BubbleUPnP Server:

Arnaud et Marie-Pia de Ruffray

unread,
Mar 19, 2024, 10:16:39 PMMar 19
to BubbleUPnP
Hi ! Thanks again for your help
For 1. I've indeed found and deactivated 'IGMP snooping' on my router. I've also added the <blastAliveInterval>30</blastAliveInterval> parameter and things are much better now !
For 2. I'll find a way to extract the current port from a tcpdump command and update it as an input_number inside Home Assistant, it shouldn't be too hard
For 3. I have tried to use Rigelian on my computer instead of my iPhone --> It worked ! I was able to sniff the 'Playlist:1#Insert' commands and replicate them using curl
I now have everything in place to finalize a NFC cards based jukebox for my kids :) 

Arnaud et Marie-Pia de Ruffray

unread,
Mar 20, 2024, 5:57:46 AMMar 20
to BubbleUPnP
For those who would be interested after reading this conversation about ports changing in the future, I found that it's much less cumbersome to check and filter port listening on the BubbleUPnP server machine than using the discovery SSDP protocol... The below command did the trick for me (BubbleUPnP server is running on 10.0.4.2 local IP). There are probably much more elegant ways of doing it but as long as it works I'll remain pragmatic !

sudo lsof -i -P -n | grep LISTEN | grep bubbleupnp | grep -Po '10\.0\.4\.2:\K([0-9]+)' | grep -Po '^(?!58050|58051)([0-9]+)$'

Reply all
Reply to author
Forward
0 new messages