Changeset 11529 for main/pyfprint
- Timestamp:
- 18 Mar 2014, 23:39:47 (11 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
main/pyfprint/trunk/src/fprint.py
r11526 r11529 2 2 import ctypes 3 3 4 lib = ctypes.cdll.LoadLibrary("libfprint.so ")4 lib = ctypes.cdll.LoadLibrary("libfprint.so.0") 5 5 6 6 # … … 28 28 ] 29 29 30 class libusb_device_descriptor(ctypes.Structure): 31 # from libusb.h 32 _fields_ = [ 33 ('bLength', ctypes.c_uint8), 34 ('bDescriptorType', ctypes.c_uint8), 35 ('bcdUSB', ctypes.c_uint16), 36 ('bDeviceClass', ctypes.c_uint8), 37 ('bDeviceSubClass', ctypes.c_uint8), 38 ('bDeviceProtocol', ctypes.c_uint8), 39 ('bMaxPacketSize0', ctypes.c_uint8), 40 ('idVendor', ctypes.c_uint16), 41 ('idProduct', ctypes.c_uint16), 42 ('bcdDevice', ctypes.c_uint16), 43 ('iManufacturer', ctypes.c_uint8), 44 ('iProduct', ctypes.c_uint8), 45 ('iSerialNumber', ctypes.c_uint8), 46 ('bNumConfigurations', ctypes.c_uint8), 47 ] 30 48 31 49 … … 48 66 # Device operations 49 67 ('discover', ctypes.CFUNCTYPE( 50 c_int, # Returntype? 51 POINTER(libusb_device_descriptor), ctypes.c_uint32_p), 68 ctypes.c_int, # Returntype? 69 ctypes.POINTER(libusb_device_descriptor), 70 ctypes.POINTER(ctypes.c_uint32)), 71 ), 52 72 # int (*discover)(struct libusb_device_descriptor *dsc, uint32_t *devtype); 53 73 # int (*open)(struct fp_dev *dev, unsigned long driver_data); … … 59 79 # int (*identify_start)(struct fp_dev *dev); 60 80 # int (*identify_stop)(struct fp_dev *dev, gboolean iterating); 61 };81 # }; 62 82 63 83 ]
Note: See TracChangeset for help on using the changeset viewer.