How can I use pactl commands for volume changes

asked 2020-03-03 22:27:12 +0200

Ralf gravatar image

updated 2020-03-03 22:33:42 +0200

In spite of at the risk of someone closing this question as a duplication, I would like to ask a expert here how can I use the pactl command right to adjust the volume of microphones, speakers, earphones, headset and Bluetooth devices.
I have a Sony Xperia 10 Dual with SFOS 3.2.1.20 and I am unhappy with some volume settings. For example, the volume (speaker ans micro) of Android apps like WhatsApp is very quiet and the call volume is also very low. While I was looking for here in the forum and I found a lot of splitted knowledge. But no question went deeper and in detail into the pactl command.
So I used the commands pactl list sinks and pactl list sourses to list all the available destinations.
Then I tested pactl set-volume-sink 0 150% and pactl set-volume-sink 1 150% and pactl set-volume-sink 2 150% but it not work for the BT headset. Maybe I have to restart the pulseaudio service? I tested systemctl restart pulseaudio.service but got a Error6. If I use systemctl --user restart pulseaudio.service I got the same Error. For micro I used pactl set-volume-source 2 150% and this works.

I create this two files: pactl list sinks.txt and pactl list sources.txt Now I have a few questions because I couldn't change the volume of the speaker.

  1. Could anybody explain me the sinks 0 - 1 - 2 ? Which sink is what? I need more Volume on my headset BH-505 from Nokia for Sailfish and Android Apps, but will not more volume on the speaker because I am affraid that I kill it.
    Sink #0 Status: SUSPENDED Name: sink.primary_output Description: Droid sink primary_output
    Sink #1 Status: SUSPENDED Name: sink.deep_buffer Description: Droid sink deep_buffer
    Sink #2 Status: SUSPENDED Name: sink.null Description: Null-Ausgabe

  2. Could anybody explain me the sources 0 - 1 - 2 - 3 - 4 ? Which sink is what?
    Source #0 Status: SUSPENDED Name: sink.primary_output.monitor Description: Monitor of Droid sink primary_output
    Source #1 Status: SUSPENDED Name: sink.deep_buffer.monitor Description: Monitor of Droid sink deep_buffer
    Source #2 Status: SUSPENDED Name: source.droid Description: Droid source droid
    Source #3 Status: SUSPENDED Name: sink.null.monitor Description: Monitor of Null-Ausgabe
    Source #4 Status: SUSPENDED Name: source.null Description: Null Input

  3. It is necessary to restart the pulseaudio service or the app which give the audiosignal after a change?

  4. I noticed also that all changes will reseted after a restart, but this is not so bad, because I have the app ShellEx. But maybe it is possible to change a config file? Where is this located?

I have suggest very often, that SFOS should be have a bigger developer settings area with many settings for experts. Maybe is this also a categorie.

Thanks for all posts in advance and please do not close this question so early, because I saw that many users are interested on this.

edit retag flag offensive close delete

Comments

1

Thx for the question. I have XA2 and handset call volume is way too low but the speaker call volume is too high. So no nice midle ground :(.

Filip K. ( 2020-03-04 00:42:04 +0200 )edit

Did you run pactl list sinks while your headset connection was established? The headset should show up as a sink in the list.

tmy ( 2020-03-04 10:21:03 +0200 )edit
1

@tmy - Thanks good idea I will list with connected headset aggain.

Ralf ( 2020-03-04 19:32:12 +0200 )edit

@tmy - You solve one question! Thanks a lot! If I list with connected BT headset it's listed a new sink no 5. And if I use pactl set-volume-sink 5 150% the volume from the BT headset is higher without restarting pulseaudio. Now I need only a description what are the rest of sinks. I mean sink2 is the speaker. But no idea what is sink0 and sink1. The same question to the sources. I will test and answer maybe here my own question. See you and perfect help!

Ralf ( 2020-03-04 19:55:53 +0200 )edit