Page 1 of 2

problem with volume level after reboot

PostPosted: 24 Jan 2014, 13:00
by tux
Hi all,

i am experiencing a volume level issue after each reboot.

When i boot runeaudio for the first time, mixer is disabled and volume is set to a very low level. I enable the hardware mixer temporarily, set the volume to 100% and then i disable it again. If i power off or reboot the OS, the volume level is reset, and set up to the initial level.

Is there any way that runeaudio remembers my volume settings?

Thank you in advance.

Re: problem with volume level after reboot

PostPosted: 01 Feb 2014, 01:22
by Orion
Hi tux,
thanks for your report.
Please can you paste here your debug informations?

Re: problem with volume level after reboot

PostPosted: 27 Feb 2014, 16:46
by tux
This is my debug information after i have rebooted, I have enabled mixer, raised volume and disabled it again. I also suffer from occasional pops and clicks and i hope this info help for that too,

Code: Select all
      Array
(
    [conf] => Array
        (
            [audio_output_interface] => 0
            [mixer_type] => disabled
            [log_level] => default
            [gapless_mp3_playback] => yes
            [dsd_usb] => yes
            [volume_normalization] => no
            [audio_buffer_size] => 512
            [buffer_before_play] => 0%
            [auto_update] => no
        )

    [save] => save
)
1
###### System info ######
Linux version 3.6.11-18-ARCH+ (nobody@) (gcc version 4.7.2 (GCC) ) #1 PREEMPT Mon Oct 21 01:15:42 CDT 2013

system load:   0.17 0.18 0.08 1/84 535

HW platform:   RaspberryPi (01)

playerID:   010ffde043544740869e68bb1ee19fb845


###### Audio backend ######
Advanced Linux Sound Architecture Driver Version 1.0.25.

Card list: (/proc/asound/cards)
--------------------------------------------------
 0 [Audio          ]: USB-Audio - SA9023 USB Audio
                      HiFimeDIY Audio SA9023 USB Audio at usb-bcm2708_usb-1.2, full speed
 1 [ALSA           ]: BRCM bcm2835 ALSbcm2835 ALSA - bcm2835 ALSA
                      bcm2835 ALSA

ALSA interface #0: (/proc/asound/card0/pcm0p/info)
--------------------------------------------------
card: 0
device: 0
subdevice: 0
stream: PLAYBACK
id: USB Audio
name: USB Audio
subname: subdevice #0
class: 0
subclass: 0
subdevices_count: 1
subdevices_avail: 0

ALSA interface #1: (/proc/asound/card1/pcm0p/info)
--------------------------------------------------
card: 1
device: 0
subdevice: 0
stream: PLAYBACK
id: bcm2835 ALSA
name: bcm2835 ALSA
subname: subdevice #0
class: 0
subclass: 0
subdevices_count: 8
subdevices_avail: 8

interface #0 stream status: (/proc/asound/card0/stream0)
--------------------------------------------------------
HiFimeDIY Audio SA9023 USB Audio at usb-bcm2708_usb-1.2, full speed : USB Audio

Playback:
  Status: Running
    Interface = 3
    Altset = 1
    Packet Size = 388
    Momentary freq = 44100 Hz (0x2c.199a)
  Interface 3
    Altset 1
    Format: S16_LE
    Channels: 2
    Endpoint: 3 OUT (ADAPTIVE)
    Rates: 96000, 88200, 48000, 44100, 32000
  Interface 3
    Altset 2
    Format: S24_3LE
    Channels: 2
    Endpoint: 3 OUT (ADAPTIVE)
    Rates: 96000, 88200, 48000, 44100, 32000

Capture:
  Status: Stop
  Interface 2
    Altset 1
    Format: S16_LE
    Channels: 2
    Endpoint: 2 IN (ADAPTIVE)
    Rates: 96000, 88200, 48000, 44100, 32000
  Interface 2
    Altset 2
    Format: S24_3LE
    Channels: 2
    Endpoint: 2 IN (ADAPTIVE)
    Rates: 96000, 88200, 48000, 44100, 32000

