Macros | Functions | Variables
libusbemu.cpp File Reference
#include "libusb.h"
#include "libusbemu_internal.h"
#include "failguard.h"
#include <cassert>
#include <algorithm>
#include "freenect_internal.h"
Include dependency graph for libusbemu.cpp:

Go to the source code of this file.

Macros

#define LIBUSB_DEBUG_CMD(cmd)
 

Functions

struct libusb_transferlibusb_alloc_transfer (int iso_packets)
 
int libusb_bulk_transfer (libusb_device_handle *dev_handle, uint8_t endpoint, uint8_t *data, int length, int *transferred, unsigned int timeout)
 
int libusb_cancel_transfer (struct libusb_transfer *transfer)
 
int libusb_claim_interface (libusb_device_handle *dev, int interface_number)
 
void libusb_close (libusb_device_handle *dev_handle)
 
int libusb_control_transfer (libusb_device_handle *dev_handle, uint8_t bmRequestType, uint8_t bRequest, uint16_t wValue, uint16_t wIndex, unsigned char *data, uint16_t wLength, unsigned int timeout)
 
void libusb_exit (libusb_context *ctx)
 
void libusb_fill_iso_transfer (struct libusb_transfer *transfer, libusb_device_handle *dev_handle, unsigned char endpoint, unsigned char *buffer, int length, int num_iso_packets, libusb_transfer_cb_fn callback, void *user_data, unsigned int timeout)
 
void libusb_free_device_list (libusb_device **list, int unref_devices)
 
void libusb_free_transfer (struct libusb_transfer *transfer)
 
int libusb_get_device_descriptor (libusb_device *dev, struct libusb_device_descriptor *desc)
 
ssize_t libusb_get_device_list (libusb_context *ctx, libusb_device ***list)
 
int libusb_get_string_descriptor (libusb_device_handle *dev_handle, uint8_t desc_index, uint16_t langid, unsigned char *data, int length)
 
int libusb_get_string_descriptor_ascii (libusb_device_handle *dev_handle, uint8_t desc_index, unsigned char *data, int length)
 
int libusb_handle_events (libusb_context *ctx)
 
int libusb_handle_events_timeout (libusb_context *ctx, struct timeval *timeout)
 
int libusb_init (libusb_context **context)
 
int libusb_open (libusb_device *dev, libusb_device_handle **handle)
 
libusb_device_handlelibusb_open_device_with_vid_pid (libusb_context *ctx, uint16_t vendor_id, uint16_t product_id)
 
int libusb_release_interface (libusb_device_handle *dev, int interface_number)
 
int libusb_set_configuration (libusb_device_handle *dev, int configuration)
 
void libusb_set_debug (libusb_context *ctx, int level)
 
int libusb_set_interface_alt_setting (libusb_device_handle *dev, int interface_number, int alternate_setting)
 
void libusb_set_iso_packet_lengths (struct libusb_transfer *transfer, unsigned int length)
 
int libusb_submit_transfer (struct libusb_transfer *transfer)
 
void libusbemu_deliver_transfer (transfer_wrapper *wrapper)
 
int libusbemu_handle_isochronous (libusb_context *ctx, const unsigned int milliseconds)
 
void PreprocessTransferFreenect (libusb_transfer *transfer, const int read)
 
void PreprocessTransferNaive (libusb_transfer *transfer, const int read)
 
int ReapThreadProc (void *params)
 
int ReapTransfer (transfer_wrapper *, unsigned int, libusb_device::TListTransfers *)
 

Variables

static libusb_contextdefault_context = NULL
 
static void(* PreprocessTransfer )(libusb_transfer *, const int)(PreprocessTransferFreenect)
 

Macro Definition Documentation

#define LIBUSB_DEBUG_CMD (   cmd)

Definition at line 83 of file libusbemu.cpp.

Function Documentation

struct libusb_transfer* libusb_alloc_transfer ( int  iso_packets)

Definition at line 439 of file libusbemu.cpp.

int libusb_bulk_transfer ( libusb_device_handle dev_handle,
uint8_t  endpoint,
uint8_t data,
int  length,
int *  transferred,
unsigned int  timeout 
)

Definition at line 412 of file libusbemu.cpp.

int libusb_cancel_transfer ( struct libusb_transfer transfer)

Definition at line 578 of file libusbemu.cpp.

int libusb_claim_interface ( libusb_device_handle dev,
int  interface_number 
)

Definition at line 316 of file libusbemu.cpp.

void libusb_close ( libusb_device_handle dev_handle)

Definition at line 249 of file libusbemu.cpp.

