Skip to content

Configure persistent Wi-Fi Direct PC identity - #11286

Open
alchemy wants to merge 2 commits into
omacom:quattrofrom
alchemy:fix/wifi-direct-pc-identity
Open

Configure persistent Wi-Fi Direct PC identity#11286
alchemy wants to merge 2 commits into
omacom:quattrofrom
alchemy:fix/wifi-direct-pc-identity

Conversation

@alchemy

@alchemy alchemy commented Sep 11, 2026

Copy link
Copy Markdown

Give Omarchy PCs an explicit, persistent Wi-Fi Direct device classification. Set device_type=1-0050F204-1 (computer / PC) in a P2P configuration loaded through wpa_supplicant's -m option, so the classification is restored when the service starts. This gives peers a consistent description of the source device across applications using that supplicant instance and across service restarts.

The device type has a general role in Wi-Fi Direct discovery: upstream exposes the primary device type in discovered peer information, and its P2P discovery API supports requesting particular device types. Consequently, advertising the correct class can matter to peer classification and discovery filtered by device type, beyond screen sharing. Improvements for other receivers or applications are plausible implications of that mechanism, but have not been tested here.

LG Screen Share motivated the investigation and provides the confirmed use case: on an LG OLED55B9PLA, advertising the PC identity made Miracast sharing open full-screen automatically instead of in a window. The result was confirmed again after restarting wpa_supplicant.

Install the tested PC identity setting as wifi-direct-pc.conf, loaded by the 50-wifi-direct-pc.conf systemd drop-in. The generic filenames describe the Wi-Fi Direct PC identity independently of the application using it. Fresh hardware setup and an idempotent migration share one setup leaf. Only Arch's stock service is augmented: existing configuration, custom ExecStart flags (including an existing -m), replacement units, and masked services are preserved and receive manual integration guidance. Unrelated service settings remain intact.

Activation is deferred until reboot so an update does not disconnect Wi-Fi. To activate immediately after installation, run sudo systemctl daemon-reload and sudo systemctl restart wpa_supplicant; the restart temporarily interrupts Wi-Fi and any active Wi-Fi Direct session.

Validation:

  • Focused tests cover fresh installation, repeat execution, partial-install recovery, custom configuration and service preservation, masked services, and the migration entry point.
  • Bash syntax and git diff --check pass. The focused Wi-Fi Direct tests were rerun successfully after renaming the configuration files and updating the -m path.
  • Full ./test/all: CLI suite passed; 230 of 237 shell test files passed, including the new Wi-Fi Direct suite. Failures outside this change: config-test.sh, snapper-test.sh, and unowned-system-paths-test.sh require the missing sibling omarchy-pkgs checkout; locate-test.sh fails with a UnicodeDecodeError; launch-about-test.sh fails its roomy-window animation assertion; runtime-smoke-test.sh reports duplicate widget IPC handlers; screenshot-sanity-test.sh reports that omarchy-shell is not responding. These failures were not repaired as part of the network configuration change.
  • The contributor reports these exact configuration files were confirmed on LG OLED55B9PLA, including after restarting wpa_supplicant. Hardware behavior was not independently retested during this change; before/after TV captures are not available.

@alchemy
alchemy marked this pull request as ready for review September 11, 2026 08:16
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant