- This document explains the overall structure of the S2E.
- The following figure shows the structure of the S2E.
- The highest layer of the structure of S2E is the
Simulation Case
, which is defined in thesrc/simulation/case/simulation_case.cpp
. - The
Simulation Case
always hasSimulation Configuration
andGlobal Environment
.Simulation Configuration
has basic information on the interface of the simulation, such aslog output
andinitialize input
information.Global Environment
is defined as the common environment for the whole simulation case. It includes time, celestial information, star catalog, and GNSS satellite position.
- Users can make their
Simulation Case
by inheriting theSimulation Case
base class and adding simulation target objects (e.g., spacecraft and ground station) for their demand. - The defined simulation objects can use the information of
Simulation Configuration
andGlobal Environment
.
- An essential simulation object is the
Spacecraft
class. Spacecraft
class has the following features to simulate the behavior of spacecraft in space.Structure
- This class handles the structure information of the spacecraft, such as the mass, the inertia tensor, surface information, and residual magnetic moment.
- The information is used to calculate disturbance and propagate dynamics.
LocalEnvironment
- This class handles space environment information around the spacecraft, such as air density, magnetic field, solar energy, and eclipse.
- The information is used to calculate disturbance and emulate environment sensors.
Disturbance
- This class handles disturbances forces(accelerations) and torques.
- The information is used to propagate dynamics.
Dynamics
- This class handles dynamics calculation for attitude, orbit, and thermal.
- This is the core of the numerical simulation.
Components
- This class emulates the behavior of components mounted on the spacecraft. The spacecraft can measure the physical quantities and generate control output by using the components.
- This class is not defined in the Spacecraft base class, and users have to define it themselves.
- Users can add multiple spacecraft into their
SimulationCase
, and these spacecraft can communicate via communication components.
- TBW
- The structure of the initializing files follows the above figure.
simulation_base.ini
sets the parameters forSimulationCase
, and file paths to each simulation object.satellite.ini
sets the parameters forSpacecraft
and file paths to each component.
Note: the structure of components is implemented now. So the following figure is just an idea, and it may be modified.
- Each component can communicate with other components. - All components have a power wire, and power control components control the switch.