23#define XREAL_AIR_HANDLE_IFACE 3
24#define XREAL_AIR_CONTROL_IFACE 4
26#define XREAL_AIR_MSG_R_BRIGHTNESS 0x03
27#define XREAL_AIR_MSG_W_BRIGHTNESS 0x04
28#define XREAL_AIR_MSG_R_DISP_MODE 0x07
29#define XREAL_AIR_MSG_W_DISP_MODE 0x08
31#define XREAL_AIR_MSG_P_START_HEARTBEAT 0x6c02
32#define XREAL_AIR_MSG_P_BUTTON_PRESSED 0x6C05
33#define XREAL_AIR_MSG_P_END_HEARTBEAT 0x6c12
34#define XREAL_AIR_MSG_P_ASYNC_TEXT_LOG 0x6c09
36#define XREAL_AIR_BUTTON_PHYS_DISPLAY_TOGGLE 0x1
37#define XREAL_AIR_BUTTON_PHYS_BRIGHTNESS_UP 0x2
38#define XREAL_AIR_BUTTON_PHYS_BRIGHTNESS_DOWN 0x3
40#define XREAL_AIR_BUTTON_VIRT_DISPLAY_TOGGLE 0x1
41#define XREAL_AIR_BUTTON_VIRT_MENU_TOGGLE 0x3
42#define XREAL_AIR_BUTTON_VIRT_BRIGHTNESS_UP 0x6
43#define XREAL_AIR_BUTTON_VIRT_BRIGHTNESS_DOWN 0x7
44#define XREAL_AIR_BUTTON_VIRT_MODE_UP 0x8
45#define XREAL_AIR_BUTTON_VIRT_MODE_DOWN 0x9
47#define XREAL_AIR_BRIGHTNESS_MIN 0
48#define XREAL_AIR_BRIGHTNESS_MAX 7
50#define XREAL_AIR_DISPLAY_MODE_2D 0x1
51#define XREAL_AIR_DISPLAY_MODE_3D 0x3
53#define XREAL_AIR_TICKS_PER_SECOND (1000.0)
54#define XREAL_AIR_NS_PER_TICK (1000000)
56#define XREAL_AIR_MSG_GET_CAL_DATA_LENGTH 0x14
57#define XREAL_AIR_MSG_CAL_DATA_GET_NEXT_SEGMENT 0x15
58#define XREAL_AIR_MSG_ALLOCATE_CAL_DATA_BUFFER 0x16
59#define XREAL_AIR_MSG_WRITE_CAL_DATA_SEGMENT 0x17
60#define XREAL_AIR_MSG_FREE_CAL_BUFFER 0x18
61#define XREAL_AIR_MSG_START_IMU_DATA 0x19
62#define XREAL_AIR_MSG_GET_STATIC_ID 0x1A
63#define XREAL_AIR_MSG_UNKNOWN 0x1D
93 int16_t accel_multiplier;
94 int16_t gyro_multiplier;
95 int16_t mag_multiplier;
97 int32_t accel_divisor;
160 const uint8_t *buffer,
u_logging_level
Logging level enum.
Definition: u_logging.h:43
struct xrt_device * xreal_air_hmd_create_device(struct os_hid_device *sensor_device, struct os_hid_device *control_device, enum u_logging_level log_level)
Create Xreal Air glasses.
Definition: xreal_air_hmd.c:1105
Wrapper around OS native hid functions.
Representing a single hid interface on a device.
Definition: os_hid.h:29
Definition: xreal_air_hmd.h:66
A control packet from the glasses in wire format.
Definition: xreal_air_hmd.h:134
A parsed single gyroscope, accelerometer and magnetometer sample with their corresponding factors for...
Definition: xreal_air_hmd.h:88
Over the wire sensor control data packet from the glasses.
Definition: xreal_air_hmd.h:121
Over the wire sensor packet from the glasses.
Definition: xreal_air_hmd.h:108
A single HMD or input device.
Definition: xrt_device.h:241
A quaternion with single floats.
Definition: xrt_defines.h:216
A 3 element vector with 32 bit integers.
Definition: xrt_defines.h:336
A 3 element vector with single floats.
Definition: xrt_defines.h:271
Basic logging functionality.
Header defining an xrt display or controller device.
Common interface to probe for devices.