Jump to content

[1.12.x] Anatid Robotics / MuMech - MechJeb - Autopilot - [2.14.3] [4th March 2023]


sarbian

Recommended Posts

No logs => No support. If you can not find the time to provide the info I need to diagnose your problem do not expect I will find the time to reply to your post.

(The thread was lost after an incident on the forum. The really old thread from even before is here)

Anatid Robotics and Multiversal Mechatronics proudly presents the first flight assistant autopilot: MechJeb

I would like to thank CardBoardBoxProcessor and Keptin for their amazing MechJeb models.

Sarbian is the current maintainer.

mj2.1_release.png

Current version: 2.14.3

2.14.3

  • Localization fix
  • fix related to radian vs degree
  • New infoItems about the Target ( MeanAnomaly, TrueLongitude, LDN, TimeToAn, TimeToDN ) that nay be of use to Principia players
  • More work on PVG

2.14.1

  • Fix a bug with infoItem in the editor

2.14.0

  • UI refactor of the Ascent Guidance
  • Improved Principia node Execution
  • Performance fix and optimization
  • Stuff

2.12.0

2.11.0

  • Landing AP fixes and improvements
  • Plane landing AP fixes and improvements
  • Rover AP fixes and improvements
  • Updated Chinese loc

2.10.0

 
  • Compact UI now the default
  • Spanish translation
  • Russian  translation
  • Updated Chinese translation
  • Principia node execution (WIP)
  • Many PVG updates
  • Plane Landing and autopilot improvements
  • Stuff I missed in the commit logs
  • Various fix and improvements

2.9.2

  • Localization support with included Simplified Chinese Localization
  • Improved integrator and Brent's Method for maneuvers
  • Fix the ApR and SMA maneuvers
  • Support Multi-Node maneuvers
  • Various fixes and code improvements
  • Stuff I forgot

2.9.1

  • ReflectionTypeLoadException will now list the DLLs that are the actual source of the exception in the log. 
  • tinygrox on GithUb took on the huge work required to add localization to MJ. People who want to translate MJ should have a look at this file
  • The DeltaV window now has buttons to hide the empty stages and switch between s and dhms for burn time

2.9.0

  • Built for KSP 1.8 
  • Added "Land somewhere" and "Land target" KSP Action
  • Improvements for remote vessel control
  • Overhaul of bi-impulsive transfer planner
  • Improvements for PVG ascent
  • Porkchop plot can now be translated with WASD and arrow keys
  • Unlock all MJ techs by creating a MechJebUnlocked folder in GameData
  • And a bunch of fix. See here for details

2.8.4

  • Built for KSP 1.7 

2.8.3

  • fix for launch-to-plane
  • PVG stabilization fixes
  • Fix xenon delta V

2.8.2

  • Primer Vector Guidance
  • bring back simple coplanar transfer option
  • make the hybrid controller the default controller 
  • Incorporate "MechJebAndEngineerForAll" style functionality
  • adding ∆v display to flight recorder
  • add steering/drag/gravity loss to flight recorder
  • Add Apoapsis and Periapsis to scripting conditions
  • Fixes

2.8.0

2.7.4

  • Change the "Online Manual" link to the github wiki since the old site is gone
  • Updated the landing sites list with the one from @El Sancho
  • Improved the landing sim precision (aka "write code with both eyes opened")
  • A bunch of small fixes

2.7.3

  • Fix the fuels sim in the editor with surface attached decouplers...

2.7.2

  • Fix for the engine plate autostagging
  • Fix for the scripting module SAS controls
  • Fix the MOI code to handle "control from here" properly. Should help with Docking

2.7.1

  • KSP 1.4.1
  • auto-deploy antennas
  • Plane landing improvements
  • Rover AP fix
  • bugs fix

