Page 3 of 4
Re: KLV-Spectr running a Spectrwm Tiling Window Manager
Posted: Thu Jun 01, 2023 2:31 am
by geo_c
@rockedge what do you think would be a good pulse audio volume mixer for KLV-spectr?
I'm seeing a lot of different mixers in the void repos, in particular several cli and ncurses mixers.
I do like the mixer in KLV-airedale.
EDiT: I'm now realizing pavucontrol is installed, but when I try to run it I get the message: Establising conncection to Pulse Audio, please wait....
And it just hangs there.
Re: KLV-Spectr running a Spectrwm Tiling Window Manager
Posted: Thu Jun 01, 2023 5:24 am
by rockedge
@geo_c we will need to check some permissions and how pulseaudio is being started. This has arisen before but at the moment it's hard to check because I am away form my desk and the machines that have the stuff on them.
I'll review the docs from here again....
Re: KLV-Spectr running a Spectrwm Tiling Window Manager
Posted: Thu Jun 01, 2023 11:10 am
by geo_c
rockedge wrote: Thu Jun 01, 2023 5:24 am
@geo_c we will need to check some permissions and how pulseaudio is being started. This has arisen before but at the moment it's hard to check because I am away form my desk and the machines that have the stuff on them.
I'll review the docs from here again....
Yes, I thought maybe I asked this question before, but I couldn't find it in the threads. I'll dig it up.
EDIT: so I found the question here: viewtopic.php?p=88594#p88594
I tried running the terminal commands again, thinking maybe a system update reset something, but I'm getting the same result. Establishing a connection please wait.
Re: KLV-Spectr running a Spectrwm Tiling Window Manager
Posted: Fri Jun 02, 2023 2:08 pm
by Sofiya
geo_c wrote: Thu Jun 01, 2023 11:10 am
rockedge wrote: Thu Jun 01, 2023 5:24 am
@geo_c we will need to check some permissions and how pulseaudio is being started. This has arisen before but at the moment it's hard to check because I am away form my desk and the machines that have the stuff on them.
I'll review the docs from here again....
Yes, I thought maybe I asked this question before, but I couldn't find it in the threads. I'll dig it up.
EDIT: so I found the question here: viewtopic.php?p=88594#p88594
I tried running the terminal commands again, thinking maybe a system update reset something, but I'm getting the same result. Establishing a connection please wait.
Try deleting the Pulse folder "/root/.config/pulse " , and restart X
Re: KLV-Spectr running a Spectrwm Tiling Window Manager
Posted: Fri Jun 02, 2023 11:51 pm
by geo_c
Sofiya wrote: Fri Jun 02, 2023 2:08 pm
Try deleting the Pulse folder "/root/.config/pulse " , and restart X
Well, I tried deleting /root/.config/pulse and rebooting, I didn't try restarting x, as I thought rebooting should be just as effective.
ran pavucontrol, no connection to pulse
Then I tried deleting the pulse folder again, running the commands @rockedge mentioned in the other thread, then rebooting
but I got the same result.
Pulseaudio works, as I'm getting sound through my sound cards, though sometimes it's the built-in sound card on the laptop, other times the usb audio interface.
I seem to remember a way to start pavucontrol with a switch option or run-as option. But I could be imagining that.
Re: KLV-Spectr running a Spectrwm Tiling Window Manager
Posted: Sat Jun 03, 2023 12:08 am
by rockedge
@geo_c that could be it. pulseaudio might be started with either run-as-spot
or sudo -u spot
but we'll need to check it.
I am still in Colorado and can't really check it out.
Re: KLV-Spectr running a Spectrwm Tiling Window Manager
Posted: Sat Jun 03, 2023 12:37 am
by geo_c
rockedge wrote: Sat Jun 03, 2023 12:08 am
@geo_c that could be it. pulseaudio might be started with either run-as-spot
or sudo -u spot
but we'll need to check it.
I am still in Colorado and can't really check it out.
Hey no hurry, spectrwm still works, I'm just tweaking! Posting from it now.
Re: KLV-Spectr running a Spectrwm Tiling Window Manager
Posted: Sat Jun 03, 2023 12:52 am
by geo_c
@rockedge and @Sofiya
This worked!
Re: KLV-Spectr running a Spectrwm Tiling Window Manager
Posted: Sat Jun 03, 2023 1:13 am
by geo_c
geo_c wrote: Sat Jun 03, 2023 12:52 am
@rockedge and @Sofiya This worked!
Well, not exactly.
pavucontrol booted up and displayed the controls, but I lost sound while it was running and the speaker icons all had 'x's on them, which couldn't be switched on.
making headway a little at a time.
Re: KLV-Spectr running a Spectrwm Tiling Window Manager
Posted: Sat Jun 03, 2023 11:14 am
by Sofiya
geo_c wrote: Sat Jun 03, 2023 1:13 am
geo_c wrote: Sat Jun 03, 2023 12:52 am
@rockedge and @Sofiya This worked!
Well, not exactly.
pavucontrol booted up and displayed the controls, but I lost sound while it was running and the speaker icons all had 'x's on them, which couldn't be switched on.
making headway a little at a time.
Apparently you need to run pavucontrol and pulseaudio how " spot "
run-as-spot pavucontrol
[ "$USER" == "spot" ] && pulseaudio --start
or sudo -u spot pulseaudio --start
Do you have a Startup folder?
Re: KLV-Spectr running a Spectrwm Tiling Window Manager
Posted: Sat Jun 03, 2023 11:29 am
by geo_c
Sofiya wrote: Sat Jun 03, 2023 11:14 am
Apparently you need to run pavucontrol and pulseaudio how " spot "
run-as-spot pavucontrol
[ "$USER" == "spot" ] && pulseaudio --start
or sudo -u spot pulseaudio --start
Do you have a Startup folder?
Yes, Startup was one of the few folders present in /root built-in.
I think we discussed putting a script in it at one time.
Re: KLV-Spectr running a Spectrwm Tiling Window Manager
Posted: Sat Jun 03, 2023 11:31 am
by Sofiya
geo_c wrote: Sat Jun 03, 2023 11:29 am
Sofiya wrote: Sat Jun 03, 2023 11:14 am
Apparently you need to run pavucontrol and pulseaudio how " spot "
run-as-spot pavucontrol
[ "$USER" == "spot" ] && pulseaudio --start
or sudo -u spot pulseaudio --start
Do you have a Startup folder?
Yes, Startup was one of the few folders present in /root built-in.
I think we discussed putting a script in it at one time.
then put the script there
in /root/Startup - Make executable
Code: Select all
#!/bin/bash
sudo -u spot pulseaudio --start
in /usr/share/applications
Code: Select all
[Desktop Entry]
Encoding=UTF-8
Type=Application
Exec=pavucontrol
Icon=multimedia-volume-control
Comment[en]=Setting the volume level
Categories=AudioVideo;Audio;Mixer;GTK;Settings;
Edit :Firstly, it will be easier to substitute commands and check how it works
Re: KLV-Spectr running a Spectrwm Tiling Window Manager
Posted: Sat Jun 03, 2023 12:42 pm
by geo_c
Sofiya wrote: Sat Jun 03, 2023 11:31 am
Edit :Firstly, it will be easier to substitute commands and check how it works
I put the startup script in Startup and changed the desktop file and rebooted.
Then I opened up a browser to check that audio was working, played a video and the audio worked fine.
Then I opened pavucontrol from the terminal with run-as-spot pavucontrol which connected to pulseaudio and booted, but the audio in the browser stopped working, and the speaker icons active checkbox couldn't be switched on.
The volume sliders were active, but did nothing.
So I suppose if I'm running pulseaudio as spot, and pavucontrol as spot, any applications trying to access audio would also have to run-as-spot?
I thought this was all working, so the only thing I can think that would have caused it to stop would be a system update.
afterthought: I wonder if I should delete the pulseaudio folder again and restartx
Re: KLV-Spectr running a Spectrwm Tiling Window Manager
Posted: Sat Jun 03, 2023 12:47 pm
by Sofiya
geo_c wrote: Sat Jun 03, 2023 12:42 pm
Sofiya wrote: Sat Jun 03, 2023 11:31 am
Edit :Firstly, it will be easier to substitute commands and check how it works
I put the startup script in Startup and changed the desktop file and rebooted.
Then I opened up a browser to check that audio was working, played a video and the audio worked fine.
Then I opened pavucontrol from the terminal with run-as-spot pavucontrol which connected to pulseaudio and booted, but the audio in the browser stopped working, and the speaker icons all had 'x's which couldn't be switched on.
The volume sliders were active, but did nothing.
So I suppose if I'm running pulseaudio as spot, and pavucontrol as spot, any applications trying to access audio would also have to run-as-spot?
I thought this was all working, so the only thing I can think that would have caused it to stop would be a system update.
afterthought: I wonder if I should delete the pulseaudio folder again and restartx
try starting as standard ( start-pulseaudio-x11 )
and just ( pavucontrol )
Re: KLV-Spectr running a Spectrwm Tiling Window Manager
Posted: Sat Jun 03, 2023 1:26 pm
by geo_c
Well, audio is working, but still no luck with pavucontrol. I'm gonna give it a rest, as I have to go setup for some music recitals today.
I tried it several ways, with a startup script starting pulseaudio as spot, and without it, and starting pavucontrol as spot, and also normally.
The basic error is below, the first command (without a pulseaudio run-as-spot script gives the establishing connection window that hangs, the second command opens pavucontrol, but it's not functioning, and locks out other applications from playing audio. When I run pulseaudio as spot I get the exact same thing:

Re: KLV-Spectr running a Spectrwm Tiling Window Manager
Posted: Tue Jun 06, 2023 8:13 pm
by rockedge
It just might be the polkit installation. I did deal with it in KLV Airedale.
I am still 2000 miles from home until Sunday so can't really work on it
Re: KLV-Spectr running a Spectrwm Tiling Window Manager
Posted: Wed Jun 07, 2023 1:55 am
by geo_c
Well I was just perusing the "enter-the-void" package repo site, and I happened upon the home page where announcements were made.
I have to wonder if this May 30th change might have something to do with the permissions issue:
Pipewire and PulseAudio system service removal
The oft-confusing services for pipewire, pipewire-pulse, wireplumber, and pulseaudio have been removed from the pipewire, wireplumber, and pulseaudio packages because they were experimental and should not have been used for almost all use-cases.
If you are currently using those services and still wish to do so, replacements for the pipewire and pulseaudio services can be found in /usr/share/examples/$pkgname/sv/. Otherwise, it is recommended to migrate to another method of launching pipewire. Refer to Void documentation if you need guidance.
Yet KLV's pavucontrol is still working normally for me, so the above may not have anything at all to do with it.
My real question now is whether the pavucontrol was ever truly working for me, as I may have fired it up and never actually used it in the past. Since pulseaudio is working, I normally just adjust my volumes in KLV-spectr from the application playing audio.
Re: KLV-Spectr running a Spectrwm Tiling Window Manager
Posted: Wed Jun 07, 2023 3:51 am
by wiak
geo_c wrote: Wed Jun 07, 2023 1:55 am
My real question now is whether the pavucontrol was ever truly working for me, as I may have fired it up and never actually used it in the past. Since pulseaudio is working, I normally just adjust my volumes in KLV-spectr from the application playing audio.
I haven't really been following this discussion (not following any closely at the moment), but what I have read I don't really understand. The main thing is to get pulseaudio working and above says it is. Pavucontrol is just a volume control/mixer that attaches to pulseaudio. Of course it will fail to attach if being run as different user/environment than that pulseaudio has been started with. So you need to check how pulseaudio has been started and by who (are you running as root and is pulseaudio being started for root user). It is possible to login as root user and start pulseaudio as non-root-user and then if you start pavucontrol as root user I imagine it will fail to connect. I don't know much/anything really about pulseaudio operation but I believe (?) it uses dbus to connect between bits and pieces so I guess that comes into who has permissions to use which dbus channel? I'd just check therefore how pulseaudio is being started, and by whom, and then check for compatibility on how pavucontrol is then being started. Since pavucontrol maybe being started by root directly that implies you must use a root-started directly pulseaudio to me or make sure both are started as same non-root user with all permissions and group rights needed for correct use of pulseaudio. Sorry, don't have time to experiment so just comments.
Re: KLV-Spectr running a Spectrwm Tiling Window Manager
Posted: Wed Jun 07, 2023 8:47 pm
by rockedge
We will review how KLV audio is working and compare to the recommended methods.
KLV-AIREDALE audio is working fine for me here on a resurrected gaming computer with a good GPU.
Amazed how great KLV is performing on it.
Does the Void Linux announcement mean don't run pulseaudio and pipewire as system services?
In KLV-AIREDALE pulseaudio is not started as a service, but by a tiny script in /root/Startup.
This might be the difference between Airedale and Spectrum............
Re: KLV-Spectr running a Spectrwm Tiling Window Manager
Posted: Thu Jun 08, 2023 1:31 am
by geo_c
rockedge wrote: Wed Jun 07, 2023 8:47 pm
In KLV-AIREDALE pulseaudio is not started as a service, but by a tiny script in /root/Startup.
This might be the difference between Airedale and Spectrum............
I explored this a little further. Indeed in KLV-spectrwm there is a broken link in /var/service to /etc/sv/pulseaudio.
It seems likely that a system update removed the files in /etc/sv/pulseaudio.

So I suppose the pulsesaudio service is started some how in the init files, but it seems like maybe if I remove the link from /var/service and restart pulse audio maybe it would work. I'm not sure I have enough knowledge to pull that off. I could stop this service in the terminal and then run pulseaudio from the terminal and see what happens. Or maybe the pulseaudio service isn't running at all. Could it be that the reason I get sound is because it's being handled by alsa?
Re: KLV-Spectr running a Spectrwm Tiling Window Manager
Posted: Fri Jun 09, 2023 3:58 am
by geo_c
So for some reason my previous post is dated June 07, even though the clock in the Spectrwm status bar says Thu Jun 08. And this seems like a cue for me to bring up the inconsistent time behaviors I've been experiencing.
At the moment I'm on 'machine #2' which I copied upper_changes to from 'machine #1."
The clock in the status bar of "machine #1" has been displaying 4 hours behind for about a week. I suspected maybe it had to with the hardware clock, but other applications on that machine "#1" display the correct time. So I thought maybe it's how the script is working. I haven't fretted about it much, but it is curious.
So I moved the most recent changes to "Machine #2" which I'm posting from at the moment, and the Spectrwm status bar is displaying the correct time. All well and good, first thought is it confirms the hardware clock theory (though like I say, on machine #1 other apps and OS's are reporting the correct time.)
But then I see that my post above is a day behind.
Could be the forum I suppose, but I thought the clock behavior is worth mentioning.
Re: KLV-Spectr running a Spectrwm Tiling Window Manager
Posted: Fri Jun 09, 2023 4:34 am
by rockedge
@geo_c try this:
It seems likely that a system update removed the files in /etc/sv/pulseaudio
replace the directory with /usr/share/examples/pulseaudio/sv/pulseaudio
OR (if we implemented the /root/Startup directory) go to the KLV-Airedale method and copy the /root/Startup/start_pulseaudio
script to KLV-Spectr /root/Startup
and leave the service files removed.
Re: KLV-Spectr running a Spectrwm Tiling Window Manager
Posted: Fri Jun 09, 2023 5:28 am
by geo_c
rockedge wrote: Fri Jun 09, 2023 4:34 am
@geo_c try this:
go to the KLV-Airedale method and copy the /root/Startup/start_pulseaudio
script to KLV-Spectr /root/Startup
and leave the service files removed.
Well dang, I got it all running simply by opening a terminal and trying to kill pulseaudio with pulseaudio --kill which returned "no such process," then running the command pulseaudio --start.
I put the KLV-airedale script in /root/Startup which is the exact same command, but pavucontrol couldn't connect, so I ran the terminal commands, and bang, pavucontrol worked perfectly.
So I'm at a loss as to why the startup script didn't work. Maybe because I created the folder in KLV-spectr's upper_changes while I was booted in KLV-airdale and copied the file, but it appeared in the existing Startup folder when I booted back into KLV-spectr.
So anyway. Both pulse and pavucontrol work by starting pulse manually. I don't know how I missed that combination before.
Re: KLV-Spectr running a Spectrwm Tiling Window Manager
Posted: Fri Jun 09, 2023 10:52 am
by Sofiya
geo_c wrote: Fri Jun 09, 2023 5:28 am
rockedge wrote: Fri Jun 09, 2023 4:34 am
@geo_c try this:
go to the KLV-Airedale method and copy the /root/Startup/start_pulseaudio
script to KLV-Spectr /root/Startup
and leave the service files removed.
Well dang, I got it all running simply by opening a terminal and trying to kill pulseaudio with pulseaudio --kill which returned "no such process," then running the command pulseaudio --start.
I put the KLV-airedale script in /root/Startup which is the exact same command, but pavucontrol couldn't connect, so I ran the terminal commands, and bang, pavucontrol worked perfectly.
So I'm at a loss as to why the startup script didn't work. Maybe because I created the folder in KLV-spectr's upper_changes while I was booted in KLV-airdale and copied the file, but it appeared in the existing Startup folder when I booted back into KLV-spectr.
So anyway. Both pulse and pavucontrol work by starting pulse manually. I don't know how I missed that combination before.
it's usually correct to restart pulseaudio
Code: Select all
1) pulseaudio -k
2) pulseaudio --start
Re: KLV-Spectr running a Spectrwm Tiling Window Manager
Posted: Fri Jun 09, 2023 11:27 am
by geo_c
Sofiya wrote: Fri Jun 09, 2023 10:52 am
it's usually correct to restart pulseaudio
Code: Select all
1) pulseaudio -k
2) pulseaudio --start
That is in fact exactly what I typed in the terminal.
So I'm going to put the pulseaudio -k line in the /root/Startup script and see if it works without having to run the commands manually.
FOLLOW-UP: Tried modifying the script and rebooting. And for some reason the Startup script doesn't do it. But the terminal commands do work perfectly.
But when I run pulseaudio -k it returns that there is no such running process. So it seems like the pulseaudio -k command shouldn't be needed at all.
Re: KLV-Spectr running a Spectrwm Tiling Window Manager
Posted: Fri Jun 09, 2023 5:26 pm
by rockedge
Then we need to review if all the pieces were installed to make the /root/Startup actually work.
I might have not fully implemented it
If @fredx181 possibly could again review if I installed the little components needed to run the scripts at system start 
Or we place the commands for pulseaudio in another location in the boot stages
Re: KLV-Spectr running a Spectrwm Tiling Window Manager
Posted: Sat Jun 10, 2023 7:49 pm
by fredx181
rockedge wrote: Fri Jun 09, 2023 5:26 pm
Then we need to review if all the pieces were installed to make the /root/Startup actually work.
I might have not fully implemented it
If @fredx181 possibly could again review if I installed the little components needed to run the scripts at system start 
Or we place the commands for pulseaudio in another location in the boot stages
In KLV-Airedale, the script start-up is started from /root/.xinitrc, I suppose it should work the same in spectrwm, make last lines; (untested)
Code: Select all
# rox -p default
/usr/local/bin/start-up &
spectrwm
Re: KLV-Spectr running a Spectrwm Tiling Window Manager
Posted: Sun Jun 11, 2023 2:37 am
by geo_c
fredx181 wrote: Sat Jun 10, 2023 7:49 pm
In KLV-Airedale, the script start-up is started from /root/.xinitrc, I suppose it should work the same in spectrwm, make last lines; (untested)
Code: Select all
# rox -p default
/usr/local/bin/start-up &
spectrwm
Thanks @fredx181, @rockedge, and @Sofiya
Modifying the /root/.xinitrc and adding a pulseaudio --start script in /root/Startup got everything working normally!
Now I've been playing around with workspaces and I'm going to dig into the Spectrwm some more and figure out how to edit the spectrwm.conf to open preconfigured workspaces. Switching workspaces is fast and efficient in this desktop environment.
Re: KLV-Spectr running a Spectrwm Tiling Window Manager
Posted: Sun Jun 11, 2023 6:16 am
by rockedge
@geo_c I am interested in the progress you're making with the configuration of the workspaces and how the conf file looks
Re: KLV-Spectr running a Spectrwm Tiling Window Manager
Posted: Sun Jun 11, 2023 10:39 am
by geo_c
rockedge wrote: Sun Jun 11, 2023 6:16 am
@geo_c I am interested in the progress you're making with the configuration of the workspaces and how the conf file looks
Will do, I'll report back once I get to work on it.
An interesting thing about the pulse startup script in Startup. I thought it worked on the first test, but this morning it was not working, so I added xterm -e to the script (which I also had done to my pavucontrol launcher script and booted a couple of times, and now it works consistently:
/root/Startup/start_pulseaudio
/root/my-applications/bin/pavucontrol.sh