scenarioDataToViz#

Overview#

Demonstrates how to convert spacecraft states, stored in a text file from another program, into Xmera messages using dataFileToViz. These messages are red by vizInterface to save a Vizard compatible data play for offline playback and analysis. In this simulation a servicer is holding a relative position with respect to an uncontrolled satellite. Custom spacecraft models are specified for Vizard in the folder dataForExamples.

The script is found in the folder xmera/examples and executed by using:

python3 scenarioDataToViz.py

The simulation layout is shown in the following illustration. A single simulation process is created which contains both modules.

../_images/test_scenarioDataToViz.svg

When the simulation completes several plots are shown for the MRP norm attitude history and the inertial relative position vector components. A servicer spacecraft approaches a target and holds a specific target-frame fixed location even while the target itself is slowly rotating. The servicer and target orientations are controlled to be the same to prepare for a final docking maneuver. If the data is saved to a Vizard file, then the visualization should look like:

../_images/vizard-DataFile.jpg

Illustration of Simulation Results#

show_plots = True
_images/Scenarios/scenarioDataToViz1.svg _images/Scenarios/scenarioDataToViz2.svg