mirror of
https://github.com/DJ2LS/FreeDATA
synced 2024-05-14 08:04:33 +00:00
wait with arq transmission if channel busy
This commit is contained in:
parent
0cafb600b3
commit
d71fb3c640
1 changed files with 7 additions and 0 deletions
|
@ -1596,6 +1596,13 @@ class DATA:
|
|||
# for calculating transmission statistics
|
||||
# static.ARQ_COMPRESSION_FACTOR = len(data_out) / len(zlib.compress(data_out))
|
||||
|
||||
# Let's check if we have a busy channel and we are not in a running arq session.
|
||||
if static.CHANNEL_BUSY and not static.ARQ_SESSION:
|
||||
self.log.warning("[TNC] Channel busy, waiting until free...")
|
||||
# wait while timeout not reached and our busy state is busy
|
||||
while static.CHANNEL_BUSY and not self.datachannel_timeout:
|
||||
time.sleep(0.01)
|
||||
|
||||
self.arq_open_data_channel(mode, n_frames_per_burst, mycallsign)
|
||||
|
||||
# wait until data channel is open
|
||||
|
|
Loading…
Reference in a new issue