Jump to content

[PART, 1.0.2] Anatid Robotics / MuMech - MechJeb - Autopilot - Historical thread


r4m0n

Recommended Posts

So just wanted to say that the MJ dev build I installed on KSP 1.0.x seems to be doing a much better job in the docking autopilot than the older version of MJ on 0.90; docking seems to go smoothly with much less back-and-forth oscillation, less RCS fuel consumption, and generally less fussiness. Thanks!

You will find that the oscillation you mentioned is due to your RCS thrusters not being in balance, i.e., at the center of mass when they are being used. I, too, thought, that MJ's Auto-Dock had improved between KSP 0.25 and 0.90. Then, I had a docking where tons of monoprop were spent. When I placed the RCS thrusters in the correct location, MJ spent less than 15 monoprop.

When building your rocket, estimate how much fuel you'll have when you're going to dock; right-click the tank and adjust both LF and Oxy sliders. I use a rough guesstimate. Then use the CoM tool to determine where to place the thrusters. Then, use the sliders to set the tank to maximum for LF and Oxy again.

The reason for your current situation is that when the thrusters are not at CoM, and MJ fires a thruster to translate, that causes the vessel to rotate about the CoM axis. MJ then corrects by firing the opposite thruster, which again, causes rotation, which must be corrected. Thus, you see a lot of RCS firing continuously and spending monoprop.

When you have unbalanced RCS thrusters in flight and preparing to dock, you can kinda workaround it with MJ's SMART A.S.S. Turn-off Auto-Docking. Select TGT->(-PAR) This will place your vessel's docking port in parallel alignment with the target docking port. Manually translate with RCS until you are roughly inline with the target port and about 15 meters out. Then, turn on Auto-Docking. You will burn far less monoprop this way instead of letting MJ's Auto-Dock spend it.

Edited by Apollo13
Link to comment
Share on other sites

Well, 6km isn't too horrible, yeah.

You didn't answer the question I had about the bug report on deltaV.

Anyways, my retest of Pol, this time I flew the ship there, so hyperedit wierdness is eliminated.

Craft file (same as the laythe one): http://sta.sh/0cwk610imhq

quicksave and output log: http://sta.sh/0hp3jn778cc

Build 444

Attempt 1:

I used the same coords that I used previously just for consistency.

Turned out to be a replay of the first testing, which is that it went normally until it started doing the tumbling, and I'll note here that I'm using the reliant engine, which doesn't have a gimbal in the first place. When it started doing that tumbling, I tried a whole bunch of things like turning off the SAS, turning off the engine, setting the thrust down as low as I could (5.5%), using just RCS, nothing worked.

Attempt2:

Sent it off to a higher latitude, same results as before.

Attempt 3:

Set the latitude to exactly equator, same results.

Attempt 4:

Did land somewhere, again, same results.

Attempt 5:

I was going to leave it at attempt 4, but then I had an idea, restrict the thrust down to 5.5, it went normally right up to the 700m point where it did the usual. Then I screwed around with a bunch of stuff, then got bored and let it crash.

