Addressed user feedback to prevent the camera feed section and its internal streams from overflowing the viewport. - **Explicitly constrained camera-view height:** Ensured `.camera-view` utilizes `height: 100%` and `overflow-y: auto` to fit within its parent (`.main-container`) and allow internal scrolling if content is too tall. - **Refined individual stream container sizing:** Removed fixed `height: 100%` from `.camera-container-individual` and re-enabled `max-width: 100%`. This, combined with `aspect-ratio` and `max-height: 100%`, allows individual camera streams to scale correctly within their allocated grid cells without causing overflow. - **Ensured grid row containment:** Applied `height: 100%` and `overflow: hidden` to `.camera-color-row` and `.camera-mono-row` to tightly constrain content within grid rows. |
||
|---|---|---|
| .. | ||
| static | ||
| templates | ||
| tests | ||
| app.py | ||
| ble_controller.py | ||
| camera_scanner.py | ||
| gstreamer_pipeline.py | ||
| README.md | ||
| run.py | ||
| test.py | ||
Unified WebUI
This application combines the functionality of the detectionSoftware and controllerSoftware into a single, unified web interface.
Features
- Camera View: Displays a tiled video stream from multiple Basler cameras.
- Lamp Control: Provides a web interface to control a 5x5 LED matrix via Bluetooth Low Energy (BLE).
- Responsive UI: The UI is designed to work on both desktop and mobile devices. On desktop, the lamp control and camera view are displayed side-by-side. On mobile, they are in separate tabs.
Setup
-
Install dependencies:
pip install -r requirements.txt -
Run the application:
python src/unified_web_ui/app.py -
Open the web interface: Open a web browser and navigate to
http://<your-ip-address>:5000.
Modules
app.py: The main Flask application file.ble_controller.py: Handles the BLE communication with the lamp matrix.camera_scanner.py: Scans for connected Basler cameras.gstreamer_pipeline.py: Creates and manages the GStreamer pipeline for video processing.templates/index.html: The main HTML template for the web interface.static/style.css: The CSS file for styling the web interface.