AscentGuidance#

class MechJeb.AscentGuidance#

The Ascent Guidance window, which flies the vessel to orbit.

Note

See the MechJeb wiki for how to set up this autopilot.

enabled: boolean#

Whether the module is enabled.

Attribute:

Can be read or written

status: string#

The autopilot status, which depends on the selected ascent path.

Attribute:

Read-only, cannot be set

ascent_type: MechJeb.AscentType#

The ascent path.

Attribute:

Can be read or written

settings: MechJeb.AscentSettings#

The Ascent Settings window.

Attribute:

Read-only, cannot be set

pvg_settings: MechJeb.PVGSettings#

The PVG Settings window, with the settings of the MechJeb.AscentType.pvg path.

Attribute:

Read-only, cannot be set

classic_path: MechJeb.ClassicPath#

The Ascent Path Editor window, with the settings of the MechJeb.AscentType.classic path.

Attribute:

Read-only, cannot be set

desired_orbit_altitude: number#

The altitude of the final circular orbit, in meters.

Attribute:

Can be read or written

desired_apoapsis: number#

The target apoapsis, in meters.

Attribute:

Can be read or written

Note

Applies on the MechJeb.AscentType.pvg path.

attach_alt_flag: boolean#

Whether the orbit is attached at MechJeb.AscentGuidance.desired_attach_alt.

Attribute:

Can be read or written

Note

Applies on the MechJeb.AscentType.pvg path, with an early shutoff stage, set by MechJeb.PVGSettings.optimize_stage_flag and MechJeb.PVGSettings.optimize_stage. Without one, MechJeb always attaches the orbit.

desired_attach_alt: number#

The altitude at which the orbit is attached, in meters.

Attribute:

Can be read or written

Note

Applies on the MechJeb.AscentType.pvg path. Requires MechJeb.AscentGuidance.attach_alt_flag, unless there is no early shutoff stage. See MechJeb.PVGSettings.optimize_stage.

desired_fpa: number#

The flight path angle at orbit insertion, in degrees.

Attribute:

Can be read or written

Note

Applies on the MechJeb.AscentType.pvg path, when there is no early shutoff stage. See MechJeb.PVGSettings.optimize_stage.

desired_inclination: number#

The inclination of the final circular orbit, in degrees.

Attribute:

Can be read or written

launch_mode: MechJeb.AscentLaunchMode#

The launch mode, which gives whether the autopilot is waiting for a timed launch.

Attribute:

Read-only, cannot be set

launch_to_rendezvous()#

Launch to rendezvous with the target. Throws an exception if there is no target, or the ascent path is PVG.

launch_phase_angle: number#

The phase angle to the target of a launch to rendezvous, in degrees.

Attribute:

Can be read or written

launch_to_target_plane()#

Launch into the plane of the target. Throws an exception if there is no target.

launch_lan_difference: number#

The difference from the target’s longitude of the ascending node of a launch into the target’s plane, in degrees.

Attribute:

Can be read or written

launch_to_match_lan()#

Launch into the plane of the target, at the time the target’s longitude of the ascending node, less MechJeb.AscentGuidance.launch_lan_difference, passes overhead. Keeps MechJeb.AscentGuidance.desired_inclination. Throws an exception if there is no target, or the ascent path is not MechJeb.AscentType.pvg.

launch_to_lan()#

Launch into the plane with longitude of the ascending node MechJeb.AscentGuidance.desired_lan and inclination MechJeb.AscentGuidance.desired_inclination. Throws an exception if the ascent path is not MechJeb.AscentType.pvg.

desired_lan: number#

The longitude of the ascending node of a launch to a LAN, in degrees. See MechJeb.AscentGuidance:launch_to_lan().

Attribute:

Can be read or written

abort_timed_launch()#

Abort a timed launch that has not started yet. Throws an exception if the launch mode is MechJeb.AscentLaunchMode.unknown.

warp_count_down: number#

The time before a timed launch at which time warp stops, in seconds.

Attribute:

Can be read or written

override_warp_to_plane: boolean#

Whether a timed launch launches at once, rather than at the time it computes.

