Instructions for Building Aerie Mission Model Template and DSN Multi-Mission Utilities and Using DSN Scripts
Click here for Aerie Mission Model Template Installation, Building, and Testing Instructions.
Click here for DSN Multi Mission Utilities Installation, Building, and Testing Instructions.
Click here for DSN Multi-Mission Utilities SAF and VP Export and Import Python script instructions.
Click here for DSN Multi-Mission Utilities azimuth and elevation Python script instructions.
This repo provides an Aerie mission model template for a fictitious mission called FireSat. It is meant as a starting point for building a new mission model in Aerie.
-
Install OpenJDK Temurin LTS. If you're on macOS, you can install brew instead and then use the following command to install JDK 19:
brew install --cask temurin19
Make sure you update your
JAVA_HOME
environment variable. For example with Zsh you can update your.zshrc
with:export JAVA_HOME="/Library/Java/JavaVirtualMachines/temurin-19.jdk/Contents/Home"
-
Set
GITHUB_USER
andGITHUB_TOKEN
environment variables to your credentials (first you need to create a personal access token in your GitHub account) so you can download the Aerie Maven packages from the GitHub Maven package registry. For example with Zsh you can update your.zshrc
to set the variables with:export GITHUB_USER="" export GITHUB_TOKEN=""
To build a mission model JAR you can do:
./gradlew build --refresh-dependencies # Outputs 'build/libs/dsn.jar'
You can then upload the JAR to Aerie using either the UI or API. If you want to just try the model without building it yourself you can download it here.
To run unit tests under ./src/test against your mission model you can do:
./gradlew test
This repo provides DSN multi-mission utilities. It provides a prototype of geometric computations for View Periods, and the ingestion and export of SAF and VP files.
- Install venv for Python 3.9+ and setup a new virtual enviornment in this directory.
cd mulit-mission-utilities-DSN/python_scripts
python3 -m venv .venv
- Activate Virtual Environment for Python project
source .venv/bin/activate
- Install project dependencies
pip3 install -r requirements.txt
- Activate Virtual Environment
source .venv/bin/activate
- Run PyTests to automatically setup tests in ./tests directory
pytest
- PIP can be used with the setup.py script to install libaerie system-wide.
- Python build can be used to create a PyPi compliant package for upload to a python mirror
pip3 install -e
python3 -m build
import_activities.py can scan DSN View Period and DSN Station Allocation files and add them activities in an existing Aerie Installation.
python3 import_activities.py --help
usage: import_activities.py [-h] [-p VP] [-s SA] [-a CONNECTION_STRING] [-b BUFFER] [-v VERBOSE] plan_id
positional arguments:
plan_id plan ID to ingest activity directives into
options:
-h, --help show this help message and exit
-p VP, --vp_file VP Filepath to a DSN View Period file
-s SA, --sa_file SA Filepath to a DSN Station Allocation file
-a CONNECTION_STRING, --connection_string CONNECTION_STRING
http://<ip_address>:<port> connection string to graphql database
-b BUFFER, --buffer_length BUFFER
Integer length of the buffer used to parse products, use if parsing large files
-v VERBOSE, --verbose VERBOSE
Increased debug output
python3 import_activities.py 25 -p INPUT.VP -s INPUT.SAF # Ingesting one file of each type
python3 import_activities.py 25 -p INPUT1.VP -p INPUT2.VP # Ingesting multiple files of one type
python3 import_activities.py 25 -p ./INPUT1.VP -p ./INPUT2.VP -s ./INPUT1.SAF -s ./INPUT2.SAF -b 500 # Ingesting multiple files of both types inserting 500 activities at a time
It's recommended to set the -b option to a value less then 1000 as a large amount of event data can stress GraphQL
export_activities.py can read an Aerie plan and will write the activities to a single DSN View Period and DSN Station Allocation files.
python3 export_activities.py --help
usage: export_activities.py [-h] [-p VP] [-s SA] [-m MISSION_NAME] [-S SPACECRAFT_NAME] [-d DSN_ID] [-a CONNECTION_STRING] [-b BUFFER] [-v VERBOSE] plan_id
positional arguments:
plan_id plan ID to ingest activity directives into
options:
-h, --help show this help message and exit
-p VP, --vp_file VP Filepath to export target DSN View Period file
-s SA, --sa_file SA Filepath to export target DSN Station Allocation file
-m MISSION_NAME, --mission_name MISSION_NAME
Mission Name for VP and SAF header
-S SPACECRAFT_NAME, --spacecraft_name SPACECRAFT_NAME
Spacecraft Name for VP and SAF header
-d DSN_ID, --dsn_id DSN_ID
Integer DSN spacecraft number for VP and SAF header
-a CONNECTION_STRING, --connection_string CONNECTION_STRING
http://<ip_address>:<port> connection string to graphql database
-b BUFFER, --buffer_length BUFFER
Integer length of the buffer used to parse products, use if parsing large files
-v VERBOSE, --verbose VERBOSE
Increased debug output
python3 export_activities.py 25 -p EXPORT..VP -s EXPORT.SAF # Export files for plan ID 25
Use the az_el.py script to calculate the azimuth and elevation of DSSs from the p.o.v. of your spacecraft. This script is currently set up to compute the azimuth, elevation, and view periods for multiple DSSs from the point of view of the spacecraft Europa-Clipper, between May 2nd, 2028 and May 5th, 2028.
- Update the
al_el_vp.py
script as needed (see below). - Run the
al_el_vp.py
script. Comment out theview_pr_driver(config)
line. (Running the script as is will result in both azimuth and elevation values being computed for DSN antennas, as well as View Periods being computed. For now, we only want to compute azimuth and elevation.) - Build the jar.
- Load jar into Aerie UI.
- Simulate the plan in the UI.
- View the azimuth and elevation resources in the timeline to ensure the data was computed and included in the jar.
Computing View Period windows for Multiple DSS and Viewing View Period Activity Instances in the Aerie UI
(This should be done after loading a jar into the UI.)
- Comment out the
el_az_driver(config)
line in the script. - Update the script with the plan id. Make any configuration updates as needed (see below).
- Run the
el_az_driver(config)
script - Simulate the plan in the UI.
- View the View Period Activity instances to ensure the data was computed and posted.
- Update the
al_el_vp.py
script to reflect your mission's time format, plan start, and plan end. - Update the step size, which reflects the seconds between time steps for computations.
- Update the
chosen_dss
list to reflect the stations for which you want to compute azimuth, elevation, or view periods. - Update the spacecraft ID
- Update the plan ID (this can be determined using the UI).
- Update the specific kernels for your mission here.
The Geometry Finder Spice functions compute the View Period for the specified DSSs and spacecraft. The parameters that can be updated are Spice parameters. The definitions and usage of the Spice functions in this script can be found here (note the python library, SpiceyPy was used in this script):
You can use the provided Meta-Kernel and kernels in this repository, or you can use your own. There are the kernels needed for the geometric computations.
- Leap Seconds (.tls)
- Solar System Ephemeris (.bsp)
- Spacecraft Ephemeris (.bsp)
- DSN Ephemeris (.bsp)
- Earth Topocentric Frame Kernel (.tf)
- NAIF PCK (Planetary Constants Kernel) (.tpc)
- Earth binary PCK (Earth orientation data) (.bpc)
- Meta-Kernel (.tm)