Module: prvSteering
Executive Summary
This module implements a PRV steering attitude control routine.
The module
PDF Description
contains further information on this module’s function,
how to run it, as well as testing.
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.
Msg Variable Name |
Msg Type |
Description |
---|---|---|
guidInMsg |
Attitude guidance input message. |
|
rateCmdOutMsg |
Rate command output message. |
Functions
-
void SelfInit_prvSteering(PrvSteeringConfig *configData, int64_t moduleID)
This method initializes the configData for this module. It checks to ensure that the inputs are sane and then creates the output message
- Parameters:
configData – The configuration data associated with this module
moduleID – The module identifier
- Returns:
void
-
void Update_prvSteering(PrvSteeringConfig *configData, uint64_t callTime, int64_t moduleID)
This method takes the attitude and rate errors relative to the Reference frame, as well as the reference frame angular rates and acceleration, and computes the required control torque Lr.
- Parameters:
configData – The configuration data associated with the MRP Steering attitude control
callTime – The clock time at which the function was called (nanoseconds)
moduleID – The module identifier
- Returns:
void
-
void Reset_prvSteering(PrvSteeringConfig *configData, uint64_t callTime, int64_t moduleID)
This method performs a complete reset of the module. Local module variables that retain time varying states between function calls are reset to their default values.
- Parameters:
configData – The configuration data associated with the MRP steering control
callTime – The clock time at which the function was called (nanoseconds)
moduleID – The module identifier
- Returns:
void
-
void PRVSteeringLaw(PrvSteeringConfig *configData, double sigma_BR[3], double omega_ast[3], double omega_ast_p[3])
This method computes the PRV Steering law. A commanded body rate is returned given the PRV attitude error measure of the body relative to a reference frame. The function returns the commanded body rate, as well as the body frame derivative of this rate command.
- Parameters:
configData – The configuration data associated with this module
sigma_BR – MRP attitude error of B relative to R
omega_ast – Commanded body rates
omega_ast_p – Body frame derivative of the commanded body rates
- Returns:
void
-
struct PrvSteeringConfig
- #include <prvSteering.h>
module configuration message definition
Public Members
-
double K1
[rad/sec] Proportional gain applied to principal rotation angle error
-
double K3
[rad/sec] Cubic gain applied to principal rotation angle error in steering saturation function
-
double omega_max
[rad/sec] Maximum rate command of steering control
-
RateCmdMsg_C rateCmdOutMsg
rate command output message
-
AttGuidMsg_C guidInMsg
attitude guidance input message
-
BSKLogger *bskLogger
BSK Logging.
-
double K1