2022-09-19 15:03:25 +02:00
|
|
|
/*
|
|
|
|
* ActuatorCmd.h
|
|
|
|
*
|
|
|
|
* Created on: 4 Aug 2022
|
|
|
|
* Author: Robin Marquardt
|
|
|
|
*/
|
|
|
|
|
|
|
|
#ifndef ACTUATORCMD_H_
|
|
|
|
#define ACTUATORCMD_H_
|
|
|
|
|
2022-09-27 11:06:11 +02:00
|
|
|
#include "AcsParameters.h"
|
|
|
|
#include "MultiplicativeKalmanFilter.h"
|
2022-11-03 10:43:27 +01:00
|
|
|
#include "SensorProcessing.h"
|
2022-09-27 11:06:11 +02:00
|
|
|
#include "SensorValues.h"
|
2022-09-19 15:03:25 +02:00
|
|
|
|
2022-11-03 10:43:27 +01:00
|
|
|
class ActuatorCmd {
|
|
|
|
public:
|
|
|
|
ActuatorCmd(AcsParameters *acsParameters_); // Input mode ?
|
|
|
|
virtual ~ActuatorCmd();
|
|
|
|
|
|
|
|
/*
|
|
|
|
* @brief: cmdSpeedToRws() will set the maximum possible torque for the reaction
|
|
|
|
* wheels, also will calculate the needed revolutions per minute for the RWs, which will be given
|
|
|
|
* as Input to the RWs
|
|
|
|
* @param: rwTrqIn given torque from pointing controller
|
|
|
|
* rwTrqNS Nullspace torque
|
|
|
|
* rwCmdSpeed output revolutions per minute for every
|
|
|
|
* reaction wheel
|
|
|
|
*/
|
|
|
|
void cmdSpeedToRws(const int32_t *speedRw0, const int32_t *speedRw1, const int32_t *speedRw2,
|
|
|
|
const int32_t *speedRw3, const double *rwTrqIn, const double *rwTrqNS,
|
|
|
|
double *rwCmdSpeed);
|
|
|
|
|
|
|
|
/*
|
|
|
|
* @brief: cmdDipolMtq() gives the commanded dipol moment for the magnetorques
|
|
|
|
*
|
|
|
|
* @param: dipolMoment given dipol moment in spacecraft frame
|
2023-02-02 10:47:58 +01:00
|
|
|
* dipolMomentActuator resulting dipol moment in actuator reference frame
|
2022-11-03 10:43:27 +01:00
|
|
|
*/
|
2023-02-02 10:47:58 +01:00
|
|
|
void cmdDipolMtq(const double *dipolMoment, double *dipolMomentActuator);
|
2022-11-03 10:43:27 +01:00
|
|
|
|
|
|
|
protected:
|
|
|
|
private:
|
|
|
|
AcsParameters acsParameters;
|
2022-09-19 15:03:25 +02:00
|
|
|
};
|
|
|
|
|
|
|
|
#endif /* ACTUATORCMD_H_ */
|