Saiyato / volumio-snapcast-plugin

Volumio 2 SnapCast plugin, to easily manage SnapCast functionality
115 stars 25 forks source link

HiFiBerry Amp2 compatible? #83

Closed tekdru closed 2 years ago

tekdru commented 3 years ago

Hello, I am planning on purchasing some HiFiBerry Amp2 DACs in hopes of using them with Volumio and Snapcast on several RPI 3b+ as a possible solution for a whole home audio system. I want to know if there would be any issues using this DAC with the snapcast plugin for the SnapServer Pis and SnapClient Pis.

https://www.hifiberry.com/shop/boards/hifiberry-amp2/

Thanks

0x0lli commented 3 years ago

the plugin just doesnt work and no one takes care to fix it for a lot of volumio releases by now. Its a year by now. I wanted to start just exactly where you are at the moment: Having a nice touchscreen center and use volumio to navigate through my spotify and private selection. If you want a multiroom setup, go for the real snapcast. It works flawlessly if you get the settings right, which appears hard in the beginning. Now I am using spotify to choose my multiroom setup as speaker-it is WAY faster than volumio and also, works very well on the pi0 so you can have plenty of clients for the fraction of the price and are not bound to volumio. Since I realized, the plugin is not being taken care of, I simply dropped volumio for the good and do not miss a thing, I am happier after all. Sorry to rain in the parade, my advise: https://github.com/badaix/snapcast have a good one

tekdru commented 3 years ago

Thank you for your input. I appreciate the information. I'm currently using two RPIs running Volumio version 2.834 and 2.806. Both of them are using the Snapcast plugin and has been working well for me. I also have another PRI running Mopidy with Snapcast and it's working well too. All the RPIs have audio output to the headphones jacks. I just wasn't sure if the Volumio PI's would still work well if I added the Amp2 hats to them.

Out of all the MPDs if tried so far, the combination of Volumio pis and the Mopidy pi turned out to be the best for my needs, so I won't just drop Volumio unless I find a better one.

Thanks

Saiyato commented 3 years ago

Hi @tekdru ,

The AMP2 should use the hifiberry-dacplus soundcard as opposed to hifiberry-amp (for AMP+). When the overlay is configured correctly (see: https://www.hifiberry.com/docs/software/configuring-linux-3-18-x/), you should be able to select it from the drop-down.

@0x0lli you can see the commits here: https://github.com/Saiyato/volumio-snapcast-plugin/commits/master The fact that they don't reflect in the plugin-store (for easy installation), is a different discussion. So I'd like to debunk the comment 'its a year by now'. ;-)

No worries, I understand the frustration, the plugin is meant to easily install the snapcast components, so it's the same binaries (or as you call it 'the real snapcast'). It can be quite difficult to keep track of changes in the ecosystem, push my patches and have then added to the plugin-store.

Apart from the whole pandemic I've had some challenges this year (hence the status), this means I've not been able to invest lots of personal time. I did however prepare docker images for future use, I've been benchmarking the performance to see if the penalties are worth it. You can see the container projects here: https://hub.docker.com/repository/docker/saiyato/snapserver and here https://hub.docker.com/repository/docker/saiyato/snapclient

Finally, I don't get the 'fraction of the price' remark, everything I've created (in terms of plugins) is free. The Volumio base is free and snapcast is free, I've not paid a penny to get things up and running. If you did, then I can understand the disappointment if stuff doesn't work. Also note that I'm (at the time of writing) not a part of the Volumio team, I'm just a happy contributer (in my spare time). :-)

