From 82af8e00dfe26882c8e1e5fa8bf3a15a952efc36 Mon Sep 17 00:00:00 2001 From: Robin Mueller Date: Thu, 27 Oct 2022 14:02:34 +0200 Subject: [PATCH 1/5] bufixes for PDEC --- bsp_q7s/boardconfig/busConf.h | 2 +- bsp_q7s/core/ObjectFactory.cpp | 3 ++- bsp_q7s/core/ObjectFactory.h | 2 +- fsfw | 2 +- linux/obc/AxiPtmeConfig.cpp | 2 +- linux/obc/PapbVcInterface.cpp | 2 +- 6 files changed, 7 insertions(+), 6 deletions(-) diff --git a/bsp_q7s/boardconfig/busConf.h b/bsp_q7s/boardconfig/busConf.h index 0bd781df..21b9db2d 100644 --- a/bsp_q7s/boardconfig/busConf.h +++ b/bsp_q7s/boardconfig/busConf.h @@ -20,7 +20,7 @@ static constexpr char UART_SCEX_DEV[] = "/dev/scex"; static constexpr char UIO_PDEC_REGISTERS[] = "/dev/uio_pdec_regs"; static constexpr char UIO_PTME[] = "/dev/uio_ptme"; static constexpr char UIO_PDEC_CONFIG_MEMORY[] = "/dev/uio_pdec_cfg_mem"; -static constexpr char UIO_PDEC_RAM[] = "/dev/pdec_ram"; +static constexpr char UIO_PDEC_RAM[] = "/dev/uio_pdec_ram"; static constexpr int MAP_ID_PTME_CONFIG = 3; namespace uiomapids { diff --git a/bsp_q7s/core/ObjectFactory.cpp b/bsp_q7s/core/ObjectFactory.cpp index 82d066c8..fdc263de 100644 --- a/bsp_q7s/core/ObjectFactory.cpp +++ b/bsp_q7s/core/ObjectFactory.cpp @@ -690,7 +690,7 @@ void ObjectFactory::createReactionWheelComponents(LinuxLibgpioIF* gpioComIF, #endif /* OBSW_ADD_RW == 1 */ } -void ObjectFactory::createCcsdsComponents(LinuxLibgpioIF* gpioComIF) { +ReturnValue_t ObjectFactory::createCcsdsComponents(LinuxLibgpioIF* gpioComIF) { using namespace gpio; // GPIO definitions of signals connected to the virtual channel interfaces of the PTME IP Core GpioCookie* gpioCookiePtmeIp = new GpioCookie; @@ -790,6 +790,7 @@ void ObjectFactory::createCcsdsComponents(LinuxLibgpioIF* gpioComIF) { Direction::OUT, Levels::LOW); gpioRS485Chip->addGpio(gpioIds::RS485_EN_RX_DATA, gpio); gpioChecker(gpioComIF->addGpios(gpioRS485Chip), "RS485 Transceiver"); + return returnvalue::OK; } void ObjectFactory::createPlPcduComponents(LinuxLibgpioIF* gpioComIF, SpiComIF* spiComIF, diff --git a/bsp_q7s/core/ObjectFactory.h b/bsp_q7s/core/ObjectFactory.h index 76660f30..2947d786 100644 --- a/bsp_q7s/core/ObjectFactory.h +++ b/bsp_q7s/core/ObjectFactory.h @@ -37,7 +37,7 @@ void createSolarArrayDeploymentComponents(PowerSwitchIF& pwrSwitcher, GpioIF& gp void createSyrlinksComponents(PowerSwitchIF* pwrSwitcher); void createPayloadComponents(LinuxLibgpioIF* gpioComIF); void createReactionWheelComponents(LinuxLibgpioIF* gpioComIF, PowerSwitchIF* pwrSwitcher); -void createCcsdsComponents(LinuxLibgpioIF* gpioComIF); +ReturnValue_t createCcsdsComponents(LinuxLibgpioIF* gpioComIF); void createMiscComponents(); void createTestComponents(LinuxLibgpioIF* gpioComIF); diff --git a/fsfw b/fsfw index 1b7e94d7..226dc4d8 160000 --- a/fsfw +++ b/fsfw @@ -1 +1 @@ -Subproject commit 1b7e94d718ba8f526dd53324d33d0e577cbfc81b +Subproject commit 226dc4d8b742fea832861bf70d37dc48beb15dc9 diff --git a/linux/obc/AxiPtmeConfig.cpp b/linux/obc/AxiPtmeConfig.cpp index 7c1f90c6..ead3d691 100644 --- a/linux/obc/AxiPtmeConfig.cpp +++ b/linux/obc/AxiPtmeConfig.cpp @@ -4,7 +4,7 @@ #include "fsfw_hal/linux/uio/UioMapper.h" AxiPtmeConfig::AxiPtmeConfig(object_id_t objectId, std::string axiUio, int mapNum) - : SystemObject(objectId), axiUio(axiUio), mapNum(mapNum) { + : SystemObject(objectId), axiUio(std::move(axiUio)), mapNum(mapNum) { mutex = MutexFactory::instance()->createMutex(); if (mutex == nullptr) { sif::warning << "Failed to create mutex" << std::endl; diff --git a/linux/obc/PapbVcInterface.cpp b/linux/obc/PapbVcInterface.cpp index fc23fed8..1fbbe2ba 100644 --- a/linux/obc/PapbVcInterface.cpp +++ b/linux/obc/PapbVcInterface.cpp @@ -8,7 +8,7 @@ PapbVcInterface::PapbVcInterface(LinuxLibgpioIF* gpioComIF, gpioId_t papbBusyId, : gpioComIF(gpioComIF), papbBusyId(papbBusyId), papbEmptyId(papbEmptyId), - uioFile(uioFile), + uioFile(std::move(uioFile)), mapNum(mapNum) {} PapbVcInterface::~PapbVcInterface() {} From 833f7c6885a07df29a11e0449f594b837ce8556b Mon Sep 17 00:00:00 2001 From: Robin Mueller Date: Thu, 27 Oct 2022 14:04:55 +0200 Subject: [PATCH 2/5] syrlink sim flag now EM/FM dependent --- CMakeLists.txt | 3 +++ bsp_q7s/OBSWConfig.h.in | 2 +- 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index 38a09a9a..a73ec9d6 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -149,6 +149,9 @@ set(OBSW_ADD_RW set(OBSW_ADD_SCEX_DEVICE ${INIT_VAL} CACHE STRING "Add Solar Cell Experiment module") +set(OBSW_SYRLINKS_SIMULATED + ${INIT_VAL} + CACHE STRING "Syrlinks is simulated") # ############################################################################## # Pre-Sources preparation diff --git a/bsp_q7s/OBSWConfig.h.in b/bsp_q7s/OBSWConfig.h.in index c0c713a9..76dce7b5 100644 --- a/bsp_q7s/OBSWConfig.h.in +++ b/bsp_q7s/OBSWConfig.h.in @@ -65,7 +65,7 @@ #define OBSW_MPSOC_JTAG_BOOT 0 #define OBSW_STAR_TRACKER_GROUND_CONFIG 1 -#define OBSW_SYRLINKS_SIMULATED 1 +#define OBSW_SYRLINKS_SIMULATED @OBSW_SYRLINKS_SIMULATED@ #define OBSW_ADD_TEST_CODE 0 #define OBSW_ADD_TEST_TASK 0 #define OBSW_ADD_TEST_PST 0 From 23da59fec55d39e07952dbfb7533b7ac5f01e805 Mon Sep 17 00:00:00 2001 From: Robin Mueller Date: Thu, 27 Oct 2022 14:09:55 +0200 Subject: [PATCH 3/5] bugfixes and improvements --- CMakeLists.txt | 2 +- bsp_q7s/OBSWConfig.h.in | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index a73ec9d6..ddf101a4 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -150,7 +150,7 @@ set(OBSW_ADD_SCEX_DEVICE ${INIT_VAL} CACHE STRING "Add Solar Cell Experiment module") set(OBSW_SYRLINKS_SIMULATED - ${INIT_VAL} + ${OBSW_Q7S_EM} CACHE STRING "Syrlinks is simulated") # ############################################################################## diff --git a/bsp_q7s/OBSWConfig.h.in b/bsp_q7s/OBSWConfig.h.in index 76dce7b5..840e2575 100644 --- a/bsp_q7s/OBSWConfig.h.in +++ b/bsp_q7s/OBSWConfig.h.in @@ -60,7 +60,7 @@ /*******************************************************************/ // Can be used to switch device to NORMAL mode immediately -#define OBSW_SWITCH_TO_NORMAL_MODE_AFTER_STARTUP 1 +#define OBSW_SWITCH_TO_NORMAL_MODE_AFTER_STARTUP 0 #define OBSW_PRINT_MISSED_DEADLINES 1 #define OBSW_MPSOC_JTAG_BOOT 0 From 09642eb6bf751f6c6894a30edac4a122fc68fc4c Mon Sep 17 00:00:00 2001 From: Robin Mueller Date: Thu, 27 Oct 2022 14:11:09 +0200 Subject: [PATCH 4/5] fixes for bash script --- scripts/install-obsw-yocto.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/scripts/install-obsw-yocto.sh b/scripts/install-obsw-yocto.sh index a7e3f20a..08fb78d3 100755 --- a/scripts/install-obsw-yocto.sh +++ b/scripts/install-obsw-yocto.sh @@ -2,7 +2,7 @@ # This is a helper script to install the compiles EIVE OBSW files # into the yocto repository to re-generate the mission root filesystem build_dir=cmake-build-release-q7s -if [ ! -z ${1} && "${1}" == "em" ] || [[ ${EIVE_Q7S_EM} == "1" ]]; then +if [[ ! -z ${1} && "${1}" == "em" ]] || [[ ${EIVE_Q7S_EM} == "1" ]]; then echo "-I- Installing EM binaries" em_install="1" build_dir=cmake-build-release-q7s-em @@ -17,7 +17,7 @@ q7s_package_path="q7s-package/${q7s_yocto_dir}" obsw_version_filename="obsw_version.txt" yocto_obsw_path="yocto/meta-eive/recipes-core/eive-obsw/files" variant_specific_path="" -if [ ${em_install} == "1" ]; then +if [[ ${em_install} == "1" ]]; then variant_specific_path="${yocto_obsw_path}/em" else variant_specific_path="${yocto_obsw_path}/fm" From 745fad2a19354ff5e6c0eb14fca436d4a136f816 Mon Sep 17 00:00:00 2001 From: Robin Mueller Date: Thu, 27 Oct 2022 16:37:16 +0200 Subject: [PATCH 5/5] use baudrate 115200 for SCEX now --- common/config/devConf.h | 2 +- tmtc | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/common/config/devConf.h b/common/config/devConf.h index 88e78e1e..e7f7de5f 100644 --- a/common/config/devConf.h +++ b/common/config/devConf.h @@ -55,7 +55,7 @@ namespace uart { static constexpr size_t HYPERION_GPS_REPLY_MAX_BUFFER = 1024; static constexpr UartBaudRate SYRLINKS_BAUD = UartBaudRate::RATE_38400; -static constexpr UartBaudRate SCEX_BAUD = UartBaudRate::RATE_38400; +static constexpr UartBaudRate SCEX_BAUD = UartBaudRate::RATE_115200; static constexpr UartBaudRate GNSS_BAUD = UartBaudRate::RATE_9600; static constexpr UartBaudRate PLOC_MPSOC_BAUD = UartBaudRate::RATE_115200; static constexpr UartBaudRate PLOC_SUPV_BAUD = UartBaudRate::RATE_115200; diff --git a/tmtc b/tmtc index 4420bf3d..044c600b 160000 --- a/tmtc +++ b/tmtc @@ -1 +1 @@ -Subproject commit 4420bf3df94f26b3270dd91ac0ef80cb3f8699df +Subproject commit 044c600b1ce13d58781a8d06125619c8cc0080f9