Skip to content

Docking and Parts

Part and docking directories are a live description of this craft. Inspect before you act. It is the difference between “undock port 0” and “why is the lander suddenly a historical artefact?”

Terminal window
# The compact whole part tree is easiest to search with jq.
cat /sim/vessels/active/parts/json | jq '.[].display_name'
ls /sim/vessels/active/docking
cat /sim/vessels/active/docking/0/docked
cat /sim/vessels/active/docking/0/docked_to
cat /sim/vessels/active/docking/0/pushoff_impulse
# One-shot. Only do this when port 0 is the one you mean.
echo 1 > /sim/vessels/active/docking/0/undock

undock returns EBUSY when the selected port is not docked. pushoff_impulse reports the KSA separation impulse in newton-seconds; its debug override lives under debug/vessels/<id>/docking/<n>/pushoff_impulse and needs debug_namespace.

Next: Closed-loop guidance, where the pieces become an actual flight program.