From 6d80ad74769200e896bbc6aa546b3ca132fb3135 Mon Sep 17 00:00:00 2001 From: Cleanroom Laptop L15 Date: Fri, 22 Apr 2022 14:21:08 +0200 Subject: [PATCH 01/11] adc channel input in hex --- pus_tc/devs/ploc_supervisor.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pus_tc/devs/ploc_supervisor.py b/pus_tc/devs/ploc_supervisor.py index 348c92d..b074d0b 100644 --- a/pus_tc/devs/ploc_supervisor.py +++ b/pus_tc/devs/ploc_supervisor.py @@ -626,7 +626,7 @@ def pack_set_adc_enabled_channels_cmd(object_id: bytearray) -> bytearray: @brief This function packs the command to enable or disable channels of the ADC. @param object_id The object id of the PLOC supervisor handler. """ - ch = int(input("Specify ch:")) + ch = int(input("Specify ch: 0x"), 16) command = bytearray() command = object_id + struct.pack("!I", SupvActionIds.SET_ADC_ENABLED_CHANNELS) command = command + struct.pack("!H", ch) From ad53f3e9bb526bf030905d24781af57ae6ac5b01 Mon Sep 17 00:00:00 2001 From: Cleanroom Laptop L15 Date: Fri, 22 Apr 2022 18:02:49 +0200 Subject: [PATCH 02/11] improved supervsior commanding --- pus_tc/devs/ploc_supervisor.py | 16 ++++++++-------- tmtccmd | 2 +- 2 files changed, 9 insertions(+), 9 deletions(-) diff --git a/pus_tc/devs/ploc_supervisor.py b/pus_tc/devs/ploc_supervisor.py index 4a2f8cf..9038928 100644 --- a/pus_tc/devs/ploc_supervisor.py +++ b/pus_tc/devs/ploc_supervisor.py @@ -32,6 +32,8 @@ MANUAL_INPUT = "1" update_file_dict = { MANUAL_INPUT: ["manual input", ""], "2": ["/mnt/sd0/ploc/supervisor/update.bin", "/mnt/sd0/ploc/supervisor/update.bin"], + "3": ["/mnt/sd0/ploc/supervisor/update-large.bin", "/mnt/sd0/ploc/supervisor/update-large.bin"], + "4": ["/mnt/sd0/ploc/supervisor/update-small.bin", "/mnt/sd0/ploc/supervisor/update-small.bin"], } event_buffer_path_dict = { @@ -649,7 +651,7 @@ def pack_set_adc_window_and_stride_cmd(object_id: bytearray) -> bytearray: def pack_set_adc_threshold_cmd(object_id: bytearray) -> bytearray: - threshold = int(input("Specify threshold:")) + threshold = int(input("Specify threshold: ")) command = bytearray() command = object_id + struct.pack("!I", SupvActionIds.SET_ADC_THRESHOLD) command = command + struct.pack("!I", threshold) @@ -767,10 +769,9 @@ def get_debug_verbosity() -> int: def pack_set_gpio_cmd(object_id: bytearray) -> bytearray: - port = int(input("Specify port: ")) - pin = int(input("Specify pin: ")) - val = int(input("Specify val: ")) - command = bytearray() + port = int(input("Specify port : 0x"), 16) + pin = int(input("Specify pin: 0x"), 16) + val = int(input("Specify val: 0x"), 16) command = object_id + struct.pack("!I", SupvActionIds.SET_GPIO) command = command + struct.pack("!B", port) command = command + struct.pack("!B", pin) @@ -779,9 +780,8 @@ def pack_set_gpio_cmd(object_id: bytearray) -> bytearray: def pack_read_gpio_cmd(object_id: bytearray) -> bytearray: - port = int(input("Specify port: ")) - pin = int(input("Specify pin: ")) - command = bytearray() + port = int(input("Specify port: 0x"), 16) + pin = int(input("Specify pin: 0x"), 16) command = object_id + struct.pack("!I", SupvActionIds.READ_GPIO) command = command + struct.pack("!B", port) command = command + struct.pack("!B", pin) diff --git a/tmtccmd b/tmtccmd index 5d6db96..48b6b83 160000 --- a/tmtccmd +++ b/tmtccmd @@ -1 +1 @@ -Subproject commit 5d6db96ffccab2fb64670875bab81fdd1ddd3816 +Subproject commit 48b6b8396eb3ea5ec4527ccb96f5909a29cd95f6 From 8df865c8c1b388d59d53616a038517b0db340756 Mon Sep 17 00:00:00 2001 From: Jakob Meier Date: Sun, 24 Apr 2022 12:35:00 +0200 Subject: [PATCH 03/11] regenerated events --- config/events.csv | 4 + config/returnvalues.csv | 191 +++++++++++++++++++++------------------- 2 files changed, 102 insertions(+), 93 deletions(-) diff --git a/config/events.csv b/config/events.csv index 5e97bab..c32eaa6 100644 --- a/config/events.csv +++ b/config/events.csv @@ -192,3 +192,7 @@ 13614;0x352e;SUPV_EXE_INVALID_APID;LOW;Supervisor helper expected execution report but received space packet with other apid P1: Apid of received space packet P2: Internal state of supervisor helper;linux\devices\ploc\PlocSupvHelper.h 13615;0x352f;ACK_RECEPTION_FAILURE;LOW;Failed to receive acknowledgment report P1: Return value P2: Apid of command for which the reception of the acknowledgment report failed;linux\devices\ploc\PlocSupvHelper.h 13616;0x3530;EXE_RECEPTION_FAILURE;LOW;Failed to receive execution report P1: Return value P2: Apid of command for which the reception of the execution report failed;linux\devices\ploc\PlocSupvHelper.h +13700;0x3584;ALLOC_FAILURE;MEDIUM;;bsp_q7s\core\CoreController.h +13701;0x3585;REBOOT_SW;MEDIUM; Software reboot occurred. Can also be a systemd reboot. P1: Current Chip, P2: Current Copy;bsp_q7s\core\CoreController.h +13702;0x3586;REBOOT_MECHANISM_TRIGGERED;MEDIUM;The reboot mechanism was triggered. P1: First 16 bits: Last Chip, Last 16 bits: Last Copy, P2: Each byte is the respective reboot count for the slots;bsp_q7s\core\CoreController.h +13703;0x3587;REBOOT_HW;MEDIUM;;bsp_q7s\core\CoreController.h diff --git a/config/returnvalues.csv b/config/returnvalues.csv index a0f1562..104795c 100644 --- a/config/returnvalues.csv +++ b/config/returnvalues.csv @@ -1,11 +1,11 @@ 0x0;OK;System-wide code for ok.;RETURN_OK;HasReturnvaluesIF.h;HasReturnvaluesIF 0x1;Failed;Unspecified system-wide code for failed.;RETURN_FAILED;HasReturnvaluesIF.h;HasReturnvaluesIF -0x5f00;GOMS_PacketTooLong;;0;mission\devices\GomspaceDeviceHandler.h;GOM_SPACE_HANDLER -0x5f01;GOMS_InvalidTableId;;1;mission\devices\GomspaceDeviceHandler.h;GOM_SPACE_HANDLER -0x5f02;GOMS_InvalidAddress;;2;mission\devices\GomspaceDeviceHandler.h;GOM_SPACE_HANDLER -0x5f03;GOMS_InvalidParamSize;;3;mission\devices\GomspaceDeviceHandler.h;GOM_SPACE_HANDLER -0x5f04;GOMS_InvalidPayloadSize;;4;mission\devices\GomspaceDeviceHandler.h;GOM_SPACE_HANDLER -0x5f05;GOMS_UnknownReplyId;;5;mission\devices\GomspaceDeviceHandler.h;GOM_SPACE_HANDLER +0x6000;GOMS_PacketTooLong;;0;mission\devices\GomspaceDeviceHandler.h;GOM_SPACE_HANDLER +0x6001;GOMS_InvalidTableId;;1;mission\devices\GomspaceDeviceHandler.h;GOM_SPACE_HANDLER +0x6002;GOMS_InvalidAddress;;2;mission\devices\GomspaceDeviceHandler.h;GOM_SPACE_HANDLER +0x6003;GOMS_InvalidParamSize;;3;mission\devices\GomspaceDeviceHandler.h;GOM_SPACE_HANDLER +0x6004;GOMS_InvalidPayloadSize;;4;mission\devices\GomspaceDeviceHandler.h;GOM_SPACE_HANDLER +0x6005;GOMS_UnknownReplyId;;5;mission\devices\GomspaceDeviceHandler.h;GOM_SPACE_HANDLER 0x52a1;HEATER_CommandNotSupported;;0xA1;mission\devices\HeaterHandler.h;HEATER_HANDLER 0x52a2;HEATER_InitFailed;;0xA2;mission\devices\HeaterHandler.h;HEATER_HANDLER 0x52a3;HEATER_InvalidSwitchNr;;0xA3;mission\devices\HeaterHandler.h;HEATER_HANDLER @@ -31,13 +31,13 @@ 0x55a2;RWHA_SetSpeedCommandInvalidLength;Received set speed command has invalid length. Should be 6.;0xA2;mission\devices\RwHandler.h;RW_HANDLER 0x55a3;RWHA_ExecutionFailed;Command execution failed;0xA3;mission\devices\RwHandler.h;RW_HANDLER 0x55a4;RWHA_CrcError;Reaction wheel reply has invalid crc;0xA4;mission\devices\RwHandler.h;RW_HANDLER -0x68a0;SADPL_CommandNotSupported;;0xA0;mission\devices\SolarArrayDeploymentHandler.h;SA_DEPL_HANDLER -0x68a1;SADPL_DeploymentAlreadyExecuting;;0xA1;mission\devices\SolarArrayDeploymentHandler.h;SA_DEPL_HANDLER -0x68a2;SADPL_MainSwitchTimeoutFailure;;0xA2;mission\devices\SolarArrayDeploymentHandler.h;SA_DEPL_HANDLER -0x68a3;SADPL_SwitchingDeplSa1Failed;;0xA3;mission\devices\SolarArrayDeploymentHandler.h;SA_DEPL_HANDLER -0x68a4;SADPL_SwitchingDeplSa2Failed;;0xA4;mission\devices\SolarArrayDeploymentHandler.h;SA_DEPL_HANDLER -0x5aa0;SUSS_ErrorUnlockMutex;;0xA0;mission\devices\SusHandler.h;SUS_HANDLER -0x5aa1;SUSS_ErrorLockMutex;;0xA1;mission\devices\SusHandler.h;SUS_HANDLER +0x69a0;SADPL_CommandNotSupported;;0xA0;mission\devices\SolarArrayDeploymentHandler.h;SA_DEPL_HANDLER +0x69a1;SADPL_DeploymentAlreadyExecuting;;0xA1;mission\devices\SolarArrayDeploymentHandler.h;SA_DEPL_HANDLER +0x69a2;SADPL_MainSwitchTimeoutFailure;;0xA2;mission\devices\SolarArrayDeploymentHandler.h;SA_DEPL_HANDLER +0x69a3;SADPL_SwitchingDeplSa1Failed;;0xA3;mission\devices\SolarArrayDeploymentHandler.h;SA_DEPL_HANDLER +0x69a4;SADPL_SwitchingDeplSa2Failed;;0xA4;mission\devices\SolarArrayDeploymentHandler.h;SA_DEPL_HANDLER +0x5ba0;SUSS_ErrorUnlockMutex;;0xA0;mission\devices\SusHandler.h;SUS_HANDLER +0x5ba1;SUSS_ErrorLockMutex;;0xA1;mission\devices\SusHandler.h;SUS_HANDLER 0x53a0;SYRLINKS_CrcFailure;;0xA0;mission\devices\SyrlinksHkHandler.h;SYRLINKS_HANDLER 0x53a1;SYRLINKS_UartFraminOrParityErrorAck;;0xA1;mission\devices\SyrlinksHkHandler.h;SYRLINKS_HANDLER 0x53a2;SYRLINKS_BadCharacterAck;;0xA2;mission\devices\SyrlinksHkHandler.h;SYRLINKS_HANDLER @@ -47,8 +47,8 @@ 0x53a6;SYRLINKS_BadCrcAck;;0xA6;mission\devices\SyrlinksHkHandler.h;SYRLINKS_HANDLER 0x53a7;SYRLINKS_ReplyWrongSize;;0xA7;mission\devices\SyrlinksHkHandler.h;SYRLINKS_HANDLER 0x53a8;SYRLINKS_MissingStartFrameCharacter;;0xA8;mission\devices\SyrlinksHkHandler.h;SYRLINKS_HANDLER -0x65a0;NVMB_KeyNotExists;Specified key does not exist in json file;0xA0;mission\memory\NVMParameterBase.h;NVM_PARAM_BASE -0x62a0;CCSDS_CommandNotImplemented;Received action message with unknown action id;0xA0;mission\tmtc\CCSDSHandler.h;CCSDS_HANDLER +0x66a0;NVMB_KeyNotExists;Specified key does not exist in json file;0xA0;mission\memory\NVMParameterBase.h;NVM_PARAM_BASE +0x63a0;CCSDS_CommandNotImplemented;Received action message with unknown action id;0xA0;mission\tmtc\CCSDSHandler.h;CCSDS_HANDLER 0x4601; HGIO_UnknownGpioId;;1;fsfw\hal\src\fsfw_hal\linux\gpio\LinuxLibgpioIF.h;HAL_GPIO 0x4602; HGIO_DriveGpioFailure;;2;fsfw\hal\src\fsfw_hal\linux\gpio\LinuxLibgpioIF.h;HAL_GPIO 0x4603; HGIO_GpioTypeFailure;;3;fsfw\hal\src\fsfw_hal\linux\gpio\LinuxLibgpioIF.h;HAL_GPIO @@ -444,59 +444,64 @@ 0x1f07; CSB_InvalidReply;;7;fsfw\src\fsfw\tmtcservices\CommandingServiceBase.h;COMMAND_SERVICE_BASE 0x4a00; SPPA_NoPacketFound;;0x00;fsfw\src\fsfw\tmtcservices\SpacePacketParser.h;SPACE_PACKET_PARSER 0x4a01; SPPA_SplitPacket;;0x01;fsfw\src\fsfw\tmtcservices\SpacePacketParser.h;SPACE_PACKET_PARSER -0x66a0;FSHLP_SdNotMounted;SD card specified with path string not mounted;0xA0;bsp_q7s\memory\FilesystemHelper.h;FILE_SYSTEM_HELPER -0x66a1;FSHLP_FileNotExists;Specified file does not exist on filesystem;0xA1;bsp_q7s\memory\FilesystemHelper.h;FILE_SYSTEM_HELPER -0x7100; SCBU_KeyNotFound;;0;bsp_q7s\memory\scratchApi.h;SCRATCH_BUFFER -0x7000; SDMA_OpOngoing;;0;bsp_q7s\memory\SdCardManager.h;SD_CARD_MANAGER -0x7001; SDMA_AlreadyOn;;1;bsp_q7s\memory\SdCardManager.h;SD_CARD_MANAGER -0x7002; SDMA_AlreadyMounted;;2;bsp_q7s\memory\SdCardManager.h;SD_CARD_MANAGER -0x7003; SDMA_AlreadyOff;;3;bsp_q7s\memory\SdCardManager.h;SD_CARD_MANAGER -0x700a; SDMA_StatusFileNexists;;10;bsp_q7s\memory\SdCardManager.h;SD_CARD_MANAGER -0x700b; SDMA_StatusFileFormatInvalid;;11;bsp_q7s\memory\SdCardManager.h;SD_CARD_MANAGER -0x700c; SDMA_MountError;;12;bsp_q7s\memory\SdCardManager.h;SD_CARD_MANAGER -0x700d; SDMA_UnmountError;;13;bsp_q7s\memory\SdCardManager.h;SD_CARD_MANAGER -0x700e; SDMA_SystemCallError;;14;bsp_q7s\memory\SdCardManager.h;SD_CARD_MANAGER -0x700f; SDMA_PopenCallError;;15;bsp_q7s\memory\SdCardManager.h;SD_CARD_MANAGER -0x69a0;MPSOCRTVIF_CrcFailure;Space Packet received from PLOC has invalid CRC;0xA0;linux\devices\devicedefinitions\MPSoCReturnValuesIF.h;MPSOC_RETURN_VALUES_IF -0x69a1;MPSOCRTVIF_ReceivedAckFailure;Received ACK failure reply from PLOC;0xA1;linux\devices\devicedefinitions\MPSoCReturnValuesIF.h;MPSOC_RETURN_VALUES_IF -0x69a2;MPSOCRTVIF_ReceivedExeFailure;Received execution failure reply from PLOC;0xA2;linux\devices\devicedefinitions\MPSoCReturnValuesIF.h;MPSOC_RETURN_VALUES_IF -0x69a3;MPSOCRTVIF_InvalidApid;Received space packet with invalid APID from PLOC;0xA3;linux\devices\devicedefinitions\MPSoCReturnValuesIF.h;MPSOC_RETURN_VALUES_IF -0x69a4;MPSOCRTVIF_InvalidLength;Received command with invalid length;0xA4;linux\devices\devicedefinitions\MPSoCReturnValuesIF.h;MPSOC_RETURN_VALUES_IF -0x69a5;MPSOCRTVIF_FilenameTooLong;Filename of file in OBC filesystem is too long;0xA5;linux\devices\devicedefinitions\MPSoCReturnValuesIF.h;MPSOC_RETURN_VALUES_IF -0x69a6;MPSOCRTVIF_MpsocHelperExecuting;MPSoC helper is currently executing a command;0xA6;linux\devices\devicedefinitions\MPSoCReturnValuesIF.h;MPSOC_RETURN_VALUES_IF -0x69a7;MPSOCRTVIF_MpsocFilenameTooLong;Filename of MPSoC file is to long (max. 256 bytes);0xA7;linux\devices\devicedefinitions\MPSoCReturnValuesIF.h;MPSOC_RETURN_VALUES_IF -0x69a8;MPSOCRTVIF_InvalidParameter;Command has invalid parameter;0xA8;linux\devices\devicedefinitions\MPSoCReturnValuesIF.h;MPSOC_RETURN_VALUES_IF -0x69a9;MPSOCRTVIF_NameTooLong;Received command has file string with invalid length;0xA9;linux\devices\devicedefinitions\MPSoCReturnValuesIF.h;MPSOC_RETURN_VALUES_IF +0x67a0;FSHLP_SdNotMounted;SD card specified with path string not mounted;0xA0;bsp_q7s\memory\FilesystemHelper.h;FILE_SYSTEM_HELPER +0x67a1;FSHLP_FileNotExists;Specified file does not exist on filesystem;0xA1;bsp_q7s\memory\FilesystemHelper.h;FILE_SYSTEM_HELPER +0x7300; SCBU_KeyNotFound;;0;bsp_q7s\memory\scratchApi.h;SCRATCH_BUFFER +0x7200; SDMA_OpOngoing;;0;bsp_q7s\memory\SdCardManager.h;SD_CARD_MANAGER +0x7201; SDMA_AlreadyOn;;1;bsp_q7s\memory\SdCardManager.h;SD_CARD_MANAGER +0x7202; SDMA_AlreadyMounted;;2;bsp_q7s\memory\SdCardManager.h;SD_CARD_MANAGER +0x7203; SDMA_AlreadyOff;;3;bsp_q7s\memory\SdCardManager.h;SD_CARD_MANAGER +0x720a; SDMA_StatusFileNexists;;10;bsp_q7s\memory\SdCardManager.h;SD_CARD_MANAGER +0x720b; SDMA_StatusFileFormatInvalid;;11;bsp_q7s\memory\SdCardManager.h;SD_CARD_MANAGER +0x720c; SDMA_MountError;;12;bsp_q7s\memory\SdCardManager.h;SD_CARD_MANAGER +0x720d; SDMA_UnmountError;;13;bsp_q7s\memory\SdCardManager.h;SD_CARD_MANAGER +0x720e; SDMA_SystemCallError;;14;bsp_q7s\memory\SdCardManager.h;SD_CARD_MANAGER +0x720f; SDMA_PopenCallError;;15;bsp_q7s\memory\SdCardManager.h;SD_CARD_MANAGER +0x6aa0;MPSOCRTVIF_CrcFailure;Space Packet received from PLOC has invalid CRC;0xA0;linux\devices\devicedefinitions\MPSoCReturnValuesIF.h;MPSOC_RETURN_VALUES_IF +0x6aa1;MPSOCRTVIF_ReceivedAckFailure;Received ACK failure reply from PLOC;0xA1;linux\devices\devicedefinitions\MPSoCReturnValuesIF.h;MPSOC_RETURN_VALUES_IF +0x6aa2;MPSOCRTVIF_ReceivedExeFailure;Received execution failure reply from PLOC;0xA2;linux\devices\devicedefinitions\MPSoCReturnValuesIF.h;MPSOC_RETURN_VALUES_IF +0x6aa3;MPSOCRTVIF_InvalidApid;Received space packet with invalid APID from PLOC;0xA3;linux\devices\devicedefinitions\MPSoCReturnValuesIF.h;MPSOC_RETURN_VALUES_IF +0x6aa4;MPSOCRTVIF_InvalidLength;Received command with invalid length;0xA4;linux\devices\devicedefinitions\MPSoCReturnValuesIF.h;MPSOC_RETURN_VALUES_IF +0x6aa5;MPSOCRTVIF_FilenameTooLong;Filename of file in OBC filesystem is too long;0xA5;linux\devices\devicedefinitions\MPSoCReturnValuesIF.h;MPSOC_RETURN_VALUES_IF +0x6aa6;MPSOCRTVIF_MpsocHelperExecuting;MPSoC helper is currently executing a command;0xA6;linux\devices\devicedefinitions\MPSoCReturnValuesIF.h;MPSOC_RETURN_VALUES_IF +0x6aa7;MPSOCRTVIF_MpsocFilenameTooLong;Filename of MPSoC file is to long (max. 256 bytes);0xA7;linux\devices\devicedefinitions\MPSoCReturnValuesIF.h;MPSOC_RETURN_VALUES_IF +0x6aa8;MPSOCRTVIF_InvalidParameter;Command has invalid parameter;0xA8;linux\devices\devicedefinitions\MPSoCReturnValuesIF.h;MPSOC_RETURN_VALUES_IF +0x6aa9;MPSOCRTVIF_NameTooLong;Received command has file string with invalid length;0xA9;linux\devices\devicedefinitions\MPSoCReturnValuesIF.h;MPSOC_RETURN_VALUES_IF 0x57e0;DWLPWRON_InvalidMode;Received command has invalid JESD mode (valid modes are 0 - 5);0xE0;linux\devices\devicedefinitions\PlocMPSoCDefinitions.h;DWLPWRON_CMD 0x57e1;DWLPWRON_InvalidLaneRate;Received command has invalid lane rate (valid lane rate are 0 - 9);0xE1;linux\devices\devicedefinitions\PlocMPSoCDefinitions.h;DWLPWRON_CMD -0x60a0;PLMEMDUMP_MramAddressTooHigh;The capacity of the MRAM amounts to 512 kB. Thus the maximum address must not be higher than 0x7d000.;0xA0;linux\devices\ploc\PlocMemoryDumper.h;PLOC_MEMORY_DUMPER -0x60a1;PLMEMDUMP_MramInvalidAddressCombination;The specified end address is lower than the start address;0xA1;linux\devices\ploc\PlocMemoryDumper.h;PLOC_MEMORY_DUMPER -0x67a0; PLMPHLP_FileClosedAccidentally;File accidentally close;0xA0;linux\devices\ploc\PlocMPSoCHelper.h;PLOC_MPSOC_HELPER -0x59a0;PLSV_CrcFailure;Space Packet received from PLOC supervisor has invalid CRC;0xA0;linux\devices\ploc\PlocSupervisorHandler.h;PLOC_SUPERVISOR_HANDLER -0x59a1;PLSV_ReceivedAckFailure;Received ACK failure reply from PLOC supervisor;0xA1;linux\devices\ploc\PlocSupervisorHandler.h;PLOC_SUPERVISOR_HANDLER -0x59a2;PLSV_ReceivedExeFailure;Received execution failure reply from PLOC supervisor;0xA2;linux\devices\ploc\PlocSupervisorHandler.h;PLOC_SUPERVISOR_HANDLER -0x59a3;PLSV_InvalidApid;Received space packet with invalid APID from PLOC supervisor;0xA3;linux\devices\ploc\PlocSupervisorHandler.h;PLOC_SUPERVISOR_HANDLER -0x59a4;PLSV_GetTimeFailure;Failed to read current system time;0xA4;linux\devices\ploc\PlocSupervisorHandler.h;PLOC_SUPERVISOR_HANDLER -0x59a5;PLSV_InvalidWatchdog;Received command with invalid watchdog parameter. Valid watchdogs are 0 for PS, 1 for PL and 2 for INT;0xA5;linux\devices\ploc\PlocSupervisorHandler.h;PLOC_SUPERVISOR_HANDLER -0x59a6;PLSV_InvalidWatchdogTimeout;Received watchdog timeout config command with invalid timeout. Valid timeouts must be in the range between 1000 and 360000 ms.;0xA6;linux\devices\ploc\PlocSupervisorHandler.h;PLOC_SUPERVISOR_HANDLER -0x59a7;PLSV_InvalidLatchupId;Received latchup config command with invalid latchup ID;0xA7;linux\devices\ploc\PlocSupervisorHandler.h;PLOC_SUPERVISOR_HANDLER -0x59a8;PLSV_SweepPeriodTooSmall;Received set adc sweep period command with invalid sweep period. Must be larger than 21.;0xA8;linux\devices\ploc\PlocSupervisorHandler.h;PLOC_SUPERVISOR_HANDLER -0x59a9;PLSV_InvalidTestParam;Receive auto EM test command with invalid test param. Valid params are 1 and 2.;0xA9;linux\devices\ploc\PlocSupervisorHandler.h;PLOC_SUPERVISOR_HANDLER -0x59aa;PLSV_MramPacketParsingFailure;Returned when scanning for MRAM dump packets failed.;0xAA;linux\devices\ploc\PlocSupervisorHandler.h;PLOC_SUPERVISOR_HANDLER -0x59ab;PLSV_InvalidMramAddresses;Returned when the start and stop addresses of the MRAM dump or MRAM wipe commands are invalid (e.g. start address bigger than stop address);0xAB;linux\devices\ploc\PlocSupervisorHandler.h;PLOC_SUPERVISOR_HANDLER -0x59ac;PLSV_NoMramPacket;Expect reception of an MRAM dump packet but received space packet with other apid.;0xAC;linux\devices\ploc\PlocSupervisorHandler.h;PLOC_SUPERVISOR_HANDLER -0x59ad;PLSV_PathDoesNotExist;Path to PLOC directory on SD card does not exist;0xAD;linux\devices\ploc\PlocSupervisorHandler.h;PLOC_SUPERVISOR_HANDLER -0x59ae;PLSV_MramFileNotExists;MRAM dump file does not exists. The file should actually already have been created with the reception of the first dump packet.;0xAE;linux\devices\ploc\PlocSupervisorHandler.h;PLOC_SUPERVISOR_HANDLER -0x5da0;PLUD_UpdaterBusy;Updater is already performing an update;0xA0;linux\devices\ploc\PlocUpdater.h;PLOC_UPDATER -0x5da1;PLUD_NameTooLong;Received update command with invalid path string (too long).;0xA1;linux\devices\ploc\PlocUpdater.h;PLOC_UPDATER -0x5da2;PLUD_SdNotMounted;Received command to initiate update but SD card with update image not mounted.;0xA2;linux\devices\ploc\PlocUpdater.h;PLOC_UPDATER -0x5da3;PLUD_FileNotExists;Update file received with update command does not exist.;0xA3;linux\devices\ploc\PlocUpdater.h;PLOC_UPDATER +0x6ba0;SPVRTVIF_CrcFailure;Space Packet received from PLOC supervisor has invalid CRC;0xA0;linux\devices\devicedefinitions\SupvReturnValuesIF.h;SUPV_RETURN_VALUES_IF +0x6ba1;SPVRTVIF_ReceivedAckFailure;Received ACK failure reply from PLOC supervisor;0xA1;linux\devices\devicedefinitions\SupvReturnValuesIF.h;SUPV_RETURN_VALUES_IF +0x6ba2;SPVRTVIF_ReceivedExeFailure;Received execution failure reply from PLOC supervisor;0xA2;linux\devices\devicedefinitions\SupvReturnValuesIF.h;SUPV_RETURN_VALUES_IF +0x6ba3;SPVRTVIF_InvalidApid;Received space packet with invalid APID from PLOC supervisor;0xA3;linux\devices\devicedefinitions\SupvReturnValuesIF.h;SUPV_RETURN_VALUES_IF +0x6ba4;SPVRTVIF_GetTimeFailure;Failed to read current system time;0xA4;linux\devices\devicedefinitions\SupvReturnValuesIF.h;SUPV_RETURN_VALUES_IF +0x6ba5;SPVRTVIF_InvalidWatchdog;Received command with invalid watchdog parameter. Valid watchdogs are 0 for PS, 1 for PL and 2 for INT;0xA5;linux\devices\devicedefinitions\SupvReturnValuesIF.h;SUPV_RETURN_VALUES_IF +0x6ba6;SPVRTVIF_InvalidWatchdogTimeout;Received watchdog timeout config command with invalid timeout. Valid timeouts must be in the range between 1000 and 360000 ms.;0xA6;linux\devices\devicedefinitions\SupvReturnValuesIF.h;SUPV_RETURN_VALUES_IF +0x6ba7;SPVRTVIF_InvalidLatchupId;Received latchup config command with invalid latchup ID;0xA7;linux\devices\devicedefinitions\SupvReturnValuesIF.h;SUPV_RETURN_VALUES_IF +0x6ba8;SPVRTVIF_SweepPeriodTooSmall;Received set adc sweep period command with invalid sweep period. Must be larger than 21.;0xA8;linux\devices\devicedefinitions\SupvReturnValuesIF.h;SUPV_RETURN_VALUES_IF +0x6ba9;SPVRTVIF_InvalidTestParam;Receive auto EM test command with invalid test param. Valid params are 1 and 2.;0xA9;linux\devices\devicedefinitions\SupvReturnValuesIF.h;SUPV_RETURN_VALUES_IF +0x6baa;SPVRTVIF_MramPacketParsingFailure;Returned when scanning for MRAM dump packets failed.;0xAA;linux\devices\devicedefinitions\SupvReturnValuesIF.h;SUPV_RETURN_VALUES_IF +0x6bab;SPVRTVIF_InvalidMramAddresses;Returned when the start and stop addresses of the MRAM dump or MRAM wipe commands are invalid (e.g. start address bigger than stop address);0xAB;linux\devices\devicedefinitions\SupvReturnValuesIF.h;SUPV_RETURN_VALUES_IF +0x6bac;SPVRTVIF_NoMramPacket;Expect reception of an MRAM dump packet but received space packet with other apid.;0xAC;linux\devices\devicedefinitions\SupvReturnValuesIF.h;SUPV_RETURN_VALUES_IF +0x6bad;SPVRTVIF_PathDoesNotExist;Path to PLOC directory on SD card does not exist;0xAD;linux\devices\devicedefinitions\SupvReturnValuesIF.h;SUPV_RETURN_VALUES_IF +0x6bae;SPVRTVIF_MramFileNotExists;MRAM dump file does not exists. The file should actually already have been created with the reception of the first dump packet.;0xAE;linux\devices\devicedefinitions\SupvReturnValuesIF.h;SUPV_RETURN_VALUES_IF +0x6baf;SPVRTVIF_InvalidLength;Received action command has invalid length;0xAF;linux\devices\devicedefinitions\SupvReturnValuesIF.h;SUPV_RETURN_VALUES_IF +0x6bb0;SPVRTVIF_FilenameTooLong;Filename too long;0xB0;linux\devices\devicedefinitions\SupvReturnValuesIF.h;SUPV_RETURN_VALUES_IF +0x6bb1;SPVRTVIF_UpdateStatusReportInvalidLength;Received update status report with invalid packet length field;0xB1;linux\devices\devicedefinitions\SupvReturnValuesIF.h;SUPV_RETURN_VALUES_IF +0x6bb2;SPVRTVIF_UpdateCrcFailure;Update status report does not contain expected CRC. There might be a bit flip in the update memory region.;0xB2;linux\devices\devicedefinitions\SupvReturnValuesIF.h;SUPV_RETURN_VALUES_IF +0x6bb3;SPVRTVIF_SupvHelperExecuting;Supervisor helper task ist currently executing a command (wait until helper tas has finished or interrupt by sending the terminate command);0xB3;linux\devices\devicedefinitions\SupvReturnValuesIF.h;SUPV_RETURN_VALUES_IF +0x61a0;PLMEMDUMP_MramAddressTooHigh;The capacity of the MRAM amounts to 512 kB. Thus the maximum address must not be higher than 0x7d000.;0xA0;linux\devices\ploc\PlocMemoryDumper.h;PLOC_MEMORY_DUMPER +0x61a1;PLMEMDUMP_MramInvalidAddressCombination;The specified end address is lower than the start address;0xA1;linux\devices\ploc\PlocMemoryDumper.h;PLOC_MEMORY_DUMPER +0x68a0; PLMPHLP_FileClosedAccidentally;File accidentally close;0xA0;linux\devices\ploc\PlocMPSoCHelper.h;PLOC_MPSOC_HELPER +0x5aa0;PLSPVhLP_FileClosedAccidentally;File accidentally close;0xA0;linux\devices\ploc\PlocSupvHelper.h;PLOC_SUPV_HELPER +0x5aa1;PLSPVhLP_ProcessTerminated;Process has been terminated by command;0xA1;linux\devices\ploc\PlocSupvHelper.h;PLOC_SUPV_HELPER +0x5aa2;PLSPVhLP_PathNotExists;Received command with invalid pathname;0xA2;linux\devices\ploc\PlocSupvHelper.h;PLOC_SUPV_HELPER +0x5aa3;PLSPVhLP_EventBufferReplyInvalidApid;Expected event buffer TM but received space packet with other APID;0xA3;linux\devices\ploc\PlocSupvHelper.h;PLOC_SUPV_HELPER 0x56a0;STRH_TemperatureReqFailed;Status in temperature reply signals error;0xA0;linux\devices\startracker\StarTrackerHandler.h;STR_HANDLER 0x56a1;STRH_PingFailed;Ping command failed;0xA1;linux\devices\startracker\StarTrackerHandler.h;STR_HANDLER 0x56a2;STRH_VersionReqFailed;Status in version reply signals error;0xA2;linux\devices\startracker\StarTrackerHandler.h;STR_HANDLER -0x6401;JSONBASE_JsonFileNotExists;Specified json file does not exist;1;linux\devices\startracker\ArcsecJsonParamBase.h;ARCSEC_JSON_BASE -0x6402;JSONBASE_SetNotExists;Requested set does not exist in json file;2;linux\devices\startracker\ArcsecJsonParamBase.h;ARCSEC_JSON_BASE -0x6403;JSONBASE_ParamNotExists;Requested parameter does not exist in json file;3;linux\devices\startracker\ArcsecJsonParamBase.h;ARCSEC_JSON_BASE +0x6501;JSONBASE_JsonFileNotExists;Specified json file does not exist;1;linux\devices\startracker\ArcsecJsonParamBase.h;ARCSEC_JSON_BASE +0x6502;JSONBASE_SetNotExists;Requested set does not exist in json file;2;linux\devices\startracker\ArcsecJsonParamBase.h;ARCSEC_JSON_BASE +0x6503;JSONBASE_ParamNotExists;Requested parameter does not exist in json file;3;linux\devices\startracker\ArcsecJsonParamBase.h;ARCSEC_JSON_BASE 0x56a3;STRH_InterfaceReqFailed;Status in interface reply signals error;0xA3;linux\devices\startracker\StarTrackerHandler.h;STR_HANDLER 0x56a4;STRH_PowerReqFailed;Status in power reply signals error;0xA4;linux\devices\startracker\StarTrackerHandler.h;STR_HANDLER 0x56a5;STRH_SetParamFailed;Status of reply to parameter set command signals error;0xA5;linux\devices\startracker\StarTrackerHandler.h;STR_HANDLER @@ -519,33 +524,33 @@ 0x56b6;STRH_StartrackerAlreadyBooted;Star tracker is already in firmware mode;0xB6;linux\devices\startracker\StarTrackerHandler.h;STR_HANDLER 0x56b7;STRH_StartrackerRunningFirmware;Star tracker is in firmware mode but must be in bootloader mode to execute this command;0xB7;linux\devices\startracker\StarTrackerHandler.h;STR_HANDLER 0x56b8;STRH_StartrackerRunningBootloader;Star tracker is in bootloader mode but must be in firmware mode to execute this command;0xB8;linux\devices\startracker\StarTrackerHandler.h;STR_HANDLER -0x5ea0;STRHLP_SdNotMounted;SD card specified in path string not mounted;0xA0;linux\devices\startracker\StrHelper.h;STR_HELPER -0x5ea1;STRHLP_FileNotExists;Specified file does not exist on filesystem;0xA1;linux\devices\startracker\StrHelper.h;STR_HELPER -0x5ea2;STRHLP_PathNotExists;Specified path does not exist;0xA2;linux\devices\startracker\StrHelper.h;STR_HELPER -0x5ea3;STRHLP_FileCreationFailed;Failed to create download image or read flash file;0xA3;linux\devices\startracker\StrHelper.h;STR_HELPER -0x5ea4;STRHLP_RegionMismatch;Region in flash write/read reply does not match expected region;0xA4;linux\devices\startracker\StrHelper.h;STR_HELPER -0x5ea5;STRHLP_AddressMismatch;Address in flash write/read reply does not match expected address;0xA5;linux\devices\startracker\StrHelper.h;STR_HELPER -0x5ea6;STRHLP_LengthMismatch;Length in flash write/read reply does not match expected length;0xA6;linux\devices\startracker\StrHelper.h;STR_HELPER -0x5ea7;STRHLP_StatusError;Status field in reply signals error;0xA7;linux\devices\startracker\StrHelper.h;STR_HELPER -0x5ea8;STRHLP_InvalidTypeId;Reply has invalid type ID (should be of action reply type);0xA8;linux\devices\startracker\StrHelper.h;STR_HELPER -0x5ba0;IPCI_PapbBusy;;0xA0;linux\obc\PapbVcInterface.h;CCSDS_IP_CORE_BRIDGE -0x61a0;PDEC_AbandonedCltu;;0xA0;linux\obc\PdecHandler.h;PDEC_HANDLER -0x61a1;PDEC_FrameDirty;;0xA1;linux\obc\PdecHandler.h;PDEC_HANDLER -0x61a2;PDEC_FrameIllegalMultipleReasons;;0xA2;linux\obc\PdecHandler.h;PDEC_HANDLER -0x61a3;PDEC_AdDiscardedLockout;;0xA3;linux\obc\PdecHandler.h;PDEC_HANDLER -0x61a4;PDEC_AdDiscardedWait;;0xA4;linux\obc\PdecHandler.h;PDEC_HANDLER -0x61a5;PDEC_AdDiscardedNsVs;;0xA5;linux\obc\PdecHandler.h;PDEC_HANDLER -0x61b0;PDEC_CommandNotImplemented;Received action message with unknown action id;0xB0;linux\obc\PdecHandler.h;PDEC_HANDLER -0x61a6;PDEC_NoReport;;0xA6;linux\obc\PdecHandler.h;PDEC_HANDLER -0x61a7;PDEC_ErrorVersionNumber;;0xA7;linux\obc\PdecHandler.h;PDEC_HANDLER -0x61a8;PDEC_IllegalCombination;;0xA8;linux\obc\PdecHandler.h;PDEC_HANDLER -0x61a9;PDEC_InvalidScId;;0xA9;linux\obc\PdecHandler.h;PDEC_HANDLER -0x61aa;PDEC_InvalidVcIdMsb;;0xAA;linux\obc\PdecHandler.h;PDEC_HANDLER -0x61ab;PDEC_InvalidVcIdLsb;;0xAB;linux\obc\PdecHandler.h;PDEC_HANDLER -0x61ac;PDEC_NsNotZero;;0xAC;linux\obc\PdecHandler.h;PDEC_HANDLER -0x61ae;PDEC_InvalidBcCc;;0xAE;linux\obc\PdecHandler.h;PDEC_HANDLER -0x5ca0;PTME_UnknownVcId;;0xA0;linux\obc\Ptme.h;PTME -0x63a0;RS_RateNotSupported;The commanded rate is not supported by the current FPGA design;0xA0;linux\obc\PtmeConfig.h;RATE_SETTER -0x63a1;RS_BadBitRate;Bad bitrate has been commanded (e.g. 0);0xA1;linux\obc\PtmeConfig.h;RATE_SETTER -0x63a2;RS_ClkInversionFailed;Failed to invert clock and thus change the time the data is updated with respect to the tx clock;0xA2;linux\obc\PtmeConfig.h;RATE_SETTER -0x63a3;RS_TxManipulatorConfigFailed;Failed to change configuration bit of tx clock manipulator;0xA3;linux\obc\PtmeConfig.h;RATE_SETTER +0x5fa0;STRHLP_SdNotMounted;SD card specified in path string not mounted;0xA0;linux\devices\startracker\StrHelper.h;STR_HELPER +0x5fa1;STRHLP_FileNotExists;Specified file does not exist on filesystem;0xA1;linux\devices\startracker\StrHelper.h;STR_HELPER +0x5fa2;STRHLP_PathNotExists;Specified path does not exist;0xA2;linux\devices\startracker\StrHelper.h;STR_HELPER +0x5fa3;STRHLP_FileCreationFailed;Failed to create download image or read flash file;0xA3;linux\devices\startracker\StrHelper.h;STR_HELPER +0x5fa4;STRHLP_RegionMismatch;Region in flash write/read reply does not match expected region;0xA4;linux\devices\startracker\StrHelper.h;STR_HELPER +0x5fa5;STRHLP_AddressMismatch;Address in flash write/read reply does not match expected address;0xA5;linux\devices\startracker\StrHelper.h;STR_HELPER +0x5fa6;STRHLP_LengthMismatch;Length in flash write/read reply does not match expected length;0xA6;linux\devices\startracker\StrHelper.h;STR_HELPER +0x5fa7;STRHLP_StatusError;Status field in reply signals error;0xA7;linux\devices\startracker\StrHelper.h;STR_HELPER +0x5fa8;STRHLP_InvalidTypeId;Reply has invalid type ID (should be of action reply type);0xA8;linux\devices\startracker\StrHelper.h;STR_HELPER +0x5ca0;IPCI_PapbBusy;;0xA0;linux\obc\PapbVcInterface.h;CCSDS_IP_CORE_BRIDGE +0x62a0;PDEC_AbandonedCltu;;0xA0;linux\obc\PdecHandler.h;PDEC_HANDLER +0x62a1;PDEC_FrameDirty;;0xA1;linux\obc\PdecHandler.h;PDEC_HANDLER +0x62a2;PDEC_FrameIllegalMultipleReasons;;0xA2;linux\obc\PdecHandler.h;PDEC_HANDLER +0x62a3;PDEC_AdDiscardedLockout;;0xA3;linux\obc\PdecHandler.h;PDEC_HANDLER +0x62a4;PDEC_AdDiscardedWait;;0xA4;linux\obc\PdecHandler.h;PDEC_HANDLER +0x62a5;PDEC_AdDiscardedNsVs;;0xA5;linux\obc\PdecHandler.h;PDEC_HANDLER +0x62b0;PDEC_CommandNotImplemented;Received action message with unknown action id;0xB0;linux\obc\PdecHandler.h;PDEC_HANDLER +0x62a6;PDEC_NoReport;;0xA6;linux\obc\PdecHandler.h;PDEC_HANDLER +0x62a7;PDEC_ErrorVersionNumber;;0xA7;linux\obc\PdecHandler.h;PDEC_HANDLER +0x62a8;PDEC_IllegalCombination;;0xA8;linux\obc\PdecHandler.h;PDEC_HANDLER +0x62a9;PDEC_InvalidScId;;0xA9;linux\obc\PdecHandler.h;PDEC_HANDLER +0x62aa;PDEC_InvalidVcIdMsb;;0xAA;linux\obc\PdecHandler.h;PDEC_HANDLER +0x62ab;PDEC_InvalidVcIdLsb;;0xAB;linux\obc\PdecHandler.h;PDEC_HANDLER +0x62ac;PDEC_NsNotZero;;0xAC;linux\obc\PdecHandler.h;PDEC_HANDLER +0x62ae;PDEC_InvalidBcCc;;0xAE;linux\obc\PdecHandler.h;PDEC_HANDLER +0x5da0;PTME_UnknownVcId;;0xA0;linux\obc\Ptme.h;PTME +0x64a0;RS_RateNotSupported;The commanded rate is not supported by the current FPGA design;0xA0;linux\obc\PtmeConfig.h;RATE_SETTER +0x64a1;RS_BadBitRate;Bad bitrate has been commanded (e.g. 0);0xA1;linux\obc\PtmeConfig.h;RATE_SETTER +0x64a2;RS_ClkInversionFailed;Failed to invert clock and thus change the time the data is updated with respect to the tx clock;0xA2;linux\obc\PtmeConfig.h;RATE_SETTER +0x64a3;RS_TxManipulatorConfigFailed;Failed to change configuration bit of tx clock manipulator;0xA3;linux\obc\PtmeConfig.h;RATE_SETTER From 5de92a366a7e7b63c80b536ec345faa8c3a58e2f Mon Sep 17 00:00:00 2001 From: Jakob Meier Date: Wed, 27 Apr 2022 16:08:51 +0200 Subject: [PATCH 04/11] reformated --- pus_tc/devs/ploc_supervisor.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/pus_tc/devs/ploc_supervisor.py b/pus_tc/devs/ploc_supervisor.py index 9038928..8dae413 100644 --- a/pus_tc/devs/ploc_supervisor.py +++ b/pus_tc/devs/ploc_supervisor.py @@ -152,10 +152,10 @@ def pack_ploc_supv_commands( tc_queue.appendleft( (QueueCommands.PRINT, "PLOC Supervisor: Select MPSoC boot image") ) - mem = int(input("MEM (NVM0 - 0 or NVM1 - 1):")) - bp0 = int(input("BP0 (0 or 1):")) - bp1 = int(input("BP1 (0 or 1):")) - bp2 = int(input("BP2 (0 or 1):")) + mem = int(input("MEM (NVM0 - 0 or NVM1 - 1): ")) + bp0 = int(input("BP0 (0 or 1): ")) + bp1 = int(input("BP1 (0 or 1): ")) + bp2 = int(input("BP2 (0 or 1): ")) command = pack_sel_boot_image_cmd(object_id, mem, bp0, bp1, bp2) command = PusTelecommand(service=8, subservice=128, ssc=24, app_data=command) tc_queue.appendleft(command.pack_command_tuple()) From 16ebba3f5b81e8e4c96f43a0b417656df534d5ce Mon Sep 17 00:00:00 2001 From: Jakob Meier Date: Thu, 28 Apr 2022 11:29:26 +0200 Subject: [PATCH 05/11] reset pl command --- pus_tc/cmd_definitions.py | 1 + pus_tc/devs/ploc_supervisor.py | 6 ++++++ 2 files changed, 7 insertions(+) diff --git a/pus_tc/cmd_definitions.py b/pus_tc/cmd_definitions.py index 37e4a8e..51c6f7c 100644 --- a/pus_tc/cmd_definitions.py +++ b/pus_tc/cmd_definitions.py @@ -640,6 +640,7 @@ def add_ploc_supv_cmds(cmd_dict: ServiceOpCodeDictT): "53": ("PLOC Supervisor: Logging set topic", {OpCodeDictKeys.TIMEOUT: 2.0}), "54": ("PLOC Supervisor: Logging request counters", {OpCodeDictKeys.TIMEOUT: 2.0}), "55": ("PLOC Supervisor: Request ADC Report", {OpCodeDictKeys.TIMEOUT: 2.0}), + "56": ("PLOC Supervisor: Reset PL", {OpCodeDictKeys.TIMEOUT: 2.0}), } service_ploc_supv_tuple = ("PLOC Supervisor", op_code_dict_srv_ploc_supv) diff --git a/pus_tc/devs/ploc_supervisor.py b/pus_tc/devs/ploc_supervisor.py index 8dae413..1382528 100644 --- a/pus_tc/devs/ploc_supervisor.py +++ b/pus_tc/devs/ploc_supervisor.py @@ -97,6 +97,7 @@ class SupvActionIds: LOGGING_CLEAR_COUNTERS = 55 LOGGING_SET_TOPIC = 56 REQUEST_ADC_REPORT = 57 + RESET_PL = 58 class SupvHkIds: @@ -466,6 +467,11 @@ def pack_ploc_supv_commands( command = object_id + struct.pack('!I', SupvActionIds.REQUEST_ADC_REPORT) command = PusTelecommand(service=8, subservice=128, ssc=70, app_data=command) tc_queue.appendleft(command.pack_command_tuple()) + elif op_code == "56": + tc_queue.appendleft((QueueCommands.PRINT, "PLOC Supervisor: Reset PL")) + command = object_id + struct.pack('!I', SupvActionIds.RESET_PL) + command = PusTelecommand(service=8, subservice=128, ssc=71, app_data=command) + tc_queue.appendleft(command.pack_command_tuple()) return tc_queue From d41a59834ceb0eefcf65cd60faed1dd90e965e8e Mon Sep 17 00:00:00 2001 From: Jakob Meier Date: Sat, 30 Apr 2022 09:25:53 +0200 Subject: [PATCH 06/11] tmtccmd update --- tmtccmd | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tmtccmd b/tmtccmd index 48b6b83..8041f3a 160000 --- a/tmtccmd +++ b/tmtccmd @@ -1 +1 @@ -Subproject commit 48b6b8396eb3ea5ec4527ccb96f5909a29cd95f6 +Subproject commit 8041f3a000dfee89f905911cf301cc314603ba3a From f263c2b9fe0d3134103c7450bab850499d714a72 Mon Sep 17 00:00:00 2001 From: Jakob Meier Date: Sat, 30 Apr 2022 09:26:19 +0200 Subject: [PATCH 07/11] fix in service 8 reply handling --- pus_tc/devs/ploc_supervisor.py | 4 +--- pus_tm/action_reply_handler.py | 10 +++++----- 2 files changed, 6 insertions(+), 8 deletions(-) diff --git a/pus_tc/devs/ploc_supervisor.py b/pus_tc/devs/ploc_supervisor.py index 1382528..c0f870e 100644 --- a/pus_tc/devs/ploc_supervisor.py +++ b/pus_tc/devs/ploc_supervisor.py @@ -357,7 +357,7 @@ def pack_ploc_supv_commands( tc_queue.appendleft( (QueueCommands.PRINT, "PLOC Supervisor: Factory reset clear mirror entries") ) - command = command = object_id + struct.pack( + command = object_id + struct.pack( "!I", SupvActionIds.FACTORY_RESET_CLEAR_MIRROR ) command = PusTelecommand(service=8, subservice=128, ssc=54, app_data=command) @@ -486,7 +486,6 @@ def pack_sel_boot_image_cmd( @param bp1 Partition pin 1 @param bp2 Partition pin 2 """ - command = bytearray() command = object_id + struct.pack("!I", SupvActionIds.SEL_MPSOC_BOOT_IMAGE) command = command + struct.pack("!B", mem) command = command + struct.pack("!B", bp0) @@ -505,7 +504,6 @@ def pack_update_available_cmd(object_id: bytearray) -> bytearray: image_size = 222 image_crc = 0x0 number_of_packets = 150 - command = bytearray() command = object_id + struct.pack("!I", SupvActionIds.UPDATE_AVAILABLE) command = command + struct.pack("!B", image_select) command = command + struct.pack("!B", image_partition) diff --git a/pus_tm/action_reply_handler.py b/pus_tm/action_reply_handler.py index cee50e1..08fae82 100644 --- a/pus_tm/action_reply_handler.py +++ b/pus_tm/action_reply_handler.py @@ -20,7 +20,7 @@ def handle_action_reply( """ tm_packet = Service8FsfwTm.unpack(raw_telemetry=raw_tm) printer.handle_long_tm_print(packet_if=tm_packet, info_if=tm_packet) - object_id = obj_id_dict.get(tm_packet.source_object_id) + object_id = obj_id_dict.get(tm_packet.source_object_id_as_bytes) custom_data = tm_packet.custom_data action_id = tm_packet.action_id generic_print_str = printer.generic_action_packet_tm_print( @@ -28,13 +28,13 @@ def handle_action_reply( ) print(generic_print_str) printer.file_logger.info(generic_print_str) - if object_id == IMTQ_HANDLER_ID: + if object_id.as_bytes == IMTQ_HANDLER_ID: return handle_imtq_replies(action_id, printer, custom_data) - elif object_id == PLOC_MPSOC_ID: + elif object_id.as_bytes == PLOC_MPSOC_ID: return handle_ploc_replies(action_id, printer, custom_data) - elif object_id == PLOC_SUPV_ID: + elif object_id.as_bytes == PLOC_SUPV_ID: return handle_supervisor_replies(action_id, printer, custom_data) - elif object_id == STAR_TRACKER_ID: + elif object_id.as_bytes == STAR_TRACKER_ID: return handle_startracker_replies(action_id, printer, custom_data) From d7c0f99a210028e4e98619a77e1cb9d549d77bd3 Mon Sep 17 00:00:00 2001 From: Jakob Meier Date: Sat, 30 Apr 2022 11:10:22 +0200 Subject: [PATCH 08/11] removed obsolete commands --- pus_tc/cmd_definitions.py | 5 ----- pus_tc/devs/ploc_supervisor.py | 14 -------------- 2 files changed, 19 deletions(-) diff --git a/pus_tc/cmd_definitions.py b/pus_tc/cmd_definitions.py index 51c6f7c..b4b4598 100644 --- a/pus_tc/cmd_definitions.py +++ b/pus_tc/cmd_definitions.py @@ -602,10 +602,6 @@ def add_ploc_supv_cmds(cmd_dict: ServiceOpCodeDictT): {OpCodeDictKeys.TIMEOUT: 2.0}, ), "27": ("PLOC Supervisor: Copy ADC data to MRAM", {OpCodeDictKeys.TIMEOUT: 2.0}), - "28": ( - "PLOC Supervisor: Enable/Disable NVM0/1/3", - {OpCodeDictKeys.TIMEOUT: 2.0}, - ), "30": ("PLOC Supervisor: Run auto EM tests", {OpCodeDictKeys.TIMEOUT: 2.0}), "31": ("PLOC Supervisor: MRAM Wipe", {OpCodeDictKeys.TIMEOUT: 2.0}), "33": ("PLOC Supervisor: Print CPU stats", {OpCodeDictKeys.TIMEOUT: 2.0}), @@ -625,7 +621,6 @@ def add_ploc_supv_cmds(cmd_dict: ServiceOpCodeDictT): "PLOC Supervisor: Factory reset clear circular entries", {OpCodeDictKeys.TIMEOUT: 2.0}, ), - "41": ("PLOC Supervisor: CAN loopback test", {OpCodeDictKeys.TIMEOUT: 2.0}), "42": ("PLOC Supervisor: Perform update", {OpCodeDictKeys.TIMEOUT: 2.0}), "43": ("PLOC Supervisor: Terminate supervisor process", {OpCodeDictKeys.TIMEOUT: 2.0}), "44": ("PLOC Supervisor: Start MPSoC quiet", {OpCodeDictKeys.TIMEOUT: 2.0}), diff --git a/pus_tc/devs/ploc_supervisor.py b/pus_tc/devs/ploc_supervisor.py index c0f870e..9b785e7 100644 --- a/pus_tc/devs/ploc_supervisor.py +++ b/pus_tc/devs/ploc_supervisor.py @@ -296,13 +296,6 @@ def pack_ploc_supv_commands( command = object_id + struct.pack("!I", SupvActionIds.COPY_ADC_DATA_TO_MRAM) command = PusTelecommand(service=8, subservice=128, ssc=44, app_data=command) tc_queue.appendleft(command.pack_command_tuple()) - elif op_code == "28": - tc_queue.appendleft( - (QueueCommands.PRINT, "PLOC Supervisor: Enalbe/Disable NVMs") - ) - command = pack_enable_nvms_cmd(object_id) - command = PusTelecommand(service=8, subservice=128, ssc=45, app_data=command) - tc_queue.appendleft(command.pack_command_tuple()) elif op_code == "30": tc_queue.appendleft((QueueCommands.PRINT, "PLOC Supervisor: Run auto EM tests")) command = pack_auto_em_tests_cmd(object_id) @@ -374,13 +367,6 @@ def pack_ploc_supv_commands( ) command = PusTelecommand(service=8, subservice=128, ssc=55, app_data=command) tc_queue.appendleft(command.pack_command_tuple()) - elif op_code == "41": - tc_queue.appendleft((QueueCommands.PRINT, "PLOC Supervisor: CAN loopback test")) - command = command = object_id + struct.pack( - "!I", SupvActionIds.CAN_LOOPBACK_TEST - ) - command = PusTelecommand(service=8, subservice=128, ssc=56, app_data=command) - tc_queue.appendleft(command.pack_command_tuple()) elif op_code == "42": tc_queue.appendleft((QueueCommands.PRINT, "PLOC Supervisor: Perform update")) command = pack_update_command(object_id) From 58b9a3cdaf83e8fd204353188e79064fa99b6650 Mon Sep 17 00:00:00 2001 From: Jakob Meier Date: Sat, 30 Apr 2022 15:31:40 +0200 Subject: [PATCH 09/11] tmtccmd update --- tmtccmd | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tmtccmd b/tmtccmd index 8041f3a..6431d3b 160000 --- a/tmtccmd +++ b/tmtccmd @@ -1 +1 @@ -Subproject commit 8041f3a000dfee89f905911cf301cc314603ba3a +Subproject commit 6431d3bc3547d008b95dd27fc146b2e2681a8257 From d8ba63c496a9479b4bf2251cd43297ea8ce669bd Mon Sep 17 00:00:00 2001 From: Jakob Meier Date: Sat, 30 Apr 2022 15:32:34 +0200 Subject: [PATCH 10/11] gitignore update --- .gitignore | 1 + 1 file changed, 1 insertion(+) diff --git a/.gitignore b/.gitignore index 0e1a63e..b0cfa06 100644 --- a/.gitignore +++ b/.gitignore @@ -5,3 +5,4 @@ __pycache__ log /gps_log.txt /config/*.json +tmtc_config.json \ No newline at end of file From bd3d5396da9a9be90ef824b8fd068e63d9d12ee4 Mon Sep 17 00:00:00 2001 From: Jakob Meier Date: Sat, 30 Apr 2022 15:33:24 +0200 Subject: [PATCH 11/11] added tmtc_conf.json --- .gitignore | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.gitignore b/.gitignore index b0cfa06..58ff4d8 100644 --- a/.gitignore +++ b/.gitignore @@ -5,4 +5,4 @@ __pycache__ log /gps_log.txt /config/*.json -tmtc_config.json \ No newline at end of file +tmtc_conf.json \ No newline at end of file