finalized raden launch
wip landing script
This commit is contained in:
@@ -1,28 +1,47 @@
|
||||
run "library/lib_math".
|
||||
run "library/lib_vessel_utils".
|
||||
|
||||
local athmoAccelTarget is 600.
|
||||
|
||||
CORE:PART:GETMODULE("kOSProcessor"):DOEVENT("Open Terminal").
|
||||
|
||||
clearScreen.
|
||||
BRAKES on.
|
||||
print "Waiting for engine ignition".
|
||||
WaitForEngineStart().
|
||||
|
||||
print "Preparing to launch".
|
||||
from { local c is 5.} until c = 0 step {set c to c - 1.} do {
|
||||
print c.
|
||||
wait 1.
|
||||
}
|
||||
clearScreen.
|
||||
print "Launching!".
|
||||
lock throttle to 100.
|
||||
lock steering to heading(90, 0, 0).
|
||||
// stage.
|
||||
lock throttle to 1.
|
||||
lock steering to heading(90, 1).
|
||||
brakes off.
|
||||
sas off.
|
||||
|
||||
print "Phase: Takeoff".
|
||||
wait until surfaceSpeed > 140.
|
||||
|
||||
wait until groundspeed > 120.
|
||||
|
||||
print "Phase: Rotate".
|
||||
lock steering to heading(90, 3, 0).
|
||||
wait 1.
|
||||
lock steering to heading(90, 4).
|
||||
wait until altitude > 80.
|
||||
print "Gear up".
|
||||
gear off.
|
||||
|
||||
print "Phase: Athmospheric Acceleration".
|
||||
lock steering to heading(90, 3, 0).
|
||||
wait until groundspeed > athmoAccelTarget.
|
||||
|
||||
print "Phase: Athmospheric Climb".
|
||||
lock steering to heading(90, 15, 0).
|
||||
wait until altitude > 20000.
|
||||
lock tgtPitch to Map(groundSpeed, athmoAccelTarget, 1600, 3, 15).
|
||||
lock steering to heading(90, tgtPitch, 0).
|
||||
|
||||
wait until altitude > 25000.
|
||||
|
||||
print "Phase: Mode Switch".
|
||||
ag1 on. //Switch engine mode
|
||||
@@ -31,20 +50,28 @@ wait until apoapsis > 80000.
|
||||
|
||||
print "Phase: Sub-Orbital Coast".
|
||||
lock throttle to 0.
|
||||
lock steering to prograde.
|
||||
set warpmode to "physics".
|
||||
set warp to 1.
|
||||
|
||||
wait until altitude > 70000.
|
||||
print "Deploying Solar".
|
||||
panels on. //deploy solar
|
||||
print "Opening Docking Port".
|
||||
ag3 on. //open docking port
|
||||
lock steering to heading(90, 0, 0).
|
||||
set warp to 0.
|
||||
set warpmode to "rails".
|
||||
set warp to 1.
|
||||
|
||||
when altitude > 70000 then {
|
||||
print "Deploying Solar".
|
||||
ag2 on. //deploy solar
|
||||
print "Opening Docking Port".
|
||||
ag3 on. //open docking port
|
||||
}
|
||||
|
||||
lock distToApo to apoapsis - altitude.
|
||||
wait until distToApo < 100.
|
||||
wait until distToApo < 500.
|
||||
|
||||
print "Phase: Circularize".
|
||||
lock throttle to 100.
|
||||
wait until periapsis > 79000.
|
||||
lock steering to heading(90, 0, 0).
|
||||
rcs on.
|
||||
lock throttle to 1.
|
||||
wait until periapsis > 75000.
|
||||
unlock throttle.
|
||||
|
||||
print "In orbit. Releasing controls".
|
||||
|
||||
Reference in New Issue
Block a user