interface #1 stream status: (/proc/asound/card1/stream0)
--------------------------------------------------------
no stream present


###### Kernel module snd_usb_audio settings ######

Module = "snd_usb_audio"

  Attributes:
    coresize            = "104025"
    initsize            = "0"
    initstate           = "live"
    refcnt              = "1"
    srcversion          = "DA9A78F56D873AB02CB47F0"
    taint               = ""
    uevent              =

  Parameters:
    async_unlink        = "Y"
    device_setup        = "0,0,0,0,0,0,0,0"
    enable              = "Y,Y,Y,Y,Y,Y,Y,Y"
    id                  = "(null),(null),(null),(null),(null),(null),(null),(null)"
    ignore_ctl_error    = "N"
    index               = "0,-1,-1,-1,-1,-1,-1,-1"
    nrpacks             = "3"
    pid                 = "-1,-1,-1,-1,-1,-1,-1,-1"
    vid                 = "-1,-1,-1,-1,-1,-1,-1,-1"

  Sections:
    .ARM.exidx.exit.text= "0xbf1a4d2c"
    .ARM.exidx.init.text= "0xbf1a4d24"
    .ARM.exidx          = "0xbf1a7144"
    .ARM.extab          = "0xbf1a70d8"
    .ARM.extab.init.text= "0xbf1a4d18"
    .bss                = "0xbf1aab2c"
    .data               = "0xbf1a75f0"
    .exit.text          = "0xbf1a3534"
    .gnu.linkonce.this_module= "0xbf1aa9c4"
    .init.text          = "0xbf1b3000"
    .note.gnu.build-id  = "0xbf1a75cc"
    .rodata             = "0xbf1a3540"
    .rodata.str1.4      = "0xbf1a4dc4"
    .strtab             = "0xbf1b7ec8"
    .symtab             = "0xbf1b3048"
    .text               = "0xbf198000"
    __param             = "0xbf1a4d34"


###### Kernel optimization parameters ######

hardware platform:   RaspberryPi
current orionprofile:   RuneAudio

kernel scheduler for mmcblk0:      [noop] deadline cfq
/proc/sys/vm/swappiness:      0
/proc/sys/kernel/sched_latency_ns:   1500000


###### Filesystem mounts ######

