# KDE Plasma 5 cannot control volume after upgrade



## Quip (Jun 10, 2022)

I upgraded my old desktop computer to FreeBSD 13.1 with KDE Plsama 5.24.5. It booted fine but no sound output.
There are 4 sound devices:


```
% ll /dev/dsp*
crw-rw-rw-  1 root  wheel  0x12c 10 Jun 15:08 /dev/dsp0.0
crw-rw-rw-  1 root  wheel  0x129 10 Jun 17:47 /dev/dsp3.0
crw-rw-rw-  1 root  wheel  0x12a 10 Jun 15:04 /dev/dsp3.1
crw-rw-rw-  1 root  wheel  0x12b 11 Jun 00:26 /dev/dsp3.2
```

pcm2 was default, it must be changed to pcm3 (`sysctl hw.snd.default_unit=3`) and sound works now in applications like Firefox, Audacious, SMPlayer etc.


```
% cat /dev/sndstat
Installed devices:
pcm0: <NVIDIA (0x0051) (HDMI/DP 8ch)> (play)
pcm1: <NVIDIA (0x0051) (HDMI/DP 8ch)> (play)
pcm2: <Realtek ALC280 (Analog 2.0+HP/2.0)> (play/rec)
pcm3: <Realtek ALC280 (Rear Analog)> (play/rec) default
```

But in System Settings / Audio there is only /dev/dsp as Playback Device and this cannot be changed to anything else. Volume control in this window does not work.
The speaker icon in tray shows /dev/dsp and volume 100% too, slider can be moved by mouse but the loundess is the same. 
It means KDE Plasma cannot control volume of the output.

I installed audio/kmix which shows all sound devices and can control the output volume just fine. (now I have two speaker icons in tray)

But what's wrong with default audio control in Plasma? It seems odd to me to install kmix if there is a newer plasma5-plasma-pa installed.
If plasma5-plasma-pa cannot control audio volume how can I change the default app to kmix? I don't want two speaker icons in tray.


----------



## grahamperrin@ (Jun 11, 2022)

Try the developer response to <https://forums.freebsd.org/posts/560961>.

Maybe also USB Audio Devices, detected but not usable : freebsd

If audio/plasma5-plasma-pa does not work as expected, maybe open a bug report but first, let's try to determine the scope of the issue.


----------



## Quip (Jun 11, 2022)

grahamperrin@ said:


> Try the developer response to <https://forums.freebsd.org/posts/560961>.
> 
> Maybe also USB Audio Devices, detected but not usable : freebsd


I already read these 2 threads before I posted mine. I cannot found information how / where /dev/dsp should be changed with audio/plasma5-plasma-pa.
I am not sure if something is broken or if I just didn't found where to switch it.

Are you able to change audio devices in default KDE Plasma installation?


----------



## grahamperrin@ (Jun 11, 2022)

Quip said:


> … Are you able to change audio devices in default KDE Plasma installation?



I'll try later. (Currently upgrading the OS on an old notebook that I got today.)

Beyond the default: I use GTK-Mixer.


----------



## Quip (Jun 11, 2022)

I dug a bit deeper - anything PulseAudio related does not list any of my soundcard devices (I tried PulseEffects now)


```
% pacmd list-sinks | grep -e 'name:' -e 'index:'
    index: 0
        name: <output>
  * index: 1
        name: <PulseEffects_apps>
    index: 2
        name: <PulseEffects_mic>

% pacmd list-cards
0 card(s) available.
```


----------



## grahamperrin@ (Jun 12, 2022)

Quip said:


> Are you able to change audio devices in default KDE Plasma installation?



Yes, however PulseAudio does not detect the _USB audio_ device: 


```
root@fuji:~ # cat /dev/sndstat
Installed devices:
pcm0: <Realtek ALC662 rev1 (Analog 2.0+HP/2.0)> (play/rec) default
pcm1: <Realtek ALC662 rev1 (Left Digital)> (play)
pcm2: <USB audio> (play/rec)
No devices installed from userspace.
root@fuji:~ # freebsd-version -kru ; uname -KU
13.1-RELEASE
13.1-RELEASE
13.1-RELEASE
1301000 1301000
root@fuji:~ #
```


----------



## Quip (Jun 12, 2022)

It is strange that PA does not sees my cards.
It was working before upgrade (it was very old - FreeBSD 11.4 and KDE from the same era) but does not work now. 

What more can I try? I never need to configure anything in PulseAudio settings so I really don't know where or what to try even if I tried to find something on the internet.


----------



## grahamperrin@ (Jun 12, 2022)

PulseAudio​Reading <https://www.freshports.org/audio/pulseaudio/#message> alongside <https://wiki.freebsd.org/Sound> and <https://docs.freebsd.org/en/books/handbook/multimedia/>, I don't know what to think.

hselasky@ please, are we overlooking something?

(For PulseAudio to detect more devices.)


----------



## bsduck (Jun 12, 2022)

Quip said:


> It was working before upgrade (it was very old - FreeBSD 11.4 and KDE from the same era) but does not work now.


Probably PulseAudio wasn't used before, and got installed with the system upgrade, therefore the change in behaviour.

If you don't want to fight against PA, just disable it (in desktop startup settings, or whatever similar place) and use audio/kmix instead of plasma5-plasma-pa.

The sooner we'll get rid of this Poetterware on default KDE installs, the better, but that's just my opinion...


----------



## Quip (Jun 14, 2022)

bsduck said:


> Probably PulseAudio wasn't used before, and got installed with the system upgrade, therefore the change in behaviour.


I have saved list of all ports installed before upgrade and audio/pulseaudio was there, audio/kmix too.

I am fine with kmix but I read elsewhere that current Plasma desktop should be better with pa / PulseAudio, that's why I am trying to set it up correctly and find a reason why it does not see my soundcard. But if it will not work, I will live with kmix.


----------



## grahamperrin@ (Jun 14, 2022)

bsduck said:


> get rid



I understand, however "good riddance" is not an incentive to gain assistance from developers.


----------