2.7.0

  • New launch profiles selection, including one that is the classic "KSP ascent", a "PEG" clone for RSS and the classic MJ profile
  • Scripting module Update with new features (you ll have too look)
  • New spaceplane landing AP
  • A rework of the advanced transfer code
  • A lot of FuelSim (dV) fix
  • Better FAR integration
  • A bunch of fix and UI improvement

2.6.1

  • Compatibility with KSP 1.3
  • Fix and improvement for the transfer calculator
  • Specific orbital energy, potential energy, and kinetic energy Orbit Info items added
  • Ascent AP improved circularization burn inclination error
  • Ullage/RO improvement
  • Remove a large recurrent allocation that froze the game every few seconds  from some
  • Flight recorder UI improvement and export
  • Plenty of fixes
  • Thanks to all contributors

2.6.0

  • Compatibility for KSP 1.2.2
  • Scripting module by @SPD13
  • Auto RCS Ullage for RO by Lamont (whose name here I forgot..)
  • Option to move the menu on any side of the screen
  • A bunch of fixes and minor features 
  • stuff I most likely forgot about

2.5.8

  • Compatibility for KSP 1.1.3
  • Add ‘At the highest AN/DN’ and ‘At the nearest AN/DN’ time selectors for inclination and plane maneuvers.
  • Add a setting for the node executor lead time
  • Custom Windows new Overlay mode
  • MJ Pod disabled since it does not work properly with the current leg code
  • FAR compatibility included
  • lots of fix

2.5.7

  • 1.1
  • Stuff
  • More stuff

2.5.6

  • Launch Inclination improvement
  • Improvement of the Landing Sim
  • Predicted Trajectory overlay in the flight view (in Landing AP window)
  • Ascent AP Fairings autodeploy with support for Procedural Fairings
  • RSS Mode swtich in the settings windows. For now it prevents engine shutdown when disabling the ascent AP
  • Greatly lowered memory garbage generated. May improve frame rate on some PC
  • A lot of bug fix

2.5.5

  • Flight Recorder Graph module
  • Education mode option (rename SmartASS to SmartACS)  see MM patch here https://raw.githubusercontent.com/MuMech/MechJeb2/master/MechJebEdu.cfg
  • Improvement to the Attitude control
  • Dynamic Pressure limiter to replace the now useless terminal velocity
  • Attitude control speed limiter to save some RCS
  • Add "periapsis in target SoI" InfoItems 
  • Add "minimum DV required for capture by target" InfoItems 
  • Add "Docking guidance: Angular velocity" infoitem
  • Add electric throttle limiter to avoid empty batteries on ion powered craft

2.5.6

  • 1.1 release. Be aware that the Pod leg are not working and will generate fantom force
  • Other stuff but I don't have time to write the change log atm

Download 2.14.3.0 for KSP 1.12.x

Download 2.12.3.0 for KSP 1.8 to 1.12

Download 2.12.0 for KSP 1.11.x

Download 2.11.0 for KSP 1.10.x

Download 2.9.2 for KSP 1.8.x and 1.9.x

Download 2.8.4 for KSP 1.7.x

Download 2.8.3 for KSP 1.6.x

Download 2.7.4 for KSP 1.4.1

Download 2.7.0 for KSP 1.3

Download 2.6.0 or Dev #698 for KSP 1.2.2

Source code available here. LGPL3 license for MechJeb code. MIT for SmoothFoundations & UnityToolbag

You can also get the latest dev builds here.

Usage instructions:

Use the button on the right side of the screen to access MechJeb window selection interface, and click on the buttons to activate the windows. The windows can be dragged anywhere on screen, and their position is saved and reused among all rockets.

Manual

Useful links and companions mods

 

  • Manual
  • MechJeb for All or MechJeb Embedded Universal to add MechJeb to all the probe and command module and use it without the parts. Also allow to unlock all MechJeb features from the start in career mode
  • Small MechJeb touchscreen case an alternative model for the part
  • An other model
  • A video from speedio explaining the basic operations you can do with it (outdated but still useful):
  • Another video, this one by tncm for AR202, but still very useful:
  • Adding "eduMode = true" to the module will rename the SmartASS to SmartACS. You can use this Module Manager patch to do it.

 

