Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
[SOLVED]Can't set default volume since plasma profile update
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Multimedia
View previous topic :: View next topic  
Author Message
Lumpy Gravy
n00b
n00b


Joined: 28 Dec 2016
Posts: 41
Location: France

PostPosted: Fri Jun 30, 2023 7:12 am    Post subject: [SOLVED]Can't set default volume since plasma profile update Reply with quote

Hello everybody,

Since the Plasma Profile update to enable PipeWire, I have some audio issue.
First I couldn't set the soundcards order I wanted so I just disabled the hdmi-audio and onboard-audio (wich I do not use) from my kernel config, leaving just usb-audio and I'm fine with it.
But at each boot, I have to open alsamixer to set the volume from -73db to -6db
I tried 'alsactl store' as user and as root but nothing changes.
Is there a file where I could set the right value?

Thanks in advance.


Last edited by Lumpy Gravy on Wed Jul 19, 2023 8:59 am; edited 1 time in total
Back to top
View user's profile Send private message
flexibeast
Guru
Guru


Joined: 04 Apr 2022
Posts: 324
Location: Naarm/Melbourne, Australia

PostPosted: Sat Jul 01, 2023 3:30 am    Post subject: Reply with quote

The man page for alsactl(1) says:
Quote:
/var/lib/alsa/asound.state (or whatever file you specify with the -f flag) is used to store current settings for your soundcards. The settings include all the usual soundcard mixer settings.

So you could check what's happening to that file. Is it perhaps on a volatile partition?
Back to top
View user's profile Send private message
Lumpy Gravy
n00b
n00b


Joined: 28 Dec 2016
Posts: 41
Location: France

PostPosted: Sat Jul 01, 2023 6:31 am    Post subject: Reply with quote

I checked the file, it exists and it's not on a volatile partition:

Code:
state.Pro {
        control.1 {
                iface PCM
                name 'Playback Channel Map'
                value.0 0
                value.1 0
                comment {
                        access read
                        type INTEGER
                        count 2
                        range '0 - 36'
                }
        }
        control.2 {
                iface MIXER
                name 'Radial USB Pro Output Playback Switch'
                value.0 true
                value.1 true
                comment {
                        access 'read write'
                        type BOOLEAN
                        count 2
                }
        }
        control.3 {
                iface MIXER
                name 'Radial USB Pro Output Playback Volume'
                value.0 122
                value.1 122
                comment {
                        access 'read write'
                        type INTEGER
                        count 2
                        range '0 - 127'
                        dbmin -12700
                        dbmax 0
                        dbvalue.0 -500
                        dbvalue.1 -500
                }
        }
}


The db values seem arbitrary to me but with "alsactl restore" as root, the volume is set to the desired level.
I can add this command at boot but all was working perfectly well without me doing anything before, that's why I'm asking.

Thanks anyway.
Back to top
View user's profile Send private message
flexibeast
Guru
Guru


Joined: 04 Apr 2022
Posts: 324
Location: Naarm/Melbourne, Australia

PostPosted: Sat Jul 01, 2023 6:58 am    Post subject: Reply with quote

Well, i don't use KDE/Plasma myself, but reading the relevant news item, the enabling of PipeWire as the default sound server means PW will be doing manipulations of the hardware sound levels; it won't matter what you do via ALSA if PipeWire is subsequently setting the sound levels itself. So it seems to me that you might need to make a decision as to whether your setup is primarily ALSA-oriented or PipeWire-oriented, and then make the appropriate changes as described in the news item.
Back to top
View user's profile Send private message
Lumpy Gravy
n00b
n00b


Joined: 28 Dec 2016
Posts: 41
Location: France

PostPosted: Sun Jul 02, 2023 6:10 am    Post subject: Reply with quote

flexibeast wrote:
So it seems to me that you might need to make a decision as to whether your setup is primarily ALSA-oriented or PipeWire-oriented, and then make the appropriate changes as described in the news item.


I thought that what I did.
I followed this:

Code:

1. To use PipeWire for sound, users should enable USE=sound-server for PipeWire:

  Place the following entries in /etc/portage/package.use:
  ```
  media-video/pipewire sound-server
  media-sound/pulseaudio -daemon
  ```

  First, sync:
  # emerge --sync

  Deselect media-sound/pulseaudio-daemon:
  # emerge --deselect media-sound/pulseaudio-daemon

  Then perform a world upgrade with PipeWire on the command line to add
  it to the world file:
  # emerge --ask --update --changed-use --deep @world media-video/pipewire

  Then depclean:
  # emerge --ask --depclean

  OpenRC users on an XDG-compliant desktop which respects autostart files
  will not need to take any further action.


Last edited by Lumpy Gravy on Mon Jul 03, 2023 4:31 am; edited 1 time in total
Back to top
View user's profile Send private message
flexibeast
Guru
Guru


Joined: 04 Apr 2022
Posts: 324
Location: Naarm/Melbourne, Australia

