openpilot icon indicating copy to clipboard operation
openpilot copied to clipboard

Toyota: improve response to acceleration requests

Open sshane opened this issue 3 years ago • 1 comments
trafficstars

Toyotas seem reluctant to apply acceleration requests immediately if this bit is set, even if you request a static acceleration of 1.0 m/s/s. There are still issues with the controller lowering or even making acceleration negative if we overshoot the plan while starting which diminishes this improvement, but this actually does make the car respond better to acceleration requests.

Here are two examples with the change showing the worse possible scenario for the car; as soon as we take off we lower the requested acceleration which normally would have the car let off the gas quite a bit, however it continues on to reach the target, albeit with a little bit of slowing that you can feel.

Screenshot from 2022-06-18 23-10-47

Screenshot from 2022-06-18 23-08-19

Routes with latest changes for my reference:

f15e3c37c118e841|2022-06-30--00-51-03--0 f15e3c37c118e841|2022-06-30--00-59-09--0 f15e3c37c118e841|2022-06-30--01-01-57--0

sshane avatar Jun 19 '22 05:06 sshane

@HaraldSchafer Are we okay with Toyota overshooting the planner's request with this PR? When starting, nearly every time it will overshoot not only the start, but throughout accelerating. We don't exactly request what the stock system does from a start, so it releases the brakes super quickly rather than ramping off them to avoid overshoot.

We might need some manual profile to fix this, but it might be different per car (hybrids might get moving faster coasting from a stop like mine).

Screenshot from 2022-07-18 23-51-31

sshane avatar Jul 19 '22 06:07 sshane

Per a recent conversation, closing as this bit isn't a great way to generically improve starting accuracy (little perceptible improvement to starting acceleration, overshoots acceleration at all speed, and can be dangerous if pitch is slightly wrong)

sshane avatar Sep 02 '22 06:09 sshane