주요 콘텐츠

setupControlStates

Class: Aero.FixedWing.State
Namespace: Aero

Set up control states for Aero.FixedWing.State object

Syntax

state = setupControlStates(state,aircraft)

Description

state = setupControlStates(state,aircraft) initializes the control states in state by creating an Aero.Aircraft.ControlState object for each controllable surface and thrust defined in aircraft.

Input Arguments

expand all

Aero.FixedWing.State object for which to set up control states, specified as a scalar.

Aero.FixedWing object that contains controllable surface and thrust definitions, specified as a scalar.

Output Arguments

expand all

Modified Aero.FixedWing.State object, returned as a scalar.

Data Types: double

Examples

expand all

Initialize the control and command states on a cruise state.

[C182, CruiseState] = astC182();
CruiseState = setupControlStates(CruiseState,C182);
CruiseState.ControlStates
ans=1×4 ControlState array with properties:
    Position
    MaximumValue
    MinimumValue
    DependsOn
    Settable
    Properties

CruiseState.ControlStates(1)
ans = 
  ControlState with properties:

        Position: 0
    MaximumValue: 0.3491
    MinimumValue: -0.3491
       DependsOn: [""    ""]
        Settable: on
      Properties: [1×1 Aero.Aircraft.Properties]

Version History

Introduced in R2021a