At the time that I was focused on one of the pieces of the debris (couldn't leave because 'about to crash' or 'moving over terrain'), I noticed that the memory usage had ballooned from 2.something gb up to 3.4gb. I thought it would hold until that debris stopped rolling downhill, but the game crashed before that. So, there is a memory leak somewhere, but I don't know if MJ is responsible.

Crashlog, it didn't put in the output log for some reason, but it's the same as the one with the quicksave: http://sta.sh/01ilnsxpd4ej

Mods that I have in this copied and pasted branchoff KSP main directory:

exceptiondetector

hangar extender

MJ

GCmonitor

KJR

KER

Hyperedit

Kerbokatz utilities (it's just the DisableTempGauges.dll)

StockBugfixModules

KAC

config that applies MJ to all command modules

Edit: Checked out build 445 and it definetly lands a whole lot better, tons better actually. :)

Also, I noticed it giving this exception when it popped the drogue chutes and stopped when it popped the regular ones. Probably related to not having a chute sim. Going to check out Pol and see if 445 changed anything, no idea why MJ is having such a problem there.


ArgumentException: OrbitExtensions.NextTimeOfRadius: given radius of 607064.948160461 is never achieved: o.PeR = 3980.40564491902 and o.ApR = 604839.870936338
at MuMech.OrbitExtensions.NextTimeOfRadius (.Orbit o, Double UT, Double radius) [0x00000] in <filename unknown>:0

at MuMech.MechJebModuleLandingAutopilot.ComputeCourseCorrection (Boolean allowPrograde) [0x00000] in <filename unknown>:0

at MuMech.Landing.CoastToDeceleration.Drive (.FlightCtrlState s) [0x00000] in <filename unknown>:0

at MuMech.AutopilotModule.Drive (.FlightCtrlState s) [0x00000] in <filename unknown>:0
UnityEngine.Debug:Internal_LogException(Exception, Object)
UnityEngine.Debug:LogException(Exception)
MuMech.AutopilotModule:Drive(FlightCtrlState)
MuMech.MechJebModuleLandingAutopilot:Drive(FlightCtrlState)
MuMech.MechJebCore:Drive(FlightCtrlState)
MuMech.MechJebCore:OnFlyByWire(FlightCtrlState)
Vessel:FeedInputFeed()
FlightInputHandler:FixedUpdate()

(Filename: Line: -1)

Edited by smjjames
Link to comment
Share on other sites

Is this working on 1.0.2?

- - - Updated - - -

The MechJeb case is supposed to be weightless and dragless, but the new aero treats weightless parts differently, however, that's really all I know. No idea how the new aero would treat dragless parts.

I'm using a config that applies MJ to all command parts, so I can't give any observation on the drag since I don't use the case.

Try what daawgees suggested though.

Where can I find that config?

- - - Updated - - -

Quick question: how can I use Mechjeb to get a satellite into a particular orbit for a contract? I've been using the AN/DN to line up my inclination during ascent, but I don't know how to line them up exactly beyond eyeballing when to launch and hoping I get lucky. You can't seem to set the designated orbits as a target and inclination changes in orbit use up far too much dV, so any suggestions?

I don't have it on right now but if I remember correctly, one of the modes is called Rendezvous Planner or something along those lines. In that mode one of the options allows you to match inclinations. And maybe there might be a similar option in the Maneuver Planner mode. Hope this helps. You have to set your target first. Edit: Never mind, I thought you were talking about rendezvousing with another ship.:P

Link to comment
Share on other sites

Is this working on 1.0.2?

- - - Updated - - -

Where can I find that config?

If by working you mean compatible, yes.

As for the config, it's in various places in the thread but I can give you it. Just copy and paste the below bit of code onto notepad, and save as a .cfg into the gamedata folder. Module Manager is required.


@PART
[*]:HAS[@MODULE[ModuleCommand],!MODULE[MechJebCore]]:Final
{
MODULE
{
name = MechJebCore
}
}

MJ is still having problems with Pol, seems like it's overshooting itself into positive vertical velocity while killing horizontial velocity. Turning off the engine and using monoprop mostly works though, until you run out of monoprop.

Edited by smjjames
Link to comment
Share on other sites

You didn't answer the question I had about the bug report on deltaV.

The code in MJ is a bit newer that the current KER. I used the next version by Padishar so it may account for the diffs.

In the future I'll have to integrate with a mods that do different launch sites so that I pull the current launch site altitude.

Anyways, my retest of Pol, this time I flew the ship there, so hyperedit wierdness is eliminated.

Frankly if Pol is the only remaining problem then all is fine.

Also, I noticed it giving this exception when it popped the drogue chutes and stopped when it popped the regular ones. Probably related to not having a chute sim. Going to check out Pol and see if 445 changed anything, no idea why MJ is having such a problem there.

Nope, this is an other problem I'll have to solve.

Is this working on 1.0.2?

If you use the dev release

The MechJeb case is supposed to be weightless and dragless, but the new aero treats weightless parts differently, however, that's really all I know. No idea how the new aero would treat dragless parts.

NO

It is not supposed to be weightless and dragless. What did I tell you about doing support in the thread ? If you don't know the answer for sure don't answer !!

Edited by sarbian
Link to comment
Share on other sites

The code in MJ is a bit newer that the current KER. I used the next version by Padishar so it may account for the diffs.

In the future I'll have to integrate with a mods that do different launch sites so that I pull the current launch site altitude.

I will be doing some careful testing of the deltaV calculations later today. I do think there is a problem with the deltaV the game says is required for a node and the amount KER says you have used not matching and I suspect an issue with the flow rate calculations after the changes that were necessary for KSP 1.0.

Link to comment
Share on other sites

Sarbian,

Thank for the updates and all the hard work, It's most appreciated!

I performed a few landing AP tests this morning:

Version 445

Test one - using save from my prev post (75km orbit).

Land at Target (KSC Pad)

Much better decent profile with no tumbling or random burns.

Distance to target rises to ~15km as craft undergoes heat effects (expected from your previous comments) but AP seems to be holding craft at -15.5 degree pitch during decent, this continues until craft hits ground ~15km west of KSC and Status field in AP is blank. There doesn't seem to be any attempt to brake for landing both with and without deploy chutes enabled. Chutes still deploy if option checked though.

Test Two - As above but abort landing and use land somewhere when heat effects start.

Aborting and selecting Land Somewhere pitches craft up to retrograde through heating and mach effects although there is some rocking (this could the AP fighting aero forces).

Normal AP powered decent to ~7km west of KSC.

Test Three - Same craft, Duna, Land at Target. Random point on equator.

Attempt 1 failed due to lack of Dv

Attempt 2 enabled infinite fuel, successful landing 700m from target point.

Test Four - Same craft, back to Kerbin, Use MJ to raise orbit from 75km (hypereditted) to 100km and Land at KSC

Same results as Test One, AP seems to lock on whatever pitch craft is at at end of mach effects and status field is blank, unpowered decent until chute opens ~5km from KSC.

Link to comment
Share on other sites

NO

It is not supposed to be weightless and dragless. What did I tell you about doing support in the thread ? If you don't know the answer for sure don't answer !!

Uh, I was under the impression that it was weightless because in the mouseover in the editor, the mass says 0, even KER says the mass is 0. Not sure where the assumption of it being dragless came from though.

Edit: Oh, looking at the part config, the MJ case actually has a very, very tiny mass. Doesn't look like it's applying drag, according to the config anyway.

The code in MJ is a bit newer that the current KER. I used the next version by Padishar so it may account for the diffs.

In the future I'll have to integrate with a mods that do different launch sites so that I pull the current launch site altitude.

Understood then.

Edited by smjjames
Link to comment
Share on other sites

I have a weird problem that I suspect is mechjeb related. Brakes stop working on my rovers after while, even if I turn rover autopilot off (turn of stability control of course) the brakes simply fail to respond, anyone experience this?

Link to comment
Share on other sites

Edit: Oh, looking at the part config, the MJ case actually has a very, very tiny mass. Doesn't look like it's applying drag, according to the config anyway.

Drag in 1.0 has nothing to do with any of the dragXXX parameters of the cfg.

Link to comment
Share on other sites

Great updates to a required mod. Is there any way to completely switch off solar panels being deployed? I found when ships dock, for some reason panels are automatically deployed. I prefer to manually deploy them since I tend to break them because I forget before undocking.

Link to comment
Share on other sites

Sarbian, Like some others have said, I don't post much but without your work - I don't think I'd be playing KSP because MechJeb makes this game infinitely more enjoyable!

I have a question though - when I do a launch to rendezvous - more often than not at the end of the auto-warp and countdown it won't launch the ship, I have to do it manually. It'll just sit there and wait for me. A bug? Auto-staging is turned on.

Link to comment
Share on other sites

Err, I looked into that in the past and I can remember what was the cause. I think it was that the current code won't stage if the first stage has launch clamp but I would have to check.

Link to comment
Share on other sites

I couldn't find an answer to this in-thread, so I apologize if anyone has asked this. I've downloaded the most recent patches etc, and the MechJeb modules and parts show up in the VAB. However, when I attempt to place them on my vehicle, they do not attach. I've heavily modified the game, but as far as I know I've kept everything compatible with MJ2. Has anyone else seen this issue?

Link to comment
Share on other sites

Another problem I have found while roving is that sometimes the MJ speedometer goes haywire and reports erroneous speeds and the only fix is to top, save and reload.

Link to comment
Share on other sites

I couldn't find an answer to this in-thread, so I apologize if anyone has asked this. I've downloaded the most recent patches etc, and the MechJeb modules and parts show up in the VAB. However, when I attempt to place them on my vehicle, they do not attach. I've heavily modified the game, but as far as I know I've kept everything compatible with MJ2. Has anyone else seen this issue?

This doesn't solve the problem but does shove it under a rug for another day:

Have you tried using the StockPlugins ModuleManager configs? it's not updated but has been working fine for me (i only extracted the StockMJ folder though).

Instead of adding a part to your craft it adds the MechJeb functionality to all command modules. I don't think it's cheaty as it still respects the same R&D requirements MechJeb does, but does help reduce part load on your crafts.

Link to comment
Share on other sites

Been a while since I have played the game, so this might be an issue with me doing it wrong, but..

I have a rocket with two liquid boosters attached with radial decouplers. The booster's engines and the first stage's engine are set to fire in in stage one. Stage two has only the decouplers for the boosters. Stage three detaches the first stage and fires the second stage up to continue on it's way to orbit.

My problem is I thought when the boosters run out of fuel that mechjeb would fire the decouplers and drop the boosters using autostaging. At least that's how I remember it working last time I played. Instead I have to hit the space bar or it will continue flying the rocket carrying the boosters until the main stage is spent and then it auto stages to the next stage with fuel in the sequence.

What am I doing wrong?

Stock KSP 1.0.2 and the latest dev mechjeb .dll. No other mods installed yet.

Link to comment
Share on other sites

Been a while since I have played the game, so this might be an issue with me doing it wrong, but..

I have a rocket with two liquid boosters attached with radial decouplers. The booster's engines and the first stage's engine are set to fire in in stage one. Stage two has only the decouplers for the boosters. Stage three detaches the first stage and fires the second stage up to continue on it's way to orbit.

My problem is I thought when the boosters run out of fuel that mechjeb would fire the decouplers and drop the boosters using autostaging. At least that's how I remember it working last time I played. Instead I have to hit the space bar or it will continue flying the rocket carrying the boosters until the main stage is spent and then it auto stages to the next stage with fuel in the sequence.

What am I doing wrong?

Stock KSP 1.0.2 and the latest dev mechjeb .dll. No other mods installed yet.

Holy crap long time no see sojourner, does your first stage use clamps?

Link to comment
Share on other sites

Hey guys... question re: the ascent autopilot on the current dev build (445)....

I'm confused as to whether the ascent profiles are working correctly or not. To make a long story short, in a career game I have an early-ish stock rocket with the basic "Swivel" engine. Ascent profile is more or less default -- 15km start, 75km end, shape is 50%ish, 100 m/s speed. Rocket is small, so fairly high TWR and fairly high COG (not high enough to cause significant instability, though).

The issue: It appears that the gravity turn starts at the lesser of the input speed or the input altitude. With this smallish rocket, speed is the first mark hit by a longshot. (The craft is at 100 m/s by about 5000m, give or take.) The gravity turn starts. The result I expected is that the gravity turn progresses based on the shape from that point until the target end altitude. What actually happens is that the turn progresses, it appears, based on something else. I can't tell if its speed, or % of desired final orbital altitude (as determined by current apoapsis), or what. I wind up with a craft that's finishing its gravity turn at about 35,000 m, and is at the desired final orbital angle -- i.e. pretty close to horizontal -- and is accelerating to hit the desired apoapsis. 35km is a low atmospheric density region... but it ain't zero. I'm getting frictional heat generation, inefficiency in the overall ascent profile, etc.

If I set the gravity turn starting speed to be something higher than what I expect to be flying at 15km altitude.... perfect gravity turns.

So tl;dr I'm not sure if this is a bug or a feature, and thought I'd report it even though I've applied my own fix.

Link to comment
Share on other sites

T I don't think it's cheaty as it still respects the same R&D requirements MechJeb does, but does help reduce part load on your crafts.

Speaking of R&D why do I have all MJ options on a pure, fresh, stock game with only MJ installed.

I am in career mode and when i get to "Flight control" and the first unlock i get everything. Does anyone have the same problem?

Edit:

note to self: "first read some pages back, then post." It apears that I am not the only one

Edited by Mighty1
Link to comment
Share on other sites

Guest
This topic is now closed to further replies.
×
×
  • Create New...