diff options
Diffstat (limited to 'ioctl/hidraw.py')
-rw-r--r-- | ioctl/hidraw.py | 21 |
1 files changed, 9 insertions, 12 deletions
diff --git a/ioctl/hidraw.py b/ioctl/hidraw.py index 94cd1b4..d72ec33 100644 --- a/ioctl/hidraw.py +++ b/ioctl/hidraw.py @@ -10,6 +10,13 @@ from typing import BinaryIO, List, Tuple import ioctl +__all__ = [ + 'HidrawReportDescriptor', + 'HidrawDevinfo', + 'Hidraw', +] + + class HidrawReportDescriptor(ctypes.Structure): HID_MAX_DESCRIPTOR_SIZE = 4096 _fields_ = [ @@ -39,7 +46,6 @@ class Hidraw(object): HIDIOCGRAWPHYS = 0x05 HIDIOCSFEATURE = 0x06 HIDIOCGFEATURE = 0x07 - HIDIOCGRAWUNIQ = 0x08 HID_NAME_SIZE = 1024 @@ -119,19 +125,10 @@ class Hidraw(object): @property def phys(self) -> str: ''' - HID physical name of the hidraw node + Physical name of the hidraw node ''' return ioctl.IOCTL.IOR( 'H', self.HIDIOCGRAWPHYS, self.HID_NAME_SIZE ).perform(self._fd).decode('utf-8').strip('\x00') - @property - def uniq(self) -> str: - ''' - HID unique identifier of the hidraw node - ''' - return ioctl.IOCTL.IOR( - 'H', self.HIDIOCGRAWUNIQ, self.HID_NAME_SIZE - ).perform(self._fd).decode('utf-8').strip('\x00') - - # TODO: HIDIOCSFEATURE, HIDIOCGFEATURE + # TODO: HIDIOCSFEATURE, HIDIOCGFEATURE, HIDIOCGRAWUNIQ |