Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
36 changes: 36 additions & 0 deletions StkAutomation/CSharp/SendEphemerisToSTK/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
# Send To STK

This utility will allow you to add a new option to your Windows right-click > Send To menu for you to send files directly to STK.

This was originally designed to send Satellite Ephemeris files to STK (by the ComSpOC Operators) but has been expanded to include TLE and TCE files.

Recent updates have been added to now include GPX files imported as waypoints on a ground vehicle. This utility can continue to be extended with additional file types/extensions.

## How to Install and Use

* Build the project to create the executable
* Move the built executable "SendEphemerisToSTK.exe" to a permanent location of your choice
* Place a shortcut to that executable here: %AppData%/Microsoft/Windows/SendTo
* Rename that shortcut "STK"
* Right click on any Ephemeris File and on the Send To menu you will see an STK option.





## License

The Code Examples in this repository are licensed under the AGI Code Examples License Agreement, which is included in this repository as [License.pdf](License.pdf).

## Redistribution
If You redistribute the Code Examples, in whole or in part, You must provide a copy of this License Agreement to any other recipient of the Code Examples, and include the following copyright notice:

© 2020 Analytical Graphics, Inc.

## What if I have questions about STK

Contact [email protected] with any questions regarding STK, STK Engine or any other AGI products.

AGI's ready-to-use STK and ODTK families of products, enterprise software, and developer tools help customers deliver digital engineering value and make better-informed decisions in a mission context at any stage in the program lifecycle: from planning and design to training and operations.

For more information, please visit the [AGI website](https://www.agi.com "AGI's Homepage").
Original file line number Diff line number Diff line change
Expand Up @@ -117,18 +117,19 @@ public static void ReadGpx(string gpxFilePath, out string errors)
_stkRoot.ExecuteCommand("Units_Set * Connect DateFormat ISO-YMD");
foreach (XmlNode xnode in nl)
{
string name = xnode.Name;
string lat = xnode.Attributes["lat"].Value;
string lon = xnode.Attributes["lon"].Value;
string alt = xnode["ele"].InnerText;
string time = xnode["time"].InnerText.Replace("Z",string.Empty);
try
{
string name = xnode.Name;
string lat = xnode.Attributes["lat"].Value;
string lon = xnode.Attributes["lon"].Value;
string alt = xnode["ele"].InnerText;
string time = xnode["time"].InnerText.Replace("Z",string.Empty);

_stkRoot.ExecuteCommand($"AddWaypoint */GroundVehicle/{gvName} DetVelFromTime {lat} {lon} {alt} {time}");
}
catch
{
errors += $"Error adding waypoint, most likely a duplicate point {lat} {lon} {alt} {time} {Environment.NewLine}";
errors += $"Error adding waypoint {xnode.InnerText}{Environment.NewLine}";
}
}

Expand Down
2 changes: 0 additions & 2 deletions StkAutomation/CSharp/SendEphemerisToSTK/readme.txt

This file was deleted.