rootfs / rootfs rw 0 0
/dev/root / ext4 rw,noatime,nouser_xattr,errors=remount-ro,data=ordered 0 0
devtmpfs /dev devtmpfs rw,relatime,size=84748k,nr_inodes=21187,mode=755 0 0
tmpfs /dev/shm tmpfs rw,nosuid,nodev 0 0
devpts /dev/pts devpts rw,nosuid,noexec,relatime,gid=5,mode=620 0 0
mqueue /dev/mqueue mqueue rw,relatime 0 0
proc /proc proc rw,nosuid,nodev,noexec,relatime 0 0
systemd-1 /proc/sys/fs/binfmt_misc autofs rw,relatime,fd=30,pgrp=1,timeout=300,minproto=5,maxproto=5,direct 0 0
sysfs /sys sysfs rw,nosuid,nodev,noexec,relatime 0 0
securityfs /sys/kernel/security securityfs rw,nosuid,nodev,noexec,relatime 0 0
tmpfs /sys/fs/cgroup tmpfs rw,nosuid,nodev,noexec,mode=755 0 0
cgroup /sys/fs/cgroup/systemd cgroup rw,nosuid,nodev,noexec,relatime,release_agent=/usr/lib/systemd/systemd-cgroups-agent,name=systemd 0 0
cgroup /sys/fs/cgroup/cpuset cgroup rw,nosuid,nodev,noexec,relatime,cpuset 0 0
cgroup /sys/fs/cgroup/cpu,cpuacct cgroup rw,nosuid,nodev,noexec,relatime,cpuacct,cpu 0 0
cgroup /sys/fs/cgroup/memory cgroup rw,nosuid,nodev,noexec,relatime,memory 0 0
cgroup /sys/fs/cgroup/devices cgroup rw,nosuid,nodev,noexec,relatime,devices 0 0
cgroup /sys/fs/cgroup/freezer cgroup rw,nosuid,nodev,noexec,relatime,freezer 0 0
cgroup /sys/fs/cgroup/blkio cgroup rw,nosuid,nodev,noexec,relatime,blkio 0 0
cgroup /sys/fs/cgroup/perf_event cgroup rw,nosuid,nodev,noexec,relatime,perf_event 0 0
cgroup /sys/fs/cgroup/net_prio cgroup rw,nosuid,nodev,noexec,relatime,net_prio 0 0
debugfs /sys/kernel/debug debugfs rw,relatime 0 0
configfs /sys/kernel/config configfs rw,relatime 0 0
tmpfs /run tmpfs rw,nosuid,nodev,mode=755 0 0
Ramdisk /run/shm tmpfs rw,nosuid,nodev,noexec,relatime,size=262144k 0 0
tmpfs /tmp tmpfs rw 0 0
rpc_pipefs /var/lib/nfs/rpc_pipefs rpc_pipefs rw,relatime 0 0
/dev/mmcblk0p1 /boot vfat rw,relatime,fmask=0022,dmask=0022,codepage=cp437,iocharset=ascii,shortname=mixed,utf8,errors=remount-ro 0 0
tmpfs /tmp tmpfs rw 0 0
/dev/root /var/tmp ext4 rw,noatime,nouser_xattr,errors=remount-ro,data=ordered 0 0
//192.168.1.150/Music /mnt/MPD/Resilience cifs ro,relatime,vers=1.0,sec=ntlm,cache=strict,unc=\\192.168.1.150\Music,uid=45,forceuid,gid=45,forcegid,addr=192.168.1.150,unix,posixpaths,serverino,acl,rsize=16384,wsize=16384,actimeo=1 0 0


###### mpd.conf ######

###################################
# Auto generated mpd.conf file
# please DO NOT edit it manually!
# Use RuneUI MPD config section
###################################

follow_outside_symlinks    "yes"
follow_inside_symlinks    "yes"
db_file    "/var/lib/mpd/mpd.db"
log_file    "/var/log/runeaudio/mpd.log"
pid_file    "/var/run/mpd/pid"
music_directory    "/mnt/MPD"
playlist_directory    "/var/lib/mpd/playlists"
state_file    "/var/lib/mpd/mpdstate"
user    "mpd"
bind_to_address    "any"
port    "6600"
log_level    "default"
zeroconf_enabled    "yes"
zeroconf_name    "runeaudio"
volume_normalization    "no"
audio_buffer_size    "512"
buffer_before_play    "0%"
filesystem_charset    "UTF-8"
id3v1_encoding    "UTF-8"
gapless_mp3_playback    "yes"
auto_update    "no"
mixer_type    "disabled"
group    "audio"
max_connections "20"

decoder {
      plugin "ffmpeg"
      enabled "no"
}

input {
      plugin "curl"
}

audio_output {
enabled      "yes"
type      "alsa"
name      "USB-Audio"
device      "hw:0,0"
dsd_usb      "yes"
}

audio_output {
enabled      "yes"
type      "null"
name      "Null"
}

audio_output {
enabled      "no"
type      "alsa"
device      "hw:1,0"
name      "AnalogJack/HDMI"
}




###### PHP backend ######

php version:   5.5
debug level:   2


###### SESSION ######

STATUS:      1
ID:      m7svckhf555b69132o1bu1let6
SAVE PATH:   /run


###### SESSION DATA ######

