Merge remote-tracking branch 'origin/develop' into acs_update_scheduling_again
All checks were successful
EIVE/eive-obsw/pipeline/pr-develop This commit looks good
All checks were successful
EIVE/eive-obsw/pipeline/pr-develop This commit looks good
This commit is contained in:
commit
4052534235
@ -21,6 +21,7 @@ change warranting a new major release:
|
||||
|
||||
- ACS Controller scheduling is now configurable via the `eive/definitions.h` file. Also ensured
|
||||
that scheduling is done in big blocks to reduce risk of missed deadlines.
|
||||
- Replaced chained locks for polling new sensor data to the `AcsController`
|
||||
|
||||
# [v1.26.1] 2023-02-08
|
||||
|
||||
|
@ -107,8 +107,6 @@ void AcsController::performControlOperation() {
|
||||
}
|
||||
|
||||
void AcsController::performSafe() {
|
||||
ACS::SensorValues sensorValues;
|
||||
|
||||
timeval now;
|
||||
Clock::getClock_timeval(&now);
|
||||
|
||||
@ -197,8 +195,6 @@ void AcsController::performSafe() {
|
||||
}
|
||||
|
||||
void AcsController::performDetumble() {
|
||||
ACS::SensorValues sensorValues;
|
||||
|
||||
timeval now;
|
||||
Clock::getClock_timeval(&now);
|
||||
|
||||
@ -258,8 +254,6 @@ void AcsController::performDetumble() {
|
||||
}
|
||||
|
||||
void AcsController::performPointingCtrl() {
|
||||
ACS::SensorValues sensorValues;
|
||||
|
||||
timeval now;
|
||||
Clock::getClock_timeval(&now);
|
||||
|
||||
@ -721,14 +715,6 @@ void AcsController::copySusData() {
|
||||
}
|
||||
}
|
||||
|
||||
ReturnValue_t AcsController::initialize() {
|
||||
ReturnValue_t result = parameterHelper.initialize();
|
||||
if (result != returnvalue::OK) {
|
||||
return result;
|
||||
}
|
||||
return ExtendedControllerBase::initialize();
|
||||
}
|
||||
|
||||
void AcsController::copyGyrData() {
|
||||
ACS::SensorValues sensorValues;
|
||||
{
|
||||
@ -776,3 +762,11 @@ void AcsController::copyGyrData() {
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
ReturnValue_t AcsController::initialize() {
|
||||
ReturnValue_t result = parameterHelper.initialize();
|
||||
if (result != returnvalue::OK) {
|
||||
return result;
|
||||
}
|
||||
return ExtendedControllerBase::initialize();
|
||||
}
|
||||
|
@ -69,8 +69,10 @@ class AcsController : public ExtendedControllerBase, public ReceivesParameterMes
|
||||
void modeChanged(Mode_t mode, Submode_t submode);
|
||||
void announceMode(bool recursive);
|
||||
|
||||
/* ACS Datasets */
|
||||
/* ACS Sensor Values */
|
||||
ACS::SensorValues sensorValues;
|
||||
|
||||
/* ACS Datasets */
|
||||
IMTQ::DipoleActuationSet dipoleSet = IMTQ::DipoleActuationSet(objects::IMTQ_HANDLER);
|
||||
// MGMs
|
||||
acsctrl::MgmDataRaw mgmDataRaw;
|
||||
|
@ -20,61 +20,112 @@ SensorValues::SensorValues() {}
|
||||
SensorValues::~SensorValues() {}
|
||||
|
||||
ReturnValue_t SensorValues::updateMgm() {
|
||||
ReturnValue_t result;
|
||||
PoolReadGuard pgMgm0(&mgm0Lis3Set), pgMgm1(&mgm1Rm3100Set), pgMgm2(&mgm2Lis3Set),
|
||||
pgMgm3(&mgm3Rm3100Set), pgImtq(&imtqMgmSet);
|
||||
std::vector<ReturnValue_t> results;
|
||||
|
||||
result = (pgMgm0.getReadResult() || pgMgm1.getReadResult() || pgMgm2.getReadResult() ||
|
||||
pgMgm3.getReadResult() || pgImtq.getReadResult());
|
||||
{
|
||||
PoolReadGuard pgMgm(&mgm0Lis3Set);
|
||||
results.push_back(pgMgm.getReadResult());
|
||||
}
|
||||
{
|
||||
PoolReadGuard pgMgm(&mgm1Rm3100Set);
|
||||
results.push_back(pgMgm.getReadResult());
|
||||
}
|
||||
{
|
||||
PoolReadGuard pgMgm(&mgm2Lis3Set);
|
||||
results.push_back(pgMgm.getReadResult());
|
||||
}
|
||||
{
|
||||
PoolReadGuard pgMgm(&mgm3Rm3100Set);
|
||||
results.push_back(pgMgm.getReadResult());
|
||||
}
|
||||
{
|
||||
PoolReadGuard pgMgm(&imtqMgmSet);
|
||||
results.push_back(pgMgm.getReadResult());
|
||||
}
|
||||
for (const auto& result : results) {
|
||||
if (result != returnvalue::OK) {
|
||||
return result;
|
||||
}
|
||||
}
|
||||
return returnvalue::OK;
|
||||
}
|
||||
|
||||
ReturnValue_t SensorValues::updateSus() {
|
||||
ReturnValue_t result;
|
||||
PoolReadGuard pgSus0(&susSets[0]), pgSus1(&susSets[1]), pgSus2(&susSets[2]), pgSus3(&susSets[3]),
|
||||
pgSus4(&susSets[4]), pgSus5(&susSets[5]), pgSus6(&susSets[6]), pgSus7(&susSets[7]),
|
||||
pgSus8(&susSets[8]), pgSus9(&susSets[9]), pgSus10(&susSets[10]), pgSus11(&susSets[11]);
|
||||
|
||||
result = (pgSus0.getReadResult() || pgSus1.getReadResult() || pgSus2.getReadResult() ||
|
||||
pgSus3.getReadResult() || pgSus4.getReadResult() || pgSus5.getReadResult() ||
|
||||
pgSus6.getReadResult() || pgSus7.getReadResult() || pgSus8.getReadResult() ||
|
||||
pgSus9.getReadResult() || pgSus10.getReadResult() || pgSus11.getReadResult());
|
||||
std::vector<ReturnValue_t> results;
|
||||
for (auto& susSet : susSets) {
|
||||
{
|
||||
PoolReadGuard pgSus(&susSet);
|
||||
results.push_back(pgSus.getReadResult());
|
||||
}
|
||||
}
|
||||
for (const auto& result : results) {
|
||||
if (result != returnvalue::OK) {
|
||||
return result;
|
||||
}
|
||||
}
|
||||
return returnvalue::OK;
|
||||
}
|
||||
|
||||
ReturnValue_t SensorValues::updateGyr() {
|
||||
ReturnValue_t result;
|
||||
PoolReadGuard pgGyr0(&gyr0AdisSet), pgGyr1(&gyr1L3gSet), pgGyr2(&gyr2AdisSet),
|
||||
pgGyr3(&gyr3L3gSet);
|
||||
|
||||
result = (pgGyr0.getReadResult() || pgGyr1.getReadResult() || pgGyr2.getReadResult() ||
|
||||
pgGyr3.getReadResult());
|
||||
std::vector<ReturnValue_t> results;
|
||||
{
|
||||
PoolReadGuard pgGyr(&gyr0AdisSet);
|
||||
results.push_back(pgGyr.getReadResult());
|
||||
}
|
||||
{
|
||||
PoolReadGuard pgGyr(&gyr1L3gSet);
|
||||
results.push_back(pgGyr.getReadResult());
|
||||
}
|
||||
{
|
||||
PoolReadGuard pgGyr(&gyr2AdisSet);
|
||||
results.push_back(pgGyr.getReadResult());
|
||||
}
|
||||
{
|
||||
PoolReadGuard pgGyr(&gyr3L3gSet);
|
||||
results.push_back(pgGyr.getReadResult());
|
||||
}
|
||||
for (const auto& result : results) {
|
||||
if (result != returnvalue::OK) {
|
||||
return result;
|
||||
}
|
||||
}
|
||||
return returnvalue::OK;
|
||||
}
|
||||
|
||||
ReturnValue_t SensorValues::updateStr() {
|
||||
ReturnValue_t result;
|
||||
PoolReadGuard pgStr(&strSet);
|
||||
|
||||
result = pgStr.getReadResult();
|
||||
return result;
|
||||
return pgStr.getReadResult();
|
||||
}
|
||||
|
||||
ReturnValue_t SensorValues::updateGps() {
|
||||
ReturnValue_t result;
|
||||
PoolReadGuard pgGps(&gpsSet);
|
||||
|
||||
result = pgGps.getReadResult();
|
||||
return result;
|
||||
return pgGps.getReadResult();
|
||||
}
|
||||
|
||||
ReturnValue_t SensorValues::updateRw() {
|
||||
ReturnValue_t result;
|
||||
PoolReadGuard pgRw1(&rw1Set), pgRw2(&rw2Set), pgRw3(&rw3Set), pgRw4(&rw4Set);
|
||||
|
||||
result = (pgRw1.getReadResult() || pgRw2.getReadResult() || pgRw3.getReadResult() ||
|
||||
pgRw4.getReadResult());
|
||||
std::vector<ReturnValue_t> results;
|
||||
{
|
||||
PoolReadGuard pgRw(&rw1Set);
|
||||
results.push_back(pgRw.getReadResult());
|
||||
}
|
||||
{
|
||||
PoolReadGuard pgRw(&rw2Set);
|
||||
results.push_back(pgRw.getReadResult());
|
||||
}
|
||||
{
|
||||
PoolReadGuard pgRw(&rw3Set);
|
||||
results.push_back(pgRw.getReadResult());
|
||||
}
|
||||
{
|
||||
PoolReadGuard pgRw(&rw4Set);
|
||||
results.push_back(pgRw.getReadResult());
|
||||
}
|
||||
for (const auto& result : results) {
|
||||
if (result != returnvalue::OK) {
|
||||
return result;
|
||||
}
|
||||
}
|
||||
return returnvalue::OK;
|
||||
}
|
||||
|
||||
ReturnValue_t SensorValues::update() {
|
||||
|
2
tmtc
2
tmtc
@ -1 +1 @@
|
||||
Subproject commit d0c8e20d4f9a6f5aee3ccfa05c4f7ab7151400b5
|
||||
Subproject commit 94a82b84e86177d122f4ac12eff6e06528f6290b
|
Loading…
Reference in New Issue
Block a user