Attempt at Hires Lossless (Max) and Dolby Atmos support #100 #1
Replies: 25 comments 11 replies
-
|
Hi @smoothquark,I've installed your release of TIDAL Hi-Res plugin. I don't know If I'm doing it right, but I've tried to play the mpd from command line, this is the result. I think it should be a problem with the "daphile" player that is should be like a squeezelite one, but now I have some doubts... |
Beta Was this translation helpful? Give feedback.
-
|
I am not sure why you are getting invalid data from the mpd. You can try the following to ascertain what is going on. It has to be fresh mpd though (less than hour) due to the token expiring. the .mpd file size should be around 1591 bytes This should give some meaningful data (assuming daphile has ffprobe installed): You could try playing it using ffplay (if it is installed). On my desktop system with pipewire where I am running my LMS server, I had to change the owner of the file to myself for ffplay or mpv to play the file, but no issues with LMS playing to squeezelite on my system. Also, this should show the mpd contents (XML file): If the mpd file is OK, then I think it must be transcoding issue. You need to enable transcoding logs. The transcoding logs will then be in the server.log However, your squeezelite screenshot is showing that it is trying to play a flac file, which should be the case. Going through the above should narrow down whether the .mpd is somehow not being saved correctly, transcoding issue or something to do squeezelite. |
Beta Was this translation helpful? Give feedback.
-
|
@smoothquark I've tried the cat command and I've found that probably the problem is the MPD that seems to be incomplete (MPD generated 2 mins ago): |
Beta Was this translation helpful? Give feedback.
-
|
That is very odd. Either the manifest is not decoded correctly or not saved correctly for some reason. I've just uploaded a new commit with debugging of the manifest. You'll need to enable TIDAL debugging (set to 'debug') and upload the server log to look at. It should probably be at /var/daphile/mediaserver/server.log. This should just show the TIDAL related logs There will also be the response returned for the track and the encrypted manifest. |
Beta Was this translation helpful? Give feedback.
-
|
@smoothquark thanks for your support, I really appreciate it. |
Beta Was this translation helpful? Give feedback.
-
|
Thanks. I shall have a look at it later this evening. I am currently doing more cleaning up of the code. |
Beta Was this translation helpful? Give feedback.
-
|
Looks like the manifest is correctly decoded. So, there must be a problem with how the file is saved. I shall go through the file saving code again and see if I can find anything that may clarify the cause. |
Beta Was this translation helpful? Give feedback.
-
|
Those tracks are all playing fine on my system. Anyway, I have made some changes to the repository. I am redoing the main branch and trying to make the changes more logical. Whilst I continue working on the main branch, I have created a 'testing' branch with the minimum changes required for HiRes and Atmos support and also some minor changes to the mpd file save code. I doubt it will make a difference but perhaps worth a try. I assume none of your hires tracks are playing? Silly question - I presume there is enough space in the cache folder and the permissions are correct? Are there any other files in the cache/tmp folder? The only other thing I can think of is whether there is a Perl version issue. I don't like the idea of cluttering the cache/tmp folder with mpd files but there does not seem to be a choice. There is also an option to use the system /tmp folder, which we could try if necessary. |
Beta Was this translation helpful? Give feedback.
-
|
Something has changed. For your question: yes, the problem is for all HiRes tracks. I have enough space on cache/tmp. No, there aren't other files in /var/daphile/mediaserver/cache/tmp, only the MPD that I try to play. |
Beta Was this translation helpful? Give feedback.
-
|
Yes, the MPD file is now correct and even plays on my system with both mpv and ffplay, presumably because the token is fresh enough. I am not sure whether the changes I made on the testing branch have made any difference. The only real difference was to force close the write rather than rely on an auto close. You should get: If you don't, then MPD DASH support is not compiled in. If you do, there must be some odd permission issue. When I run ffprobe, I get a libpostproc entry - but I think that is only for video processing. |
Beta Was this translation helpful? Give feedback.
-
|
My other thought is whether it has anything to do with the LMS version? I am not sure which version does Daphile run. Mine is version 9.0.1 on Debian Bookworm. Unfortunately I do not have currently have a spare PC to try Daphile on, but I have been testing out mpd via upmpdcli on another Debian Bookworm system too, so I could try installing Daphile on it and see what happens. |
Beta Was this translation helpful? Give feedback.
-
|
LMS version in Daphile is 8.5.3 |
Beta Was this translation helpful? Give feedback.
-
|
Ah yes, I think that might be the case, unfortunately. I don't know if there is any way or plans to have MPD support incorporated within Daphile. A quick search shows this up (https://forums.lyrion.org/forum/user-forums/logitech-media-server/1697301-daphile-lms-deezer) regarding some issues with LMS-Deezer but an update to Daphile resolved it. LMS does not have built in support for DASH, but I think the BBC Sounds and Youtube plugins have implemented their own versions. If I am not mistaken, MP4 support started of as a plugin too before become incorporated into LMS. Its implementation is rather flaky, almost certainly due to different version and codecs within MP4. I have been considering trying to get MPD support done for TIDAL but it does look like a lot of work. |
Beta Was this translation helpful? Give feedback.
-
|
I've changed the entire system to try to resolve. Edit: I've made a test with a local WAV track 24b/192kHz with no issues and my DAC recognise it correctly |
Beta Was this translation helpful? Give feedback.
-
|
Thank you for that. Some observations:
The TIDAL plugin may not be able to write the .mpd file. Are there any .mpd files in the cache/tmp folder? I think it should be at /var/lib/squeezeboxserver/cache/tmp. ls -l /var/lib/squeezeboxserver/cache:
|
Beta Was this translation helpful? Give feedback.
-
|
I've added further logging in the testing branch to show where the mpd file is being saved to to help with debugging. |
Beta Was this translation helpful? Give feedback.
-
|
Solved by reinstalling Ubuntu but in "Desktop" version that has native support for D/E "Muxer" + LMS 9.0.2 + Squeezelite as a player. |
Beta Was this translation helpful? Give feedback.
-
|
@smoothquark update: Daphile is now officially on LMS 9. Thanks for all your work. |
Beta Was this translation helpful? Give feedback.
-
|
Thank you. It is working well for me too, much better than the Tidal apps! I do need to make a few tweaks though - for example the bitrate shown is not correct. I do get the odd occasion where some tracks stop playing, but it is not reproducible. |
Beta Was this translation helpful? Give feedback.
-
|
@smoothquark bad news: the plugin doesn’t work anymore for me(see comments on the original michaelherger repo) |
Beta Was this translation helpful? Give feedback.
-
|
Hmm.. I just tried playing an album from Tidal on my system and it is working fine. Looking at the comments on michaelherger#104 it looks like the OAuth Client ID, and secret have been updated. Interestingly, my bash script using the same Client ID and secret has stopped working, so I presume it will soon stop working on my system too. I am quite busy over the next few days, but should hopefully have some time next week to have a look. This was always going to be a hack to get HiRes and Atmos working. I'll try committing Michael's changes to my fork, but I suspect Atmos will stop working. |
Beta Was this translation helpful? Give feedback.
-
|
I just updated TidalAPI on my system and now my tidal bash scripts using the API work, but had to reauthenticate. I am using an androidTV client id/secret and it appears that some of them (including mine) still work. When I get more time, I shall try restarting Lyrion and see if my plugin stops working. Even if it continues to work, it would probably stop at some point. By the way, do you play Atmos on your system? If you don't, then I think my fork could still work. Perhaps try uninstalling my fork, install Michael's (which will then give you the updated client ID/secret), reauthenticate and then try again with my fork? I had a quick look at his commits - it looks like the main changes have been with the id/secret and authentication code and I think once I update my fork, everything should be working again (hopefully...). |
Beta Was this translation helpful? Give feedback.
-
|
Great. Thank you for the update. I think Michael's plugin has changed the default client id/secret which I think also requires a different methodology for authentication. I shall have a more detailed look when I get the chance, hopefully later this week, as I think my fork will fail soon when the id/secret that I am using inevitably gets unrecognised. |
Beta Was this translation helpful? Give feedback.
-
|
I've updated my fork. Works without needing to install Michael's version. However, Atmos is now broken. As expected, Tidal authentication has changed. So, although my Atmos albums are being picked up (using my own client ID/secret) they are not being played as Atmos but as either HiRes stereo or CD quality. |
Beta Was this translation helpful? Give feedback.
-
|
As expected, Michael's code forces the client id/secret which he has provided. I have made some changes to the code for custom id/secret to be used to enable Dolby Atmos. So far, has been working fine on my system but I think there may be some issues when the tokens refresh. I shall keep an eye out and make changes as necessary. |
Beta Was this translation helpful? Give feedback.











Uh oh!
There was an error while loading. Please reload this page.
-
Continued from michaelherger#100
Beta Was this translation helpful? Give feedback.
All reactions