Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Vehicles - Add Auto-Throttle to Planes #8275

Merged
merged 7 commits into from
Sep 3, 2021

Conversation

TheCandianVendingMachine
Copy link
Contributor

When merged this pull request will:

  • Add a speed-limiter type control to planes

Uses a basic PID Controller to control the throttle of a plane to keep it at some speed. PID was tuned in Simulink, so values work well. Once you have speed limiter on, you don't have to touch the throttle again.

Video of it in action

@jonpas jonpas added this to the 3.14.0 milestone Jun 2, 2021
@PabstMirror
Copy link
Contributor

Close #2818 (I think)

@jonpas
Copy link
Member

jonpas commented Jul 23, 2021

Why only planes? Most cars today have cruise control / tempomat. I assume the PID tune would be different though, so if you don't want to do that, that's fine. :D

@jonpas jonpas changed the title Add an auto-throttle to Planes Vehicles - Add Auto-Tthrottle to Planes Jul 23, 2021
@jonpas jonpas changed the title Vehicles - Add Auto-Tthrottle to Planes Vehicles - Add Auto-Throttle to Planes Jul 23, 2021
@PabstMirror
Copy link
Contributor

ground vics are getting in-engine cruise in 2.06
https://community.bistudio.com/wiki/setCruiseControl

@jonpas
Copy link
Member

jonpas commented Jul 23, 2021

Ah right! We have another PR somewhere for that already as well.
EDIT: Just for limit, but an actual use of cruise control for ground vehicles would be cool too.

@TheCandianVendingMachine
Copy link
Contributor Author

I don't think there is a way to control the throttle in non-plane vehicles, so I'd have to go into the config and setVelocity appropriately and it just turns into a mess

@jonpas
Copy link
Member

jonpas commented Jul 23, 2021

setCruiseControl has autoThrust.

@dedmen
Copy link
Contributor

dedmen commented Aug 2, 2021

Somewhat unrelated to this PR

PID was tuned in Simulink

Engine setCruiseControl has hardcoded PID params that might not be optimal
kp = 0.5
ki = 0.3
kd = 0.2
maybe that can be tuned better.
If you can optimize that and find better values, feel free to contact me and i can transfer them into the engine vehicle PID, but it needs to work with all vehicles from quads to tanks

@PabstMirror PabstMirror merged commit 0f7376f into acemod:master Sep 3, 2021
@jonpas jonpas added kind/feature Release Notes: **ADDED:** and removed kind/added feature labels Oct 14, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
kind/feature Release Notes: **ADDED:**
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants