Jump to content

[1.9-1.10] Throttle Controlled Avionics


allista

Recommended Posts

8 hours ago, allista said:

I was thinking more like middle mouse button, really. Then again, I don't know how Mac users manage with their cyclop-mutant mice :confused:

Current Mac mice actually have three buttons.  So us Mac users don't have problems with that.  :wink:  (Well, mostly: I use a pen-and-tablet, so third mouse button is a bit hard to use...)

But KSP has lots of things fighting over the mouse, and quite often I can't get a mouse click to do what I want because it wants to do something else.  I'll second the suggestion to have a nice, simple, working text box.  :wink:

Link to comment
Share on other sites

19 minutes ago, DStaal said:

Current Mac mice actually have three buttons.  So us Mac users don't have problems with that.  :wink:  (Well, mostly: I use a pen-and-tablet, so third mouse button is a bit hard to use...)

But KSP has lots of things fighting over the mouse, and quite often I can't get a mouse click to do what I want because it wants to do something else.  I'll second the suggestion to have a nice, simple, working text box.  :wink:

As you can see, I've done both :cool:

Link to comment
Share on other sites

1 hour ago, Constan7ine said:

TCA isn't showing in my applauncher. Could this have something to do with the Contract Configurator bug I've been hearing about?

This thing:  http://forum.kerbalspaceprogram.com/index.php?/topic/150719-contract-configurator-broke-my-mod/&do=findComment&comment=2826102

Don't think so: first, I've already updated the ToolbarWrapper, which should have fixed that bug; second, stock AppLauncher is not affected at all. Maybe something's wrong with the installation?

Link to comment
Share on other sites

5 minutes ago, allista said:

Don't think so: first, I've already updated the ToolbarWrapper, which should have fixed that bug; second, stock AppLauncher is not affected at all. Maybe something's wrong with the installation?

Reinstalled from the download from SpaceDock and it's working now. I previously downloaded from GitHub, so if they're identical I must have done something wrong the first time. Thanks!

Link to comment
Share on other sites

11 hours ago, Constan7ine said:

Reinstalled from the download from SpaceDock and it's working now. I previously downloaded from GitHub, so if they're identical I must have done something wrong the first time. Thanks!

Sorry, I haven't updated GitHub releases in a while. Only SpaceDock and CKAN provide current versions.

Link to comment
Share on other sites

7 hours ago, allista said:

Sorry, I haven't updated GitHub releases in a while. Only SpaceDock and CKAN provide current versions.

Spacedock isn't working at the minute and this is also where CKAN pulls it from so it's not currently available. Would you be able to offer an alternative download?

Cheers

Link to comment
Share on other sites

Hi here.

Discover a small issue, due nav-buoy deployment mission.

TAC use local coordinate system from one of un-maned core. I have two buoys with two cores, attached to helicopter radially, and  TAC use one of core for reference direction of craft. It means, on cruise, helicopter flying to right side, and acc/dec by roll :) 

For example: Craft on runway, forward direction of craft to east (90°). On right side attached unmaned core. After activation cruise (90°), craft turn left and point to 90° by unmaned core.

I try to use "Control from here" on cabin, try to add docking port and use "Control from here" on docking port - it not help.
Founded workaround: After all unmaned cores add last one, with right direction :D

 

 

 

 

Link to comment
Share on other sites

14 hours ago, g_BonE said:

okay, so what is that NewOrbit-dT.log file that gets written to KSP root folder used for?

Ah, sorry, this is a debugging code I forgot to remove. Before KSP-1.2, each time TCA calculates a close-to-circular orbit, it needed to correct the epoche as it got drifted on Orbit creation due to undefined periapsis. In 1.2 it seems this was somehow fixed, though I haven't figured out how from KSP code. So I was trying to gather statistics on the amount of correction that need to be made now.

This file contains these corrections (in seconds), and if there's no entries greater than 1, I would assume I can remove the correction part.

Link to comment
Share on other sites

15 hours ago, Shirson said:

Hi here.

Discover a small issue, due nav-buoy deployment mission.

TAC use local coordinate system from one of un-maned core. I have two buoys with two cores, attached to helicopter radially, and  TAC use one of core for reference direction of craft. It means, on cruise, helicopter flying to right side, and acc/dec by roll :) 

For example: Craft on runway, forward direction of craft to east (90°). On right side attached unmaned core. After activation cruise (90°), craft turn left and point to 90° by unmaned core.

I try to use "Control from here" on cabin, try to add docking port and use "Control from here" on docking port - it not help.
Founded workaround: After all unmaned cores add last one, with right direction :D

I see. Thanks for the report!

The "Control from here" should have worked, so this is a bug.

Link to comment
Share on other sites

Holy crap this mod has come far! Awesome job! I'm totally going to use this on everything cinematic, but... is there currently a way to close the waypoint path into a loop that the craft repeats? I didn't see anything simple in the video or the manual. Probably possible with a macro?

