diff --git a/obsw_tmtc_client.py b/obsw_tmtc_client.py
index af5ac00312fe8adc8d2195c92c85272f0ab42649..c2da60cd9f2ee9b0e7e0c7c007478d1372cea5da 100755
--- a/obsw_tmtc_client.py
+++ b/obsw_tmtc_client.py
@@ -60,28 +60,26 @@ import sys
 from collections import deque
 from typing import Tuple, Union
 
-from test import obsw_pus_service_test
 from config import obsw_config as g
 from config.obsw_config import set_globals
-from tc.obsw_pus_tc_packer import create_total_tc_queue, ServiceQueuePacker
-from tmtc_core.tc.obsw_pus_tc_base import PusTcInfo
-from obsw_user_code import command_preparation_hook
 
+from tmtc_core.tc.obsw_pus_tc_base import PusTcInfo
 from tmtc_core.sendreceive.obsw_single_command_sender_receiver import SingleCommandSenderReceiver
 from tmtc_core.sendreceive.obsw_sequential_sender_receiver import SequentialCommandSenderReceiver
 from tmtc_core.sendreceive.obsw_tm_listener import TmListener
-
-from utility.obsw_args_parser import parse_input_arguments
 from tmtc_core.utility.obsw_tmtc_printer import TmTcPrinter
 from tmtc_core.utility.obsw_exit_handler import keyboard_interrupt_handler
 from tmtc_core.utility.obsw_logger import set_tmtc_logger, get_logger
-from utility.obsw_binary_uploader import perform_binary_upload
-
 from tmtc_core.comIF.obsw_com_config import set_communication_interface
 
+from test import obsw_pus_service_test
+from tc.obsw_pus_tc_packer import create_total_tc_queue, ServiceQueuePacker
+from utility.obsw_args_parser import parse_input_arguments
+from utility.obsw_binary_uploader import perform_binary_upload
+
 from gui.obsw_tmtc_gui import TmTcGUI
 from gui.obsw_backend_test import TmTcBackend
-
+from obsw_user_code import command_preparation_hook
 
 LOGGER = get_logger()
 
@@ -102,15 +100,8 @@ def main():
     LOGGER.info("Starting TMTC Handler")
 
     if g.G_MODE_ID == g.ModeList.GUIMode:
-        # Experimental
-        backend = TmTcBackend()
-        backend.start()
-        gui = TmTcGUI()
-        gui.start()
-        backend.join()
-        gui.join()
-        LOGGER.info("Both processes have closed")
-        sys.exit()
+        do_gui_test()
+
     else:
         tmtc_handler = TmTcHandler()
         tmtc_handler.perform_operation()
@@ -122,6 +113,18 @@ def main():
         pass
 
 
+def do_gui_test():
+    # Experimental
+    backend = TmTcBackend()
+    backend.start()
+    gui = TmTcGUI()
+    gui.start()
+    backend.join()
+    gui.join()
+    LOGGER.info("Both processes have closed")
+    sys.exit()
+
+
 def command_preparation() -> Tuple[bytearray, Union[None, PusTcInfo]]:
     """
     Prepare command for single command testing