Class SunSafePointingSoftware
- Namespace
- NominalSystems.Classes
- Assembly
- NominalSystems.Classes.dll
[Nominal] This module provides the attitude guidance output for a sun pointing mode. This is used for safe mode, or a power generation mode. The input is the sun direction vector which does not have to be normalized, as well as the body rate information. The output is the standard attitude reference state message. The sun direction measurement is cross with the desired body axis that is to point at the sun to create a principle rotation vector. The dot product between these two vectors is used to extract the principal rotation angle. With these a tracking error MRP state is computer. The body rate tracking errors relative to the reference frame are set equal to the measured body rates to bring the vehicle to rest when pointing at the sun. Thus, the reference angular rate and acceleration vectors relative to the inertial frame are nominally set to zero. If the sun vector is not available, then the reference rate is set to a body-fixed value while the attitude tracking error is set to zero.
public class SunSafePointingSoftware : Software
- Inheritance
-
SunSafePointingSoftware
Constructors
SunSafePointingSoftware()
Default constructor
protected SunSafePointingSoftware()
Fields
In_NavigationAttitudeMsg
Input body attitude (estimation)
public NavigationAttitudeMessage? In_NavigationAttitudeMsg
Field Value
In_SunDirectionMsg
Input sun position (estimation)
public NavigationAttitudeMessage? In_SunDirectionMsg
Field Value
MinUnitMag
[-] The minimally acceptable norm of sun body vector
[Unit(UnitType.NONE)]
public double MinUnitMag
Field Value
Omega_RN_B
[r/s] Desired body rate vector if no sun direction is available
[Unit(UnitType.RADIAN_PER_SECOND)]
public Vector3 Omega_RN_B
Field Value
Out_AttitudeErrorMsg
for the outgoing body estimate message
public AttitudeErrorMessage? Out_AttitudeErrorMsg
Field Value
Out_AttitudeReferenceMsg
For the outgoing body attitude reference message
public AttitudeReferenceMessage? Out_AttitudeReferenceMsg
Field Value
SmallAngle
[rad] An angle value that specifies what is near 0 or 180 degrees
[Unit(UnitType.RADIAN)]
public double SmallAngle
Field Value
SunAxisSpinRate
[r/s] Desired constant spin rate about sun heading vector
[Unit(UnitType.RADIAN_PER_SECOND)]
public double SunAxisSpinRate
Field Value
SunBodyVector
[-] Desired body vector to point at the sun
[Unit(UnitType.NONE)]
public Vector3 SunBodyVector
Field Value
Methods
Initialise()
This method is called whenever some key parameters are changed and any new local variables are required to be recalculated. This can be called by the software chains if a configuration of some values are updated.
public override void Initialise()
OnBegin(double)
Called when the object is beginning ticking for the first time. This is when the simulation calls the very first tick and will run before the update call.
protected override void OnBegin(double time)
Parameters
time
double[s] Current time of the simulation before the tick
OnCreate()
Called when the object is created from the controller and has been attached to the parent object. By this point, it has been registered to the simulation and will run after the constructor.
protected override void OnCreate()
OnLoad(double)
Called after all of the data has been loaded from a save state on this object. This enables any post-load operations to be performed and extra data to be loaded from the metadata.
protected override void OnLoad(double time)
Parameters
time
double[s] The current clock time of the simulation
OnUpdate(double, double)
Called when the object should update from the simulation tick. This will take in a time and a step, where the time is the time of the clock before updating the object.
protected override void OnUpdate(double time, double step)