mirror of
https://github.com/DJ2LS/FreeDATA
synced 2024-05-14 08:04:33 +00:00
modem optimization
This commit is contained in:
parent
2c7ca05bee
commit
327f07ed4d
1 changed files with 3 additions and 17 deletions
20
modem.py
20
modem.py
|
@ -137,6 +137,7 @@ class RF():
|
||||||
|
|
||||||
self.my_rig.set_ptt(self.hamlib_ptt_type,0)
|
self.my_rig.set_ptt(self.hamlib_ptt_type,0)
|
||||||
static.PTT_STATE = False
|
static.PTT_STATE = False
|
||||||
|
|
||||||
static.ARQ_STATE = 'RECEIVING_DATA'
|
static.ARQ_STATE = 'RECEIVING_DATA'
|
||||||
#--------------------------------------------------------------------------------------------------------
|
#--------------------------------------------------------------------------------------------------------
|
||||||
# GET ARQ BURST FRAME VOM BUFFER AND MODULATE IT
|
# GET ARQ BURST FRAME VOM BUFFER AND MODULATE IT
|
||||||
|
@ -280,13 +281,6 @@ class RF():
|
||||||
stuck_in_sync_counter = 0
|
stuck_in_sync_counter = 0
|
||||||
stuck_in_sync_10_counter = 0
|
stuck_in_sync_10_counter = 0
|
||||||
#
|
#
|
||||||
|
|
||||||
|
|
||||||
#for i in range(0,3):
|
|
||||||
# data_dummy = bytes(self.c_lib.freedv_nin(freedv_data))
|
|
||||||
# signalling_dummy = bytes(self.c_lib.freedv_nin(freedv_signalling))
|
|
||||||
# self.c_lib.freedv_rawdatarx(freedv_data, data_bytes_out, data_dummy)
|
|
||||||
# self.c_lib.freedv_rawdatarx(freedv_signalling, data_bytes_out, signalling_dummy)
|
|
||||||
|
|
||||||
while static.ARQ_STATE == 'RECEIVING_DATA':
|
while static.ARQ_STATE == 'RECEIVING_DATA':
|
||||||
time.sleep(0.01)
|
time.sleep(0.01)
|
||||||
|
@ -357,16 +351,8 @@ class RF():
|
||||||
if frame == n_frames_per_burst:
|
if frame == n_frames_per_burst:
|
||||||
logging.debug("LAST FRAME ---> UNSYNC")
|
logging.debug("LAST FRAME ---> UNSYNC")
|
||||||
self.c_lib.freedv_set_sync(freedv_data, 0) #FORCE UNSYNC
|
self.c_lib.freedv_set_sync(freedv_data, 0) #FORCE UNSYNC
|
||||||
|
|
||||||
# clear demod buffer
|
|
||||||
|
|
||||||
#for i in range(0,3):
|
|
||||||
# data_dummy = bytes(self.c_lib.freedv_nin(freedv_data))
|
|
||||||
# signalling_dummy = bytes(self.c_lib.freedv_nin(freedv_signalling))
|
|
||||||
# self.c_lib.freedv_rawdatarx(freedv_data, data_bytes_out, data_dummy)
|
|
||||||
# self.c_lib.freedv_rawdatarx(freedv_signalling, data_bytes_out, signalling_dummy)
|
|
||||||
|
|
||||||
|
|
||||||
#while static.ARQ_STATE == 'IDLE' or static.ARQ_STATE == 'RECEIVING_SIGNALLING':
|
#while static.ARQ_STATE == 'IDLE' or static.ARQ_STATE == 'RECEIVING_SIGNALLING':
|
||||||
while static.ARQ_STATE == 'RECEIVING_SIGNALLING':
|
while static.ARQ_STATE == 'RECEIVING_SIGNALLING':
|
||||||
time.sleep(0.01)
|
time.sleep(0.01)
|
||||||
|
|
Loading…
Reference in a new issue