diff --git a/sendreceive/obsw_multiple_commands_sender_receiver.py b/sendreceive/obsw_multiple_commands_sender_receiver.py index 7c8bfd79a41ce817590da24f49369da37eed9a08..274204c3d182ca459b708717e17a8ac044bd5cf5 100644 --- a/sendreceive/obsw_multiple_commands_sender_receiver.py +++ b/sendreceive/obsw_multiple_commands_sender_receiver.py @@ -58,6 +58,8 @@ class MultipleCommandSenderReceiver(SequentialCommandSenderReceiver): self.wait_for_last_replies_listening(self._tm_timeout / 1.4) # Get a copy of the queue, otherwise we will lose the data. tm_packet_queue_list = self._tm_listener.retrieve_tm_packet_queue().copy() + if g.G_PRINT_TM: + self.print_tm_queue(self._tm_listener.retrieve_tm_packet_queue()) self._tm_listener.clear_tm_packet_queue() self._tm_listener.event_mode_op_finished.set() if g.G_PRINT_TO_FILE: diff --git a/test/obsw_module_test.py b/test/obsw_module_test.py index 6cb4d373a5294332cd96cda2485563512d04f81d..9c1f4681c42b95d1e2884648a1682cc85694f96c 100644 --- a/test/obsw_module_test.py +++ b/test/obsw_module_test.py @@ -4,9 +4,11 @@ @brief Module/High-Level test of on-board software, used by the TMTC client in software test mode. @details +Supply --np to suppress output of TM, ommit for debugging! + It is very difficult to execute Unit Tests on embedded hardware. -The most significant functonalities for satellites are commanding and TM reception. -As such, these functionalities will be tested by sending TCs and checking the expected Telemetry. +The most significant software components for satellites are commanding and TM reception. +As such, these components will be tested by sending TCs and checking the expected Telemetry. Still, we make use of the Unit Testing Framework provided by Python (with some hacks involved). @manual @@ -39,7 +41,6 @@ from enum import Enum from abc import abstractmethod from collections import deque from typing import Deque -import pprint from config import obsw_config as g from tc.obsw_pus_tc_packer import pack_dummy_device_test_into @@ -136,7 +137,6 @@ class TestService(unittest.TestCase): tm_packet_queue = deque() try: (tc_info_queue, tm_packet_queue) = module_tester.send_tc_queue_and_return_info() - module_tester.print_tm_queue(tm_packet_queue) except (IOError, KeyboardInterrupt): LOGGER.info("Closing TMTC Handler") tm_info_queue = deque()