Page 1 of 1
Pipewire-Fedora35 live dvd -pipewire is default, audio tools seem OK
Posted: Tue Mar 15, 2022 6:23 am
by glowrak guy
Hi, to test current pipewire,
I burned a Fedora 35 dvd from an iso image, rebooted to Fedora, got aquainted with the default setup,
used it's yum package manager command to install qjackctl, rakarrack, mudita24 (the mixer for my soundcard) and pcmanfm
for a familiar filemanager.
I then copied over my Reaper folder and .config/REAPER folder from AVLinux, adjusted the plugin paths to the
/home/liveuser area, and installed the free U-he Triplecheese plugin, did a rescan, and all is well.
I connected reaper output to rakarrack for some extra effects, again no troubles. Triplecheese pluks played without
any latency I could detect.
I'm no coder, and don't know what pipewire does when qjackctl is launched, but it appears not
to hamper it in typical usage.
There is in fedora /usr/bin, a 'pipewire-pulse' command, no idea how what it does, or how it behaves, but those interested
and familiar with pulse could easily test things of interest.
(the main Fedora menu is called 'Activities' in the upper left, and you can right-click items to become 'favorites,
so they will appear in a panel at the bottom of the screen, that opens when you access the Activities.
I added a terminal, filemanager, qjackctl, and rakarrack to favorites,
to make the test setup.
An example to install something by command,
yum install qjackctl
...and typical package-manager choices follow.
Hope you add your pipewire experience and knowledge here, from whatever distro's you are using.
Cheers
Re: Pipewire-Fedora35 live dvd -pipewire is default, audio tools seem OK
Posted: Tue Mar 15, 2022 6:27 am
by j_e_f_f_g
What happens when you have pipewire running, then take a program that can output directly to ALSA, set it to do that, and try to play audio?
Re: Pipewire-Fedora35 live dvd -pipewire is default, audio tools seem OK
Posted: Tue Mar 15, 2022 7:20 am
by glowrak guy
Hi, I quit qjackctl and reaper, and started yoshimi -a which loads the alsa version.
Seems to work fine, so midi is ok for that app at that basic level. But it's audio is on the motherboard chip,
and I haven't reconfigured yoshimi yet.
I restarted reaper using alsa instead of jackd, It's audio is receiving input, and plays back on using the pci soundcard,
but no midi input is getting through, and the midi controller is activated, same one that plays Yoshimi.
This assumes pipewire is running since it's the default audio, and it is listed in top output.
Re: Pipewire-Fedora35 live dvd -pipewire is default, audio tools seem OK
Posted: Tue Mar 15, 2022 7:35 am
by glowrak guy
So I quit everything, and restart qjackctl. I start both
yoshimi -a
and
yoshimi -j
and both are playing on the motherboard audio, each with different sounds, Alsa and jackd
at the same time, same midi controller (an old Alesis QS8)
In qjackctl, I disconnect both yoshimi's from motherboard audio, and connect them to
the pci card, and both are heard there.
There is only one yoshimi in the midi tabs of qjackctl, since one is on alsa.
Re: Pipewire-Fedora35 live dvd -pipewire is default, audio tools seem OK
Posted: Tue Mar 15, 2022 7:55 am
by glowrak guy
Breaking news, Firefox is now appearing in qjackctl!
I am playing my youtube playlist in firefox, and jamming along with both yoshimi's
and both my motherboard chip output, and my soundcard are are working, just switch the headphones
between them...huzzzahhhhh
I'd call this progress.
Cheers
edit: and this is still in a live-dvd session, on an 8gig memory computer, things can change compared to an install,
hopefully for the better.
Re: Pipewire-Fedora35 live dvd -pipewire is default, audio tools seem OK
Posted: Tue Mar 15, 2022 1:31 pm
by j_e_f_f_g
glowrak guy wrote:
I start both
yoshimi -a
and
yoshimi -j
This is using jack midi and ALSA sequencer (MIDI). Your audio outputs are both still going through jack. In other words, this doesn't test whether pipewire causes problems with app's that use ALSA directly for audio playback/recording.
Alsa and jackd at the same time, same midi controller (an old Alesis QS8)
That's because jack midi goes through ALSA Sequencer. Try an app that uses rawmidi API, along with an app that uses jackmidi or ALSA sequencer, and you should get a "device busy" in one of those apps.
In qjackctl, I disconnect both yoshimi's from motherboard audio, and connect them to the pci card, and both are heard there.
That's because both instances of yoshimi are using jack audio. QJackCtl
does not list alsa pcm devices. It lists only jack ins/outs to applications. If you see a program's name under the "Audio" tab of QJackCtl, then the app is using jack, not alsa directly.
If you see an app listed under "MIDI", then it's using ALSA Sequencer MIDI.
Set an app to use alsa audio output directly, and some app listed in QJackCtl set to the same sound output, and you should see a "device busy" error.
You need to find an app that can use ALSA MIDI and audio directly (like BackupBand). If the app doesn't have some sort of "Sound Setup" configuration built into it that lets you pick a MIDI in/out, and audio in/out, then it's using jack (because there otherwise would be no possible way to set it up).
So you didn't test what I was asking about. But I did learn one thing from your tests. I believe Firefox uses PulseAudio. If Firefox now appears in QJackCtl's Audio listbox (which does not list PulseAudio ins/outs -- only jack ins/outs) under Pipewire, this means that Pipewire is telling apps that they can use PulseAudio ins/outs as if they were jack ins/outs. This Jack and PulseAudio emulation had better be 100% compatible (and I mean 100%) or it's going to start breaking things.
Re: Pipewire-Fedora35 live dvd -pipewire is default, audio tools seem OK
Posted: Tue Mar 15, 2022 2:46 pm
by glowrak guy
In a fresh rebooted fedora live session, the first and only app I open is yoshimi -a
Works fine, midi keyboard working, and when I run top, there is no jackd, and no qjacktl,
the only audio things listed in top are pipewire and yoshimi.
Re: Pipewire-Fedora35 live dvd -pipewire is default, audio tools seem OK
Posted: Tue Mar 15, 2022 3:03 pm
by glowrak guy
Now, I have installed qjackctl and a2jmidid.
I launch qjackctl, start a2jmidid, and command yoshimi -j
One yoshimi appears in each of the qjackctl midi tabs, and both of them
appear in the audio tab. Both are working at the same time.
In top, both yoshimi's are there, distinct processes, as are a2jmidid and qjackctl and pipewire.
I don't see how you claim the first yoshimi is not running on alsa, as it was started before
any jackd items were even installed or available.
I must say I detest the default fedora setup. I wouldn't wish it on you, or anyone in the forum
I'll install it on a drive later, and set up a decent system gui. But my wife is sick, and I need sleep.
I appreciate your efforts to educate me/us, and help clarify this convoluted audio situation!
Cheers
Re: Pipewire-Fedora35 live dvd -pipewire is default, audio tools seem OK
Posted: Tue Mar 15, 2022 11:03 pm
by j_e_f_f_g
glowrak guy wrote:
only app is yoshimi -a
In that configuration, yoshimi is connecting to your midi keyboard using ALSA Sequencer (MIDI) -- that's what the -a stands for. (Otherwise it would use jack midi.) And Yoshimi is playing its synth sounds using Jack audio to your sound card. The -a is all about midi (jack midi versus alsa midi), but nothing to do with audio playback.
An interesting test is with jack midi or alsa midi versus the rawmidi API. (Apparently Yoshimi doesn't support rawmidi. Who maintains it? Is that folderol? He could confirm that it doesn't use rawmidi). In this case, I expect you to see a "Device busy" error message (like I get with BackupBand).
The -A (capital letter) option is all about digital audio (jack audio versus alsa MMAP direct audio output(=).
You need to run 2 copies of Yoshimi -- one with the -A option and one without it, to test what I was asking about. In this case, the one with -A will
not show up in QJackCtl's "Audio" listbox. That's because it's not using jack. And QJackCtl tells you only about apps that
are using jack. The other Yoshimi will show up.
And the -A one should give you a "Device Busy" error message. (Or it just may make no noise if folderol didn't do error-checking. I'm looking at you, folderol. Don't skip the checks!).
I run top, there is no jackd
That's because it's now part of Pipewire. (ie Pipewire emulates jack). Think of it this way: JackD is now "inside of" Pipewire. HTOP doesn't know this. HTOP knows only that this hermaphrodite calls itself Pipewire.
PulseAudio is also inside of Pipewire. (Pipewire emulates that too). HTOP doesn't know this either. If you run firefox, which needs pulseaudio, then Pipewire will pull a con job and pose as pulseaudio to firefox. Neither HTOP nor firefox know what's really going on with this pipewire thing.
It's like the Borg. Pipewire has assimilated jack and pulseaudio. They are now borg units inside of the collective. The pipewire collective is 3 units:
The Queen who controls everything (Pipewire)
Unit F- (jack)
Unit 666 (pulse)
All audio/midi hardware will be assimilated. Resistance is futile. (So is persistence, which is why you need a session manager... and BackupBand doesn't).
no qjacktl
Well, qjackctl doesn't need to be running in order for jack to be running. Think of it this way. You run a Device Manager app and it shows you a list of all the hardware and their drivers currently running on your system. It can show you how the hardware/drivers are connected to each other, and enable/disable items, and change various settings.
So you exit that Device Manager app. Does all your hardware/drivers then just stop working? Are they no longer doing exacting what they were doing before you monitored them? Of course not. You simply are no longer running an app that lets you monitor and adjust your drivers/hardware.
QJackCtl is exactly like that device manager/monitor. But it specializes in one particular thing - managing/monitoring jack and software using jack right now.
only in top are pipewire
The collective.
and yoshimi.
About to be assimilated and retrofitted with a segway in place of jack transport.
Re: Pipewire-Fedora35 live dvd -pipewire is default, audio tools seem OK
Posted: Thu Mar 17, 2022 1:24 pm
by glowrak guy
I have now a hard-disk install of Fedora 35,
pipewire-alsa
pipewire-pulseaudio
pipewire-jack-audio-connection-kit
are separate apps from pipewire, that you can download and install via the dnfdragora
package manager, in addition to pipewire, which is in the system by default. I assume those 'extra' apps exist to provide
functionality. Several pulseaudio libs are also in the default install.
A pipewire-plugin-jack also exists, to utilize 'spa' (whatever that is) providing
/usr/lib64/spa-0.2/jack and
/usr/lib64/spa-0.2/jack/libspa-jack.so
jack-audio-connection-kit is yet another separate download, as is pulseaudio-module-jack
providing
/usr/lib64/pulse-15.0/modules/module-jack-sink.so
/usr/lib64/pulse-15.0/modules/module-jack-source.so
/usr/lib64/pulse-15.0/modules/module-jackdbus-detect.so
I'm not a coder, so it looks on the surface, like the core pipewire
has it's own purposes out of the box. If as you say, it fully contains jackd and pulse,
or their emulated essence, while preventing annoying audio conclicts, I'm all for it.
But there appears to be more than meets the eye, with the typical lack of information
as to what is really under the hood, and how it works.
Anything you contribute to the project, be it code, or clarifying discussion,
is very be welcome. So far, I'm happy with how things are working.
Cheers
Re: Pipewire-Fedora35 live dvd -pipewire is default, audio tools seem OK
Posted: Thu Mar 17, 2022 5:21 pm
by bluzee
Pipewie-alsa would seem that pipewire may not timeout and release the hardware like pulse audio did. I wonder if it will be necessary to manually stop the pipewire service to have direct access to alsa?
Pasusspender has always seemed to do the trick for pulse in the past. Perhaps there is a pipewire equivalent?
I don't believe pipewire is 100% compatible just yet either.
Re: Pipewire-Fedora35 live dvd -pipewire is default, audio tools seem OK
Posted: Fri Mar 18, 2022 3:57 am
by j_e_f_f_g
bluzee wrote:
pipewire may not timeout and release the hardware like pulse audio did.
That's what concerns me.
will it be necessary to manually stop the pipewire service to have direct access to alsa?
That's
exactly what I'd like to know.
More than that, I'd like to know if another app can communicate with pipewire to ask it to let go of some device your app wants to use directly. Like you can with jack or pulse. And if so, does a program use either the jack or pulse methods, or something different than those two (ie, is anyone following a standard here)?
Re: Pipewire-Fedora35 live dvd -pipewire is default, audio tools seem OK
Posted: Fri Mar 18, 2022 4:27 am
by Kott
j_e_f_f_g wrote: ↑Fri Mar 18, 2022 3:57 am
More than that, I'd like to know if another app can communicate with pipewire to ask it to let go of some device your app wants to use directly. Like you can with jack or pulse. And if so, does a program use either the jack or pulse methods, or something different than those two (ie, is anyone following a standard here)?
How it works? I thought it's not possible without killing the daemon.
Re: Pipewire-Fedora35 live dvd -pipewire is default, audio tools seem OK
Posted: Fri Mar 18, 2022 5:06 am
by j_e_f_f_g
not possible without killing the daemon.
Jack1 you write a certain file handle that the jack daemon creates specifically for other programs to write "commands" to jack deamon. One of the commands tells it to terminate. Jack2 you use some DBus message, or if systemd is your init system, you can stop Jack2 by calling system() to run systemctl and tell it to stop the jack2 unit. PulseAudio has different DBus messages it calls "Device Reserve".
And I don't yet know what's going on with Pipewire.