Raspberry 2B and HiFi-Berry DAC+ -- Keyborad & Volume Problems after re-install

classic Classic list List threaded Threaded
4 messages Options
Reply | Threaded
Open this post in threaded view
|

Raspberry 2B and HiFi-Berry DAC+ -- Keyborad & Volume Problems after re-install

Stefan U. Hegner
Hi there,

... some time ago my voyage-installation got corrupted (presumably problems with the SD-card), so I choose to re-install.

First of all I was somewhat surprised, that voyage-mubox-rpi is still Wheezy and not yet Jessie. - I remember vaguely that I read on the list, that there was already an update to jessie. - Strange.

Moreover, I do not get German keyboard on the console. My issue of
# apt-get install keyboard-configuration
and the subsequent settings of a German keyboard does not lead to any changes, not even after a re-boot. - This is strange too.

However, now we come to the real annoying issue: mpd volume control does not get working. Both outputs (HiFi Berry DAC+ and Bluetooth Speaker) are working and can be toggled. However, now after the re-install I seem to have different alsa-controls. - Namely:
# amixer controls
numid=6,iface=MIXER,name='DSP Program'
numid=3,iface=MIXER,name='Analogue Playback Boost Volume'
numid=2,iface=MIXER,name='Analogue Playback Volume'
numid=10,iface=MIXER,name='Auto Mute Mono Switch'
numid=11,iface=MIXER,name='Auto Mute Switch'
numid=8,iface=MIXER,name='Auto Mute Time Left'
numid=9,iface=MIXER,name='Auto Mute Time Right'
numid=18,iface=MIXER,name='BT Speaker'
numid=7,iface=MIXER,name='Clock Missing Period'
numid=5,iface=MIXER,name='Deemphasis Switch'
numid=4,iface=MIXER,name='Digital Playback Switch'
numid=1,iface=MIXER,name='Digital Playback Volume'
numid=16,iface=MIXER,name='Volume Ramp Down Emergency Rate'
numid=17,iface=MIXER,name='Volume Ramp Down Emergency Step'
numid=12,iface=MIXER,name='Volume Ramp Down Rate'
numid=13,iface=MIXER,name='Volume Ramp Down Step'
numid=14,iface=MIXER,name='Volume Ramp Up Rate'
numid=15,iface=MIXER,name='Volume Ramp Up Step'
The two bold marked entries are those of interest. In my /etc/mpd.conf I have the following:
mixer_type "hardware"
[...]
audio_output {
        type            "alsa"
        name            "HiFi-Berry DAC+"
        device          "hw:0,0"
        priority        "FIFO:32"
#       mixer_control   "Digital Playback Volume"
#       mixer_control   "Digital"    ### different name of control in alsamixer
        mixer_index     "1"
}

