libusb_wait_for_event
int libusb_wait_for_event(libusb_context * ctx, struct timeval *tv);
err = libusb_wait_for_event(ctx, tv);