int libusb_control_transfer ( libusb_device_handle dev_handle,
uint8_t  bmRequestType,
uint8_t  bRequest,
uint16_t  wValue,
uint16_t  wIndex,
unsigned char *  data,
uint16_t  wLength,
unsigned int  timeout 
)

Definition at line 394 of file libusbemu.cpp.

void libusb_exit ( libusb_context ctx)

Definition at line 110 of file libusbemu.cpp.

void libusb_fill_iso_transfer ( struct libusb_transfer transfer,
libusb_device_handle dev_handle,
unsigned char  endpoint,
unsigned char *  buffer,
int  length,
int  num_iso_packets,
libusb_transfer_cb_fn  callback,
void *  user_data,
unsigned int  timeout 
)

Definition at line 489 of file libusbemu.cpp.

void libusb_free_device_list ( libusb_device **  list,
int  unref_devices 
)

Definition at line 190 of file libusbemu.cpp.

void libusb_free_transfer ( struct libusb_transfer transfer)

Definition at line 451 of file libusbemu.cpp.

int libusb_get_device_descriptor ( libusb_device dev,
struct libusb_device_descriptor desc 
)

Definition at line 206 of file libusbemu.cpp.

ssize_t libusb_get_device_list ( libusb_context ctx,
libusb_device ***  list 
)

Definition at line 151 of file libusbemu.cpp.

int libusb_get_string_descriptor ( libusb_device_handle dev_handle,
uint8_t  desc_index,
uint16_t  langid,
unsigned char *  data,
int  length 
)

Definition at line 267 of file libusbemu.cpp.

int libusb_get_string_descriptor_ascii ( libusb_device_handle dev_handle,
uint8_t  desc_index,
unsigned char *  data,
int  length 
)

Definition at line 276 of file libusbemu.cpp.

int libusb_handle_events ( libusb_context ctx)

Definition at line 622 of file libusbemu.cpp.

int libusb_handle_events_timeout ( libusb_context ctx,
struct timeval *  timeout 
)

Definition at line 638 of file libusbemu.cpp.

int libusb_init ( libusb_context **  context)

Definition at line 88 of file libusbemu.cpp.

int libusb_open ( libusb_device dev,
libusb_device_handle **  handle 
)

Definition at line 217 of file libusbemu.cpp.

libusb_device_handle* libusb_open_device_with_vid_pid ( libusb_context ctx,
uint16_t  vendor_id,
uint16_t  product_id 
)

Definition at line 362 of file libusbemu.cpp.

int libusb_release_interface ( libusb_device_handle dev,
int  interface_number 
)

Definition at line 347 of file libusbemu.cpp.

int libusb_set_configuration ( libusb_device_handle dev,
int  configuration 
)

Definition at line 286 of file libusbemu.cpp.

void libusb_set_debug ( libusb_context ctx,
int  level 
)

Definition at line 142 of file libusbemu.cpp.

int libusb_set_interface_alt_setting ( libusb_device_handle dev,
int  interface_number,
int  alternate_setting 
)

Definition at line 305 of file libusbemu.cpp.

void libusb_set_iso_packet_lengths ( struct libusb_transfer transfer,
unsigned int  length 
)

Definition at line 516 of file libusbemu.cpp.

int libusb_submit_transfer ( struct libusb_transfer transfer)

Definition at line 529 of file libusbemu.cpp.

void libusbemu_deliver_transfer ( transfer_wrapper wrapper)

Definition at line 661 of file libusbemu.cpp.

int libusbemu_handle_isochronous ( libusb_context ctx,
const unsigned int  milliseconds 
)

Definition at line 599 of file libusbemu.cpp.

void PreprocessTransferFreenect ( libusb_transfer transfer,
const int  read 
)

Definition at line 925 of file libusbemu.cpp.

void PreprocessTransferNaive ( libusb_transfer transfer,
const int  read 
)

Definition at line 905 of file libusbemu.cpp.

int ReapThreadProc ( void *  params)

Definition at line 685 of file libusbemu.cpp.

int ReapTransfer ( transfer_wrapper wrapper,
unsigned int  timeout,
libusb_device::TListTransfers lstReady 
)

Definition at line 810 of file libusbemu.cpp.

Variable Documentation

libusb_context* default_context = NULL
static

Definition at line 86 of file libusbemu.cpp.

void(* PreprocessTransfer) (libusb_transfer *, const int)(PreprocessTransferFreenect)
static

Definition at line 659 of file libusbemu.cpp.



libfreenect
Author(s): Hector Martin, Josh Blake, Kyle Machulis, OpenKinect community
autogenerated on Mon Jun 10 2019 13:46:43