mirror of
https://github.com/kovidgoyal/calibre.git
synced 2025-07-08 10:44:09 -04:00
Raised default timeout from 100 to 1000ms as operations on storage card were occassionally timing out
This commit is contained in:
parent
e3a9bfc265
commit
f31caad22a
@ -273,7 +273,7 @@ class PRS500Device(object):
|
|||||||
self.handle.releaseInterface()
|
self.handle.releaseInterface()
|
||||||
self.handle, self.device = None, None
|
self.handle, self.device = None, None
|
||||||
|
|
||||||
def _send_command(self, command, response_type=Response, timeout=100):
|
def _send_command(self, command, response_type=Response, timeout=1000):
|
||||||
"""
|
"""
|
||||||
Send L{command<Command>} to device and return its L{response<Response>}.
|
Send L{command<Command>} to device and return its L{response<Response>}.
|
||||||
|
|
||||||
@ -289,7 +289,7 @@ class PRS500Device(object):
|
|||||||
if self._log_packets: _log_packet(response, "Response")
|
if self._log_packets: _log_packet(response, "Response")
|
||||||
return response
|
return response
|
||||||
|
|
||||||
def _send_validated_command(self, command, cnumber=None, response_type=Response, timeout=100):
|
def _send_validated_command(self, command, cnumber=None, response_type=Response, timeout=1000):
|
||||||
"""
|
"""
|
||||||
Wrapper around L{_send_command} that checks if the C{Response.rnumber == cnumber or command.number if cnumber==None}. Also check that
|
Wrapper around L{_send_command} that checks if the C{Response.rnumber == cnumber or command.number if cnumber==None}. Also check that
|
||||||
C{Response.type == Command.type}.
|
C{Response.type == Command.type}.
|
||||||
|
Loading…
x
Reference in New Issue
Block a user