Right now i want my VTOL to fly by a cliff so i can jump my rover into the cargo bay. But i seriously doubt i'll get it on the first try. For the time being i'll just overlap the waypoints back and forth. Like this: https://youtu.be/GX-SYhzfaf0?t=2m11s  but with a moving target instead.

 

Edited by achroma
Link to comment
Share on other sites

23 minutes ago, achroma said:

Holy crap this mod has come far! Awesome job! I'm totally going to use this on everything cinematic, but... is there currently a way to close the waypoint path into a loop that the craft repeats? I didn't see anything simple in the video or the manual. Probably possible with a macro?

Right now i want my VTOL to fly by a cliff so i can jump my rover into the cargo bay. But i seriously doubt i'll get it on the first try. For the time being i'll just overlap the waypoints back and forth. Like this: https://youtu.be/GX-SYhzfaf0?t=2m11s  but with a moving target instead.

Yes, it should be possible using the Follow Path macro with the For or While loop macro.

Link to comment
Share on other sites

Quote
4 hours ago, allista said:

Yes, it should be possible using the Follow Path macro with the For or While loop macro.

 

Would you please elaborate on this? Maybe even a video? I would love to do closed loop macros unfortunately my macro skills are lacking (unless I see it done). Once I see it I can understand how to do it. Please help! I would love to setup hover craft patrols lol

Link to comment
Share on other sites

1 hour ago, Steel Dragon said:

Would you please elaborate on this? Maybe even a video? I would love to do closed loop macros unfortunately my macro skills are lacking (unless I see it done). Once I see it I can understand how to do it. Please help! I would love to setup hover craft patrols lol

Sure, I'll cook something up :wink:

Meanwhile, does someone have an expertise in control theory? I have a problem with dynamic PID tuning for attitude control :confused:

Link to comment
Share on other sites

1 hour ago, Bit Fiddler said:

I have written PIDs for CS classes when I was in college.   lol but that was 30 years ago...  however I may be able to dig up some memory of this.  what did you need help with ?

Super! :D

So, the basic problem is this:

attitude error (for pitch, roll and yaw) => PID (one for each dimension) => control input (pitch, roll, yaw)

Static PID parameters will, of course, work for only a limited set of vessels (if not for a single one), so dynamic adjustment is needed to adapt to arbitrary moments of inertia, available torque and engine types (instantaneous thrust change, or some hysteresis).

Another issue is that the target attitude may continuously change, providing a degree of unpredictability of the attitude error.

Currently, by trial and error I have concocted an attenuation algorithm that manages quite well (judging by TCA's performance), but it's pure alchemy! More than a dozen manually tuned numeric coefficients to strap together all the parameters of different scale and dimensionality.

But. It all fails in (at least) one particular case: big, bad, heavy VTOL on large jets. Remember the Mk2-based small jet VTOL drone that I use in many of the videos (including the last one)? Imagine tweakscaling it 2-3 times. So, numerically, all should work: it has ~same angular acceleration around the axes, same response times of the engines. But where the small one flies flawlessly, this thing goes into self-excitation, producing ever-increasing oscillations resulting in overflipping.

I'm beating meself against this for three days now and can't figure out what the hell happens.

I understand that for any real help you'll need particulars, but I thought an overview would also help.

Edited by allista
Link to comment
Share on other sites

10 minutes ago, allista said:

can't figure out what the hell happens

Most probably tweakscale applying different exponents to different parameters - thrust squared and mass power 2.5 for example. I wouldn't assume it's the same craft mathematically.

Edited by Boris-Barboris
Link to comment
Share on other sites

Just now, Boris-Barboris said:

Most probably tweakscale applying different exponents to different parameters - thrust squared and mass power 2.5 for example. I woul'd assume it's the same craft mathematically.

It's not actually tweakscaled, it's from stock parts; this was just a way to describe it visually.

Link to comment
Share on other sites

I'd recommend wasting a week and writing yourself a sandbox. Simple matlab\watever script is faster to work with than KSP. Implement one axis of rotation, write out a couple of cases you want to check your controller on (small, medium, heavy craft, jets or rockets), look at the plot, tweak, iterate. Trial and error is the way to go, the trick is to minimize iteration count, period and environment complexity.

On the controller itself, well, PIDs are fine, the easiest and well-tested approach is gain scheduling - instead of woodoo coefficients you interpolate a big table of gains, tested for each test craft (will get trickier if table dimension is high, but your case seems to have one dimension - ratio of max torque to axis MOI). You can make two tables - for jets and for rockets. Then maybe some global gain around 0.5 to ease the fact that you omitted aero forces (don't even go there, trust me on this). I've seen a formula somewhere in RPC thread for analythical PI gains from desired overshoot margin, but I don't think it will help you - you need PID, unless you're cascading and already have good angular acceleration controller.

Edited by Boris-Barboris
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...