audio_output {
        type            "alsa"
        name            "TempiTec BT-Speaker"
        device          "btspeaker_softvol"
#        mixer_control   "BT Speaker"
        mixer_index     "18"
[...]
As you can see in the commented lines, I have already played a bit around. - To no avail. The bluetooth speaker is defined in my /etc/asound.conf as follows:
pcm.!default  {
 type hw card 0
}
ctl.!default {
 type hw card 0
}

pcm.btspeaker
{
   type plug
   slave
   {
      pcm
      {
         type bluetooth
         device 00:11:22:33:44:55
         profile "auto"
      }
   }
}

pcm.btspeaker_softvol
{
   type softvol
   slave.pcm "btspeaker"
   control.name "BT Speaker"
   control.card 0
}

ctl.btspeaker
{
   type bluetooth
}
However, mpd seems to try to access in both cases a mixer control called "PCM":
Jan 01 00:00 : inotify: Failed to register /var/lib/mpd/music/media/local/lost+found: inotify_add_watch() has failed: Permission denied
Jan 01 00:00 : Failed to open mixer for 'HiFi-Berry DAC+': no such mixer control: PCM
Jan 01 00:00 : avahi: Service name collision, renaming service to 'Voyage Music Player #2'
Jan 01 00:00 : avahi: Service 'Voyage Music Player #2' successfully established.
Jul 04 15:22 : Failed to open mixer for 'TempiTec BT-Speaker': no such mixer control: PCM
What am I missing here?
It must co-relate to the temperatures  (outside 39°C, and no A/C in the house ...).

Thanks a lot in advance!

Stefan.

-- 
Stefan U. Hegner 
            [hidden email]
              * * *
D-32584 Löhne --- good ole Germany

_______________________________________________
Voyage-linux mailing list
[hidden email]
http://list.voyage.hk/mailman/listinfo/voyage-linux
Reply | Threaded
Open this post in threaded view
|

Re: Raspberry 2B and HiFi-Berry DAC+ -- Keyborad & Volume Problems after re-install

Kim-man 'Punky' TSE-2
Hi Stefan,

mixer_control in /etc/mpd should be set to "Digital".  You should use "amixer scontrols" to check:

root@voyage-mubox:~# amixer scontrols
Simple mixer control 'DSP Program',0
Simple mixer control 'Analogue',0
Simple mixer control 'Analogue Playback Boost',0
Simple mixer control 'Auto Mute',0
Simple mixer control 'Auto Mute Mono',0
Simple mixer control 'Auto Mute Time Left',0
Simple mixer control 'Auto Mute Time Right',0
Simple mixer control 'Clock Missing Period',0
Simple mixer control 'Deemphasis',0
Simple mixer control 'Digital',0
Simple mixer control 'Volume Ramp Down Emergency Rate',0
Simple mixer control 'Volume Ramp Down Emergency Step',0
Simple mixer control 'Volume Ramp Down Rate',0
Simple mixer control 'Volume Ramp Down Step',0
Simple mixer control 'Volume Ramp Up Rate',0
Simple mixer control 'Volume Ramp Up Step',0

Also check if DAC+ is set as hw:0, using the following commands.

root@voyage-mubox:~# cat /proc/asound/cards
  0 [sndrpihifiberry]: snd_rpi_hifiber - snd_rpi_hifiberry_dacplus
                       snd_rpi_hifiberry_dacplus

For keyboard and bt speaker I really cannot help, I only have US keyboard and DAC+.

Regards,
Punky


On 7/4/2015 11:43 PM, Stefan U. Hegner wrote:

> Hi there,
>
> ... some time ago my voyage-installation got corrupted (presumably problems with the SD-card), so I choose to re-install.
>
> First of all I was somewhat surprised, that voyage-mubox-rpi is still Wheezy and not yet Jessie. - I remember vaguely
> that I read on the list, that there was already an update to jessie. - Strange.
>
> Moreover, I do not get German keyboard on the console. My issue of
>
>     # apt-get install keyboard-configuration
>
> and the subsequent settings of a German keyboard does not lead to any changes, not even after a re-boot. - This is
> strange too.
>
> However, now we come to the real annoying issue: mpd volume control does not get working. Both outputs (HiFi Berry
> DAC+ and Bluetooth Speaker) are working and can be toggled. However, now after the re-install I seem to have different
> alsa-controls. - Namely:
>
>     # amixer controls
>     numid=6,iface=MIXER,name='DSP Program'
>     numid=3,iface=MIXER,name='Analogue Playback Boost Volume'
>     numid=2,iface=MIXER,name='Analogue Playback Volume'
>     numid=10,iface=MIXER,name='Auto Mute Mono Switch'
>     numid=11,iface=MIXER,name='Auto Mute Switch'
>     numid=8,iface=MIXER,name='Auto Mute Time Left'
>     numid=9,iface=MIXER,name='Auto Mute Time Right'
>     *numid=18,iface=MIXER,name='BT Speaker'*
>     numid=7,iface=MIXER,name='Clock Missing Period'
>     numid=5,iface=MIXER,name='Deemphasis Switch'
>     numid=4,iface=MIXER,name='Digital Playback Switch'
>     *numid=1,iface=MIXER,name='Digital Playback Volume'*
>     numid=16,iface=MIXER,name='Volume Ramp Down Emergency Rate'
>     numid=17,iface=MIXER,name='Volume Ramp Down Emergency Step'
>     numid=12,iface=MIXER,name='Volume Ramp Down Rate'
>     numid=13,iface=MIXER,name='Volume Ramp Down Step'
>     numid=14,iface=MIXER,name='Volume Ramp Up Rate'
>     numid=15,iface=MIXER,name='Volume Ramp Up Step'
>
> The two bold marked entries are those of interest. In my /etc/mpd.conf I have the following:
>
>     mixer_type "hardware"
>     [...]
>     audio_output {
>             type            "alsa"
>             name            "HiFi-Berry DAC+"
>             device          "hw:0,0"
>             priority        "FIFO:32"
>     #       mixer_control   "Digital Playback Volume"
>     #       mixer_control   "Digital"    ### different name of control in alsamixer
>             mixer_index     "1"
>     }
>
>     audio_output {
>             type            "alsa"
>             name            "TempiTec BT-Speaker"
>             device          "btspeaker_softvol"
>     #        mixer_control   "BT Speaker"
>             mixer_index     "18"
>     [...]
>
> As you can see in the commented lines, I have already played a bit around. - To no avail. The bluetooth speaker is
> defined in my /etc/asound.conf as follows:
>
>     pcm.!default  {
>      type hw card 0
>     }
>     ctl.!default {
>      type hw card 0
>     }
>
>     pcm.btspeaker
>     {
>        type plug
>        slave
>        {
>           pcm
>           {
>              type bluetooth
>              device 00:11:22:33:44:55
>              profile "auto"
>           }
>        }
>     }
>
>     pcm.btspeaker_softvol
>     {
>        type softvol
>        slave.pcm "btspeaker"
>        control.name "BT Speaker"
>        control.card 0
>     }
>
>     ctl.btspeaker
>     {
>        type bluetooth
>     }
>
> However, mpd seems to try to access in both cases a mixer control called "PCM":
>
>     Jan 01 00:00 : inotify: Failed to register /var/lib/mpd/music/media/local/lost+found: inotify_add_watch() has
>     failed: Permission denied
>     Jan 01 00:00 : Failed to open mixer for 'HiFi-Berry DAC+': no such mixer control: PCM
>     Jan 01 00:00 : avahi: Service name collision, renaming service to 'Voyage Music Player #2'
>     Jan 01 00:00 : avahi: Service 'Voyage Music Player #2' successfully established.
>     Jul 04 15:22 : Failed to open mixer for 'TempiTec BT-Speaker': no such mixer control: PCM
>
> What am I missing here?
> It must co-relate to the temperatures  (outside 39°C, and no A/C in the house ...).
>
> Thanks a lot in advance!
>
> Stefan.
>
> --
> Stefan U. Hegner
>              <[hidden email]>
>                * * *
> D-32584 Löhne --- good ole Germany
>
>
> _______________________________________________
> Voyage-linux mailing list
> [hidden email]
> http://list.voyage.hk/mailman/listinfo/voyage-linux


--
Regards,
Kim-man "Punky" Tse

* Open Source Embedded Solutions and Systems
   - Voyage Linux (http://linux.voyage.hk)
   - Voyage MPD   (http://linux.voyage.hk/voyage-mpd)
   - Voyage MuBox (http://mubox.voyage.hk)
* Voyage Store   (http://store.voyage.hk)


_______________________________________________
Voyage-linux mailing list
[hidden email]
http://list.voyage.hk/mailman/listinfo/voyage-linux
Reply | Threaded
Open this post in threaded view
|

Re: Raspberry 2B and HiFi-Berry DAC+ -- Keyborad & Volume Problems after re-install

Stefan U. Hegner
Hey Punky,

thanks for your quick reply.

Am 06.07.2015 um 03:51 schrieb Kim-man 'Punky' TSE:
mixer_control in /etc/mpd should be set to "Digital".  You should use "amixer scontrols" to check:

I tried the mixer_control "Digital" before. - But probably with other conflicting settings. Now I got the following in my/etc/mpd.conf, and this works:
audio_output {
        type            "alsa"
        name            "HiFi-Berry DAC+"
        device          "hw:0,0"
        priority        "FIFO:32"
        mixer_control   "Digital"
}
However, it seems that the alsa driver for the DAC+ has changed, as the controls are now somewhat different. - I got (now) the same scontrols as you have:
root@voyage-mubox:~# amixer scontrols
Simple mixer control 'DSP Program',0
Simple mixer control 'Analogue',0
Simple mixer control 'Analogue Playback Boost',0
Simple mixer control 'Auto Mute',0
Simple mixer control 'Auto Mute Mono',0
Simple mixer control 'Auto Mute Time Left',0
Simple mixer control 'Auto Mute Time Right',0
Simple mixer control 'Clock Missing Period',0
Simple mixer control 'Deemphasis',0
Simple mixer control 'Digital',0
Simple mixer control 'Volume Ramp Down Emergency Rate',0
Simple mixer control 'Volume Ramp Down Emergency Step',0
Simple mixer control 'Volume Ramp Down Rate',0
Simple mixer control 'Volume Ramp Down Step',0
Simple mixer control 'Volume Ramp Up Rate',0
Simple mixer control 'Volume Ramp Up Step',0

But I'm not sure as to how to setup alsa optimal.

I got no clue as to the differences between the DSP Programs. And althogh I'm using an analogue output, I have both "Analogue" and "Analogue Playback Boost" unset, as the level of the output signal is exremely high. I'm pretty sure it used to be lower. When I have "Digital" at around 55% that's plenty of output level - And if I go above I get a distorted signal. - Is this supposed to be this way? With the "old" alsa-driver I got a clean signal at 100%. - Are there any tweaks for this?

For keyboard and bt speaker I really cannot help, I only have US keyboard and DAC+.
The above also helped me to resolve the Bluetooth speaker issue. Now I got the following in my/etc/mpd.conf, and this works:
audio_output {
        type            "alsa"
        name            "TempiTec BT-Speaker"
        device          "btspeaker_softvol"
        mixer_control   "BT Speaker"
}
Regarding the Keyboard: It's not a nagging problem, as I usually only access my 2B via ssh. But maybe there any other folks out there, who got their national keyboard to work. - If so, please share, you made it work.

Thanks a lot for your assistance and have a nice day!

Greetings from Germany!

Stefan.

-- 
Stefan U. Hegner 
            [hidden email]
              * * *
D-32584 Löhne --- good ole Germany

_______________________________________________
Voyage-linux mailing list
[hidden email]
http://list.voyage.hk/mailman/listinfo/voyage-linux
Reply | Threaded
Open this post in threaded view
|

Re: Raspberry 2B and HiFi-Berry DAC+ -- Keyborad & Volume Problems after re-install

Kim-man 'Punky' TSE-2
Hi Stefan,

On 7/7/2015 3:43 AM, Stefan U. Hegner wrote:
> I got no clue as to the differences between the DSP Programs. And althogh I'm using an analogue output, I have both
> "Analogue" and "Analogue Playback Boost" unset, as the level of the output signal is exremely high. I'm pretty sure it
> used to be lower. When I have "Digital" at around 55% that's plenty of output level - And if I go above I get a
> distorted signal. - Is this supposed to be this way? With the "old" alsa-driver I got a clean signal at 100%. - Are
> there any tweaks for this?
The volume control is "Digital", I did not bother others.   My headphone works without distorted at 80% (default) volume
level. You can run "/etc/init.d/alsa-utils reset 0" to reset the card (this would set the volume level back to 80%).

>
> Greetings from Germany!
>
> Stefan.
>
> --
> Stefan U. Hegner
>              <[hidden email]>
>                * * *
> D-32584 Löhne --- good ole Germany


--
Regards,
Kim-man "Punky" Tse

* Open Source Embedded Solutions and Systems
   - Voyage Linux (http://linux.voyage.hk)
   - Voyage MPD   (http://linux.voyage.hk/voyage-mpd)
   - Voyage MuBox (http://mubox.voyage.hk)
* Voyage Store   (http://store.voyage.hk)


_______________________________________________
Voyage-linux mailing list
[hidden email]
http://list.voyage.hk/mailman/listinfo/voyage-linux