2022-09-20 13:36:17 +02:00
|
|
|
#ifndef ACS_CONTROL_DETUMBLE_H_
|
|
|
|
#define ACS_CONTROL_DETUMBLE_H_
|
|
|
|
|
2022-12-01 15:56:55 +01:00
|
|
|
#include <fsfw/returnvalues/returnvalue.h>
|
2022-09-20 13:36:17 +02:00
|
|
|
#include <stdio.h>
|
2022-12-01 15:56:55 +01:00
|
|
|
#include <string.h>
|
2022-09-26 13:23:20 +02:00
|
|
|
#include <time.h>
|
2022-09-27 11:06:11 +02:00
|
|
|
|
2022-12-01 15:56:55 +01:00
|
|
|
#include "../AcsParameters.h"
|
|
|
|
#include "../SensorValues.h"
|
2023-02-08 14:11:11 +01:00
|
|
|
#include "eive/resultClassIds.h"
|
2022-09-20 13:36:17 +02:00
|
|
|
|
2022-12-01 15:56:55 +01:00
|
|
|
class Detumble {
|
|
|
|
public:
|
2023-02-28 10:12:25 +01:00
|
|
|
Detumble();
|
2022-12-01 15:56:55 +01:00
|
|
|
virtual ~Detumble();
|
2022-09-20 13:36:17 +02:00
|
|
|
|
2023-02-08 14:11:11 +01:00
|
|
|
static const uint8_t INTERFACE_ID = CLASS_ID::ACS_DETUMBLE;
|
2022-12-01 15:56:55 +01:00
|
|
|
static const ReturnValue_t DETUMBLE_NO_SENSORDATA = MAKE_RETURN_CODE(0x01);
|
2022-09-20 13:36:17 +02:00
|
|
|
|
2022-12-01 15:56:55 +01:00
|
|
|
ReturnValue_t bDotLaw(const double *magRate, const bool magRateValid, const double *magField,
|
2023-02-28 10:12:25 +01:00
|
|
|
const bool magFieldValid, double *magMom, double gain);
|
2022-09-20 13:36:17 +02:00
|
|
|
|
2023-02-28 10:12:25 +01:00
|
|
|
ReturnValue_t bangbangLaw(const double *magRate, const bool magRateValid, double *magMom,
|
|
|
|
double dipolMax);
|
2022-09-20 13:36:17 +02:00
|
|
|
|
2023-02-28 10:12:25 +01:00
|
|
|
ReturnValue_t bDotLawFull(const double *satRate, const bool *satRateValid, const double *magField,
|
|
|
|
const bool *magFieldValid, double *magMom, double gain);
|
2022-10-21 16:46:09 +02:00
|
|
|
|
2022-12-13 11:51:03 +01:00
|
|
|
private:
|
2022-09-20 13:36:17 +02:00
|
|
|
};
|
|
|
|
|
2022-09-27 11:57:15 +02:00
|
|
|
#endif /*ACS_CONTROL_DETUMBLE_H_*/
|