[RISOLTO]Problema Alsamixer
Inviato: lun 20 ott 2008, 11:11
Non mi rimangono salvate con alsactl store le impostazioni audio al riavvio.... che puo essere???
/etc/rc.d/rc.alsa ha i permessi di esecuzione vero?N1cuz ha scritto:Non mi rimangono salvate con alsactl store le impostazioni audio al riavvio.... che puo essere???
Se daiN1cuz ha scritto:si, ce l'ha, funziona tutto fino a che non spengo o riavvio la macchina, dopodichè le impostazioni tornano quelle dell'installazione...
Codice: Seleziona tutto
alsactl restorecon quel comando nulla, la configurazione audio rimane invariata all'attualeconraid ha scritto:Se daiN1cuz ha scritto:si, ce l'ha, funziona tutto fino a che non spengo o riavvio la macchina, dopodichè le impostazioni tornano quelle dell'installazione...che succede?Codice: Seleziona tutto
alsactl restore
Comando che in teoria è in rc.alsa
Fammi capire, tu faiN1cuz ha scritto:con quel comando nulla, la configurazione audio rimane invariata all'attualeconraid ha scritto:Se daiN1cuz ha scritto:si, ce l'ha, funziona tutto fino a che non spengo o riavvio la macchina, dopodichè le impostazioni tornano quelle dell'installazione...che succede?Codice: Seleziona tutto
alsactl restore
Comando che in teoria è in rc.alsa
Codice: Seleziona tutto
# alsamixer
# alsactl storeCodice: Seleziona tutto
# alsactl restoreSi esattamente, ma se ogni volta che riavvio devo dare un alsactl restore, posso direttamente regolare il volume dall'applet del pannello di kde.... comunque strano, mi sembra che prima alsamixer funzionasse...
Fammi capire, tu faiCodice: Seleziona tutto
# alsamixer # alsactl store
e quando al riavvio fai
non ti prende le impostazioni precedentemente salvate?Codice: Seleziona tutto
# alsactl restore
Aspetta. Tu devi dire se con alsactl restore funziona o no?N1cuz ha scritto: Si esattamente, ma se ogni volta che riavvio devo dare un alsactl restore, posso direttamente regolare il volume dall'applet del pannello di kde.... comunque strano, mi sembra che prima alsamixer funzionasse...
allora posta questi il risultato di questi comando. A pc avviato, prima di dare alsactl restoreN1cuz ha scritto:mi sono spiegato male... il "si, esattamente" era riferito proprio al comando alsactl restore (che funziona), lo sfogo successivo era riferito al malfinzionamento dell' alsactl store che non è un comando "vitale", ma che comunque evita la seccatura di dover, ad ogni riavvio, reimpostare i volumi...
Codice: Seleziona tutto
# ls -l /etc/rc.d/rc.alsa
# cat /etc/rc.d/rc.alsa
# ls -l /etc/asound.state
# grep rc.alsa /etc/rc.d/*
... un lo vorrei neanch'io:conraid ha scritto:allora posta questi il risultato di questi comando. A pc avviato, prima di dare alsactl restoreN1cuz ha scritto:mi sono spiegato male... il "si, esattamente" era riferito proprio al comando alsactl restore (che funziona), lo sfogo successivo era riferito al malfinzionamento dell' alsactl store che non è un comando "vitale", ma che comunque evita la seccatura di dover, ad ogni riavvio, reimpostare i volumi...
Non vorrei che nei tuoi esperimenti hai tolto qualcosa che lancia rc.alsaCodice: Seleziona tutto
# ls -l /etc/rc.d/rc.alsa # cat /etc/rc.d/rc.alsa # ls -l /etc/asound.state # grep rc.alsa /etc/rc.d/*
Codice: Seleziona tutto
root@nicoLaptop:/home/nico# ls -l /etc/rc.d/rc.alsa
-rwxr-xr-x 1 root root 2671 2008-04-01 07:18 /etc/rc.d/rc.alsa
root@nicoLaptop:/home/nico# cat /etc/asound.state
state.Intel {
control.1 {
comment.access 'read write'
comment.type ENUMERATED
comment.count 1
comment.item.0 IntMic
comment.item.1 ExtMic
iface MIXER
name 'Capture Source'
value ExtMic
}
control.2 {
comment.access 'read write'
comment.type INTEGER
comment.count 2
comment.range '0 - 23'
iface MIXER
name 'Int Mic Capture Volume'
value.0 0
value.1 0
}
control.3 {
comment.access 'read write'
comment.type BOOLEAN
comment.count 2
iface MIXER
name 'Int Mic Capture Switch'
value.0 true
value.1 true
}
control.4 {
comment.access 'read write'
comment.type INTEGER
comment.count 2
comment.range '0 - 23'
iface MIXER
name 'Ext Mic Capture Volume'
value.0 0
value.1 0
}
control.5 {
comment.access 'read write'
comment.type BOOLEAN
comment.count 2
iface MIXER
name 'Ext Mic Capture Switch'
value.0 true
value.1 true
}
control.6 {
comment.access 'read write'
comment.type INTEGER
comment.count 2
comment.range '0 - 20'
iface MIXER
name 'PCM Playback Volume'
value.0 17
value.1 17
}
control.7 {
comment.access 'read write'
comment.type BOOLEAN
comment.count 2
iface MIXER
name 'PCM Playback Switch'
value.0 true
value.1 true
}
control.8 {
comment.access 'read write'
comment.type INTEGER
comment.count 2
comment.range '0 - 20'
iface MIXER
name 'Int Mic Playback Volume'
value.0 0
value.1 0
}
control.9 {
comment.access 'read write'
comment.type BOOLEAN
comment.count 2
iface MIXER
name 'Int Mic Playback Switch'
value.0 true
value.1 true
}
control.10 {
comment.access 'read write'
comment.type INTEGER
comment.count 2
comment.range '0 - 20'
iface MIXER
name 'Ext Mic Playback Volume'
value.0 0
value.1 0
}
control.11 {
comment.access 'read write'
comment.type BOOLEAN
comment.count 2
iface MIXER
name 'Ext Mic Playback Switch'
value.0 false
value.1 false
}
control.12 {
comment.access 'read write'
comment.type INTEGER
comment.count 2
comment.range '0 - 43'
iface MIXER
name 'Master Playback Volume'
value.0 30
value.1 30
}
control.13 {
comment.access 'read write'
comment.type BOOLEAN
comment.count 1
iface MIXER
name 'Master Playback Switch'
value true
}
control.14 {
comment.access read
comment.type IEC958
comment.count 1
iface MIXER
name 'IEC958 Playback Con Mask'
value '0fff000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000'
}
control.15 {
comment.access read
comment.type IEC958
comment.count 1
iface MIXER
name 'IEC958 Playback Pro Mask'
value '0f00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000'
}
control.16 {
comment.access 'read write'
comment.type IEC958
comment.count 1
iface MIXER
name 'IEC958 Playback Default'
value '0400000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000'
}
control.17 {
comment.access 'read write'
comment.type BOOLEAN
comment.count 1
iface MIXER
name 'IEC958 Playback Switch'
value true
}
control.18 {
comment.access 'read write'
comment.type BOOLEAN
comment.count 1
iface MIXER
name 'IEC958 Default PCM Playback Switch'
value false
}
}
root@nicoLaptop:/home/nico# ls -l /etc/asound.state
-rw-r--r-- 1 root root 4052 2008-10-20 22:54 /etc/asound.state
root@nicoLaptop:/home/nico# grep rc.alsa /etc/rc.d/*
/etc/rc.d/rc.M:#if [ -x /etc/rc.d/rc.alsa ]; then
/etc/rc.d/rc.M: . /etc/rc.d/rc.alsa
/etc/rc.d/rc.M.backup:if [ -x /etc/rc.d/rc.alsa ]; then
/etc/rc.d/rc.M.backup: . /etc/rc.d/rc.alsa
/etc/rc.d/rc.M~:#if [ -x /etc/rc.d/rc.alsa ]; then
/etc/rc.d/rc.M~: . /etc/rc.d/rc.alsa
scusami non mi ero accorto:conraid ha scritto:intanto hai scritto male, volevo il cat di rc.alsa (sicuro di non averlo mai toccato?) non di alsa.state, comunque prova a mettere rc.M originale e guarda che succede
vedo che in quello modificato hai commentato l'IF ma non il comando di chiamata di rc.alsa, quindi "dovrebbe" andare.
Codice: Seleziona tutto
root@nicoLaptop:/home/nico# cat /etc/rc.d/rc.alsa
#!/bin/sh
# Load the mixer settings and OSS compatibility for ALSA.
# (the Advanced Linux Sound Architecture)
# A function to load the ALSA mixer settings:
load_alsa_mixer() {
if [ -r /etc/asound.state ]; then
echo "Loading ALSA mixer settings: /usr/sbin/alsactl restore"
/usr/sbin/alsactl restore
else
# It's possible a user might not want to set a default sound state.
# In that case, do this: touch /etc/no.asound.state
if [ ! -r /etc/no.asound.state ]; then
echo "Setting default ALSA mixer settings."
# set default mixer volumes for ALSA
# Taken from the alsaconfig script.
amixer -s -q <<EOF
set Master 75% unmute
set Master -12dB
set 'Master Mono' 75% unmute
set 'Master Mono' -12dB
set Front 75% unmute
set Front -12dB
set PCM 90% unmute
set PCM 0dB
mixer Synth 90% unmute
mixer Synth 0dB
mixer CD 90% unmute
mixer CD 0dB
# mute mic
set Mic 0% mute
# ESS 1969 chipset has 2 PCM channels
set PCM,1 90% unmute
set PCM,1 0dB
# Trident/YMFPCI/emu10k1
set Wave 100% unmute
set Music 100% unmute
set AC97 100% unmute
# CS4237B chipset:
set 'Master Digital' 75% unmute
# Envy24 chips with analog outs
set DAC 90% unmute
set DAC -12dB
set DAC,0 90% unmute
set DAC,0 -12dB
set DAC,1 90% unmute
set DAC,1 -12dB
# some notebooks use headphone instead of master
set Headphone 75% unmute
set Headphone -12dB
set Playback 100% unmute
# turn off digital switches
set "SB Live Analog/Digital Output Jack" off
set "Audigy Analog/Digital Output Jack" off
EOF
echo "Storing default ALSA mixer settings: /usr/sbin/alsactl store"
/usr/sbin/alsactl store
fi
fi
}
# A function to load the ALSA OSS compat modules:
load_alsa_oss_modules() {
if ! cat /proc/modules | tr _ - | grep -wq snd-pcm-oss ; then
echo "Loading OSS compatibility modules for ALSA."
modprobe snd-pcm-oss
modprobe snd-seq-oss
modprobe snd-mixer-oss
fi
}
# If hotplug or something else has loaded the ALSA modules, then
# simply load the mixer settings and make sure the OSS compat
# modules are loaded:
if [ -d /proc/asound ]; then
load_alsa_oss_modules
load_alsa_mixer
else
# If there are ALSA modules defined in /etc/modules.conf, but
# ALSA is not yet loaded, then load the modules now:
DRIVERS=$(modprobe -c | grep -E "^[[:space:]]*alias[[:space:]]+snd-card-[[:digit:]]" | tr -s "[[:space:]]" " " | cut -d " " -f 3)
if [ ! "$DRIVERS" = "" ]; then
echo "Loading ALSA kernel modules."
for module in $DRIVERS; do
modprobe $module
done
fi
# If ALSA is now up, then load the mixer settings and OSS modules:
if [ -d /proc/asound ]; then
load_alsa_oss_modules
load_alsa_mixer
fi
fi
Se metti questo comando in rc.local che succedeN1cuz ha scritto:non cambia niente, anche col vecchio rc.M il suono mi torna alle impostazioni precedenti a quelle salvate quando riavvio...
Codice: Seleziona tutto
/usr/sbin/alsactl restore