Monado OpenXR Runtime
vive_protocol.c File Reference

Vive USB HID reports. More...

#include "math/m_mathinclude.h"
#include "math/m_api.h"
#include "util/u_debug.h"
#include "util/u_misc.h"
#include "util/u_json.h"
#include "util/u_logging.h"
#include "util/u_trace_marker.h"
#include "vive_protocol.h"
#include <stdio.h>
#include <zlib.h>
Include dependency graph for vive_protocol.c:

Macros

#define CONFIG_Z_MAX_SIZE   (1024 * 16)
 
#define CONFIG_JSON_MAX_SIZE   (1024 * 64)
 

Functions

char * vive_read_config (struct os_hid_device *hid_dev)
 
int vive_get_imu_range_report (struct os_hid_device *hid_dev, double *gyro_range, double *acc_range)
 
int vive_read_firmware (struct os_hid_device *hid_dev, uint32_t *firmware_version, uint8_t *hardware_revision, uint8_t *hardware_version_micro, uint8_t *hardware_version_minor, uint8_t *hardware_version_major)
 

Variables

const struct vive_headset_power_report power_on_report
 
const struct vive_headset_power_report power_off_report
 

Detailed Description

Variable Documentation

◆ power_off_report

const struct vive_headset_power_report power_off_report
Initial value:
= {
.id = 0x04 ,
.type = __cpu_to_le16( 0x2978 ),
.len = 56,
.unknown1 =
{
0x00,
0x00,
0x00,
0x00,
0x00,
0x00,
0x02,
0x00,
0x00,
},
.unknown2 = 0x7c,
}

◆ power_on_report

const struct vive_headset_power_report power_on_report
Initial value:
= {
.id = 0x04 ,
.type = __cpu_to_le16( 0x2978 ),
.len = 56,
.unknown1 =
{
0x01,
0x00,
0x00,
0x00,
0x00,
0x00,
0x02,
0x00,
0x01,
},
.unknown2 = 0x7a,
}