Package frc.alotobots.util
Class NotificationPresets.Oculus
java.lang.Object
frc.alotobots.util.NotificationPresets.Oculus
- Enclosing class:
- NotificationPresets
Contains notification methods related to the Oculus tracking system.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic void
Sends a notification when the Oculus battery is critically low.static void
Sends a notification when the Oculus battery is low.static void
Sends a notification when the Oculus disconnects.static void
Sends a notification when the Oculus heading reset fails.static void
Sends a notification when the Oculus heading is reset.static void
Sends a notification when the Oculus pose reset fails.static void
sendOculusPoseResetNotification
(Pose2d newPose) Sends a notification when the Oculus pose is reset.static void
Sends a notification when the Oculus reconnects.static void
sendOculusTrackingLostNotification
(int totalTrackingLostEvents) Sends a notification when the Oculus tracking is lost.static void
Sends a notification when the Oculus tracking is regained.static void
sendOculusTransformUpdateNotification
(Transform2d newTransform) Sends a notification when the Oculus transform is updated.
-
Constructor Details
-
Oculus
public Oculus()
-
-
Method Details
-
sendOculusPoseResetFailedNotification
public static void sendOculusPoseResetFailedNotification()Sends a notification when the Oculus pose reset fails. -
sendOculusPoseResetNotification
Sends a notification when the Oculus pose is reset.- Parameters:
newPose
- The new pose after reset
-
sendOculusHeadingResetFailedNotification
public static void sendOculusHeadingResetFailedNotification()Sends a notification when the Oculus heading reset fails. -
sendOculusHeadingResetNotification
public static void sendOculusHeadingResetNotification()Sends a notification when the Oculus heading is reset. -
sendOculusTransformUpdateNotification
Sends a notification when the Oculus transform is updated.- Parameters:
newTransform
- The new transform applied to the Oculus
-
sendOculusReconnectedNotification
public static void sendOculusReconnectedNotification()Sends a notification when the Oculus reconnects. Only sends if a disconnection was previously reported. -
sendOculusDisconnectedNotification
public static void sendOculusDisconnectedNotification()Sends a notification when the Oculus disconnects. Only sends the notification once until the device reconnects. -
sendOculusBatteryLowNotification
public static void sendOculusBatteryLowNotification()Sends a notification when the Oculus battery is low. Only sends the notification once per battery discharge cycle. -
sendOculusBatteryCriticalNotification
public static void sendOculusBatteryCriticalNotification()Sends a notification when the Oculus battery is critically low. Only sends the notification once per battery discharge cycle. -
sendOculusTrackingLostNotification
public static void sendOculusTrackingLostNotification(int totalTrackingLostEvents) Sends a notification when the Oculus tracking is lost. Only sends the notification once until tracking is regained.- Parameters:
totalTrackingLostEvents
- The times the quest has lost tracking total since app boot.
-
sendOculusTrackingRegainedNotification
public static void sendOculusTrackingRegainedNotification()Sends a notification when the Oculus tracking is regained. Only sends the notification once until tracking is lost again.
-