balbuze / volumio-plugins

volumio's plugins from balbuze
190 stars 60 forks source link

Problems with Brutefir-plugin #39

Closed BenHoeeck closed 7 years ago

BenHoeeck commented 7 years ago

Hi, i use Volumio2 (Vers. 2.129) on a RPi 3 Modell B V1.2 connected to a Roland UA1G DAC via USB and have following problems with Brutefir for Volumio 0.2.6:

  1. It tries to install twice, which seems to be a common problem with plugins, so i do not really care.
  2. Unlike other plugins, it is not shown in the plugin section unless the RPi is rebootet. Ok with me as well.
  3. It does not really save any of the settings in the plugin, to be correctly, there is no "popup" saying that the settings were saved, like it is, when i save setting in other menus. It did save the name of the filter, which i started to try it with: anothertest.wav, but it did not always save the output (USB: UA1G) and most of all, the plugin is always inactive and the advanced settings are off, when i return in the plugin section.
  4. Most important: There is no sound. I have chosen loopback in the Playback menu and Loopback as input/UA1G DAC as output in the plugin, but it is quiet. I tried several settings in the UI in the last days, using the second newest versions of volumio and brutefir plugin, but at one point, it seems, that there were so many things screwed, that i was not even able to save the playback options as UA1G to listen to music without brutefir, so that i formatted the sdcard and reinstalled everything in the newest versioin, but it still does not work. I do not know, what to do, so it would be nice, if i can get some help here. Thanks and best regards, Ben
balbuze commented 7 years ago

hi, thank you for testing.... 1 - yes it is a general installation plugin issue... Should be solved in a near futur. 2 - just refresh the page after install should be enough to see the plugin. But you have to reboot to be able to use Loopback device 3 - When no popup appears, it means that brutefir doesn't start due to a wrong config. 4 - to configure, do the following :

balbuze commented 7 years ago

he, I found a stupid error in ver 0.2.6 that hang the plugin. I think it is the base of your problem. It is solved with 0.2.7. Sorry for that

BenHoeeck commented 7 years ago

Hi balbuze, thank you for the fast reply, no need to apologize, thank you for making DSP possible in Volumio. I tested the 0.2.7 version, but it did not change anything, still there is no popup saying that the settings are saved and the plugin is still inactive after returning to the plugin section, the advanced settings are still off and there is no sound. i did not change anything in the brutefir settings. I tested "systemctl status brutefir" in two different settings. 1: Playback option in the volumio settings is USB DAC, it says: volumio@volumio:~$ systemctl status brutefir ● brutefir.service - brutefir Daemon Loaded: loaded (/etc/systemd/system/brutefir.service; disabled) Active: failed (Result: start-limit) since Fri 2017-04-07 19:17:07 UTC; 2min 19s ago Process: 1613 ExecStart=/usr/bin/brutefir /data/configuration/miscellanea/brutefir/volumio-brutefir-config (code=exited, status=1/FAILURE) Main PID: 1613 (code=exited, status=1/FAILURE)

Apr 07 19:17:07 volumio systemd[1]: Unit brutefir.service entered failed state. Apr 07 19:17:07 volumio systemd[1]: brutefir.service holdoff time over, scheduling restart. Apr 07 19:17:07 volumio systemd[1]: Stopping brutefir Daemon... Apr 07 19:17:07 volumio systemd[1]: Starting brutefir Daemon... Apr 07 19:17:07 volumio systemd[1]: brutefir.service start request repeated too quickly, refusing to start. Apr 07 19:17:07 volumio systemd[1]: Failed to start brutefir Daemon. Apr 07 19:17:07 volumio systemd[1]: Unit brutefir.service entered failed state.

2: Playback option in volumio is loopback: volumio@volumio:~$ systemctl status brutefir ● brutefir.service - brutefir Daemon Loaded: loaded (/etc/systemd/system/brutefir.service; disabled) Active: failed (Result: start-limit) since Fri 2017-04-07 19:21:45 UTC; 15s ago Process: 1874 ExecStart=/usr/bin/brutefir /data/configuration/miscellanea/brutefir/volumio-brutefir-config (code=exited, status=1/FAILURE) Main PID: 1874 (code=exited, status=1/FAILURE)

Apr 07 19:21:45 volumio systemd[1]: Starting brutefir Daemon... Apr 07 19:21:45 volumio systemd[1]: brutefir.service start request repeated too quickly, refusing to start. Apr 07 19:21:45 volumio systemd[1]: Failed to start brutefir Daemon. Apr 07 19:21:45 volumio systemd[1]: Unit brutefir.service entered failed state. Apr 07 19:21:52 volumio systemd[1]: Starting brutefir Daemon... Apr 07 19:21:52 volumio systemd[1]: brutefir.service start request repeated too quickly, refusing to start. Apr 07 19:21:52 volumio systemd[1]: Failed to start brutefir Daemon. Apr 07 19:21:52 volumio systemd[1]: Starting brutefir Daemon... Apr 07 19:21:52 volumio systemd[1]: brutefir.service start request repeated too quickly, refusing to start. Apr 07 19:21:52 volumio systemd[1]: Failed to start brutefir Daemon.

