I have a system with two audio cards: a scarlett 2i2 where I have connected two speakers and the HDMI monitor, where I have connected the headphones. Its also possible I connect at some point some bluetooth headphones.
I have created a null sink where I connect all the audio applications and I would like to automatically connect this null sink to my hardware audio devices. Since the bluetooth headphones may be present or not in the system, I guess I need to do this dynamically, so I need Wireplumber, but I have no idea how to do it.
I have added the my Pipewire graph. In blue, the applications playing some audio, connected to easy effects input. In red, the easy effects pipe, connected to my output null sink. In white, the hardware audio devices. These are getting audio from the null sink. These are the connections I want to generate automatically, as right now I have to connect them by hand when I boot the computer In yellow, the microphone pipeline.
How should I perform the connections from the null sink to the hardware devices automatically?