Table of Contents

Class Vehicle

Namespace
NominalSystems.Universe
Assembly
NominalSystems.Universe.dll

[Nominal] A ground vehicle is able to move along the ground of a planet and be controlled. The vehicle can have a reference frame for which the movement is relative to.


public class Vehicle : GroundObject
Inheritance
Vehicle
Derived
Extension Methods

Constructors

Vehicle()

Default constructor

protected Vehicle()

Fields

Out_VehicleStateMsg

The output message storing the state of the vehicle and the current origin and position data.

public VehicleStateMessage? Out_VehicleStateMsg

Field Value

VehicleStateMessage

Properties

Coordinates

The coordinates of the vehicle in the origin coordinate system. This is relative to the 0, 0, 0 location and always along the surface of the planet, where the Y axis is the origin's north direction, the X axis is 90 degrees clockwise from the north direction, and the Z axis is up towards the zenith from the ground.

[Unit(UnitType.METRE)]
[Metadata(ContainedIn = "Out_VehicleStateMsg")]
public Vector3 Coordinates { get; set; }

Property Value

Vector3

EulerAngles

The euler angles, as a roll, pitch, yaw set, of the vehicle in degrees.

[Unit(UnitType.DEGREE)]
public Vector3 EulerAngles { get; set; }

Property Value

Vector3

Origin

The origin of the coordinate system. This defines where 0, 0, 0 is located on the planet surface.

[Unit(UnitType.NONE)]
public GeodeticElements Origin { get; set; }

Property Value

GeodeticElements

OriginNorth

The northing of the origin of the coordinate system. This defines the angle, relative to true north along the surface, where 0, 0, 0 is located. This is a clockwise angle between 0 and 360 degrees.

[Unit(UnitType.DEGREE)]
[Metadata(IsAdvanced = true, ContainedIn = "Out_VehicleStateMsg")]
public double OriginNorth { get; set; }

Property Value

double

Quaternion

The quaternion that defines the rotation of the vehicle in the origin reference frame.

[Unit(UnitType.NONE)]
[Metadata(IsAdvanced = true, ContainedIn = "Out_VehicleStateMsg")]
public Vector4 Quaternion { get; set; }

Property Value

Vector4

VehicleForwardAxis

Defines the forward axis relative to the vehicle and the ground. This will be in the Y axis of the coordinate frame, in the origin coordinate frame.

[Unit(UnitType.NONE)]
[Metadata(IsAdvanced = true)]
public Vector3 VehicleForwardAxis { get; }

Property Value

Vector3

VehicleRightAxis

Defines the right axis relative to the vehicle and the ground. This will be in the X axis of the coordinate frame, in the origin coordinate frame.

[Unit(UnitType.NONE)]
[Metadata(IsAdvanced = true)]
public Vector3 VehicleRightAxis { get; }

Property Value

Vector3

VehicleUpAxis

Defines the forward axis relative to the vehicle and the ground. This will be in the Y axis of the coordinate frame, in the origin coordinate frame.

[Unit(UnitType.NONE)]
[Metadata(IsAdvanced = true)]
public Vector3 VehicleUpAxis { get; }

Property Value

Vector3

Velocity

The velocity of the vehicle's body (B) in the origin (O) coordinate system, where the Y axis is the origin's north direction, the X axis is 90 degrees clockwise from the north direction, and the Z axis is up towards the zenith from the ground.

[Unit(UnitType.METRE_PER_SECOND)]
[Metadata(ContainedIn = "Out_VehicleStateMsg")]
public Vector3 Velocity { get; set; }

Property Value

Vector3

Methods

CalculateRotation()

Calculates the rotation matrix from the planet-centered planet-fixed frame that will be relative to the inertial origin.

protected override DCM CalculateRotation()

Returns

DCM

The DCM

OnBegin(double)

Called when the object is beginning ticking for the first time. This is when the simulation calls the very first tick and will run before the update call.

protected override void OnBegin(double time)

Parameters

time double

[s] Current time of the simulation before the tick

OnCreate()

Called when the 'Component' is created from the controller.

protected override void OnCreate()

OnUpdate(double, double)

Called when the object should update from the simulation tick. This will take in a time and a step, where the time is the time of the clock before updating the object.

protected override void OnUpdate(double time, double step)

Parameters

time double

[s] Current time of the simulation before the update

step double

[s] The time-step to update during this tick

PitchDegrees(double)

Pitches the local transform by some rotation along the X axis.

public override void PitchDegrees(double degrees)

Parameters

degrees double

[deg] The angle to pitch by

RollDegrees(double)

Rolls the local transform by some rotation along the Y axis.

public override void RollDegrees(double degrees)

Parameters

degrees double

[deg] The angle to roll by

YawDegrees(double)

Yaws the local transform by some rotation along the Z axis.

public override void YawDegrees(double degrees)

Parameters

degrees double

[deg] The angle to yaw by