summaryrefslogtreecommitdiff
path: root/examples/xusb.c
Commit message (Collapse)AuthorAgeFilesLines
* switched DDK calling convention for examples to __cdeclr260Pete Batard2010-04-181-5/+1
|
* added advapi32.lib dependency reference in xusb.cPete Batard2010-04-161-1/+3
|
* better handling of attach/detach for Linux in xusb.cr254Pete Batard2010-04-161-12/+14
|
* added more explicit library dependencies in xusb.c (MSVC)Tim Roberts2010-04-161-0/+6
|
* set default messaging level to warnings in xusbr248Pete Batard2010-04-081-2/+2
|
* fixed "ignoring return value of 'fwrite'" warning with gccr247Pete Batard2010-04-081-2/+4
|
* added binary dump option to xusb (-b)Pete Batard2010-04-081-11/+34
| | | | also switched boolean variables to actual bool
* fixed HID record size computation in xusbPete Batard2010-04-081-7/+10
|
* fixed arglen warning from previous commitr242Pete Batard2010-04-061-5/+5
|
* xusb improvements (parameter handling + debug enable)r241Pete Batard2010-04-061-83/+87
|
* xusb HID test improvements (Feature Reports)Michael Plante2010-04-061-63/+85
| | | | Issue reported by Axel Rohde
* removed trailing whitespaces (Windows backend)r214bPeter Stuge2010-03-181-22/+22
|
* xusb improvements (parameters checks)r200Pete Batard2010-03-081-47/+81
|
* reattach driver when detached in xusb (Xiaofan Chen)r183Pete Batard2010-03-011-0/+11
|
* xusb improvements for HID test: int. vs bulk (Xiaofan Chen)r182Pete Batard2010-03-011-2/+2
|
* xusb improvements and fixesr181Pete Batard2010-02-281-12/+24
|
* includes simplification and cleanup (core)Pete Batard2010-02-241-2/+0
|
* merge abstraction for POSIX Threads and integration changes (Michael Plante, ↵r169Pete Batard2010-02-241-4/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Peter Stuge) v1.0.6 release Darwin: support multiple calls to libusb_init Credit to Orin Eman for finding this bug. Darwin: use logging functions Use usbi_warn, usbi_err, and usbi_info instead of _usbi_log. Darwin: fix memory leak in process_device Credit to Mike Colagrosso for finding this bug. Add internal abstraction for POSIX Threads This prepares for a Windows backend without dependency on pthreads-w32. pthread_* is renamed to usbi_* and PTHREAD_* to USBI_*. A usbi_mutex_static_t and usbi_mutex_static_lock() and _unlock() are introduced for statically initialized mutexes, since they may be implemented using other types when pthreads mutexes aren't used. Move -pthread from libusb/Makefile.am to host-specific AM_CFLAGS in configure.ac. AM_CFLAGS is already used in Makefile.am. (Numerous merge conflicts resolved by Michael Plante) misc fixes to pthreads abstraction * windows_compat.h should not be directly included (use libusbi.h) * windows_usb.c still had some references to pthread_mutex_[un]lock Add libusb_strerror() to get short error message in English from enum (Merge conflicts resolved by Michael Plante) Better cleanup on errors, stricter types and some good casts Avoid various memory leaks in error code paths and remove warnings. Also add usbi_cond_destroy in os/threads_posix.h because it's used for cleanup now. (Merge conflicts resolved by Michael Plante) Rename all interface parameters to usb_interface or interface_number (Merge conflicts resolved by Michael Plante) Add type parameter to the list_for_each_entry() and _safe() macros (Merge conflicts resolved by Michael Plante) VA_ARGS workaround for logging with MSVC6 (Merge conflicts resolved by Michael Plante) Fix context memory leak in libusb_init() * Now holds default_context_lock for duration of libusb_init * Doesn't allocate it if not needed Fix the last MSVC /W3 warning removal of pthreads from MSVC and mingw * removed pthread*.lib from linking in msvc6 (2005/8 not yet edited) * added threads_windows.[ch] to all project files in msvc6 * added usbi_cond_signal to both threading versions, unused * added native windows threading code, now used removed redundant time.h includes removed pthread-win32 informational solution files updated MSVC 2005/2008 for thread abstraction fixed DDK build fixed cygwin's use of POSIX threads fixed dpfp/dpfp_threaded for MinGW compatibility config_msvc.h -> msvc/config.h pthread abstraction for DLL project files fixed bad reference to thread_windows in 2005 DLL vcproj cygwin ifdef is not required in threads_windows.h - removed fixed residuals from previous patches moved thread source detection into autotool scripts
* updated copyright notice and credits in sourcer167Pete Batard2010-02-201-2/+4
|
* xusb improvements (feature reports)r162Pete Batard2010-02-181-2/+13
|
* r141: HID I/O Overhaul:r141Pete Batard2010-02-061-47/+96
| | | | | | | | - discard report ID from buffer (new hid_buffer in transfer_priv & new copy_transfer_data backend call) - overflow detection - extended HID xusb test Also: - fixed ill placed memset on composite device siblings detection
* r132: harmonized compatibility layer function names (_libusb prefix always, ↵r132Pete Batard2010-02-021-7/+25
| | | | | | rather than _for_poll suffix) additional minor xusb improvements.
* r129: xusb fixes for Mass Storage test (Alan Stern):Pete Batard2010-01-311-6/+19
| | | | | | - forces command length to 31 - null termination of vid/pid/rev strings - big endian detection
* r126: fixed sscanf_s test for MSVC6 usersPete Batard2010-01-301-1/+1
|
* r124: removes #error on previous commit and fixes thing ourselvesPete Batard2010-01-301-2/+2
|
* r123: reverted the use of usb_interface in core and forced interface to be ↵Pete Batard2010-01-291-5/+21
| | | | undefined always on Windows
* r122: fixed poll conflict on cygwin (all compat functions renamed to ↵Pete Batard2010-01-281-3/+3
| | | | | | | _libusb_####) - fixed sscanf_s undefined for non MS compilers - fixed cygiwn warnings in windows_usb.c
* r121: some more small improvements for xusb.c (vid:pid as cmdline parameter)Pete Batard2010-01-281-16/+39
|
* r119: xusb improvements for mass storage (Alan Stern)Pete Batard2010-01-271-46/+83
|
* r118: more readable xusb output and added automated endpoint generation for ↵Pete Batard2010-01-261-58/+71
| | | | Mass Storage
* r116: DDK build completion (Orin Eman):Pete Batard2010-01-261-2/+6
| | | | | | - lsusb/xusb sources + ddk_build call - missing libusb_strerror in .def - removed "handle_timeouts_locked unused" warning in in io.c for MinGW
* r115: added libusb_strerror (Francesco Montorsi)Pete Batard2010-01-251-1/+1
|
* r105: added MS Sidewinder HID test in xusb.c + minor changes/improvementsPete Batard2010-01-231-8/+82
|
* r94: removed the need for DDK includes + minor fixesPete Batard2010-01-211-1/+1
|
* r93: HID part 2 (WIP)Pete Batard2010-01-201-3/+9
| | | | | | | | | | - added composite HID device support in xusb.c - fixed signed/unsigned bug in windows_compat.c (Orin Eman) - added support for synchronous completion of async requests - composite HID device support (ClassGUID fallback for driver unavail., read interface number from MI_##, extra path for HID) - generic interface_by_endpoint and get_valid_interface - added HID struct in priv - HID submit_control_transfer
* r89: extended API supportPete Batard2010-01-181-1/+9
| | | | | | | | | - composite devices as a separate backend API - mutidriver support in composite devices interface - HID: device interface path, open/close (WIP) - added HID test in xusb.c - fixed Windows version and DDK support - smaller fixes
* r80: workaround for interface macro redefinition on Windows (removes the ↵Pete Batard2010-01-151-13/+11
| | | | need for #undef interface in end user sources)
* r75: fixed missing <stdarg.h> include in xusb.c for UNIX platformsPete Batard2010-01-141-0/+1
|
* Fix CR/LF inconsistenciesPete Batard2010-01-141-23/+23
|
* svn r62: More MSVC6 compatibilityPete Batard2010-01-141-1/+12
| | | | | - perr() without variadic in xusb.c (Michael Plante) - dropped LOOP_CONTINUE variadic in windows_usb.c
* svn r54: - fixes missing config_msvc.hPete Batard2010-01-141-4/+8
|
* svn r44:Pete Batard2010-01-141-42/+173
| | | | | | - fixed configure.ac for libusb handled timeouts - fixed crash on invalid fds in windows_compat.c - xusb improvements for mass storage test
* svn r42:Pete Batard2010-01-141-5/+38
| | | | | | - code cleanup - device reset improvement (tentative) - inquiry request for Mass Storage in xusb.c
* svn r40:Pete Batard2010-01-141-0/+3
| | | | | | | - feature complete! - added transfer cancellation - added device reset - additional code cleanup
* svn r38:Pete Batard2010-01-141-21/+77
| | | | | | - bulk/interrupt I/O at last! - endpoint handling - minor code improvements
* svn r37:Pete Batard2010-01-141-58/+166
| | | | | | | - windows_set_interface_altsetting (untested) - windows_set_configuration (untested) - updated xusb.c test program, with comprehensive XBox Controller test and preparation for bulk transfers test on Mass Storage device
* svn r25:Pete Batard2010-01-141-6/+7
| | | | | | - WinUSB composite device support (with DeviceClasses registry lookup) - better interface handling - other minor improvements
* svn r22: Partial async I/O (control only) with custom poll and OVERLAPPED ↵Pete Batard2010-01-141-37/+58
| | | | pointers as fds. Should read device strings. Also some provisions for composite devices.
* svn r18: basic open/close & claim/release interface + detection of WinUSB ↵Pete Batard2010-01-141-3/+46
| | | | and driverless devices (priv->driver)
* svn r13: add winusb to the mix: query first interface and pipes on device openPete Batard2010-01-141-3/+8
|