This commit is contained in:
parent
f932c4c2c5
commit
ad168f18b3
@ -10,10 +10,8 @@
|
|||||||
|
|
||||||
#include "OBSWConfig.h"
|
#include "OBSWConfig.h"
|
||||||
#include "devConf.h"
|
#include "devConf.h"
|
||||||
#include "eive/definitions.h"
|
|
||||||
#include "fsfw/platform.h"
|
#include "fsfw/platform.h"
|
||||||
#include "fsfw_tests/integration/task/TestTask.h"
|
#include "fsfw_tests/integration/task/TestTask.h"
|
||||||
#include "tmtc/pusIds.h"
|
|
||||||
|
|
||||||
#if OBSW_USE_TMTC_TCP_BRIDGE == 0
|
#if OBSW_USE_TMTC_TCP_BRIDGE == 0
|
||||||
#include "fsfw/osal/common/UdpTcPollingTask.h"
|
#include "fsfw/osal/common/UdpTcPollingTask.h"
|
||||||
@ -79,7 +77,7 @@ void ObjectFactory::produce(void* args) {
|
|||||||
CfdpTmFunnel* cfdpFunnel;
|
CfdpTmFunnel* cfdpFunnel;
|
||||||
ObjectFactory::produceGenericObjects(nullptr, &pusFunnel, &cfdpFunnel);
|
ObjectFactory::produceGenericObjects(nullptr, &pusFunnel, &cfdpFunnel);
|
||||||
|
|
||||||
DummyGpioIF* dummyGpioIF = new DummyGpioIF();
|
auto* dummyGpioIF = new DummyGpioIF();
|
||||||
auto* dummySwitcher = new DummyPowerSwitcher(objects::PCDU_HANDLER, 18, 0);
|
auto* dummySwitcher = new DummyPowerSwitcher(objects::PCDU_HANDLER, 18, 0);
|
||||||
static_cast<void>(dummyGpioIF);
|
static_cast<void>(dummyGpioIF);
|
||||||
#ifdef PLATFORM_UNIX
|
#ifdef PLATFORM_UNIX
|
||||||
@ -109,6 +107,14 @@ void ObjectFactory::produce(void* args) {
|
|||||||
|
|
||||||
dummy::DummyCfg cfg;
|
dummy::DummyCfg cfg;
|
||||||
dummy::createDummies(cfg, *dummySwitcher);
|
dummy::createDummies(cfg, *dummySwitcher);
|
||||||
new ThermalController(objects::THERMAL_CONTROLLER);
|
|
||||||
|
HeaterHandler* heaterHandler = nullptr;
|
||||||
|
//new ThermalController(objects::THERMAL_CONTROLLER);
|
||||||
|
ObjectFactory::createGenericHeaterComponents(*dummyGpioIF, *dummySwitcher, heaterHandler);
|
||||||
|
if(heaterHandler == nullptr){
|
||||||
|
sif::error << "HeaterHandler could not be created" << std::endl;
|
||||||
|
}else{
|
||||||
|
ObjectFactory::createThermalController(*heaterHandler);
|
||||||
|
}
|
||||||
new TestTask(objects::TEST_TASK);
|
new TestTask(objects::TEST_TASK);
|
||||||
}
|
}
|
||||||
|
@ -19,4 +19,5 @@ target_sources(
|
|||||||
PlPcduDummy.cpp
|
PlPcduDummy.cpp
|
||||||
CoreControllerDummy.cpp
|
CoreControllerDummy.cpp
|
||||||
helpers.cpp
|
helpers.cpp
|
||||||
MgmRm3100Dummy.cpp)
|
MgmRm3100Dummy.cpp
|
||||||
|
DummyHeaterHandler.cpp)
|
||||||
|
6
dummies/DummyHeaterHandler.cpp
Normal file
6
dummies/DummyHeaterHandler.cpp
Normal file
@ -0,0 +1,6 @@
|
|||||||
|
//
|
||||||
|
// Created by irini on 24.11.22.
|
||||||
|
//
|
||||||
|
#include "DummyHeaterHandler.h"
|
||||||
|
|
||||||
|
|
13
dummies/DummyHeaterHandler.h
Normal file
13
dummies/DummyHeaterHandler.h
Normal file
@ -0,0 +1,13 @@
|
|||||||
|
//
|
||||||
|
// Created by irini on 24.11.22.
|
||||||
|
//
|
||||||
|
|
||||||
|
#ifndef EIVE_OBSW_DUMMYHEATERHANDLER_H
|
||||||
|
#define EIVE_OBSW_DUMMYHEATERHANDLER_H
|
||||||
|
|
||||||
|
#include "mission/devices/HeaterHandler.h"
|
||||||
|
class DummyHeaterHandler: public HeaterHandler{
|
||||||
|
public:
|
||||||
|
//DummyHeaterHandler();
|
||||||
|
};
|
||||||
|
#endif // EIVE_OBSW_DUMMYHEATERHANDLER_H
|
@ -6,7 +6,7 @@
|
|||||||
#include <cstdlib>
|
#include <cstdlib>
|
||||||
|
|
||||||
TemperatureSensorInserter::TemperatureSensorInserter(object_id_t objectId)
|
TemperatureSensorInserter::TemperatureSensorInserter(object_id_t objectId)
|
||||||
: SystemObject(objects::THERMAL_CONTROLLER),
|
: SystemObject(objects::THERMAL_TEMP_INSERTER),
|
||||||
max31865PlocHeatspreaderSet(objects::RTD_0_IC3_PLOC_HEATSPREADER, MAX31865::MAX31865_SET_ID),
|
max31865PlocHeatspreaderSet(objects::RTD_0_IC3_PLOC_HEATSPREADER, MAX31865::MAX31865_SET_ID),
|
||||||
max31865PlocMissionboardSet(objects::RTD_1_IC4_PLOC_MISSIONBOARD, MAX31865::MAX31865_SET_ID) {
|
max31865PlocMissionboardSet(objects::RTD_1_IC4_PLOC_MISSIONBOARD, MAX31865::MAX31865_SET_ID) {
|
||||||
}
|
}
|
||||||
|
2
fsfw
2
fsfw
@ -1 +1 @@
|
|||||||
Subproject commit 160ff799ace61e24708dcf1fdeaf5fafdf23a4ca
|
Subproject commit c5f91926c95a8db0c7921176aa3f62cc2bebef47
|
@ -9,23 +9,14 @@
|
|||||||
#include <fsfw_hal/linux/spi/SpiComIF.h>
|
#include <fsfw_hal/linux/spi/SpiComIF.h>
|
||||||
#include <fsfw_hal/linux/spi/SpiCookie.h>
|
#include <fsfw_hal/linux/spi/SpiCookie.h>
|
||||||
#include <linux/callbacks/gpioCallbacks.h>
|
#include <linux/callbacks/gpioCallbacks.h>
|
||||||
#include <linux/devices/Max31865RtdLowlevelHandler.h>
|
|
||||||
#include <mission/controller/AcsController.h>
|
#include <mission/controller/AcsController.h>
|
||||||
#include <mission/controller/ThermalController.h>
|
|
||||||
#include <mission/devices/Max31865EiveHandler.h>
|
|
||||||
#include <mission/devices/Max31865PT1000Handler.h>
|
|
||||||
#include <mission/devices/ScexDeviceHandler.h>
|
#include <mission/devices/ScexDeviceHandler.h>
|
||||||
#include <mission/devices/SusHandler.h>
|
|
||||||
#include <mission/system/fdir/RtdFdir.h>
|
|
||||||
#include <mission/system/fdir/SusFdir.h>
|
|
||||||
|
|
||||||
#include "OBSWConfig.h"
|
#include "OBSWConfig.h"
|
||||||
#include "devConf.h"
|
#include "devConf.h"
|
||||||
#include "devices/addresses.h"
|
#include "devices/addresses.h"
|
||||||
#include "devices/gpioIds.h"
|
#include "devices/gpioIds.h"
|
||||||
#include "eive/definitions.h"
|
#include "eive/definitions.h"
|
||||||
#include "mission/system/objects/SusAssembly.h"
|
|
||||||
#include "mission/system/objects/TcsBoardAssembly.h"
|
|
||||||
#include "mission/system/tree/acsModeTree.h"
|
#include "mission/system/tree/acsModeTree.h"
|
||||||
#include "mission/system/tree/payloadModeTree.h"
|
#include "mission/system/tree/payloadModeTree.h"
|
||||||
|
|
||||||
@ -340,10 +331,6 @@ void ObjectFactory::createScexComponents(std::string uartDev, PowerSwitchIF* pwr
|
|||||||
scexHandler->connectModeTreeParent(satsystem::pl::SUBSYSTEM);
|
scexHandler->connectModeTreeParent(satsystem::pl::SUBSYSTEM);
|
||||||
}
|
}
|
||||||
|
|
||||||
void ObjectFactory::createThermalController() {
|
|
||||||
new ThermalController(objects::THERMAL_CONTROLLER);
|
|
||||||
}
|
|
||||||
|
|
||||||
AcsController* ObjectFactory::createAcsController(bool connectSubsystem) {
|
AcsController* ObjectFactory::createAcsController(bool connectSubsystem) {
|
||||||
auto acsCtrl = new AcsController(objects::ACS_CONTROLLER);
|
auto acsCtrl = new AcsController(objects::ACS_CONTROLLER);
|
||||||
if (connectSubsystem) {
|
if (connectSubsystem) {
|
||||||
|
@ -11,6 +11,8 @@
|
|||||||
#include <optional>
|
#include <optional>
|
||||||
#include <string>
|
#include <string>
|
||||||
|
|
||||||
|
#include "mission/devices/HeaterHandler.h"
|
||||||
|
|
||||||
class GpioIF;
|
class GpioIF;
|
||||||
class SpiComIF;
|
class SpiComIF;
|
||||||
class PowerSwitchIF;
|
class PowerSwitchIF;
|
||||||
@ -29,7 +31,6 @@ void createScexComponents(std::string uartDev, PowerSwitchIF* pwrSwitcher,
|
|||||||
|
|
||||||
void gpioChecker(ReturnValue_t result, std::string output);
|
void gpioChecker(ReturnValue_t result, std::string output);
|
||||||
|
|
||||||
void createThermalController();
|
|
||||||
AcsController* createAcsController(bool connectSubsystem);
|
AcsController* createAcsController(bool connectSubsystem);
|
||||||
|
|
||||||
void addTmtcIpCoresToFunnels(CcsdsIpCoreHandler& ipCoreHandler, PusTmFunnel& pusFunnel,
|
void addTmtcIpCoresToFunnels(CcsdsIpCoreHandler& ipCoreHandler, PusTmFunnel& pusFunnel,
|
||||||
|
@ -36,8 +36,12 @@
|
|||||||
#if OBSW_ADD_TCPIP_BRIDGE == 1
|
#if OBSW_ADD_TCPIP_BRIDGE == 1
|
||||||
#if OBSW_USE_TMTC_TCP_BRIDGE == 0
|
#if OBSW_USE_TMTC_TCP_BRIDGE == 0
|
||||||
// UDP server includes
|
// UDP server includes
|
||||||
|
#include "devices/gpioIds.h"
|
||||||
#include "fsfw/osal/common/UdpTcPollingTask.h"
|
#include "fsfw/osal/common/UdpTcPollingTask.h"
|
||||||
#include "fsfw/osal/common/UdpTmTcBridge.h"
|
#include "fsfw/osal/common/UdpTmTcBridge.h"
|
||||||
|
#include "mission/controller/ThermalController.h"
|
||||||
|
#include "mission/devices/HeaterHandler.h"
|
||||||
|
#include "mission/devices/devicedefinitions/GomspaceDefinitions.h"
|
||||||
#else
|
#else
|
||||||
// TCP server includes
|
// TCP server includes
|
||||||
#include "fsfw/osal/common/TcpTmTcBridge.h"
|
#include "fsfw/osal/common/TcpTmTcBridge.h"
|
||||||
@ -179,3 +183,23 @@ void ObjectFactory::produceGenericObjects(HealthTableIF** healthTable_, PusTmFun
|
|||||||
ccsdsDistrib->registerApplication(info);
|
ccsdsDistrib->registerApplication(info);
|
||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void ObjectFactory::createGenericHeaterComponents(GpioIF& gpioIF, PowerSwitchIF& pwrSwitcher, HeaterHandler*& heaterHandler) {
|
||||||
|
HeaterHelper helper({{
|
||||||
|
{new HealthDevice(objects::HEATER_0_PLOC_PROC_BRD, MessageQueueIF::NO_QUEUE),
|
||||||
|
gpioIds::HEATER_0},
|
||||||
|
{new HealthDevice(objects::HEATER_1_PCDU_BRD, MessageQueueIF::NO_QUEUE), gpioIds::HEATER_1},
|
||||||
|
{new HealthDevice(objects::HEATER_2_ACS_BRD, MessageQueueIF::NO_QUEUE), gpioIds::HEATER_2},
|
||||||
|
{new HealthDevice(objects::HEATER_3_OBC_BRD, MessageQueueIF::NO_QUEUE), gpioIds::HEATER_3},
|
||||||
|
{new HealthDevice(objects::HEATER_4_CAMERA, MessageQueueIF::NO_QUEUE), gpioIds::HEATER_4},
|
||||||
|
{new HealthDevice(objects::HEATER_5_STR, MessageQueueIF::NO_QUEUE), gpioIds::HEATER_5},
|
||||||
|
{new HealthDevice(objects::HEATER_6_DRO, MessageQueueIF::NO_QUEUE), gpioIds::HEATER_6},
|
||||||
|
{new HealthDevice(objects::HEATER_7_HPA, MessageQueueIF::NO_QUEUE), gpioIds::HEATER_7},
|
||||||
|
}});
|
||||||
|
heaterHandler = new HeaterHandler(objects::HEATER_HANDLER, &gpioIF, helper, &pwrSwitcher,
|
||||||
|
pcdu::Switches::PDU2_CH3_TCS_BOARD_HEATER_IN_8V);
|
||||||
|
}
|
||||||
|
|
||||||
|
void ObjectFactory::createThermalController(HeaterHandler& heaterHandler) {
|
||||||
|
new ThermalController(objects::THERMAL_CONTROLLER, heaterHandler);
|
||||||
|
}
|
@ -1,6 +1,10 @@
|
|||||||
#ifndef MISSION_CORE_GENERICFACTORY_H_
|
#ifndef MISSION_CORE_GENERICFACTORY_H_
|
||||||
#define MISSION_CORE_GENERICFACTORY_H_
|
#define MISSION_CORE_GENERICFACTORY_H_
|
||||||
|
|
||||||
|
#include "fsfw_hal/common/gpio/GpioIF.h"
|
||||||
|
#include "fsfw/power/PowerSwitchIF.h"
|
||||||
|
|
||||||
|
class HeaterHandler;
|
||||||
class HealthTableIF;
|
class HealthTableIF;
|
||||||
class PusTmFunnel;
|
class PusTmFunnel;
|
||||||
class CfdpTmFunnel;
|
class CfdpTmFunnel;
|
||||||
@ -9,7 +13,9 @@ namespace ObjectFactory {
|
|||||||
|
|
||||||
void produceGenericObjects(HealthTableIF** healthTable, PusTmFunnel** pusFunnel,
|
void produceGenericObjects(HealthTableIF** healthTable, PusTmFunnel** pusFunnel,
|
||||||
CfdpTmFunnel** cfdpFunnel);
|
CfdpTmFunnel** cfdpFunnel);
|
||||||
|
void createGenericHeaterComponents(GpioIF& gpioIF, PowerSwitchIF& pwrSwitcher, HeaterHandler*& heaterHandler);
|
||||||
|
|
||||||
|
void createThermalController(HeaterHandler& heaterHandler);
|
||||||
}
|
}
|
||||||
|
|
||||||
#endif /* MISSION_CORE_GENERICFACTORY_H_ */
|
#endif /* MISSION_CORE_GENERICFACTORY_H_ */
|
||||||
|
@ -15,6 +15,7 @@
|
|||||||
#include <fsfw_hal/common/gpio/GpioIF.h>
|
#include <fsfw_hal/common/gpio/GpioIF.h>
|
||||||
|
|
||||||
#include <array>
|
#include <array>
|
||||||
|
#include <utility>
|
||||||
#include <vector>
|
#include <vector>
|
||||||
|
|
||||||
#include "devices/heaterSwitcherList.h"
|
#include "devices/heaterSwitcherList.h"
|
||||||
@ -28,7 +29,7 @@ using HeaterPair = std::pair<HealthDevice*, gpioId_t>;
|
|||||||
|
|
||||||
struct HeaterHelper {
|
struct HeaterHelper {
|
||||||
public:
|
public:
|
||||||
HeaterHelper(std::array<HeaterPair, heater::NUMBER_OF_SWITCHES> heaters) : heaters(heaters) {}
|
HeaterHelper(std::array<HeaterPair, heater::NUMBER_OF_SWITCHES> heaters) : heaters(std::move(heaters)) {}
|
||||||
std::array<HeaterPair, heater::NUMBER_OF_SWITCHES> heaters = {};
|
std::array<HeaterPair, heater::NUMBER_OF_SWITCHES> heaters = {};
|
||||||
};
|
};
|
||||||
/**
|
/**
|
||||||
|
2
tmtc
2
tmtc
@ -1 +1 @@
|
|||||||
Subproject commit 292bafa0918d386e7f64bf9ed0e114a887420899
|
Subproject commit d5813e1a422beae7d0cb092a885e0956e9f1ddc1
|
Loading…
Reference in New Issue
Block a user