Add axis deadzones to enterprise version of SpaceMouse

This commit is contained in:
Malin E
2022-04-20 17:35:29 +02:00
parent 6085c6affc
commit 71cae1363d
2 changed files with 14 additions and 0 deletions
@@ -37,6 +37,13 @@ asset.onInitialize(function()
local controller = SpaceMouse;
local name = "3Dconnexion Universal Receiver";
openspace.navigation.setAxisDeadZone(name, controller.Push[1], 0.1)
openspace.navigation.setAxisDeadZone(name, controller.Push[2], 0.1)
openspace.navigation.setAxisDeadZone(name, controller.Twist[1], 0.1)
openspace.navigation.setAxisDeadZone(name, controller.Tilt[2], 0.1)
openspace.navigation.setAxisDeadZone(name, controller.Push[3], 0.1)
openspace.navigation.setAxisDeadZone(name, controller.Tilt[1], 0.1)
openspace.navigation.bindJoystickAxis(name, controller.Push[1], "Orbit X");
openspace.navigation.bindJoystickAxis(name, controller.Push[2], "Orbit Y");
openspace.navigation.bindJoystickAxis(name, controller.Twist[1], "Pan X", true);
@@ -37,6 +37,13 @@ asset.onInitialize(function()
local controller = SpaceMouse;
local name = "SpaceMouse Enterprise";
openspace.navigation.setAxisDeadZone(name, controller.Push[1], 0.1)
openspace.navigation.setAxisDeadZone(name, controller.Push[2], 0.1)
openspace.navigation.setAxisDeadZone(name, controller.Twist[1], 0.1)
openspace.navigation.setAxisDeadZone(name, controller.Tilt[2], 0.1)
openspace.navigation.setAxisDeadZone(name, controller.Push[3], 0.1)
openspace.navigation.setAxisDeadZone(name, controller.Tilt[1], 0.1)
openspace.navigation.bindJoystickAxis(name, controller.Push[1], "Orbit X");
openspace.navigation.bindJoystickAxis(name, controller.Push[2], "Orbit Y");
openspace.navigation.bindJoystickAxis(name, controller.Twist[1], "Pan X", true);