This repository houses an example Aerie orbiter mission model, built from a collection of spacecraft subsystem models that can be configured, customized, and then run within Aerie by a mission. By combining these models together with other models, such as the Aerie Simple Power Model and Aerie Simple Data Model, a mission can build up an integrated spacecraft model quickly to perform mission trades and analyses.
The models in this repository were originally derived from models created for the Blackbird planner, a java-based planning system developed at NASA's Jet Propulsion Lab (JPL). There is also code included here for you to export and translate model data to the free 3D visualization software Cosmographia.
The following models are included in this repository:
- Geometry
- DSN (in work)
- Guidance Navigation and Control (in work)
Below you'll find short descriptions of each model and brief instructions on how to configure and run them. For general instructions on how to compile models, see the instructions in the README of mission model template repo. If you'd like to learn how to write PlanDev models, please see our modeling tutorial.
This product was formerly known as Aerie and is now named PlanDev. While we've updated most documentation and external references, some legacy mentions of the old product name may remain as we complete the transition.
What to know:
- The planning product, including modeling, simulation, scheduling and constraint-checking, is now named PlanDev
- The sequencing product, including the sequence editor, workspaces, and actions, is now named SeqDev
- All features and functionality remain the same
- Currently, repository names, package names and other internal code references will retain their existing names, and deployment/migration procedures have not changed
- In a future release, our repository and/or package names may change. If so, this will be communicated to users via release notes and normal communication channels
For the latest documentation, visit: PlanDev Documentation
-
Install OpenJDK Temurin LTS, if you don't already have it. If you're on macOS, you can install brew instead and then use the following command to install JDK 21:
brew install --cask temurin@21
-
Install Git Large File Storage. This repository uses Git LFS to manage large files, which you can install from git-lfs.com or with
brew:brew install git-lfs
If you have never run LFS before, you must run the command
git lfs installonce after running the installer. -
You need to create a personal access token in your GitHub account that includes the
read-packagesscope, so that you can download the PlanDev Maven packages from the GitHub Maven package registry. Keep track of the username and token after you generate it.
To start working with this model:
-
Clone this repository and
cdto it -
Generate a
.envfile from the template by running:cp .env.template .env -
Fill in the missing variables in the
.envfile with your Github username and access token from the Prerequisites section above:# in .env file GITHUB_USER="your_github_username_here" GITHUB_TOKEN="your_personal_access_token"
-
Run
git lfs pullto download large files in the repo, like the SPICE kernel. -
Run
docker compose up -dto run PlanDev locally - after it starts up, it should be accessible on http://localhost:80
Once PlanDev is up and running with an empty database, you can use the following steps to populate it with a working mission model, constraints, and scheduling procedures:
The main mission model code is in the missionmodel folder. To build the mission model JAR (initially or after any changes to it), run:
./gradlew :missionmodel:build --refresh-dependenciesThis will create the file 'missionmodel/build/libs/missionmodel.jar, which you can upload to PlanDev using the UI or API.
Once you have built the mission model and uploaded it to PlanDev (via the "Models" page), you can use it to create Plans.
This repo contains an example Plan to demonstrate the model's capabilities: Example_MarsSat_Plan.json. To use it,
go to the "Plans" page on PlanDev and use the Import button to select & import this JSON file. Set the "Model" to your
uploaded model, and create the plan.
A custom view for this plan is also included - access the view menu in the top right of the PlanDev and import the file
MarsSat_Overview_View.json
To build scheduling procedures or procedural constraints, the following will be your process every time you iterate on these procedures
./gradlew scheduling:build
./gradlew scheduling:buildAllProcedureJarsor
./gradlew constraints:build
./gradlew constraints:buildAllProcedureJarsYour procedure jars will then be in build/libs/OriginalSourceCodeFileName.jar of either the scheduling or constraints directories.
The geometry model provides an easy way for you to compute geometric quantities based on SPICE kernel data based on your spacecraft's trajectory. Example quantities that the model can compute include spacecraft to body distance and speed, sub-spacecraft illumination angles, Sun-body-spacecraft angle, orbit period and inclination, body half-angle size, and more! There are also some "spawner" activities within the model that will schedule activities to represent spacecraft eclipses, occultations, and periapsis and apoapsis times.
Since the geometry model requires SPICE data to work, you'll need to include kernels for your spacecraft trajectory and any other bodies to which you are computing relative geometry. There are some example kernels included in this repository for the Juno mission you can use to try out the model. When you are ready to use your own kernels, you will want to update the latest_meta_kernel.tm file to point to your kernels.
Note: In order for PlanDev to read SPICE files, you must mount a folder on your filesystem so that it’s shared with the
Docker containers in which PlanDev runs. The docker-compose.yml file in this repo already does this for you, so if you
start PlanDev from that file and store your kernels in the spice/kernels directory, you shouldn't have
to do anything special.
Bodies and geometric quantities you want to calculate are all configured in the default_geometry_config.json,
which gets bundled into the mission model jar when you compile the model.
Finally, in order to point the model to the right spacecraft to compute geometry against, you need to tell the model the SPICE ID of that spacecraft. You can either do this via simulation configuration after you have uploaded the model or change the default value in the Configuration class.
A special thanks to Chris Lawler and Flora Ridenhour, the original developers of the Blackbird planner, who have graciously provided the Blackbird multi-mission models to the PlanDev team as a starting point for the models in this repository.