Merge remote-tracking branch 'origin/develop' into mueller/pus-15-tm-storage
Some checks failed
EIVE/eive-obsw/pipeline/pr-develop There was a failure building this commit

This commit is contained in:
Robin Müller 2022-11-24 14:48:59 +01:00
commit e3730a9b94
8 changed files with 38 additions and 12 deletions

View File

@ -141,7 +141,7 @@ set(OBSW_ADD_TMP_DEVICES
${INIT_VAL}
CACHE STRING "Add TMP devices")
set(OBSW_ADD_GOMSPACE_PCDU
${INIT_VAL}
1
CACHE STRING "Add GomSpace PCDU modules")
set(OBSW_ADD_RW
${INIT_VAL}

View File

@ -1,5 +1,6 @@
#include "ObjectFactory.h"
#include <fsfw/power/DummyPowerSwitcher.h>
#include <fsfw/tmtcservices/CommandingServiceBase.h>
#include <fsfw/tmtcservices/PusServiceBase.h>
#include <mission/controller/ThermalController.h>
@ -79,6 +80,7 @@ void ObjectFactory::produce(void* args) {
ObjectFactory::produceGenericObjects(nullptr, &pusFunnel, &cfdpFunnel);
DummyGpioIF* dummyGpioIF = new DummyGpioIF();
auto* dummySwitcher = new DummyPowerSwitcher(objects::PCDU_HANDLER, 18, 0);
static_cast<void>(dummyGpioIF);
#ifdef PLATFORM_UNIX
new SerialComIF(objects::UART_COM_IF);
@ -106,7 +108,7 @@ void ObjectFactory::produce(void* args) {
#endif
dummy::DummyCfg cfg;
dummy::createDummies(cfg);
dummy::createDummies(cfg, *dummySwitcher);
new ThermalController(objects::THERMAL_CONTROLLER);
new TestTask(objects::TEST_TASK);
}

View File

@ -1,6 +1,7 @@
#include <bsp_q7s/callbacks/q7sGpioCallbacks.h>
#include <fsfw/health/HealthTableIF.h>
#include <fsfw/power/DummyPowerSwitcher.h>
#include <mission/devices/devicedefinitions/GomspaceDefinitions.h>
#include "OBSWConfig.h"
#include "bsp_q7s/core/CoreController.h"
@ -38,13 +39,21 @@ void ObjectFactory::produce(void* args) {
#if OBSW_ADD_SYRLINKS == 1
dummyCfg.addSyrlinksDummies = false;
#endif
dummy::createDummies(dummyCfg);
#if OBSW_ADD_GOMSPACE_PCDU == 1
dummyCfg.addPowerDummies = false;
#endif
PowerSwitchIF* pwrSwitcher = nullptr;
#if OBSW_ADD_GOMSPACE_PCDU == 0
pwrSwitcher = new DummyPowerSwitcher(objects::PCDU_HANDLER, 18, 0);
#else
createPcduComponents(gpioComIF, &pwrSwitcher);
#endif
dummy::createDummies(dummyCfg, *pwrSwitcher);
new CoreController(objects::CORE_CONTROLLER);
PowerSwitchIF* pwrSwitcher = new DummyPowerSwitcher(objects::PCDU_HANDLER, 18, 0);
static_cast<void>(pwrSwitcher);
// Regular FM code, does not work for EM if the hardware is not connected
// createPcduComponents(gpioComIF, &pwrSwitcher);
// createPlPcduComponents(gpioComIF, spiMainComIF, pwrSwitcher);
@ -95,8 +104,8 @@ void ObjectFactory::produce(void* args) {
createTestComponents(gpioComIF);
#endif /* OBSW_ADD_TEST_CODE == 1 */
#if OBSW_ADD_SCEX_DEVICE == 1
createScexComponents(q7s::UART_SCEX_DEV, pwrSwitcher, *SdCardManager::instance(), true,
std::nullopt);
createScexComponents(q7s::UART_SCEX_DEV, pwrSwitcher, *SdCardManager::instance(), false,
pcdu::Switches::PDU1_CH5_SOLAR_CELL_EXP_5V);
#endif
createAcsController(true);
}

View File

@ -57,7 +57,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;

View File

@ -19,10 +19,11 @@
#include <dummies/SusDummy.h>
#include <dummies/SyrlinksDummy.h>
#include <dummies/TemperatureSensorsDummy.h>
#include <mission/system/objects/CamSwitcher.h>
using namespace dummy;
void dummy::createDummies(DummyCfg cfg) {
void dummy::createDummies(DummyCfg cfg, PowerSwitchIF& pwrSwitch) {
new ComIFDummy(objects::DUMMY_COM_IF);
ComCookieDummy* comCookieDummy = new ComCookieDummy();
new BpxDummy(objects::BPX_BATT_HANDLER, objects::DUMMY_COM_IF, comCookieDummy);
@ -67,5 +68,6 @@ void dummy::createDummies(DummyCfg cfg) {
if (cfg.addTempSensorDummies) {
new TemperatureSensorsDummy();
}
new CamSwitcher(objects::CAM_SWITCHER, pwrSwitch, power::NO_SWITCH);
new PlPcduDummy(objects::PLPCDU_HANDLER, objects::DUMMY_COM_IF, comCookieDummy);
}

View File

@ -1,5 +1,7 @@
#pragma once
#include <fsfw/power/PowerSwitchIF.h>
namespace dummy {
struct DummyCfg {
@ -12,6 +14,6 @@ struct DummyCfg {
bool addRtdComIFDummy = true;
};
void createDummies(DummyCfg cfg);
void createDummies(DummyCfg cfg, PowerSwitchIF& pwrSwitch);
} // namespace dummy

View File

@ -37,6 +37,17 @@ void scheduling::schedulingScex(TaskFactory& factory, PeriodicTaskIF*& scexDevHa
printAddObjectError("SCEX_DEV", objects::SCEX);
}
result = scexDevHandler->addComponent(objects::SCEX, DeviceHandlerIF::GET_READ);
if (result != returnvalue::OK) {
printAddObjectError("SCEX_DEV", objects::SCEX);
}
result = scexDevHandler->addComponent(objects::SCEX, DeviceHandlerIF::SEND_READ);
if (result != returnvalue::OK) {
printAddObjectError("SCEX_DEV", objects::SCEX);
}
result = scexDevHandler->addComponent(objects::SCEX, DeviceHandlerIF::GET_READ);
if (result != returnvalue::OK) {
printAddObjectError("SCEX_DEV", objects::SCEX);
}
result = returnvalue::OK;
scexReaderTask = factory.createPeriodicTask(

2
tmtc

@ -1 +1 @@
Subproject commit 9cd4846d396373325fc5e03a367fed236dfc16d7
Subproject commit 70a1d49246b5bd5297c22d336e9dd8f58f019f90