As for @tekdru, I can understand why Volumio might be a good fit for you, the MPD integration is pretty neat (I ran into some trouble when adding my library and I'm missing a bug fix, apart from that, pretty happy).

TL;DR Yes the HATs are supported and if you've already got it running, it's a matter of configuring the correct output for the client (select hifiberry_dacplus for AMP2).

0x0lli commented 3 years ago

@tekdru thanks for your input! what workaround did you use in order to get it running? I have tried both volumio versions you mentioned and the plugin just wouln't run out of the box. Even after using the sometimes contradicting advice given in the volumio forum (if an answer would be given at all) the plugin wouldn't work (for me, that is).

@Saiyato Unfortunately, you understood it as a complaint about your work. I think, I would so, too if it was my work- the lines toward tekdru were an advice I made given my experience with volumio, which I have always liked and it has always worked. I still dont understand why they updated their kernel if the most interesting plugin is not working (for me that is: snapcast, touchscreen, rotary encoder in that order). Also, agreed: I fail to understand how they can keep up that updating policy. If the proposed installation process would have worked for me, I would not have given such an advice. The interaction between me and the snapcast-plugin-interface within volumio was completely irreproducible for me, even after following the manual installation. I am really curious as to how tekdru has got it working. I have spend about 8 to ten fresh installations of even old volumio versions that I have gotten off torrent, just in order to see it fail and fail again for me. After all, it would have been plausible for me that I should've worked with the old kernel. That amount of frustration about spent time is the reason I have given up upon volumio.

concerning the fractions of the price remark: Sorry to get me wrong- that was pointing towards the performance of pi3 and pi4 (which are 36 euros where I live) compared to pi0 (which is 11 Euro). I would not use volumio on a pi0 as it behaves too slow for my liking so I had pi3 and pi4 setups which I ran separately in order to find the bugs I just described above: irreproducible error-messages. using snapcast on a buster-lite install with a pi0 is very responsive and more reliable than sonos-support within my primary source : spotify. For sonos v1 and v2 devices, I would sometimes have to repeatedly select the output several times to have it playback, volumio bahaved absolutely similar (independent on the used device; spotify on PC, macOS, android, iOS, I tried several). I have not payed for volumio, aswell.

Your work is highly appreciated and I (really) know how frustrating it is if you count yourself responsible for things out of your responsibility, which is obviously the case here and also, partly my fault as I have not been explicitly enough. I hope to have been, by now. I wish you all the best on your personal account and professionally-wise! Kind regards

Saiyato commented 3 years ago

Hi @0x0lli,

Thanks for clarifying, makes absolute sense. I think I know now what your issue is/was, it's not really kernel-related, but at some point the rights in Volumio for /etc/ changed. Since SnapCast relies on specific asound-config and this config resides in /etc/ I ran into a whole new challenge. I need to be able to change the contents of /etc/asound.conf without having to use the Volumio password (because I think people should be able to change it). Note: if you change the Volumio password, you will break functionality (e.g. installing plugins). This particular problem also exists for the Kodi plugin and I've spent some time finding a suitable workaround without having to use the password. This is most likely causing you issues, the quick-and-dirty fix would be chowning /etc/ for Volumio 😄 (from a security perspective a no-go imho) <- this has probably caused the most issues in the past year, I kind of lost my progress at some point and had to start all over with the new way of working around this. Note: another problem is other plugins, some just overwrite /etc/asound.conf with their new version (hence the (re)patch option in the plugin UI)

Then SnapCast moved ahead and needs a new kernel, Volumio is stuck on Jessie and while tests are looking promising for Buster, it's not nearly finished. You can compile SnapCast on newer versions of the OS and use the binaries on Jessie, not sure how stable that is. So your choice; installing Buster like on a Pi0 is probably the best way for a simple SnapCast device. You can even go as far as installing Alpine instead of Debian to minimize the footprint (see the Dockerfiles for deps). Speaking of which, I have an RPi2B + Hifiberry AMP+ which I use in my garden... I might make that a super light slave (Alpine + SnapClient (no server) + script for led indicator of boot/network + rotary encoder for volume). You triggered me 😉

...Or boot HypriotOS + a super light container (makes it portable). In any case, running Volumio on a Pi0 which is only used as a playback slave is overkill in terms of CPU usage.

As for the problems with Spotify, not sure what your setup was, but I have had super results with the latest VolspotConnect2 versions, all of my earlier problems (selecting output multiple times, shuffle issues, playback stopping) are gone fingers crossed

Thanks again for clarifying, I hope the above helps you too (maybe even explain what problems you had). As said, fixing them is one thing, the other one is maybe even more frustrating... when will they be available in the plugin-store for easy installation.

Cheers

tekdru commented 3 years ago

Hey @Saiyato, Thanks for the clarification and the confirmation on the AMP2 hat!

@0x0lli, I followed the instructions on this video (https://www.youtube.com/watch?v=oA0L4tSvPKk), It worked well for me on a couple installs. Hope you get it working!

Saiyato commented 2 years ago

You can use the new plugins now (requires manual installation): https://github.com/Saiyato/volumio-snapserver-plugin https://github.com/Saiyato/volumio-snapclient-plugin