lvra.gitlab.io/content/docs/fossvr/wivrn/_index.md

107 lines
4.5 KiB
Markdown
Raw Permalink Normal View History

2023-12-06 01:43:59 +01:00
---
weight: 50
2023-12-06 01:43:59 +01:00
title: WiVRn
---
# WiVRn
2024-08-15 18:03:39 +02:00
- [WiVRn GitHub repository](https://github.com/WiVRn/WiVRn)
2023-12-06 01:43:59 +01:00
2024-08-15 18:03:39 +02:00
![The WiVRn mascot](https://github.com/WiVRn/WiVRn/blob/master/images/wivrn.svg?raw=true)
2024-03-27 19:01:58 +01:00
> WiVRn wirelessly connects a standalone VR headset to a Linux computer. You can then play PCVR games on the headset while processing is done on the computer.
2023-12-06 01:43:59 +01:00
WiVRn is based on [Monado](/docs/fossvr/monado/) and can be used with [OpenComposite](/docs/fossvr/opencomposite/) to support a majority of titles available for SteamVR. A wide range of standalone headsets are supported.
2024-03-27 19:01:58 +01:00
2024-11-04 15:43:22 +01:00
## Installing WiVRn
We recommend using [Envision](/docs/fossvr/envision/) to install and launch WiVRn & OpenComposite. Envision will handle all configuration seamlessly and avoids many of the pitfalls of a manual setup.
2024-09-13 17:45:47 +02:00
2024-11-04 15:43:22 +01:00
Alternatively, you can use the [WiVRn Flatpak](https://flathub.org/apps/io.github.wivrn.wivrn) which includes OpenComposite as part of it. Processes in flatpak cannot take advantage of setcap, and so your performance may suffer when compared to Envision.
## General WiVRn Notes
2024-11-04 15:43:22 +01:00
WiVRn uses Avahi for network discovery. Ensure it is running with the following terminal command:
```bash
systemctl enable --now avahi-daemon
```
2024-11-04 15:43:22 +01:00
(If Avahi is not available, the IP address of the server must be entered into the client.)
If a firewall is installed, make sure ports 5353/UDP and 9757/UDP+TCP are open for Avahi and WiVRn itself, respectively.
2024-11-04 15:43:22 +01:00
If using Nvidia proprietary drivers, have [Monado Vulkan Layers](https://gitlab.freedesktop.org/monado/utilities/vulkan-layers) installed, otherwise games will crash with a segmentation fault.
For audio in WiVRn, you will need to assign applications, or the system as a whole, to output audio to the virtual output "WiVRn" which is created upon connection between the server and the headset.
2024-09-13 18:16:26 +02:00
## Wired WiVRn
Use WiVRn with a cable instead of Wifi. Use a 5Gbps cable & port at the very least.
2024-09-23 11:05:49 +02:00
WiVRn version: 0.19+
2024-09-23 11:08:59 +02:00
Using Envision:
2024-09-23 11:05:49 +02:00
- Connect the headset via USB
- Click the `Start WiVRn Client (Wired)` button in Envision.
- If it's not there, an Envision update might be necessary.
Manual steps:
2024-09-13 18:16:26 +02:00
- Connect the headset via USB
2024-09-13 18:32:31 +02:00
- If WiVRn is running on the headset, close it now.
- While in the system lobby of the headset, run the following `adb` commands on the PC:
2024-09-13 18:16:26 +02:00
```bash
adb reverse tcp:9757 tcp:9757
2024-09-19 17:21:00 +02:00
adb shell am start -a android.intent.action.VIEW -d "wivrn+tcp://127.0.0.1" org.meumeu.wivrn
2024-09-13 18:16:26 +02:00
```
2024-09-13 17:45:47 +02:00
## WiVRn + Lighthouse driver
2024-09-13 18:49:35 +02:00
This section covers using WiVRn with any lighthouse-tracked device: Index/Vive controllers, Vive/Tundra trackers, etc.
2024-09-13 17:45:47 +02:00
2024-09-23 11:05:49 +02:00
WiVRn version: 0.19+
2024-09-13 18:32:31 +02:00
Have SteamVR installed (no need to run it).
2024-09-13 17:45:47 +02:00
2024-09-13 18:32:31 +02:00
In Envision, set WiVRn Profile as such:
2024-09-13 17:45:47 +02:00
- XR Service CMake Flags:
- `WIVRN_FEATURE_STEAMVR_LIGHTHOUSE=ON`
- Environment Variables:
- `WIVRN_USE_STEAMVR_LH=1`
- `LH_DISCOVER_WAIT_MS=6000`
2024-09-13 18:32:31 +02:00
Perform a **Clean Build** after changing the CMake flags!
2024-09-13 17:45:47 +02:00
If not using Envision, simply pass `-DWIVRN_FEATURE_STEAMVR_LIGHTHOUSE=ON` to cmake and export the env variables before starting `wivrn-server`.
2024-09-13 18:16:26 +02:00
[Motoc](/docs/fossvr/motoc/) will be used to calibrate the two tracking technologies to work together.
2024-09-13 17:45:47 +02:00
Discovery happens only on first connection, so be sure to **have all lighthouse devices powered on and in line of sight of base stations before connecting the headset!**
Once a device is discovered, it may be powered off and then back on later.
2024-09-13 18:32:31 +02:00
Once video appears in the headset, check `motoc monitor` to make sure your devices all show up.
2024-09-13 17:45:47 +02:00
If one or more devices are missing, try:
- Spread the devices out more; lighthouse devices get discovered quicker if they're not piled up on each other. Simply strapping them on is good, too.
- Increase `LH_DISCOVER_WAIT_MS`, though this delays the client on first connection.
To re-discover devices, restart WiVRn server.
At this point, your lighthouse devices will be randomly floating about somewhere. To calibrate them, follow the guide in the [Motoc README](https://github.com/galister/motoc/blob/main/README.md).
2024-11-05 06:20:37 +01:00
## WiVRn + SlimeVR trackers
2024-09-23 11:05:49 +02:00
This section covers using WiVRn with SlimeVR trackers (not via OSC). Tracking fidelity is reported to be similar to what's achievable with the SteamVR-native solution.
2024-10-27 11:33:49 +01:00
Required SliveVR Server version: 0.13.0 or later
2024-09-23 11:05:49 +02:00
In Envision, set WiVRn Profile as such:
- XR Service Branch:
2024-10-01 23:19:47 +02:00
- `master`
2024-09-23 11:05:49 +02:00
- XR Service CMake Flags:
- `WIVRN_FEATURE_SOLARXR=ON`
Perform a **Clean Build** after changing these!
2024-11-05 06:20:37 +01:00
Starting up:
2024-09-23 11:08:59 +02:00
- Always start SlimeVR server before starting WiVRn.
2024-10-27 11:33:49 +01:00
- Do not quit SlimeVR server mid-session; trackers will not work until WiVRn is restarted.