test_callable (__main__.TestDevice) ... ERROR
test_callable_blocked (__main__.TestDevice) ... ERROR
test_callable_unknown (__main__.TestDevice) ... ok
======================================================================
ERROR: test_callable (__main__.TestDevice)
----------------------------------------------------------------------
Traceback (most recent call last):
File "test_device.py", line 19, in test_callable
self.assertEqual(self._switch.on(), 100)
File "/var/www/pyfs20-master/fs20/device.py", line 98, in callable
, time=util.time_string_to_byte(time_string)
File "/var/www/pyfs20-master/fs20/pcs.py", line 234, in send_once
+ self._get_raw_command(command + time)
File "/var/www/pyfs20-master/fs20/pcs.py", line 184, in _write
return self._get_response()
File "/var/www/pyfs20-master/fs20/pcs.py", line 169, in _get_response
raise DeviceInvalidResponse('Invalid response from device.')
DeviceInvalidResponse: Invalid response from device.
======================================================================
ERROR: test_callable_blocked (__main__.TestDevice)
----------------------------------------------------------------------
Traceback (most recent call last):
File "test_device.py", line 27, in test_callable_blocked
self.assertEqual(self._switch.on(), 100)
File "/var/www/pyfs20-master/fs20/device.py", line 98, in callable
, time=util.time_string_to_byte(time_string)
File "/var/www/pyfs20-master/fs20/pcs.py", line 234, in send_once
+ self._get_raw_command(command + time)
File "/var/www/pyfs20-master/fs20/pcs.py", line 182, in _write
self._get_device().write(ENDPOINT_WRITE, dataframe)
File "/usr/local/lib/python2.7/dist-packages/usb/core.py", line 940, in write
intf, ep = self._ctx.setup_request(self, endpoint)
File "/usr/local/lib/python2.7/dist-packages/usb/core.py", line 102, in wrapper
return f(self, *args, **kwargs)
File "/usr/local/lib/python2.7/dist-packages/usb/core.py", line 216, in setup_request
self.managed_claim_interface(device, intf)
File "/usr/local/lib/python2.7/dist-packages/usb/core.py", line 102, in wrapper
return f(self, *args, **kwargs)
File "/usr/local/lib/python2.7/dist-packages/usb/core.py", line 167, in managed_claim_interface
self.backend.claim_interface(self.handle, i)
File "/usr/local/lib/python2.7/dist-packages/usb/backend/libusb1.py", line 811, in claim_interface
_check(self.lib.libusb_claim_interface(dev_handle.handle, intf))
File "/usr/local/lib/python2.7/dist-packages/usb/backend/libusb1.py", line 595, in _check
raise USBError(_strerror(ret), ret, _libusb_errno[ret])
USBError: [Errno 16] Resource busy