i hope, this will help. best regards Ben

BenHoeeck commented 7 years ago

one correction: I did change one setting in the brutefir-plugin settings: I changed the output to USB DAC, if not, of course, that would be the mistake for no sound, but that would have been to easy :)

balbuze commented 7 years ago

yes in volumio playback setting : Loopback In brutefir advanced setting output : usb dac (it is replace by a number when you'll come back but is not a problem). Save

balbuze commented 7 years ago

I'm using it when writing with a usb fda and it works simply... If not past the result of "aplay -l" here and the content of /data/configuration/miscellanea/brutefir/volumio-brutefir-config

balbuze commented 7 years ago

brutesetting

BenHoeeck commented 7 years ago

Hi balbuze, just to sure, that we do not have a conversation problem: The settings are: k640_audio output the plugin section looks like this when i enter it: k640_plugins but the GPIO plugin works fine, although it is said to be inactive. When i enter the brutefir plugin, the settings are: k640_brutefir settings 1 k640_brutefir settings 2 when i press "save" nathing happens. aplay -l is: k640_aplay -l systemctl... is: k640_systemctl

balbuze commented 7 years ago

please the content of /data/configuration/miscellanea/brutefir/volumio-brutefir-config you can enter "cat /data/configuration/miscellanea/brutefir/volumio-brutefir-config" to get it. I'll have a look tomorow. Is your mixer set to none ? And the plugin won't appears as activated until brutefir start properly...

BenHoeeck commented 7 years ago

Thanks again for helping me! Yes, the mixer in Audio Output is none. cat /data... is: k640_config1 k640_config2 k640_config3

balbuze commented 7 years ago

Humm. Try to change sample rate.I had a quick look at your config and nothing.... Continue tomorrow....

balbuze commented 7 years ago

well we'll get more info trying to launch "by hand" brutefir. using ssh enter "brutefir /data/configuration/miscellanea/brutefir/volumio-brutefir-config" and past what is returned. Maybe we can try in to change device: "alsa" {device: "hw:5"; ignore_xrun: true; }; at en end of /data/configuration/miscellanea/brutefir/volumio-brutefir-config by device: "alsa" {device: "plughw:5"; ignore_xrun: true; }; and retry to start with "brutefir /data/configuration/miscellanea/brutefir/volumio-brutefir-config"

balbuze commented 7 years ago

I made some test and before changing anything, try to change samplerate with different value proposed in plugin setting. With my usb fda, no sound (and brutefir hang) if set to 48000. but ok with 44100

BenHoeeck commented 7 years ago

hi, the result of brutefir /data/configuration/mis... is: k640_brutefir per ssh

after that, i changed the sample rate to 48000 but still nothing then i changed the config to "plughw:5" and run it via ssh. the result: k640_brutefir per ssh 2

BenHoeeck commented 7 years ago

i will erase the "plug" again, reboot volumio an try some other sample rates now, just to be sure...

balbuze commented 7 years ago

Oh it seems this due to input format. Try a other value please

BenHoeeck commented 7 years ago

i changed the config to "plughw:5"... and the input to Loopback,0 in the plugin UI, then started the brutefir via ssh, the result is (first i had the wrong sample rate, i changed it, then i changed the output format to 32 LE, to see, what happens): k640_brutefir per ssh 3

BenHoeeck commented 7 years ago

picture to small to read, here it is bigger: k800_brutefir per ssh 3

BenHoeeck commented 7 years ago

i tried to change the output in the plugin UI to audio jack, and the was the popup saying that the configuration is successfully saved, but there is no sound on the head phone, the ssh says: k800_brutefir per ssh 4 audio jack

balbuze commented 7 years ago

You get this message because brutefir is running. It is probably launch by the plugin ! You can check with systemctl status brutefir. But I think now it's clear. The problem comes from input output format. You have to play with this parameter. And input device in plugin is Loopback,1 or you'll have no sound

BenHoeeck commented 7 years ago

i changed the input in the pugin UI to loopback,1 and output to audio jack and now, there is sound, but very quit and much noise on it, the same with HDMI, when i put a monitor at the RPi.

BenHoeeck commented 7 years ago

and the plugin is stated "active" in the plugin section

BenHoeeck commented 7 years ago

and still a lot of noise on the signal, when i try anothertest.wav. i will try some other options and settings, but i guess, the main problem is my USB DAC ...

balbuze commented 7 years ago

Ok we are near.... The jack output of the RPI is rather crappy... Never tested hdmi... Now the best is to get the USB DAC working.... This should be ok when setting it in advanced plugin setting and trying​ different set in input output format checking with SSH. Now I know that default settings are not universal....

BenHoeeck commented 7 years ago

ok, i will do some tests, but right now i will cook some potatoes, because i´m hungry :) i will get back to this in about two hours with some more information. Thank you for your help!!!

