Jump to content

[0.21.x] KerbCom Avionics 0.3.0.6 Alpha (29 August) - now with video!


ZRM

Recommended Posts

Sorry if this has been mentioned: Despite working fine after upgrading to 0.3.0.5 (It took me ages to track down what was causing the flameout bug), I opened an error log after a recent crash (they just happen. Don't know if Kerbcom is involved) to discover nearly five million lines of Null Reference Exceptions from Kerbcom. I won't post the whole log obviously, but it was a whole, whole lot of

(Filename:  Line: -1)

NullReferenceException: Object reference not set to an instance of an object
at KerbCom.MyRCSModule.FixedUpdate () [0x00000] in <filename unknown>:0

Any ideas? The output file was actually too large for notepad to open; I had to use Notepad++

Hmm. I have only experienced a NullReferenceException in MyRCSModule.FixedUpdate a few times myself, and I have yet to find the exact cause. I also suspect that this voluminous log may have been responsible for the crash. If you could find a way to reproduce this bug reliably I would be extremely grateful. Stability is my top priority for this mod right now, as it is relied upon by the yet-to-be-released Kerbin Mini Shuttle mod.

Also, if anyone wants to post pictures of any vehicles they have created using this mod (e.g. VTOLs, unbalanced launchers etc.) I would be happy to have them in this thread. So far I have made a few successful VTOLs, including a rover dropship and a two-Kerbal high-mobility vehicle. I should post some pictures at some point.

Edit:

Any chance of a Linux version?

Once the Kerbin Mini Shuttle has its first release I will see if I have some time to get the native DLL loading working correctly on Linux.

Link to comment
Share on other sites

Hmm. I have only experienced a NullReferenceException in MyRCSModule.FixedUpdate a few times myself, and I have yet to find the exact cause. I also suspect that this voluminous log may have been responsible for the crash. If you could find a way to reproduce this bug reliably I would be extremely grateful. Stability is my top priority for this mod right now, as it is relied upon by the yet-to-be-released Kerbin Mini Shuttle mod.

Well, currently I can't get the game to run at all. I can say, though, that my crashes almost always happen either going from VAB/SPH to Launchpad/Runway and back, or, oddly enough, taking screenshots. The stupidly long output log basically had all of those NREs, then "Scene changed from EDITOR to FLIGHT" and then crash.

Link to comment
Share on other sites

Well, currently I can't get the game to run at all. I can say, though, that my crashes almost always happen either going from VAB/SPH to Launchpad/Runway and back, or, oddly enough, taking screenshots. The stupidly long output log basically had all of those NREs, then "Scene changed from EDITOR to FLIGHT" and then crash.

Do you know whether this is definitely caused by KCA? Have you tried uninstalling it?

Link to comment
Share on other sites

Sorry I didn't offer more input.

I can't say for sure what caused that issue. The game would not run at all, despite using fewer mods than I had before. I suspect the huge logs gummed up the works somehow, but I have no idea if it was Kerbcom or not. Did a totally fresh install, installed a reduced number of mods from original downloads (including Kerbcom), and started a new save, and I've yet to have a crash. Things seem to be working fine. I suspect it may have been my cutting and moving of parts and files trying to reduce memory usage that broke /something/.

I have to say, I'm pretty impressed. I figured out that Kerbcom's throttle controls override mechjeb's overheat protection (Just need to watch the heat myself instead of trusting Jeb). I found this out when five engines detonated while testing a large VTOL craft. Amazingly, I was able to enter a hover and land with what should have been a completely unworkable engine configuration; six in front, one in back right corner.

1146127_10151683389177669_1952309069_o.jpg

(Is there a way to make photos smaller without resizing the actual file? I feel bad posting such huge pictures...)

Link to comment
Share on other sites

Sorry I didn't offer more input.

I can't say for sure what caused that issue. The game would not run at all, despite using fewer mods than I had before. I suspect the huge logs gummed up the works somehow, but I have no idea if it was Kerbcom or not. Did a totally fresh install, installed a reduced number of mods from original downloads (including Kerbcom), and started a new save, and I've yet to have a crash. Things seem to be working fine. I suspect it may have been my cutting and moving of parts and files trying to reduce memory usage that broke /something/.

I have to say, I'm pretty impressed. I figured out that Kerbcom's throttle controls override mechjeb's overheat protection (Just need to watch the heat myself instead of trusting Jeb). I found this out when five engines detonated while testing a large VTOL craft. Amazingly, I was able to enter a hover and land with what should have been a completely unworkable engine configuration; six in front, one in back right corner.

huge image

(Is there a way to make photos smaller without resizing the actual file? I feel bad posting such huge pictures...)

I'm glad you're getting good use out of KCA. If I'm not mistaken this is the first screenshot anyone's posted. How's KCA behaving with jet VTOLs? On some crafts the huge response time for jets can make it overcompensate.

You can sort of do some overheat protection of your own by scaling down the maximum throttle (strength) slider in the KCA settings, however this is not a measure of the maximum allowed individual throttle value, so be careful relying on that for very unbalanced vessels. I suppose I could add a feature at some point to do proper overheat protection. One thing you will definitely want to do is disable MechJeb heat protection, as with KCA enabled it will only hinder you.

Looking at that picture, you can sort of visualise why the vessel was still stable. Look at the area formed by the convex hull of the engine positions. If the centre of mass is within or very close to being in that area KCA has a good chance of being able to balance everything. Judging from where the camera is pointing, it looks like the centre of mass really is within that area, and quite close to the front of the vessel. This is because of the distribution of the remaining engines being primarily in the front.

The only thing I have found you can do other than resize your images is to use an imgur album.

P.S. A good parts mod I have found indispensable for use in VTOL crafts is RLA Stockalike. It includes invaluable radial stack mounting plates.

Edited by ZRM
Link to comment
Share on other sites

It works quite nicely with B9's Vtol engines, since they respond fairly quickly.

That's an interesting point about the stability. I hadn't thought of it that way but it makes sense.

I love making VTOL's, partially because I'm a fan of overly complicated solutions to simple problems. Poor Jeb has been stranded 20KM away from KSC for days because I'm determined to recover his command pod skycrane style.

Link to comment
Share on other sites

It works quite nicely with B9's Vtol engines, since they respond fairly quickly.

That's an interesting point about the stability. I hadn't thought of it that way but it makes sense.

I love making VTOL's, partially because I'm a fan of overly complicated solutions to simple problems. Poor Jeb has been stranded 20KM away from KSC for days because I'm determined to recover his command pod skycrane style.

Kerbals are stubborn like that. He could have walked 20KM in a couple of days.

Link to comment
Share on other sites

I hate to keep posting issues, but I get an immense slowdown with KCA. Especially on ships with a lot of engines (as to be expected). The lag goes away significantly if I hide the avionics panel, but exists whenever it's visible, even if the system isn't running.

I'm not complaining about performance, I'm just curious if that's normal or there's a problem on my end somewhere. Just hiding the GUI takes me from ~8fps up to ~40fps

I also apologize if this has been mentioned. The forum won't let me search the thread for "lag" and nothing else I could think of produced anything.

EDIT- in case you were curious, I don't think KCA was causing the huge output log issue. I've got it uninstalled right now due to the performance hit, and I'm still getting massive output logs. Something is spamming up the log during vehicle editing. Now only to figure out what...

Edited by Torminator
Link to comment
Share on other sites

I hate to keep posting issues, but I get an immense slowdown with KCA. Especially on ships with a lot of engines (as to be expected). The lag goes away significantly if I hide the avionics panel, but exists whenever it's visible, even if the system isn't running.

I'm not complaining about performance, I'm just curious if that's normal or there's a problem on my end somewhere. Just hiding the GUI takes me from ~8fps up to ~40fps

I also apologize if this has been mentioned. The forum won't let me search the thread for "lag" and nothing else I could think of produced anything.

EDIT- in case you were curious, I don't think KCA was causing the huge output log issue. I've got it uninstalled right now due to the performance hit, and I'm still getting massive output logs. Something is spamming up the log during vehicle editing. Now only to figure out what...

Do you have Extraplanetary Launchpads installed? It seems I left a print statement in there that spams "Loading" in the VAB.

Link to comment
Share on other sites

I hate to keep posting issues, but I get an immense slowdown with KCA. Especially on ships with a lot of engines (as to be expected). The lag goes away significantly if I hide the avionics panel, but exists whenever it's visible, even if the system isn't running.

I'm not complaining about performance, I'm just curious if that's normal or there's a problem on my end somewhere. Just hiding the GUI takes me from ~8fps up to ~40fps

I also apologize if this has been mentioned. The forum won't let me search the thread for "lag" and nothing else I could think of produced anything.

EDIT- in case you were curious, I don't think KCA was causing the huge output log issue. I've got it uninstalled right now due to the performance hit, and I'm still getting massive output logs. Something is spamming up the log during vehicle editing. Now only to figure out what...

Ah, that would be due to a particular inefficient bit of code in the GUI that I thought would not be noticeable unless you have a lot of parts. I will have to add caching at some point. Thanks for the heads up. Just to check, if the control panel is not visible, but the system is still active, you don't get the lag, right?

Link to comment
Share on other sites

Hmm. I don't think I tried having the system running with the GUI hidden. I'll give that a shot.

I don't know about a lot of parts... I've had it happen on simple spaceplanes with maybe 100 parts max (but nearly 16 small VTOL engines)

Link to comment
Share on other sites

Right click on the command module. there should be a toggle there.

Doesn't work, I have a B9 pod, though. Additionally, I confirm the massive FPS drop with KCA GUI open. frames drop from 45 to 20, as reported by Dxtory.

Edited by SkyHook
Link to comment
Share on other sites

I seem to be spectacularly talented at breaking things.

I've also noticed that, after installing Kerbcom, any maneuvers done by Mechjeb seem to spaz out, firing RCS in every direction. It points the right way... eventually, but it uses an incredible amount of monopropellant. I just docked two identical modules to my station, both using mechjeb autopilot rendevous.

The first missed, had to make another rendevous attempt. The second got lucky, and didn't have to do nearly as much maneuvering. When I got to the vicinity of my station, the second, which I ran after re-installing KCA, had used about 40% of its monopropellant, while the first had used maybe 10%. I'll try to get some video to demonstrate what I mean. The only thing that changed between attempt 1 and attempt 2 was installing KCA, RBI tracks, and the newest MSI update. I've had this behavior before, and just assumed it was Mechjeb being inefficient.

Link to comment
Share on other sites

I seem to be spectacularly talented at breaking things.

I've also noticed that, after installing Kerbcom, any maneuvers done by Mechjeb seem to spaz out, firing RCS in every direction. It points the right way... eventually, but it uses an incredible amount of monopropellant. I just docked two identical modules to my station, both using mechjeb autopilot rendevous.

The first missed, had to make another rendevous attempt. The second got lucky, and didn't have to do nearly as much maneuvering. When I got to the vicinity of my station, the second, which I ran after re-installing KCA, had used about 40% of its monopropellant, while the first had used maybe 10%. I'll try to get some video to demonstrate what I mean. The only thing that changed between attempt 1 and attempt 2 was installing KCA, RBI tracks, and the newest MSI update. I've had this behavior before, and just assumed it was Mechjeb being inefficient.

Mechjeb spazzes out in general, though. It will do that with any craft. It hasn't been updated with the 0.21 "Chill Pill" that the new ASAS has gotten.

Link to comment
Share on other sites

Mechjeb spazzes out in general, though. It will do that with any craft. It hasn't been updated with the 0.21 "Chill Pill" that the new ASAS has gotten.

That's what I'm saying, though. I'm using Sarbian's .dll, which seemed to eliminate the overuse of RCS, but it returned concurrent with re-installing KCA. I'm not complaining; I'm just trying to bring any and all potential glitches to ZRM's attention, especially if stability is a priority.

FWIW, I did -not- install the mechjeb config folder. I did use the stock one, however. I'm pretty sure it only changes the AR202 part, but hey.

Link to comment
Share on other sites

That's what I'm saying, though. I'm using Sarbian's .dll, which seemed to eliminate the overuse of RCS, but it returned concurrent with re-installing KCA. I'm not complaining; I'm just trying to bring any and all potential glitches to ZRM's attention, especially if stability is a priority.

FWIW, I did -not- install the mechjeb config folder. I did use the stock one, however. I'm pretty sure it only changes the AR202 part, but hey.

There is an animation/fx glitch that causes any ship to animate, but no RCS is actually being used, nor are there any forces being exerted. Are you sure that this is't happening?

Link to comment
Share on other sites

This plugin causes about 1FPS with certain vehicles in the VAB/SPH. A quick look at the output file for KSP yields hundreds of instances of this line:

"NullReferenceException: Object reference not set to an instance of an object at KerbCom.MyRCSModule.FixedUpdate () [0x00000] in <filename unknown>:0 (Filename: Line: -1)"

If i understand correctly, then something was poorly installed, or KSP borks itself when it tries to look for the module, but finds a dead end for the designated path. I am guessing this is related to the fact that no parts in the game actually use a module called "MyRCSModule" and instead use "ModuleRCS" Wanted to report this here, the glitch is gamebreaking.

Edited by SkyHook
Link to comment
Share on other sites

I seem to be spectacularly talented at breaking things.

I've also noticed that, after installing Kerbcom, any maneuvers done by Mechjeb seem to spaz out, firing RCS in every direction. It points the right way... eventually, but it uses an incredible amount of monopropellant. I just docked two identical modules to my station, both using mechjeb autopilot rendevous.

The first missed, had to make another rendevous attempt. The second got lucky, and didn't have to do nearly as much maneuvering. When I got to the vicinity of my station, the second, which I ran after re-installing KCA, had used about 40% of its monopropellant, while the first had used maybe 10%. I'll try to get some video to demonstrate what I mean. The only thing that changed between attempt 1 and attempt 2 was installing KCA, RBI tracks, and the newest MSI update. I've had this behavior before, and just assumed it was Mechjeb being inefficient.

MechJeb doesn't like KCA very much - MJ tends to rely on the statistics it reads from RCS ports, reaction wheels and engines to determine how to behave. Since some of the assumptions it makes (such as all engines having the same throttle, and how it thinks RCS behaves) are no longer valid with KCA installed it can have difficulties determining the correct control input. I am thinking of writing my own autopilot routines at some point to make best use of the flexibility KCA provides for flight control and to make up for the lost MJ functionality.

However, KCA does make docking much easier than normal, due to the thrust balancing, so often you should not need an autopilot for docking. Just make sure to keep the 0.21 SAS enabled.

This plugin causes about 1FPS with certain vehicles in the VAB/SPH. A quick look at the output file for KSP yields hundreds of instances of this line:

"NullReferenceException: Object reference not set to an instance of an object at KerbCom.MyRCSModule.FixedUpdate () [0x00000] in <filename unknown>:0 (Filename: Line: -1)"

If i understand correctly, then something was poorly installed, or KSP borks itself when it tries to look for the module, but finds a dead end for the designated path. I am guessing this is related to the fact that no parts in the game actually use a module called "MyRCSModule" and instead use "ModuleRCS" Wanted to report this here, the glitch is gamebreaking.

Right, I've tracked down this bug. It is something I had fixed in a previous version, but the change was not incorporated into the new module management system I have incorporated.

I will roll out this fix once I have also implemented caching to deal with the reported slowdown caused by the editor GUI. I would also be grateful for an example craft where the GUI slowdown is especially noticeable.

Link to comment
Share on other sites

Doesn't work, I have a B9 pod, though. Additionally, I confirm the massive FPS drop with KCA GUI open. frames drop from 45 to 20, as reported by Dxtory.

How exactly did you install KCA? Did you use the stock config or the MechJeb one, or did you make a custom one? The KCA GUI context button shows up on the par that KCA is installed on. In your case this might be the MechJeb AR202 part.

Link to comment
Share on other sites

MechJeb doesn't like KCA very much - MJ tends to rely on the statistics it reads from RCS ports, reaction wheels and engines to determine how to behave. Since some of the assumptions it makes (such as all engines having the same throttle, and how it thinks RCS behaves) are no longer valid with KCA installed it can have difficulties determining the correct control input. I am thinking of writing my own autopilot routines at some point to make best use of the flexibility KCA provides for flight control and to make up for the lost MJ functionality.

However, KCA does make docking much easier than normal, due to the thrust balancing, so often you should not need an autopilot for docking. Just make sure to keep the 0.21 SAS enabled.

Does this effect MJ even when KCA isn't active (I.E. none of the GUI buttons are depressed) or even not on the craft at all? Mostly I use MJ's autopilot for making sure I don't deviate from a maneuver node, or for keeping my docking port pointed at the target during docking, which is helpful when I have to, say, move to the other side of a station. I may try the LAZOR autopilot, see if that's any better at dealing with things.

I can also report a stream of NRE's in the VAB/SPH whenever I place any sort of RCS thruster, stock or otherwise, into the scene. The EVER so helpful debug log doesn't give any more details, but it's likely the same thing Skyhook was getting, compounded with the Extraplanetary Launchpads spam bug.

Link to comment
Share on other sites

How exactly did you install KCA? Did you use the stock config or the MechJeb one, or did you make a custom one? The KCA GUI context button shows up on the par that KCA is installed on. In your case this might be the MechJeb AR202 part.

Thank you for the quick response! I installed both optional module manager files...should I have? I have many mod parts, so i thought it best to install both. As well, the option to use KCA appears only intermittently. Restarting the game allows the gui options to pop up, but only once. Not sure why this happens, but it may be a conflict with two or more command pods and KCA. I'm just speculating, though.

EDIT: These are the files: https://www.dropbox.com/sh/9o4r1hcdvigxlfg/3AgjaxgJtU

AM-02 Ursa is for SPH, Ursa Shuttle is for VAB. Editor scene slowdown with either of them.

Edited by SkyHook
Link to comment
Share on other sites

Does this effect MJ even when KCA isn't active (I.E. none of the GUI buttons are depressed) or even not on the craft at all? Mostly I use MJ's autopilot for making sure I don't deviate from a maneuver node, or for keeping my docking port pointed at the target during docking, which is helpful when I have to, say, move to the other side of a station. I may try the LAZOR autopilot, see if that's any better at dealing with things.

I can also report a stream of NRE's in the VAB/SPH whenever I place any sort of RCS thruster, stock or otherwise, into the scene. The EVER so helpful debug log doesn't give any more details, but it's likely the same thing Skyhook was getting, compounded with the Extraplanetary Launchpads spam bug.

It should not cause problems with anything other than RCS ports when KCA is not active. KCA actually uses some ModuelManager-style (but not actually using ModuleManager) config transformation to make RCS ports use my code instead of the stock ModuleRCS. This affects every RCS port in the game. So MechJeb may believe that your vessel has no RCS ports on it, and so it may behave incorrectly.

Having said all of that, MechJeb does seem to work reasonably well with engines under control of KCA, and it will follow manoeuvre nodes well once under thrust.

I have made a fix for the NRE bug, and also (hopefully) for the GUI slowdown bug. I will release that later today once I have the time.


Thank you for the quick response! I installed both optional module manager files...should I have? I have many mod parts, so i thought it best to install both. As well, the option to use KCA appears only intermittently. Restarting the game allows the gui options to pop up, but only once. Not sure why this happens, but it may be a conflict with two or more command pods and KCA. I'm just speculating, though.

EDIT: These are the files: https://www.dropbox.com/sh/9o4r1hcdvigxlfg/3AgjaxgJtU

AM-02 Ursa is for SPH, Ursa Shuttle is for VAB. Editor scene slowdown with either of them.

It should (in theory) work fine with both module manager configs installed. My plugin does have code for dealing with multiple KCA modules being installed on the same vessel, however it is the least tested part of KCA, so there may be a bug or ten that is/are causing your problems. Thanks for the upload - I will look at your craft files when I have the time. I hope they don't rely on too many mods. If they do, if possible please could you reduce the dependencies to make it easier for me to test. BTW, my latest bugfix release that I will release today should fix the editor lag.

Link to comment
Share on other sites

This thread is quite old. Please consider starting a new thread rather than reviving this one.

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...