コード例 #1
0
ファイル: hidsensor.py プロジェクト: snim2/python-csp
 def open(self):
     self._check(hid.hid_force_open(self._interface,
                                    0,
                                    self.__class__.MATCHER.matcher,
                                    3),
              'hid_force_open')
     self._id = self._interface.id
     with os.tmpfile() as tmpfile:
         hid.hid_write_identification(tmpfile, self._interface)
         tmpfile.flush()
         tmpfile.seek(0)
         details = tmpfile.read() + '\n'
     return details
コード例 #2
0
ファイル: hidwrap.py プロジェクト: chad3814/libhid
 def write_identification(self, stream):
     '''Print the vendor, model and serial number strings, as available.'''
     _hid_raise("write_identification", hid.hid_write_identification(
         stream, self.interface))
コード例 #3
0
ファイル: hidwrap.py プロジェクト: raurodba/psychophysics
 def write_identification(self, stream):
     _hid_raise("write_identification",
                hid.hid_write_identification(stream, self.interface))
コード例 #4
0
ファイル: hidwrap.py プロジェクト: rippelchristoph/libhid
 def write_identification(self, stream):
     '''Print the vendor, model and serial number strings, as available.'''
     _hid_raise("write_identification",
                hid.hid_write_identification(stream, self.interface))
コード例 #5
0
ファイル: hidwrap.py プロジェクト: JanaMa/psychophysics
 def write_identification(self, stream):
     _hid_raise("write_identification", hid.hid_write_identification(
         stream, self.interface))