Transport job callback in thread
This commit is contained in:
parent
f02715bced
commit
540bde4cd4
@ -144,6 +144,7 @@ class RNodeInterface(Interface):
|
||||
if (self.validateRadioState()):
|
||||
self.interface_ready = True
|
||||
RNS.log(str(self)+" is configured and powered up")
|
||||
sleep(1.0)
|
||||
else:
|
||||
RNS.log("After configuring "+str(self)+", the actual radio parameters did not match your configuration.", RNS.LOG_ERROR)
|
||||
RNS.log("Make sure that your hardware actually supports the parameters specified in the configuration", RNS.LOG_ERROR)
|
||||
|
@ -74,7 +74,9 @@ class Transport:
|
||||
# Process receipts list for timed-out packets
|
||||
if Transport.receipts_last_checked+Transport.receipts_check_interval < time.time():
|
||||
for receipt in Transport.receipts:
|
||||
receipt.check_timeout()
|
||||
thread = threading.Thread(target=receipt.check_timeout)
|
||||
thread.setDaemon(True)
|
||||
thread.start()
|
||||
if receipt.status != RNS.PacketReceipt.SENT:
|
||||
Transport.receipts.remove(receipt)
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user