Monado OpenXR Runtime
os_hid_hidraw.c File Reference

Hid implementation based on hidraw. More...

#include "os_hid.h"
#include "util/u_misc.h"
#include <poll.h>
#include <errno.h>
#include <fcntl.h>
#include <unistd.h>
#include <string.h>
#include <time.h>
#include <stdint.h>
#include <sys/ioctl.h>
#include <linux/hidraw.h>
#include <stdio.h>
Include dependency graph for os_hid_hidraw.c:

Data Structures

struct  hid_hidraw
 

Functions

static int os_hidraw_read (struct os_hid_device *ohdev, uint8_t *data, size_t length, int milliseconds)
 
static int os_hidraw_write (struct os_hid_device *ohdev, const uint8_t *data, size_t length)
 
static int os_hidraw_get_feature (struct os_hid_device *ohdev, uint8_t report_num, uint8_t *data, size_t length)
 
static int os_hidraw_get_physical_address (struct os_hid_device *ohdev, uint8_t *data, size_t length)
 
static int os_hidraw_get_feature_timeout (struct os_hid_device *ohdev, void *data, size_t length, uint32_t timeout)
 
static int os_hidraw_set_feature (struct os_hid_device *ohdev, const uint8_t *data, size_t length)
 
static void os_hidraw_destroy (struct os_hid_device *ohdev)
 
int os_hid_open_hidraw (const char *path, struct os_hid_device **out_hid)
 

Detailed Description