balbuze commented 7 years ago

Bon appetit?

BenHoeeck commented 7 years ago

thanks

BenHoeeck commented 7 years ago

i solved it!!! the problem really was the USB DAC, it has a switch to put on an "advanced driver" at the side, which was "on", after switching it off, everything worked, the anothertest.wav made a clear difference, of course not to the good side, but it is clear, because every room and speakers needs it own correction... So now i feel bad for stealing your time. Can i do anything for you? I work as a consultant for room acoustics, perhaps, i can help you with your room? at the end one last question: when i build my own correction (i will use DRCDesigner), is it better to build two seperated files for left and right, or is one stereofile good as well?

BenHoeeck commented 7 years ago

forget my last question, your files are stereo files as well. i should have thought before writing, silly me

balbuze commented 7 years ago

I Thanks patatoes! I'm really happy it works for you ! I'm going to admit something.... Even if I spent a lot of time on writing this plugin, I don't really use it because because​ I have to make a room measurements with a good mic I have to buy... And I not really familiar with Software used to generate good filters... So I have a request. When you have a good filters, please send me a copy and I will integrate it as demo filter. Are you able to create some filter such as more bass, more medium or less... The idea is to help user having a idea of what can be done... And last point, with your RPI 3 you can increase filter size with no problems. You can check CPU load with top command. And if you need other settings in plugin let me know!

BenHoeeck commented 7 years ago

Right now, i do not know, how flexible the software is, with which i will make the first filters and how good they are, but i will try some other stuff, if i am not satisfied. Of course, i will try to build some filters with different sound characteristics, like you asked for. The measurements are just needed, to correct the influence of the room t the listening position. The filters you are looking for are more a kind of equalizer, or the "loudness" switch of older amplifiers... I do not know, when i will find some time to do so, because i have some stuff to do in the next days, so it may take a couple of days, until i will get back to you. i think, the easiest way to contact you, is to write here at github, right?

BenHoeeck commented 7 years ago

and yes, potatoes! there is a reason, why i always liked them :)

balbuze commented 7 years ago

Yes just contact me here And if you have no time for the filter it is not a problem. I was asking because it is always very important to have advice from other user. And until now we.are not a lot. Drc is something easy to understand but it may be very difficult to apply / configure. And I'm still working to get equaliser functional. It uses brutefir capabilities..In fact it always works in command line but not from the plugin setting..

BenHoeeck commented 7 years ago

I just experienced with some settings in the target designer of the software DRCDesigner without making measurements. I did not listen to it, but it seems to be quit simple to build some files with more or less bass/middle/highs or so. I will listen to it tomorrow and contact you, when i have something for you. I am curious, if it is possible to build some filters after Blauert to gain a more present or diffuse sound. i heard the effect made with an equalizer an white noise, but did not test it with real music, so lets see, how it will work out. By the way, i will use two different microphones for the measurements for the room coorection, one for approx. 120 € and one for approx. 50 €. For measurements of the frequency response of the room or a waterfall diagramm of the bass, to find out, how bad the standing waves are, you can see no difference. But i will find out, if i can hear a difference between the two microphones. Do you know, if there is a way, that i can do a measurement routing the signal through the RPi and the bruftefir plugin, so that i can show the difference, that the plugin does? As far as i know, Volumio does not have an input for external signals, right?

balbuze commented 7 years ago

The only way I see to send something to volumio is airplay... But it introduce a delay and I don't know if we can use it to make mesurement. From a computer you can use tuneblade or read this : https://volumio.github.io/docs/User_Manual/Stream_audio_to_volumio.html I use Bauer filter for a very cose listenning in my home office. The effect is subtil and I can't say if I prefer with or whitout... It can be used with brutefir. The only thing is that it conflict with softvol. But as I understood you don't use softvol. Don't forget, if you generated filter that increase signal, to set attenuation a least equivalent of the increase to avoid clipping. 0 means 0db so the max level. So, if the filter increase a frequency of 6db, attenuation must be a least 6db. Hope it will work as expected.

Good night !

BenHoeeck commented 7 years ago

