From d9cea2ae8b06bca774d9bae413df2693bb3d8fd0 Mon Sep 17 00:00:00 2001 From: Alan Johnston Date: Sun, 30 Jul 2023 14:41:48 -0400 Subject: [PATCH] change file to T or F --- rpitx.py | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/rpitx.py b/rpitx.py index c9bc9699..3062b7ae 100644 --- a/rpitx.py +++ b/rpitx.py @@ -104,7 +104,11 @@ if __name__ == "__main__": try: file = open("/home/pi/CubeSatSim/command_tx") - command_tx = file.readline().split(" ")[0] + char = file.read(1) + if (char == 'T') + command_tx = True + else: + command_tx = False except: command_tx = True if (debug_mode == 1):