Skip to content

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

4 Commits
 
 
 
 
 
 
 
 

Repository files navigation

MAXHUB Linux

Run the MAXHUB wireless screen-share dongle on Linux (GNOME / Wayland) using Wine — with a working screen capture.

The MAXHUB DongleClient is Windows-only. Under plain Wine on Wayland it launches and pairs fine, but the shared screen is black: the client captures the screen with GDI BitBlt, which can only see Wine's own (empty) virtual desktop — no Windows capture API under Wine can read the host Wayland framebuffer.

This project fixes that with an X11/Xvfb capture bridge.

How it works

GNOME Wayland desktop
        │  org.gnome.Mutter.ScreenCast → PipeWire
        ▼
  wlmirror.py  (GStreamer: pipewiresrc → ximagesink)
        │
        ▼
  Xvfb :99  ← a private, headless X display showing a live mirror of your real desktop
        │
        ▼
  Wine (x11 driver) runs DongleClient on the Xvfb
        │  its GDI screen capture now BitBlts a REAL desktop
        ▼
  MAXHUB dongle → receiver shows your screen

Your normal GNOME session is untouched — the Xvfb is only a capture target. The DongleClient's window lives on the Xvfb, not on your screen.

Files

File Purpose
maxhub-dongle-bridge.sh Main launcher: starts Xvfb, the Wayland→X mirror, and the DongleClient under Wine; tears everything down on exit.
wlmirror.py Mirrors a Wayland monitor into $DISPLAY via Mutter ScreenCast → PipeWire → GStreamer (no portal popup).

Requirements

  • GNOME on Wayland (uses the Mutter ScreenCast D-Bus API)

  • Wine (a portable build is expected at wine/ inside the install dir)

  • xvfb, python3-gi, gstreamer1.0-pipewire

    sudo apt install xvfb python3-gi gstreamer1.0-pipewire
  • The MAXHUB USB dongle (USB ID 1ff7:0f52)

  • The proprietary MAXHUB client payload (MAXHUB.exe, VirtualScreenSetup.exe, bundle.dat, bundle.nfo, uwstconfig) — not included; copy it from the dongle's mass-storage partition into the install dir.

Setup

sudo git clone https://github.com/osadan/maxhub-linux /opt/maxhub-dongle
cd /opt/maxhub-dongle
# 1. put a portable Wine build in ./wine
# 2. copy the MAXHUB payload from the dongle here (MAXHUB.exe etc.)
# 3. plug in the dongle and run:
./maxhub-dongle-bridge.sh

Press Ctrl+C to stop sharing — the bridge tears down the Xvfb, the mirror, and the Wine processes, and restores the Wayland driver setting.

Configuration

Override via environment variables:

Variable Default Meaning
MAXHUB_MIRROR_OUTPUT eDP-1 Monitor connector to share
MAXHUB_BRIDGE_DISPLAY :99 Xvfb display number
WINEDEBUG -all Wine debug channels

The Xvfb is sized to the mirrored monitor's native resolution (queried from Mutter), falling back to 1920×1080.

Logs go to logs/maxhub-bridge.log.

Note on the Intel GPU pins

maxhub-dongle-bridge.sh was written for an Intel iGPU laptop and pins two things:

  • VK_ICD_FILENAMES=/usr/share/vulkan/icd.d/intel_icd.json — forces the Intel Vulkan driver (avoids NVIDIA EGL retry noise on hybrid-GPU machines).
  • DRI_PRIME=pci-0000_00_02_0 — the Intel iGPU's PCI address on that machine (overridable via the DRI_PRIME env var).

These are harmless on the X11 software rendering path, but on a machine without an Intel GPU you should edit or override them — e.g. unset VK_ICD_FILENAMES and set DRI_PRIME to your own GPU's tag (see ls /dev/dri/by-path/). Likewise the default shared monitor is eDP-1 (a laptop panel); set MAXHUB_MIRROR_OUTPUT for external monitors (e.g. HDMI-1, DP-1).

Why not just use winewayland?

Tried and dead-ends:

  • winewayland driver — the client runs, but GDI screen capture reads Wine's own empty surface → black share. No registry or GPU tweak changes this.
  • Windows capture APIs under Wine — none of them can reach the host compositor's framebuffer.

Mirroring the real desktop into an X server that Wine can read is the only path that gives the unmodified client a genuine desktop to capture.

About

Run the MAXHUB wireless screen-share dongle on Linux (GNOME/Wayland) via Wine with an Xvfb capture bridge

Topics

Resources

Stars

Watchers

Forks

Releases

Packages

Contributors

Languages