PostPosted: Sun Jul 02, 2023 10:51 am    Post subject: Reply with quote

Lumpy Gravy wrote:
I thought that what I did.
I followed this:

Oh, sorry, i wasn't clear. What i was trying to say is: If you're actually using PipeWire (and WirePlumber), manage your volumes via PipeWire and WirePlumber, not via ALSA interfaces. But if you just want to use ALSA directly - which some people do, and which your mention of alsactl suggests you might want to do - then you should make sure that PipeWire and WirePlumber don't get started, otherwise you'll have different sound systems fighting over the actual hardware.
Back to top
View user's profile Send private message
Hu
Moderator
Moderator


Joined: 06 Mar 2007
Posts: 21624

PostPosted: Sun Jul 02, 2023 3:02 pm    Post subject: Reply with quote

Lumpy Gravy wrote:
1. To use PipeWire for sound, users should enable USE=sound-server for PipeWire:

Place the following entries in /etc/portage/package.use:
```
media-video/pipewire sound-server
media-sound/pulseaudio -daemon
```
Gentoo forums do not use Markdown. See BBCode (also linked to the left of the post composition box) for how to decorate your posts with code blocks, among other features.
Back to top
View user's profile Send private message
Lumpy Gravy
n00b
n00b


Joined: 28 Dec 2016
Posts: 41
Location: France

PostPosted: Wed Jul 19, 2023 5:44 am    Post subject: Reply with quote

After a new update, kmix disappeared from my taskbar and I could only set audio levels with alsamixer, so I reverted to PulseAudio.
Now, kmix won't start at boot but can be started from the console with error messages, but sound works ok:

Quote:

$ kmix &
[1] 3000
percent 1 -> divisor 100
org.kde.kmix: no mix devices and not dynamic
org.kde.kmix: no mix devices and not dynamic
org.kde.kmix: no mix devices and not dynamic
org.kde.kmix: no mix devices and not dynamic
org.kde.kmix: no mix devices and not dynamic
org.kde.kmix: no mix devices and not dynamic
org.kde.kmix: no mix devices and not dynamic
org.kde.kmix: no mix devices and not dynamic
org.kde.kmix: no mix devices and not dynamic
org.kde.kmix: no mix devices and not dynamic
org.kde.kmix: no mix devices and not dynamic
org.kde.kmix: no mix devices and not dynamic
org.kde.kmix: no mix devices and not dynamic
org.kde.kmix: no mix devices and not dynamic
org.kde.kmix: no mix devices and not dynamic
org.kde.kmix: no mix devices and not dynamic
org.kde.kmix: Cannot load profile "PulseAudio.Périphériques_de_lecture.1.default"
org.kde.kmix: Cannot load profile "PulseAudio.Périphériques_de_capture.1.default"
org.kde.kmix: Cannot load profile "PulseAudio.Flux_de_lecture.1.default"
org.kde.kmix: Cannot load profile "PulseAudio.Flux_de_capture.1.default"
org.kde.kmix: Could not get icon for "audio-card-usb"
org.kde.kmix: Cannot load profile "PulseAudio.Périphériques_de_lecture.1.default"
org.kde.kmix: Could not get icon for "audio-card-usb"
org.kde.kmix: Cannot load profile "PulseAudio.Périphériques_de_capture.1.default"
org.kde.kmix: Cannot load profile "PulseAudio.Flux_de_lecture.1.default"
org.kde.kmix: Cannot load profile "PulseAudio.Flux_de_capture.1.default"
org.kde.kmix: Could not get icon for "audio-card-usb"
org.kde.kmix: Could not get icon for "audio-card-usb"


Any idea?
Back to top
View user's profile Send private message
rab0171610
Apprentice
Apprentice


Joined: 24 Dec 2022
Posts: 298

PostPosted: Wed Jul 19, 2023 6:31 am    Post subject: Reply with quote

You could easily do away with kmix. You can install and use kde-plasma/plasma-pa. This will replace the kmix icon in the system tray. If you decide to go back to pipewire, 'alsactl store' with sudo or as root will still save the default volumes when using pipewire as the sound server, provided pipewire is built with the pipewire-alsa use flag. The alsactl command should still work with pulseaudio as the sound server daemon. If you set the volume to 60 percent with 'alsactl store', every time you log in the sound should be automatically be set at 60%, this works with pipewire as the sound server and, as I mentioned, should work with pulseaudio.
Back to top
View user's profile Send private message
asturm
Developer
Developer


Joined: 05 Apr 2007
Posts: 8936

PostPosted: Wed Jul 19, 2023 7:42 am    Post subject: Reply with quote

plasma-meta gives you plasma-pa, so there's no need for kmix - and kmix' postinst messages tell you as much.
Back to top
View user's profile Send private message
Lumpy Gravy
n00b
n00b


Joined: 28 Dec 2016
Posts: 41
Location: France

PostPosted: Wed Jul 19, 2023 8:58 am    Post subject: Reply with quote

plasma-pa does the trick, thank you very much!
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Multimedia All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum