To help you get started modeling and simulating CubeSats, the CubeSat Simulation Library Add-On provides a project and model on the Simulink® Start Page. If you have not yet done so, install the Aerospace Blockset™ CubeSat Simulation Library. For more information, see Getting Started with CubeSats.
CubeSat Vehicle Model template — A model template (CubeSat
Simulation Project
) that illustrates how to propagate and
visualize CubeSat trajectories using the CubeSat
Vehicle block. The Spherical Harmonic Gravity Model
block performs the orbit propagation. The preconfigured pointing modes set in
the CubeSat Vehicle block control the attitude.
CubeSat Simulation Project — A ready-to-simulate project (CubeSat
Simulation Project
) that illustrates how to create a detailed
CubeSat system design in Simulink by adding in detailed vehicle components to the provided
framework.
The template model is a ready-to-simulate example that contains a CubeSat Vehicle block with visualization using Simulink 3D Animation™.
Start the CubeSat Vehicle Model template.
Click Create Model.
The CubeSat Vehicle block models a simple CubeSat vehicle that you can use as is, with the CubeSat Vehicle block configured to use the initial orbital state as a set of Keplerian orbital elements.
The model uses the Spherical Harmonic Gravity Model block to provide the vehicle gravity for the CubeSat.
To familiarize yourself with CubeSats, experiment with the CubeSat Vehicle block settings.
On the CubeSat Orbit tab of the block, you can optionally use the Input method parameter to change the initial orbital state as a set of:
Position and velocity state vectors in Earth-centered inertial axes
Position and velocity state vectors in Earth-centered Earth-fixed axes
Latitude, longitude, altitude, and velocity of the body with respect to ECEF, expressed in the NED frame
On the CubeSat Attitude tab, you can specify the alignment and constraint vectors to define the CubeSat attitude control.
The CubeSat vehicle first aligns the primary alignment vector with the primary constraint vector. The CubeSat vehicle then attempts to align the secondary alignment vector with the secondary constraint vector as closely as possible without affecting primary alignment.
The CubeSat Altitude tab also lets you choose between preconfigured Earth (Nadir) Earth Pointing (default) and Sun Tracking attitude control modes.
On the Earth Orientation Parameters tab, you can direct the block to include higher order earth orientation parameters while computing vehicle initial conditions.
Run and simulate the model.
To view the output signals from the CubeSat, double-click the Scopes subsystem and open the multiple scopes.
If you have a valid Simulink 3D Animation license, you can also visualize the orbit in the CubeSat Orbit Animation window.
Save a copy of the orbit propagation model. You can use this model for the mission analysis live script.
The CubeSat Vehicle Model template CubeSat Vehicle block uses simple preconfigured orbit and attitude control modes. To model and simulate CubeSat vehicles using your own detailed components, consider the CubeSat Simulation Project from the Simulink Start Page. For more information, see CubeSat Simulation Project
The model is a ready-to-simulate example with visualization using Simulink 3D Animation. This example uses a Vehicle Model subsystem in place of a CubeSat Vehicle block. For a simpler model that illustrates the use of the CubeSat Vehicle block, see CubeSat Vehicle Model Template.
Start the CubeSat Simulation Project.
Click Create Project.
The Vehicle Model subsystem models a CubeSat vehicle that you can use as is.
To create your own more sophisticated satellite models, experiment with the Vehicle Model framework For example, you can replace the perfect thruster model included by default in the actuator subsystem with your own more realistic thruster or reaction wheel model.
To change the orbit trajectory and attitude of the CubeSat, in the Mission Configuration section, double-click the Edit Initial Orbit and Attitude block. These parameters have the same intent as the corresponding parameters as the CubeSat Vehicle block.
Run and simulate the model.
To view the output signals from the CubeSat, double-click the Scopes subsystem and open the multiple scopes.
If you have a license for Simulink 3D Animation, you can also visualize the orbit in an animation window. Double-click the Visualization subsystem and click the Open Simulink 3D Animation window button.
The CubeSat Orbit Animation window opens.
In addition to the existing Aerospace Blockset and Aerospace Toolbox functions, the CubeSat Simulation Library provides utility functions for coordinate transformations. You can use these functions to go between the various initial condition modes of the CubeSat Vehicle block.
Action | Function |
---|---|
Calculate position and velocity vectors in Earth-centered inertial mean-equator mean-equinox | |
Calculate position, velocity, and acceleration vectors in Earth-centered Earth-fixed (ECEF) coordinate system | |
Calculate Greenwich mean and apparent sidereal times | |
Calculate Keplerian orbit elements using geocentric equatorial position and velocity vectors | |
Calculate position and velocity vectors in geocentric equatorial coordinate system using Keplerian orbit elements |
[1] Vallado, D. A. Fundamentals of Astrodynamics and Applications. alg. 1 and eqs. 1-63. New York: McGraw-Hill, 1997.
asbAddOns
| asbCubeSatMissionAnalysis
| Attitude
Profile | CubeSat
Vehicle | ecef2eci
| eci2ecef
| generateAccessTable
| greenwichsrt
| ijk2keplerian
| keplerian2ijk
| Orbit
Propagator