You've already forked TEF6686_Driver
make it based on the stereo pilot
This commit is contained in:
4
xrd.py
4
xrd.py
@@ -164,7 +164,7 @@ def send_signal_status(tef: TEF6686, conn: socket.socket, state: dict):
|
|||||||
if not freq_allowed(state["last_tune"]):
|
if not freq_allowed(state["last_tune"]):
|
||||||
conn.sendall(b"Sm11.25,0,0,0\n\n")
|
conn.sendall(b"Sm11.25,0,0,0\n\n")
|
||||||
return
|
return
|
||||||
_, _, stereo, _ = d if (d := tef.FM_Get_Processing_Status()) else (None, None, 1000, None)
|
stereo_pilot, _ = d if (d := tef.FM_Get_Signal_Status()) else (None, None)
|
||||||
|
|
||||||
res = tef.FM_Get_Quality_Data()
|
res = tef.FM_Get_Quality_Data()
|
||||||
if res is None: return
|
if res is None: return
|
||||||
@@ -174,7 +174,7 @@ def send_signal_status(tef: TEF6686, conn: socket.socket, state: dict):
|
|||||||
|
|
||||||
data = b"S"
|
data = b"S"
|
||||||
if state['forced_mono']: data += b"M"
|
if state['forced_mono']: data += b"M"
|
||||||
elif stereo < 350: data += b"s"
|
elif stereo_pilot: data += b"s"
|
||||||
else: data += b"m"
|
else: data += b"m"
|
||||||
|
|
||||||
data += f"{level + 11.25},{wam//10},{usn//10},{bandwidth}\n\n".encode()
|
data += f"{level + 11.25},{wam//10},{usn//10},{bandwidth}\n\n".encode()
|
||||||
|
|||||||
Reference in New Issue
Block a user