Description
SGP4 Automatic Update properties.
Public Properties
FileSource | A file to be used as the element source, containing GP data (either TLEs or CCSDS OMM content). |
OnlineSource | AGI server to be used as the element source. |
Properties | Get the Automatic Update selection and method. |
SelectedSource | Gets or sets the source type for element updates. |
Example
Set SGP4 to auto-update from file source
[C#] |
---|
propagator.AutoUpdateEnabled = true;
propagator.AutoUpdate.SelectedSource = AgEVeSGP4AutoUpdateSource.eSGP4AutoUpdateSourceFile;
propagator.AutoUpdate.FileSource.Filename = fileUpdateSource;
// Preview TLEs (optional)
// Preview() returns a one dimension string of tles
Array tles = propagator.AutoUpdate.FileSource.Preview();
Regex rx = new Regex(@"^(?[-]?\d+) (?[-]?\d+[.]?\d+) (?[-]?\d+)$");
foreach (object line in tles)
{
Match m = rx.Match(line.ToString());
Console.WriteLine("SCC: {0}, orbit epoch: {1}, rev number: {2}", m.Groups["ssc"], m.Groups["orbitepoch"], m.Groups["revnumber"]);
}
// Propagate
propagator.Propagate();
|
|
Set SGP4 to auto-update from online source
[C#] |
---|
propagator.AutoUpdateEnabled = true;
propagator.AutoUpdate.SelectedSource = AgEVeSGP4AutoUpdateSource.eSGP4AutoUpdateSourceOnline;
// Preview TLEs (optional)
// Preview() returns a one dimension string of tles
Array tles = propagator.AutoUpdate.FileSource.Preview();
Regex rx = new Regex(@"^(?[-]?\d+) (?[-]?\d+[.]?\d+) (?[-]?\d+)$");
foreach (object line in tles)
{
Match m = rx.Match(line.ToString());
Console.WriteLine("SCC: {0}, orbit epoch: {1}, rev number: {2}", m.Groups["ssc"], m.Groups["orbitepoch"], m.Groups["revnumber"]);
}
// Propagate
propagator.Propagate();
|
|
Set SGP4 to auto-update from file source
[Visual Basic .NET] |
---|
propagator.AutoUpdateEnabled = True
propagator.AutoUpdate.SelectedSource = AgEVeSGP4AutoUpdateSource.eSGP4AutoUpdateSourceFile
propagator.AutoUpdate.FileSource.Filename = fileUpdateSource
' Preview TLEs (optional)
' Preview() returns a one dimension string of tles
Dim tles As Array = propagator.AutoUpdate.FileSource.Preview()
Dim rx As New Regex("^(?[-]?\d+) (?[-]?\d+[.]?\d+) (?[-]?\d+)$")
For Each line As Object In tles
Dim m As Match = rx.Match(line.ToString())
Console.WriteLine("SCC: {0}, orbit epoch: {1}, rev number: {2}", m.Groups("ssc"), m.Groups("orbitepoch"), m.Groups("revnumber"))
Next
' Propagate
propagator.Propagate()
|
|
Set SGP4 to auto-update from online source
[Visual Basic .NET] |
---|
propagator.AutoUpdateEnabled = True
propagator.AutoUpdate.SelectedSource = AgEVeSGP4AutoUpdateSource.eSGP4AutoUpdateSourceOnline
' Preview TLEs (optional)
' Preview() returns a one dimension string of tles
Dim tles As Array = propagator.AutoUpdate.FileSource.Preview()
Dim rx As New Regex("^(?[-]?\d+) (?[-]?\d+[.]?\d+) (?[-]?\d+)$")
For Each line As Object In tles
Dim m As Match = rx.Match(line.ToString())
Console.WriteLine("SCC: {0}, orbit epoch: {1}, rev number: {2}", m.Groups("ssc"), m.Groups("orbitepoch"), m.Groups("revnumber"))
Next
' Propagate
propagator.Propagate()
|
|