Hi balbuze, please excuse my much too late reply. I tried do do some filters some weeks ago, but they all sounded terrible. Because i had other things to do i did not find time to play around with other software than DRCDesigner. Now i tried it again in the last days, but it still is no improvement. The results with the software RoomEqWizard were a little bit better, but it still sounds better without filters. For me, listening to music is more important than trying to improve the sound (wich is already really good in my room), i decided to stop the brutefir plugin. I am sorry that i am not able to give you some sample files to show the possibilities of improvements made by the brutefir plugin. best regards Ben

balbuze commented 7 years ago

Hi! Thank you anyway for trying... Since the last time, I rewrote the plugin now called brutefir2 and now the equalizer is working and I added some preset such as loudness, voice, rock .... If you are interested : https://github.com/balbuze/volumio-plugins/tree/master/plugins/miscellanea/brutefir2

BenHoeeck commented 7 years ago

Hi, i wil try the new plugin with your filters, i have to renew the whole volumio system anyway, it does not find my wireless network anymore :)

balbuze commented 7 years ago

but remember my filters present no audio improvement....

Bollejoet commented 7 years ago

Hello Balbuse. Thanks for all the work you're doing on creating an equalizer for Volumio! I'm really new to Volumio and Brutefir but I have a problem. The filter stays inactive (output Volumio: Loopback, Mixer : None, Input plugin: Loopback,1, Output plugin : Audio Jack). The switch is "on" but the red dot stays red. I'm using RPi 2, Audio Jack output, Volumio2 (3 days old) and your plugin from yesterday (0.29). The system has rebooted after install.

Bollejoet commented 7 years ago

I ran: brutefir /data/configuration/miscellanea/brutefir/volumio-brutefir-config (Saw it at the comments of BenHoeeck). It gave me:

BruteFIR v1.0m (November 2013) (c) Anders Torger

Internal resolution is 64 bit floating point. Creating 4 FFTW plans of size 2048...finished. Loading 4 coefficient sets...finished. Realtime priorities are min = 2, usermax = 1, mid = 3 and max = 4. Warning: no support for clock cycle counter on this platform. Timers for benchmarking may be unreliable. ALSA lib pcm_hw.c:1667:(_snd_pcm_hw_open) Invalid value for card ALSA I/O: Could not open audio output "hw:Audio Jack": No such device. Failed to init output device. Failed to initialise digital audio interfaces.

Bollejoet commented 7 years ago

"systemctl status brutefir" Gives me:

● brutefir.service - brutefir Daemon Loaded: loaded (/etc/systemd/system/brutefir.service; disabled) Active: failed (Result: start-limit) since Mon 2017-05-08 13:38:31 UTC; 18min ago Process: 1127 ExecStart=/usr/bin/brutefir /data/configuration/miscellanea/brutefir/volumio-brutefir-config (code=exited, status=1/FAILURE) Main PID: 1127 (code=exited, status=1/FAILURE)

May 08 13:38:31 volumio systemd[1]: brutefir.service holdoff time over, sch...t. May 08 13:38:31 volumio systemd[1]: Stopping brutefir Daemon... May 08 13:38:31 volumio systemd[1]: Starting brutefir Daemon... May 08 13:38:31 volumio systemd[1]: brutefir.service start request repeated...t. May 08 13:38:31 volumio systemd[1]: Failed to start brutefir Daemon. May 08 13:38:31 volumio systemd[1]: Unit brutefir.service entered failed state. Hint: Some lines were ellipsized, use -l to show in full.

Hope you can help me and this helps you.

Thanks in advance!

balbuze commented 7 years ago

@Bollejoet It seems your are not using the good version of plugin : please use https://github.com/balbuze/volumio-plugins/tree/master/plugins/miscellanea/brutefir2 and let me know

Bollejoet commented 7 years ago

That is the one I'am using. I downloaded only the brutefir.zip file. Installed it without problems. I can open the pluginn settings. I see the equelizer, advancedsettings etc. The readme file has production date 7 mei 2017 11.04. So I guess it is the last one (brutefir2).

balbuze commented 7 years ago

Ok. Have you saved advanced settings?

balbuze commented 7 years ago

I never tested it with audio jack as output. I have to check something...

Bollejoet commented 7 years ago

Yep, Saved after changing output to Loopback and after changing Mixer to None.

Bollejoet commented 7 years ago

Saved everything under Advanced settings too!

balbuze commented 7 years ago

Can you try a other output just to see if it starts?

Bollejoet commented 7 years ago

Changed it to hdmi. No start. When I save the equalizer I get a green popup confirming the change. After that a red pop telling me brutefir didn't start. When I switch the Bauerfilter on and save I only get the red popup. When saving advanced settings nothing happens. I'll be gone in ten minutes. Be back tomorrow. Thank you for your fast answers !!!!!!!!!!!