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

How to control gear shift in Carla? #269

Closed
YashBansod opened this issue Mar 6, 2018 · 7 comments
Closed

How to control gear shift in Carla? #269

YashBansod opened this issue Mar 6, 2018 · 7 comments
Assignees
Labels

Comments

@YashBansod
Copy link

I was trying to implement a basic velocity control algorithm using PID, in carla.
But I notice that the car keeps shifting the gears between kmph to 40kmph (1st and 2nd gear) and 50-60kmph (3rd gear). This is causing a fluctuating speed and control commands from my PID controller.

Is there a way to control the gear shift or outright disable it?

The following plots may help visualize the problem better.All plots are with the same tuning parameters:
60_0 120000_0 005000_0 600000_vc
55_0 120000_0 005000_0 600000_vc
50_0 120000_0 005000_0 600000_vc
45_0 120000_0 005000_0 600000_vc
40_0 120000_0 005000_0 600000_vc
35_0 120000_0 005000_0 600000_vc
30_0 120000_0 005000_0 600000_vc
25_0 120000_0 005000_0 600000_vc
20_0 120000_0 005000_0 600000_vc
15_0 120000_0 005000_0 600000_vc

@YashBansod
Copy link
Author

YashBansod commented Mar 7, 2018

Although it is possible to try and reduce the velocity errors by changing the control parameters, the control signals need to be really extreme.
30_0 150000_0 005000_5 000000_vc

And you would never do this kind of control in a real car. Instead you will just prefer to upshift the gear and drive the car at low throttle (and rpm) to maintain the speed.

But of course it requires a manual shifting of gears.

@nsubiron nsubiron self-assigned this Mar 7, 2018
@nsubiron
Copy link
Collaborator

nsubiron commented Mar 7, 2018

Is there a way to control the gear shift or outright disable it?

We don't have currently any way of shifting gears from the client side, it's just not added to the vehicle control. I'm actually surprised no one asked for this up until now :D I think is reasonable to add this to our backlog (#270).

Meanwhile you can tune the vehicle's engine model inside Unreal Editor, would it work adding a single very long gear?

screenshot from 2018-03-07 11-17-22

@YashBansod
Copy link
Author

Thanks @nsubiron.
I think setting a very long gear may solve the purpose for now.

@fbuchinger
Copy link

+1 for the manual gear shift, would love to use my logitech g25 shifter for that.

@AlienTech83
Copy link

+1 for this, would really be good to be able to shift gears using manual control (either from keyboard or from a steering wheel)

@NYJiaxing
Copy link

@YashBansod
Hello Sir,

Would you mind if you can share with me how you get the vehicle's speed data? And did you find where is the vehicle's yaw angle data?

Thank you so much

@DongChen06
Copy link

Hello, I am not sure what is the meaning of " setting a very long gear ", does that mean we can set munual_gear_shift = 10 (big number?). thank you very much!!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

6 participants