Attribute:

Can be read or written

class MechJeb.AscentType#

The ascent path. See MechJeb.AscentGuidance.ascent_type.

classic#

The classic ascent path. See MechJeb.AscentGuidance.classic_path.

pvg#

Primer Vector Guidance, for RSS/RO. See MechJeb.AscentGuidance.pvg_settings.

class MechJeb.AscentLaunchMode#

The launch mode of the ascent autopilot. See MechJeb.AscentGuidance.launch_mode.

normal#

The autopilot is not performing a timed launch.

rendezvous#

A timed launch to rendezvous with the target vessel.

target_plane#

A timed launch into the plane of the target.

match_lan#

A timed launch to the target’s longitude of the ascending node. See MechJeb.AscentGuidance:launch_to_match_lan().

lan#

A timed launch to a longitude of the ascending node. See MechJeb.AscentGuidance:launch_to_lan().

unknown#

A timed launch of another kind, started from MechJeb’s window.

AscentSettings#

class MechJeb.AscentSettings#

The Ascent Settings window, which holds the settings shared by the ascent paths.

force_roll: boolean#

Whether the autopilot controls the roll.

Attribute:

Can be read or written

vertical_roll: number#

The roll during the vertical climb, in degrees.

Attribute:

Can be read or written

turn_roll: number#

The roll during the turn, in degrees.

Attribute:

Can be read or written

roll_altitude: number#

The altitude above which the autopilot controls the roll, in meters.

Attribute:

Can be read or written

limit_angle_of_attack: boolean#

Whether to limit the angle of attack.

Attribute:

Can be read or written

Note

Applies on the MechJeb.AscentType.classic path.

max_angle_of_attack: number#

The largest angle of attack, in degrees.

Attribute:

Can be read or written

angle_of_attack_limit_fadeout_pressure: number#

The dynamic pressure below which the angle of attack limit fades out, in pascals.

Attribute:

Can be read or written

limiting_angle_of_attack: boolean#

Whether the angle of attack limit is limiting the steering.

Attribute:

Read-only, cannot be set

current_max_angle_of_attack: number#

The largest angle of attack the limit allows now, in degrees.

Attribute:

Read-only, cannot be set

corrective_steering: boolean#

Whether the autopilot steers by the velocity vector rather than the position vector.

Attribute:

Can be read or written

Note

It is more accurate, though large craft may do better without it. Applies on the MechJeb.AscentType.classic path.

corrective_steering_gain: number#

The gain of the corrective steering.

Attribute:

Can be read or written

autostage: boolean#

Whether the autopilot stages when the current stage runs out of fuel.

Attribute:

Can be read or written

staging: MechJeb.Autostaging#

The autostaging settings. The same object as MechJeb.Utilities.staging.

Attribute:

Read-only, cannot be set

thrust: MechJeb.ThrustLimiter#

The throttle limiters. The same object as MechJeb.Utilities.thrust.

Attribute:

Read-only, cannot be set

autodeploy_solar_panels: boolean#

Whether to deploy the solar panels when the ascent finishes.

Attribute:

Can be read or written

auto_deploy_antennas: boolean#

Whether to deploy the antennas when the ascent finishes.

Attribute:

Can be read or written

autowarp: boolean#

Whether to warp time during the ascent.

Attribute:

Can be read or written

Note

The same setting as MechJeb.ManeuverPlanner.autowarp.

skip_circularization: boolean#

Whether to skip the circularization burn.

Attribute:

Can be read or written

PVGSettings#

class MechJeb.PVGSettings#

The PVG Settings window, which holds the settings of the Primer Vector Guidance ascent path.

dynamic_pressure_trigger: number#

The dynamic pressure below which guidance starts, in pascals.

Attribute:

Can be read or written

fixed_coast: boolean#

Whether the coast has a fixed length.

Attribute:

Can be read or written

fixed_coast_length: number#

The length of the coast, in seconds.

Attribute:

Can be read or written

min_delta_v: number#

The smallest delta-v of a stage that guidance plans with, in \(\mathrm{m/s}\).

