moved config flag to cmmon config
This commit is contained in:
parent
590d5e11e1
commit
261fc8b58f
@ -70,15 +70,15 @@ void initmission::initTasks() {
|
||||
}
|
||||
|
||||
/* UDP bridge */
|
||||
PeriodicTaskIF* udpBridgeTask = factory->createPeriodicTask(
|
||||
"UDP_UNIX_BRIDGE", 50, PeriodicTaskIF::MINIMUM_STACK_SIZE, 0.2, missedDeadlineFunc);
|
||||
result = udpBridgeTask->addComponent(objects::TMTC_BRIDGE);
|
||||
PeriodicTaskIF* tmtcBridgeTask = factory->createPeriodicTask(
|
||||
"TMTC_UNIX_BRIDGE", 50, PeriodicTaskIF::MINIMUM_STACK_SIZE, 0.2, missedDeadlineFunc);
|
||||
result = tmtcBridgeTask->addComponent(objects::TMTC_BRIDGE);
|
||||
if(result != HasReturnvaluesIF::RETURN_OK) {
|
||||
sif::error << "Add component UDP Unix Bridge failed" << std::endl;
|
||||
}
|
||||
PeriodicTaskIF* udpPollingTask = factory->createPeriodicTask(
|
||||
PeriodicTaskIF* tmtcPollingTask = factory->createPeriodicTask(
|
||||
"UDP_POLLING", 80, PeriodicTaskIF::MINIMUM_STACK_SIZE, 2.0, missedDeadlineFunc);
|
||||
result = udpPollingTask->addComponent(objects::TMTC_POLLING_TASK);
|
||||
result = tmtcPollingTask->addComponent(objects::TMTC_POLLING_TASK);
|
||||
if(result != HasReturnvaluesIF::RETURN_OK) {
|
||||
sif::error << "Add component UDP Polling failed" << std::endl;
|
||||
}
|
||||
@ -142,8 +142,8 @@ void initmission::initTasks() {
|
||||
|
||||
sif::info << "Starting tasks.." << std::endl;
|
||||
tmTcDistributor->startTask();
|
||||
udpBridgeTask->startTask();
|
||||
udpPollingTask->startTask();
|
||||
tmtcBridgeTask->startTask();
|
||||
tmtcPollingTask->startTask();
|
||||
|
||||
pusVerification->startTask();
|
||||
pusEvents->startTask();
|
||||
|
@ -1,6 +1,5 @@
|
||||
#include "ObjectFactory.h"
|
||||
|
||||
#include <OBSWConfig.h>
|
||||
#include "OBSWConfig.h"
|
||||
#include <objects/systemObjectList.h>
|
||||
#include <tmtc/apid.h>
|
||||
#include <tmtc/pusIds.h>
|
||||
@ -11,8 +10,13 @@
|
||||
#include <mission/core/GenericFactory.h>
|
||||
#include <mission/utility/TmFunnel.h>
|
||||
|
||||
#include <fsfw/osal/common/UdpTcPollingTask.h>
|
||||
#include <fsfw/osal/common/UdpTmTcBridge.h>
|
||||
#if OBSW_USE_TMTC_TCP_BRIDGE == 0
|
||||
#include "fsfw/osal/common/UdpTcPollingTask.h"
|
||||
#include "fsfw/osal/common/UdpTmTcBridge.h"
|
||||
#else
|
||||
#include "fsfw/osal/common/TcpTmTcBridge.h"
|
||||
#include "fsfw/osal/common/TcpTmTcServer.h"
|
||||
#endif
|
||||
|
||||
#include <fsfw/tmtcpacket/pus/tm.h>
|
||||
|
||||
@ -40,7 +44,16 @@ void ObjectFactory::produce(void* args){
|
||||
Factory::setStaticFrameworkObjectIds();
|
||||
ObjectFactory::produceGenericObjects();
|
||||
|
||||
#if OBSW_USE_TMTC_TCP_BRIDGE == 0
|
||||
sif::info << "Setting up UDP TMTC bridge with listener port " <<
|
||||
UdpTmTcBridge::DEFAULT_SERVER_PORT << std::endl;
|
||||
new UdpTmTcBridge(objects::TMTC_BRIDGE, objects::CCSDS_PACKET_DISTRIBUTOR);
|
||||
new UdpTcPollingTask(objects::TMTC_POLLING_TASK, objects::TMTC_BRIDGE);
|
||||
#else
|
||||
sif::info << "Setting up TCP TMTC bridge with listener port " <<
|
||||
TcpTmTcBridge::DEFAULT_SERVER_PORT << std::endl;
|
||||
new TcpTmTcBridge(objects::TMTC_BRIDGE, objects::CCSDS_PACKET_DISTRIBUTOR);
|
||||
new TcpTmTcServer(objects::TMTC_POLLING_TASK, objects::TMTC_BRIDGE);
|
||||
#endif
|
||||
|
||||
}
|
||||
|
@ -360,10 +360,10 @@ void CoreController::initPrint() {
|
||||
#if OBSW_VERBOSE_LEVEL >= 1
|
||||
#if OBSW_USE_TMTC_TCP_BRIDGE == 0
|
||||
sif::info << "Created UDP server for TMTC commanding with listener port " <<
|
||||
UdpTmTcBridge::DEFAULT_UDP_SERVER_PORT << std::endl;
|
||||
UdpTmTcBridge::DEFAULT_SERVER_PORT << std::endl;
|
||||
#else
|
||||
sif::info << "Created TCP server for TMTC commanding with listener port " <<
|
||||
TcpTmTcBridge::DEFAULT_TCP_SERVER_PORT << std::endl;
|
||||
TcpTmTcBridge::DEFAULT_SERVER_PORT << std::endl;
|
||||
#endif
|
||||
#endif
|
||||
}
|
||||
|
@ -3,4 +3,8 @@
|
||||
|
||||
#define OBSW_ADD_LWGPS_TEST 0
|
||||
|
||||
// Use TCP instead of UDP for the TMTC bridge. This allows using the TMTC client locally
|
||||
// because UDP packets are not allowed in the VPN
|
||||
#define OBSW_USE_TMTC_TCP_BRIDGE 0
|
||||
|
||||
#endif /* COMMON_CONFIG_COMMONCONFIG_H_ */
|
||||
|
2
fsfw
2
fsfw
@ -1 +1 @@
|
||||
Subproject commit 1f6a5e635fcd6bd812e262cc65a15a8a054f7ecf
|
||||
Subproject commit 54c028f913e81077855aa1ed727bac43e7efea82
|
@ -18,10 +18,6 @@
|
||||
debugging. */
|
||||
#define OBSW_VERBOSE_LEVEL 1
|
||||
|
||||
// Use TCP instead of UDP for the TMTC bridge. This allows using the TMTC client locally
|
||||
// because UDP packets are not allowed in the VPN
|
||||
#define OBSW_USE_TMTC_TCP_BRIDGE 0
|
||||
|
||||
#define OBSW_PRINT_MISSED_DEADLINES 1
|
||||
#define OBSW_ADD_TEST_CODE 1
|
||||
#define OBSW_ADD_TEST_PST 1
|
||||
|
Loading…
Reference in New Issue
Block a user