Module: eulerRotation

Executive Summary

This module guidance modules creates constant Euler angle rate rotations about a primary axis to create dynamic reference frames.

Message Connection Descriptions

The following table lists all the module input and output messages. The module msg connection is set by the user from python. The msg type contains a link to the message structure definition, while the description provides information on what this message is used for.

Module I/O Messages

Msg Variable Name

Msg Type

Description

attRefOutMsg

AttRefMsgPayload

name of the output message containing the Reference

attRefInMsg

AttRefMsgPayload

name of the guidance reference input message

desiredAttInMsg

AttStateMsgPayload

(optional) name of the incoming message containing the desired Euler angle set

User Guide

The initial orientation of the dynamic reference frame is set through the module variable angleSet. This is a 3-2-1 Euler angle sequence.

To set the desired constant 3-2-1 Euler angel rates, set the module variable angleRates.


Functions

void SelfInit_eulerRotation(eulerRotationConfig *configData, int64_t moduleID)

This method initializes the configData for eulerRotation model. It creates the module output message.

Parameters:
  • configData – The configuration data associated with the null space control

  • moduleID – The ID associated with the configData

Returns:

void

void Reset_eulerRotation(eulerRotationConfig *configData, uint64_t callTime, int64_t moduleID)

This resets the module to original states.

Parameters:
  • configData – The configuration data associated with the null space control

  • callTime – The clock time at which the function was called (nanoseconds)

  • moduleID – The ID associated with the configData

Returns:

void

void Update_eulerRotation(eulerRotationConfig *configData, uint64_t callTime, int64_t moduleID)

This method takes the input attitude reference frame, and and superimposes the dynamic euler angle scanning motion on top of this.

Parameters:
  • configData – The configuration data associated with the mrpRotation module

  • callTime – The clock time at which the function was called (nanoseconds)

  • moduleID – The ID associated with the configData

Returns:

void

void checkRasterCommands(eulerRotationConfig *configData)

This function checks if there is a new commanded raster maneuver message available.

Parameters:

configData – The configuration data associated with the mrpRotation module

Returns:

void

void computeTimeStep(eulerRotationConfig *configData, uint64_t callTime)

This function computes control update time.

Parameters:
  • configData – The configuration data associated with the mrpRotation module

  • callTime – The clock time at which the function was called (nanoseconds)

Returns:

void

void computeEuler321_Binv_derivative(double angleSet[3], double angleRates[3], double B_inv_deriv[3][3])

This function computes the analytical derivative of the B_inv matrix for the 3-2-1 Euler Angle set.

Parameters:
  • angleSet – 321 Euler angles

  • angleRates – The 321 Euler angle rates

  • B_inv_deriv – the inv(B) matrix for 321 Euler angles

Returns:

void

void computeEulerRotationReference(eulerRotationConfig *configData, double sigma_R0N[3], double omega_R0N_N[3], double domega_R0N_N[3], AttRefMsgPayload *attRefOut)

This function computes the reference (Euler angle attitude set, angular velocity and angular acceleration) associated with a rotation defined in terms of an initial euler angle set and a constant euler angle rate.

Parameters:
  • configData – The configuration data associated with the mrpRotation module

  • sigma_R0N – The input reference attitude using MRPs

  • omega_R0N_N – The input reference frame angular rate vector

  • domega_R0N_N – The input reference frame angular acceleration vector

  • attRefOut – The output message copy

Returns:

void

struct eulerRotationConfig
#include <eulerRotation.h>

Top level structure for the sub-module routines.

Public Members

double angleSet[3]

[-] current euler angle 321 set R/R0 with respect to the input reference

double angleRates[3]

[rad/s] euler angle 321 rates

double cmdSet[3]

[] msg commanded initial Euler angle 321 set with respect to input reference

double cmdRates[3]

[rad/s] msg commanded constant 321 Euler angle rates

double priorCmdSet[3]

[] prior commanded 321 Euler angle set

double priorCmdRates[3]

[rad/s] prior commanded 321 Euler angle rates

uint64_t priorTime

[ns] last time the guidance module is called

double dt

[s] integration time-step

AttRefMsg_C attRefOutMsg

The name of the output message containing the Reference.

AttRefMsg_C attRefInMsg

The name of the guidance reference input message.

AttStateMsg_C desiredAttInMsg

The name of the incoming message containing the desired EA set.

BSKLogger *bskLogger

BSK Logging.