Description | Example | Return message | Group

SetAttitude File

Reset attitude to read from an external attitude file

Syntax

SetAttitude <VehObjectPath> File "<FilePath>" [<Blocking>] [{SaveFile | SaveLocally}]

Description

The SetAttitude File command loads the attitude profile of a vehicle from a specified attitude file (*.a).

Attitude information at a given time may be added to an existing attitude profile using the AddAttitude Quat, AddAttitude Euler, AddAttitude ECIYPR or AddAttitude YPR commands.

ParameterDescription
Filename "<FilePath>"Indicate the path and filename of the attitude (*.a) file that you wish to load. The file must be in the correct STK attitude file format. Refer to the Attitude File Format (*.a) STK Help topic for more information.

"<FilePath>" can be the path to a file on your local drive or the path to a file on an SDF server. See Specifying Paths for "<SDFFilePath>" syntax information.

Blocking <Blocking>This optional parameter is an integer greater than 0 indicating the blocking factor to use to control memory allocation for new attitude points.
Save {File | Locally}Enter Save File to have the Save command to write the entire attitude to the file specified by the "<FilePath>".

Using the Save File option will overwrite the original attitude file unless the original file is renamed.

Enter Save Locally to have the Save command to write the entire attitude to the user's current Scenario directory the next time you save the vehicle for which the attitude was specified. When the vehicle is reloaded into STK, the local version of the attitude (*.a) file will be used.

Use the Save Locally option when you want a vehicle's external attitude (*.a) file to be saved in the same directory as the vehicle with which it is associated regardless of where on your computer system the external attitude (*.a) file originally resided. This makes it much easier to locate the attitude (*.a) files that you have associated with a specific vehicle.

StartTime {TimeInstant}Specify a time to override the start time in the file.

For valid {TimeInstant} values see Time Options.

Examples

Set the attitude profile for the Shuttle Satellite from C:\stk\User\stkData\SpinNadir.a:

SetAttitude */Satellite/Shuttle File Filename "C:\stk\User\stkData\SpinNadir.a"

Set the attitude profile for the Missile ratpack1 from "c:\FtpDir\missilex.a". If a Save command is then issued the attitude file specified will be written back to its original location and overwrite the existing attitude file:

SetAttitude */Missile/ratpack1 File Filename"c:\FtpDir\missilex.a" Save File

Set the attitude profile for the Missile ratpack1 from "c:\FtpDir\missilex.a". If a Save command is then issued the attitude file will be written to the user's Scenario directory:

SetAttitude */Missile/ratpack1 File Filename "c:\FtpDir\missilex.a" Save Locally

Set the attitude profile for the Shuttle Satellite from C:\stk\User\stkData\SpinNadir.a, specifying the start time:

SetAttitude */Satellite/Shuttle File Filename "C:\stk\User\stkData\SpinNadir.a" StartTime "Satellite/Test153 EphemerisStartTime Time Instant"

Return message

If activated, Connect returns an acknowledgement message.

Group membership

This command belongs to the following group(s):

Vehicles

Version

11.5