Commands¶
In bluesky, a stack command is a text that uses a custom domain-specific language (DSL). The idea is to be able to easily replay commands.
minisky largely supports the same DSL, but makes some tweaks, most notably the requirement of specifying explicit units.
This DSL is used by scenario files (.scn) and the interactive console, for example:
> CRE KL001 B738 52 4 90 FL100 250KT[CAS]
> KL001 ALT FL200
> POS KL001
To run commands at a specified simulation time, specify a timestamp for each command:
00:00:00.00> CRE KL001 B738 52 4 90 FL100 250KT[CAS]
00:00:00.00> KL001 ADDWPT HELEN FL100 250KT[CAS]
00:00:10.00> KL001 ALT FL200
00:30:00.00> QUIT
Run with:
uv run minisky run --scenario example.scn --speed 10
Here, --speed 10 changes how quickly simulation time is paced against wall-clock time (see basics for more information).
runtime.commands.stack("KL001 ALT FL200")
runtime.simulation.step()
See the complete stack command reference for all supported commands. If you are a plugin developer, see the guide on adding commands.
Warning
We strongly recommend using the typed MiniSky Python API instead of the DSL, so mistakes can be caught by static type checkers (e.g. pyright) instead of at runtime. The Python API is also usually much easier to work with.