fossvr/wivrn: Add NixOS instructions for lighthouse usage

This commit is contained in:
Sapphire 2025-04-10 19:02:31 -05:00 committed by hypevhs
parent 1935b7dc73
commit 3a5d772127

View file

@ -108,13 +108,12 @@ Override the `wivrn` package from nixpkgs with something resembling the followin
## WiVRn + Lighthouse driver ## WiVRn + Lighthouse driver
This section covers using WiVRn with any Lighthouse-tracked device: Index/Vive controllers, Vive/Tundra trackers, etc. This section covers using WiVRn 0.19 and newer with any Lighthouse-tracked device (such as Index/Vive controllers, Vive/Tundra trackers, etc.)
WiVRn version: 0.19+
You must have SteamVR installed (no need to run it). You must have SteamVR installed (no need to run it).
In Envision, set WiVRn Profile as such: ### Envision
Set WiVRn Profile as such:
- XR Service CMake Flags: - XR Service CMake Flags:
- `WIVRN_FEATURE_STEAMVR_LIGHTHOUSE=ON` - `WIVRN_FEATURE_STEAMVR_LIGHTHOUSE=ON`
- Environment Variables: - Environment Variables:
@ -123,14 +122,31 @@ In Envision, set WiVRn Profile as such:
Perform a **Clean Build** after changing the CMake flags! Perform a **Clean Build** after changing the CMake flags!
If not using Envision, simply pass `-DWIVRN_FEATURE_STEAMVR_LIGHTHOUSE=ON` to CMake and export the above environment variables before starting `wivrn-server`. ### NixOS
Override the `wivrn` package:
```nix
{
services.wivrn = {
enable = true;
defaultRuntime = true;
package = pkgs.wivrn.overrideAttrs (old: {
cmakeFlags = old.cmakeFlags ++ [
(lib.cmakeBool "WIVRN_FEATURE_STEAMVR_LIGHTHOUSE" true)
];
});
};
}
```
### Manual
Simply pass `-DWIVRN_FEATURE_STEAMVR_LIGHTHOUSE=ON` to CMake and export the above environment variables before starting `wivrn-server`.
### Usage tips
Discovery happens only on first connection, so be sure to **have all Lighthouse devices powered on and in line-of-sight of your base stations before connecting the headset!** Once a device is discovered, you may power it off and on at-will.
You can use [Motoc](/docs/fossvr/motoc/) to calibrate the two tracking technologies to work together. You can use [Motoc](/docs/fossvr/motoc/) to calibrate the two tracking technologies to work together.
Discovery happens only on first connection, so be sure to **have all Lighthouse devices powered on and in line-of-sight of your base stations before connecting the headset!**
Once a device is discovered, you may power it off and on at-will.
Once video appears in the headset, check `motoc monitor` to make sure your devices all show up. Once video appears in the headset, check `motoc monitor` to make sure your devices all show up.
If one or more devices are missing, try: If one or more devices are missing, try: