A Python-GTK application for streaming audio to multiple Bluetooth devices simultaneously. ConnectFlow simplifies the process of broadcasting system audio to all your connected Bluetooth speakers and headphones through an intuitive interface.
Built to replace the need for manually configuring Helvum, Pavucontrol, and complex Pipewire commands, ConnectFlow handles virtual sink management and device routing automatically.
ConnectFlow application running with the main interface
- 🎵 Multi-Device Audio Broadcasting: Stream audio to multiple Bluetooth devices simultaneously
- 🔧 Automated Virtual Sink Management: Handles Pipewire configuration automatically
- 📱 Bluetooth Device Management: Simple connection and profile management for audio devices
- 🎛️ Individual Volume Control: Adjust volume per device or control all devices together
- 💾 Session Management: Save and restore device configurations
- 🖥️ Clean GTK Interface: Intuitive user interface built with GTK 4
Before installation, ensure you have:
- Python 3.8 or higher
- GTK 4
- Pipewire audio server
- BlueZ Bluetooth stack
- PyGObject
Install the required Python packages:
pip install -r requirements.txtVerify these system components are installed and running:
- Pipewire audio server
- BlueZ Bluetooth stack
- GTK 4 development libraries
-
Launch the application:
python main.py
-
Device Discovery:
- The application automatically scans for available Bluetooth devices
- Paired devices will appear in the device list
-
Select Devices:
- Choose which Bluetooth devices to include in your broadcast group
- ConnectFlow creates a virtual sink for multi-device output
-
Start Broadcasting:
- System audio is automatically routed to all selected devices
- Audio streams simultaneously to all connected devices
-
Volume Management:
- Adjust individual device volumes as needed
- Save your configuration for future sessions
ConnectFlow operates through the following workflow:
- Initialization: Connects to Pipewire and loads saved configurations
- Device Discovery: Scans for available Bluetooth audio devices
- Virtual Sink Creation: Creates a Pipewire virtual sink for multi-device output
- Device Connection: Establishes connections to selected Bluetooth devices
- Audio Routing: Routes system audio through the virtual sink to all devices
- Volume Control: Provides individual and master volume management
- Session Persistence: Saves configurations for future use
ConnectFlow uses Pipewire's libpipewire-module-combine-stream to create a virtual sink:
context.modules = [
{ name = libpipewire-module-combine-stream
args = {
combine.mode = sink
node.name = "connectflow_sink"
node.description = "Connectflow Output"
combine.latency-compensate = false
combine.props = { audio.position = [ FL FR FC LFE SL SR ] }
stream.rules = [
{ matches = [ { media.class = "Audio/Sink" } ]
actions = { create-stream = {
combine.audio.position = [ FL FR FC LFE SL SR ]
audio.position = [ FL FR FC LFE SL SR ]
} }
}
]
}
}
]
connectflow/
├── main.py # Application entry point
├── requirements.txt # Python dependencies
├── config/ # Configuration templates
├── core/ # Core functionality
│ ├── audio/ # Audio and sink management
│ └── bluetooth/ # Bluetooth device handling
├── ui/ # User interface components
│ ├── components/ # GTK widgets and dialogs
│ ├── windows/ # Main application windows
│ └── styles/ # CSS styling
└── utils/ # Common utilities and helpers
Contributions are welcome! To contribute:
- Fork the repository
- Create a feature branch:
git checkout -b feature-name - Commit your changes:
git commit -m 'Add feature description' - Push to the branch:
git push origin feature-name - Submit a pull request
To set up a development environment:
-
Clone the repository:
git clone https://github.com/ash-baseplate/ConnectFlow.git cd ConnectFlow -
Create a virtual environment:
python -m venv venv source venv/bin/activate # Windows: venv\Scripts\activate
-
Install dependencies:
pip install -r requirements.txt
-
Run the application:
python main.py
This project builds upon excellent open-source technologies:
- Pipewire - Modern audio server for Linux
- BlueZ - Official Linux Bluetooth protocol stack
- GTK - Cross-platform widget toolkit
- PyGObject - Python bindings for GTK
For issues, questions, or feature requests, please open an issue on GitHub.
Note: This project is currently in active development. Some features may not be fully implemented yet.