Array
(
    [orionprofile] => RuneAudio
    [cmediafix] => 0
    [playmod] => 0
    [ramplay] => 0
    [sessionid] => m7svckhf555b69132o1bu1let6
    [mpdconfhash] => 12eed229f02c52816ed997cbce4b9f32
    [lastfm_apikey] => ba8ad00468a50732a3860832eaed0882
    [netconfhash] => 643f8967af551f683b3cfd493950c550
    [mpdconf_advanced] => 0
    [netconf_advanced] => 0
    [dev] =>
    [sourceconfhash] => d41d8cd98f00b204e9800998ecf8427e
    [sourceconf_advanced] => 1
    [debug] => 2
    [hiddendebug] => 0
    [opcache] => 1
    [playerid] => 010ffde043544740869e68bb1ee19fb845
    [hwplatform] => RaspberryPi
    [hwplatformid] => 01
    [airplay] => 0
    [scrobbling_lastfm] => 0
    [scrobbling_librefm] => 0
    [scrobbling_jamendo] => 0
    [spotify] => 0
    [db_version] => 1.2
    [udevil] => 1
    [coverart] => 1
    [volume] => 0
    [ao] => 0
    [ntpserver] => ntp.inrim.it
    [hostname] => runeaudio
    [w_queue] =>
    [w_queueargs] =>
    [w_lock] => 0
    [w_active] => 0
    [w_jobID] =>
    [debugdata] =>
    [netconf] => Array
        (
            [eth0] => Array
                (
                    [ip] => 192.168.1.106
                )

        )

    [state] => play
    [notify] =>
)

Page created in 1.24605 seconds.

Re: problem with volume level after reboot

PostPosted: 27 Feb 2014, 17:47
by tux
I read your reply on the other thread so let's continue here regarding both the level problem and the pops and clicks!

My Dac is not asynchronus.

The main problems i have with pops and clicks are when using the NAS. If i use my external USB disk i get no pops and clicks with16/44.1 and with 24/96 i have but less that when using the NAS.

I tried all kernel profiles and many combinations of rsize and wsize. I saw no difference and at the moment i am with stock settings.

I have tested with 2-3 different pdus. The one I use at the moment is 5V/2A and it is supposed to be a trusty solution.

Re: problem with volume level after reboot

PostPosted: 27 Feb 2014, 17:56
by ACX
I see you are using SMB/CIFS for your mount. Do you have the possibility to use NFS protocol with your NAS? In my experience it performs better and solves pops/clicks problems in some cases.

Re: problem with volume level after reboot

PostPosted: 27 Feb 2014, 17:57
by tux
I tested with an NFS share and performance was worse but i will check again.

Re: problem with volume level after reboot

PostPosted: 27 Feb 2014, 18:05
by ACX
Have you other peripherals connected to your Pi, draining power from USB ports?
Maybe your DAC is more power hungry than the average, and this could create problems to the shared Eth/USB bus. That's the Pi's Achilles' heel, all the USB related problems are because of its poor implementation. A friend of us has a similiar problem with an old adaptive USB DAC and he cannot get completely rid of pops/clicks, although not so frequent.

Re: problem with volume level after reboot

PostPosted: 27 Feb 2014, 18:10
by tux
My dac is not usb powered. I have an external PDU for this:

http://hifimediy.com/index.php?route=pr ... uct_id=108

when i use the NAS i have nothing but the DAC attached.

To be honest i do not care about 24/96 (i just do my tests with 24/96 to test my limits). I just want a problem free FLAC 16/44.1 reproduction!

Re: problem with volume level after reboot

PostPosted: 27 Feb 2014, 18:32
by tux
I decided to try again a NFS setup (i had tested it many days ago with another linux distro) and it seems that 16/44.1 is trouble free with this. I'll stay with this a while to test.

As far as the sound level problem, it keeps resetting after each reboot back to 67. I had that problem long ago(in my desktop installation) and i had found a solution for alsa to remember the last level setting, but unfortunately i don't remember what I had done.

Re: problem with volume level after reboot

PostPosted: 27 Feb 2014, 18:54
by tux
I think I found a solution to the alsa volume state.

I logged in using ssh and gave the following command:

alsactl store

Now after reboot the level is always set to 100.