How to Install

Manual install : unzip the zip in KSP GameData directory. You should have something that looks like that :

 

  • KSP
    • GameData
      • MechJeb2
        • Icons
        • Parts
        • Plugins

         

 

CKAN has all the release of MechJeb.

If you want the dev version of MechJeb then :

  • open CKAN settings (Settings => CKAN Settings)
  • press the New button
  • select the MechJeb-dev line, click OK and exit the options.
  • refresh
  • select "Mechjeb2 - DEV RELEASE" in the list and then "Go to Change" to install

Common problems

  • The MechJeb menu is not showing. First make sure you have the part on your ship (AR202 case in the Control section). Some windows protection and anti-virus can sometimes block KSP from loading MechJeb. You should install KSP outside the C:\Program Files (x86) directory. Steam has an option to change the install directory of a game or you can just copy the directory somewhere else.
  • Some function are not present in career. Some function require to unlock some specific node in the Research and Development tree. Some other also require to upgrade the tracking station to level 2 (Game code restriction we can't do much about)

Bugs

There is two version of MechJeb available

  • The main version that we release once or twice per KSP version
  • The dev version that gets a a couple or release per month, week or even days. It may also have more bugs than the main version since new features are added

The dev release gets all the new features and bugs fix and the main version gets them when a new KSP version is released (or major bugs requires it). If you experience a bug the first thing I advise is to try the dev release. You can read the change log of the dev release here.

If your bugs don't seems to be fixed then please open a new ticket on the project tracker. Don't forget to include a link to your log (see here to find it and how to share it) and the version of Mechjeb you where using (shown in MechJeb Menu).

Please send Suggestions/Bug reports here: https://github.com/MuMech/MechJeb2/issues

Edited by sarbian
Link to comment
Share on other sites

Ok i've got a giant "How the *Beep* do i do this with mechjeb question. Had an ongoing science mission go a little fubar. I didn't put enough comms on it :blush:. Now it's a little over a 100 days from Duna and i need to rush a relay there.. Given Kerbin and Duna's positions the only way to beat the probe there will be to send the relay on a reciprocal of Duna's orbit. I've got a craft that assuming nothing goes wrong on the way to orbit will have enough d/v to do the job, (>20kps), but i'm not entirely sure how to tell mechjeb to do that...

Link to comment
Share on other sites

2 hours ago, Carl said:

Ok i've got a giant "How the *Beep* do i do this with mechjeb question. Had an ongoing science mission go a little fubar. I didn't put enough comms on it :blush:. Now it's a little over a 100 days from Duna and i need to rush a relay there.. Given Kerbin and Duna's positions the only way to beat the probe there will be to send the relay on a reciprocal of Duna's orbit. I've got a craft that assuming nothing goes wrong on the way to orbit will have enough d/v to do the job, (>20kps), but i'm not entirely sure how to tell mechjeb to do that...

I don't have the game up and running, but can't you use Advanced Transfer to Another planet, set Duna as the target and then click the ASAP button?

Link to comment
Share on other sites

Sadly not, just checked it, (thanks for the tip though, never investigated that as the manual has nothing on it), but it still tries to plot a prograde trajectory, (which is fair enough, retrograde needs more dv than is remotely sane, your velocity at encounter with duna would be 14kps and you have to shed 9kps of kerbin orbital velocity first to get that).

Link to comment
Share on other sites

Cheers, to be fair the hard part is getting a retrograde sun orbit setup, once you haver that setting up a retrograde intercept isn't too hard. I just don't know how to setup a retrograde sun orbit from kerbin SOI.

Link to comment
Share on other sites

1 hour ago, Carl said:

Cheers, to be fair the hard part is getting a retrograde sun orbit setup, once you haver that setting up a retrograde intercept isn't too hard. I just don't know how to setup a retrograde sun orbit from kerbin SOI.

Can't think that would be the best way to achieve a retrograde Sun orbit. Kerbin travels at ~ 9196 m/s around Sun (of course, prograde). You can of course setup a retrograde burn relative to Sun while still in Kerbin's SoI (need to burn so to increase Ap in the opposite direction of where Kerbin moves, meaning burn prograde in Kerbin's LKO when Sun rises above the horizon) but why waste 9196 m/s DV that way? (that would only be useful in case you want to dive into Sun, and even in that case would be better to save DV using a slingshot from Eve or other bodies). Going farther away from Sun however reduces orbital speed (Jool speed is on average ~ 4120 m/s) therefore is easier to set retrograde Sun orbit by first raising Ap. And then, intercepting a massive body as Jool at the correct angle (get a Pe in front and higher of Jool) provides a lot of DV to make that retrograde orbit.

Link to comment
Share on other sites

Well i managed via messing with the node editor and setting a manual node to get it to work, turns out i need even more d/v than i thought, joy.

 

Thats led me to a new issue, built a multi-stage ion for the obscene dv, but can't get MJ to recognise ion stages beyond the first. What do you need from me serbin? Not sure what if any logs you'll need on this one.

 

Image of probe:

VbFX5gA.png

Quote

Can't think that would be the best way to achieve a retrograde Sun orbit. Kerbin travels at ~ 9196 m/s around Sun (of course, prograde). You can of course setup a retrograde burn relative to Sun while still in Kerbin's SoI (need to burn so to increase Ap in the opposite direction of where Kerbin moves, meaning burn prograde in Kerbin's LKO when Sun rises above the horizon) but why waste 9196 m/s DV that way? (that would only be useful in case you want to dive into Sun, and even in that case would be better to save DV using a slingshot from Eve or other bodies). Going farther away from Sun however reduces orbital speed (Jool speed is on average ~ 4120 m/s) therefore is easier to set retrograde Sun orbit by first raising Ap. And then, intercepting a massive body as Jool at the correct angle (get a Pe in front and higher of Jool) provides a lot of DV to make that retrograde orbit.

Don't have the time, image of the geometries, (probe i'm trying to beat there is the one down near eve with the red comms line):

MzP2tRH.png

A direct retrograde shot from kerbin is the only trajectory that will get me there in time, and thats a maybe.

Link to comment
Share on other sites

Thing is i'd never touched the controls for that before except my accident, so i had no clue how to work it, i just experimented till stuff happened.

 

Also ethier KSP or MJ dosen;t like retrograde trajectories as anytime i reduced the dv to try and fine tun the encounter it deselected duna as a target. Not sure weather that's KSP or MJ though. Not sue if maneuver nodes even exist in stock, i get them impression they do but i could be way off base, again if serbian needs logs just tell me which logs he wants, i assume MJ has several given all the modules and VAb vs SPH vs flight, plus KSP's own logs that may or may not be applicable.

 

Still managed to do it, but annoying. Currently trying the burn without having proper craft dv info, will se how it goes, have a save to revert to if needed from pre launchpad.

Edited by Carl
Link to comment
Share on other sites

Minor note, figured out the odd d/v display. Xenon does not appear to respect cross feed settings, so it was all one stage from the PoV of fuel consumption. Joy. Back to the drawing board.

Edited by Carl
Link to comment
Share on other sites

I've recently had a power outage twice (I haven't got any UPS) while playing KSP and both times my mechjeb configuration got messed up - all the custom windows I've made were gone and I was unable to recover from this using mechjeb's interface. I had to remove MJ completely, install it again and customize again - quite a pain as I like setting up orbit and surface windows in a similar fashion to KER's hud displays. I prefer MJ's font to KER's as during a landing bigger font is easier to quickly read.

It's not a big deal as power outages are extremely rare for me yet all the other plugins maintained their configs (admitedly very few mods are as customizable as mechjeb is). I the end I simply backed up the main config file to avoid this again.

Regardles, MJ is a truly magnificent piece of code and is extremely useful as it allows to automate some of the boring stuff. Great work!

Link to comment
Share on other sites

Issue with the changes to settings save in #683...

First time opening KSP all the MJ windows are in the top left corner.

Re-arranging them in the right place and then returning to the VAB then launching again and all the windows are back in the top lift corner.

In other words, it looks as though the window positions settings aren't now being saved at all. 

Link to comment
Share on other sites

4 hours ago, sarbian said:

I made some change in the dev release to fix a recurrent memory allocation that may also help with those corrupted config on power loss. MJ was saving its config way too often.

So it's intentional that #683 resetted all custom windows i assume?

Link to comment
Share on other sites

Sarbian, I have a suggestion, my inclination is to believe that it wouldn't be extremely difficult, but I'm no expert.

Could the Trajectorie's API be used to provide accurate landing predictions in atmosphere (i.e. with FAR?)

Link to comment
Share on other sites

Ok, this was actually quick. It should work now.

11 minutes ago, dlrk said:

Sarbian, I have a suggestion, my inclination is to believe that it wouldn't be extremely difficult, but I'm no expert.

Could the Trajectorie's API be used to provide accurate landing predictions in atmosphere (i.e. with FAR?)

Sure. Just give me a version of Trajectorie's API than can run in a thread.

Link to comment
Share on other sites

MJ requires the math to be done fast because it need the trajectory updated often for the landing AP to work. To do that the lending sim is done in a thread. 

Trajectories code cannot run in a thread so I would have to run it each frame and the frame rate would plumel. 

 

The problem is not me copying an other mod code. I know perfectly what need to be done for FAR (and stock support for lift) to work. But I don't see how to do it fast enough or without copying half of FAR code.

Link to comment
Share on other sites

I'd like to understand this a bit better. Trajectorie's calculates the trajectory live without a frame rate issue, and people have written KOS scripts that use the Trajectories API for landings. What keeps MJ from doing the same thing?

Link to comment
Share on other sites

1 hour ago, sarbian said:

It is not... I ll have a look later today or tomorrow.

Content, position or both ?

Actually it's even worse than i thought, the default VAB windows aren't even on and nothing i customize seems to save. 
Current situation: All i have in the VAB are "Custom Window Editor" and "Settings", so i create a Delta-V window with the preset for it. Exit to space center, back in VAB, the dV window isn't listed. 

Link to comment
Share on other sites

1 hour ago, Mokmo said:

Actually it's even worse than i thought, the default VAB windows aren't even on and nothing i customize seems to save. 
Current situation: All i have in the VAB are "Custom Window Editor" and "Settings", so i create a Delta-V window with the preset for it. Exit to space center, back in VAB, the dV window isn't listed. 

Same here. Outside VAB/SPH all windows work. (At least those that I tried.) Inside VAB/SPH only 'settings' and 'custom'.

Link to comment
Share on other sites

I came here to ask about the same thing others have noted: window positions aren't saved at all, so far as I can see. After every scene change, the window positions all default back to the upper left corner. In addition, in the VAB (haven't checked the SPH), the dV and Vessel Info options aren't available at all.

I also have a secondary issue but it is probably something @sarbianis already aware of, but I want to confirm that before I try to duplicate it exhaustively and provide logs. In the Landing Guidance, MJ does what a friend of mine describes as "stutter warping" - after the initial de-orbit burn, when in prior versions, MJ would warp a good ways through the descent, go back to real-time and make a correction, then maybe warp again before final descent and landing, now MJ instead seems to cycle between 1X, 2X, 5X and maybe 10X all within a matter of seconds, constantly adjusting the speed of the warp but never really just settling down, warping, unwarping and landing. The accuracy (on Minmus) is phenomenal, but it take a much longer amount of real-time to perform a routine vacuum body landing. Is this problem already known or is it others have experienced?

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...