Class in Zendir.Classes | Inherits from Software
Declaration
class ROEFormationControllerSoftware;Description
ROE-based formation flying flight control software module. This module computes the required translational accelerations for a chaser satellite to follow a desired relative trajectory around a target (chief) spacecraft. The trajectory is defined in the Local-Vertical/Local-Horizontal (LVLH) frame and is controlled via feedback on position and velocity errors using a Proportional-Derivative (PD) controller.
The module supports multiple formation flying modes:
- Perch: Fixed LVLH offset with zero relative velocity
- Stationary Ellipse: Closed elliptical orbit with no drift
- Walking Ellipse: Elliptical orbit with along-track drift
- Teardrop: Asymmetric approach-and-retreat trajectory
Properties
| Declared | Description |
|---|---|
| AccelerationCommand_LVLH | Current acceleration command in LVLH frame [m/s²]. This is a read-onlyproperty that reflects the output of the PD controller. |
| AlignmentGateAngle | Mating-axis alignment [deg] that must be met before final closure whenis true. |
| AlignmentGateRoll | Clocking alignment [deg] that must be met before final closure.Default 180 accepts any roll. |
| ApproachAcceleration | Acceleration/deceleration magnitude [m/s²] for the trapezoidal profile.Only used when MaxApproachSpeed is positive. Defaults to 0.01 if zero. |
| ApproachPhase | Current phase of the trapezoidal approach profile. |
| ApproachSegmentStartTime | Simulation time [s] when the bar approach segment started, or -1 if not yet started. |
| BarApproachDuration | Bar maneuver approach duration [s]. Time from start of approach to final distance.Used for R- or V- BarApproach mode when MaxApproachSpeed is zero (Hermite profile).When MaxApproachSpeed is positive, duration is computed from the trapezoid profile. |
| BarFinalDistance | Final approach distance on the R-bar or V-bar in LVLH [m] away from the target. Used for RBarApproach mode; |
| BarHoldDistance | Hold approach distance on the R-bar or V-bar in LVLH [m] away from the target. Used for RBarApproach or VBarApproach mode; |
| CorridorRadius | Maximum lateral offset [m] from the target port axis allowed before final closure. |
| DockAfterPerch | When true in Perch mode, after reaching the PerchOffset and satisfying holdtolerances (and optional PerchHoldDwell), a second approach segment is startedfrom PerchOffset to the origin (0,0,0) for final docking capture. |
| ForceDeadband | Force deadband [N]. When positive, sets ForceRequest_N to zero if thecommanded force magnitude is below this threshold. Used to quiet thrustersduring coast and hold phases. Zero disables deadband (legacy behavior). |
| HoldAxisPositionTolerance | Position tolerance [m] for Y and Z (R-bar) or X and Z (V-bar) in LVLH. The approach segment starts only when the chaser is on the bar axis for the mode. |
| HoldPhaseIntegralMultiplier | During R-bar or V-bar hold (before approach starts), the integral gain on the axis being nulled(Y for R-bar, X for V-bar) is multiplied by this factor. Values > 1 help the controller achievetighter axis position/velocity tolerances so approach can start with smaller RBarAxisPositionToleranceor VBarAxisPositionTolerance. Has no effect after approach start or in other modes. |
| HoldVelocityTolerance | Velocity magnitude tolerance [m/s]. The approach segment starts only when relative velocity magnitude is within this tolerance (null relative velocity). |
| In_BodyMassMsg | Vehicle mass properties message from the chaser spacecraft body.Used to convert acceleration commands to force commands (F = m * a). |
| In_ChaserEphemerisMsg | Chaser spacecraft ephemeris message containing position and velocityin the inertial frame. This is the state of the spacecraft beingcontrolled (the chaser). |
| In_DockingAdapterMsg | Chaser docking adapter telemetry used for port-relative targeting and alignment gates. |
| In_FormationFlyingCommandMsg | Optional command message for external mode requests (e.g. RPO executive retreat). |
| In_PlanetStateMsg | Planet state message containing gravitational parameter and otherplanetary constants needed for orbital calculations. |
| In_SpacecraftStateMsg | Spacecraft state message containing attitude (Sigma_BN) for N→B rotation.Auto-resolved from parent spacecraft if not explicitly set.Used to compute body-frame force request for thruster-based actuators. |
| In_TargetDockingAdapterMsg | Target docking adapter telemetry used for port-relative targeting. |
| In_TargetEphemerisMsg | Target spacecraft ephemeris message containing position and velocityin the inertial frame. This is the state of the reference spacecraft(the target/chief) that the chaser is maintaining formation with. |
| InitialPhase | Initial phase angle on the ellipse for ellipse trajectories [rad].Determines the starting point on the relative orbit. |
| IntegralLimit | Anti-windup limit for position error integral [m·s]. Integral is clamped to ±IntegralLimit per component.Higher values allow the integral to correct larger steady-state errors (e.g. along-track on V-bar hold). |
| IsCoasting | Returns true if currently in a coast phase (zero acceleration reference). |
| Kd | Derivative gain vector for the PD controller. Each componentcorresponds to the radial (x), along-track (y), and cross-track (z)axes in the LVLH frame. Units: [1/s] = [Hz] (acceleration per velocity).Default values are tuned for stable formation flying control:- Base natural frequency: 20x orbital rate (~0.0216 rad/s for 7000 km orbit)- Along-track (y) uses 2x multiplier to counteract orbital drift- Critical damping (ζ=1.0) for optimal response |
| Ki | Integral gain vector (optional). Use to eliminate steady-state position error;Ki.Y (e.g. 2.5e-4) helps R-bar and V-bar holds reach the desired off-axis position.Use only on axes that need nulling (e.g. Y for R-bar hold); integral on the approachaxis can wind up during the approach segment. Units: [1/s³]. |
| Kp | Proportional gain vector for the PD controller. Each componentcorresponds to the radial (x), along-track (y), and cross-track (z)axes in the LVLH frame. Units: [1/s²] = [Hz/s] (acceleration per distance).Default values are tuned for stable formation flying control:- Base natural frequency: 20x orbital rate (~0.0216 rad/s for 7000 km orbit)- Along-track (y) uses 2x multiplier to counteract orbital drift- Critical damping (ζ=1.0) for optimal response |
| MaxApproachSpeed | Maximum approach speed [m/s]. When positive, a trapezoidal velocity profile(accelerate-coast-brake) is used instead of Hermite. Duration is computedfrom the profile. When zero or negative, legacy Hermite profile is used. |
| MaxCrossTrackDistance | Maximum cross-track distance for ellipse trajectories (z-axis amplitudein LVLH frame). Used for Stationary Ellipse, Walking Ellipse, andTeardrop modes. |
| MaxRadialDistance | Maximum radial distance for ellipse trajectories (x-axis amplitudein LVLH frame). Used for Stationary Ellipse, Walking Ellipse, andTeardrop modes. |
| Mode | Current formation flying operating mode. This determines whichreference trajectory generator is active. |
| Out_CommandForceMsg | Command force message output containing the force commandin both inertial (N) and body (B) frames. ForceRequest_N is transformedto inertial frame from LVLH. ForceRequest_B is rotated from N usingthe spacecraft attitude DCM for thruster-based actuators. |
| Out_FormationFlyingMsg | Formation flying status message containing current relative state,reference trajectory, errors, and commanded accelerations. |
| PerchHoldDwell | Dwell time [s] at the perch position before starting the second approachto the origin when DockAfterPerch is true. Prevents starting the dock approachon a single-tick position flicker. Zero means no dwell. |
| PerchOffset | Perch offset position in LVLH frame [m]. Used for Perch mode todefine the fixed position where the chaser should maintain station. |
| PortRelativeApproach | When true, the perch target is computed from the target docking adapter axisrather than a static LVLH . |
| PortStandoffDistance | Distance [m] to hold along the target port axis before final closure.Used when is true and not yet in dock approach. |
| PositionError_LVLH | Current position error in LVLH frame [m]. This is a read-onlyproperty computed as reference - current position. |
| PublishedApproachSegmentStartTime | Bar approach segment start time published on . |
| PublishedBarApproachDuration | Bar approach duration published on . |
| RelativePosition_LVLH | Current relative position in LVLH frame [m]. This is a read-onlyproperty that reflects the computed relative state. |
| RelativeVelocity_LVLH | Current relative velocity in LVLH frame [m/s]. This is a read-onlyproperty that reflects the computed relative state. |
| SemiMajorAxisDifference | Semi-major axis difference (delta-a) for walking ellipse and teardroptrajectories. This creates the along-track drift. Set to zero forstationary ellipse. |
| UseHCWFeedforward | When true, adds full Clohessy-Wiltshire feedforward at the reference state:a_ff = (-3n²x_ref - 2n·vy_ref, +2n·vx_ref, +n²z_ref) so the controller cancelsnatural drift and coupling and can reach/hold the R-bar and V-bar with tight tolerance. |
| VelocityError_LVLH | Current velocity error in LVLH frame [m/s]. This is a read-onlyproperty computed as reference - current velocity. |
| Inherited | Description |
|---|---|
| IsEnabled | Is true if the object is currently enabled. |
| Name | The display name or tag of this object. |
| Parent | The currently attached parent object (if any). |
Methods
| Inherited | Description |
|---|---|
| Disable | Disable the software componentDerived classes should clear any output messages |
| Enable | Enable the software component |
| FindParentWithID | Returns an attached parent that satisfies the specified ID. |
| FindParentWithType | Returns an attached parent that satisfies the specified type. |
| FindRootWithID | Returns a root object that satisfies the specified ID. |
| FindRootWithType | Returns a root object that satisfies the specified type. |