Attribute:

Can be read or written

last_stage: number#

The last stage that guidance plans with.

Attribute:

Can be read or written

optimize_stage_flag: boolean#

Whether guidance may shut off MechJeb.PVGSettings.optimize_stage early.

Attribute:

Can be read or written

optimize_stage: number#

The stage that guidance may shut off early.

Attribute:

Can be read or written

Note

Requires MechJeb.PVGSettings.optimize_stage_flag. -1 is no stage.

unguided_stages_flag: boolean#

Whether guidance leaves MechJeb.PVGSettings.unguided_stages unguided.

Attribute:

Can be read or written

unguided_stages: List#

The stages that guidance leaves unguided.

Attribute:

Can be read or written

coast_stage_flag: boolean#

Whether guidance coasts in MechJeb.PVGSettings.coast_stage.

Attribute:

Can be read or written

coast_stage: number#

The stage before or after which guidance coasts.

Attribute:

Can be read or written

coast_before_flag: boolean#

Whether the coast comes before MechJeb.PVGSettings.coast_stage, rather than after it.

Attribute:

Can be read or written

ullage_lead_time: number#

The time before an ignition at which RCS settles the propellant, in seconds.

Attribute:

Can be read or written

spinup_stage_flag: boolean#

Whether to spin up the vessel before MechJeb.PVGSettings.spinup_stage.

Attribute:

Can be read or written

spinup_stage: number#

The stage before which to spin up the vessel.

Attribute:

Can be read or written

spinup_angular_velocity: number#

The angular velocity of the spin-up, in \(\mathrm{rad/s}\).

Attribute:

Can be read or written

Note

Requires MechJeb.PVGSettings.spinup_stage_flag. MechJeb’s window shows it in revolutions per minute.

spinup_lead_time: number#

The time before staging at which the spin-up starts, in seconds.

Attribute:

Can be read or written

limit_qa: number#

The limit on dynamic pressure times angle of attack, in \(\mathrm{Pa \cdot rad}\).

Attribute:

Can be read or written

Note

MechJeb clamps it to between 0 and 10000.

pitch_rate: number#

The pitch rate of the booster, in \(\mathrm{deg/s}\).

Attribute:

Can be read or written

pitch_start_velocity: number#

The speed at which the booster starts to pitch over, in \(\mathrm{m/s}\).

Attribute:

Can be read or written

staging_trigger: number#

The stage after which guidance starts.

Attribute:

Can be read or written

staging_trigger_flag: boolean#

Whether guidance starts after MechJeb.PVGSettings.staging_trigger.

Attribute:

Can be read or written

ClassicPath#

class MechJeb.ClassicPath#

The Ascent Path Editor window, which holds the settings of the classic ascent path.

auto_path: boolean#

Whether the autopilot chooses the turn altitudes and speed.

Attribute:

Can be read or written

auto_turn_percent: number#

The altitude at which an automatic turn starts, as a fraction of the height of the atmosphere.

Attribute:

Can be read or written

auto_turn_speed_factor: number#

The factor that sets the speed at which an automatic turn starts.

Attribute:

Can be read or written

auto_turn_start_altitude: number#

The altitude at which an automatic turn starts, in meters.

Attribute:

Read-only, cannot be set

auto_turn_start_velocity: number#

The speed at which an automatic turn starts, in \(\mathrm{m/s}\).

Attribute:

Read-only, cannot be set

auto_turn_end_altitude: number#

The altitude at which an automatic turn ends, in meters.

Attribute:

Read-only, cannot be set

turn_start_altitude: number#

The altitude at which the turn starts, in meters.

Attribute:

Can be read or written

turn_start_velocity: number#

The speed at which the turn starts, in \(\mathrm{m/s}\).

Attribute:

Can be read or written

turn_end_altitude: number#

The altitude at which the turn ends, in meters.

Attribute:

Can be read or written

turn_end_angle: number#

The final flight path angle, in degrees.

Attribute:

Can be read or written

turn_shape_exponent: number#

The steepness of the turn, between 0 and 1.

Attribute:

Can be read or written