commaai / openpilot

openpilot is an operating system for robotics. Currently, it upgrades the driver assistance system on 275+ supported cars.
https://comma.ai/openpilot
MIT License
50.08k stars 9.15k forks source link

comma pedal: erroneous disengages due to signal noise on some Honda #21998

Closed fraserxiong closed 2 years ago

fraserxiong commented 3 years ago

Describe the bug

OP disengages randomly, or OP disengages immediately after enable. The issue seems not car specific, but we have seen many Hondas with the same issue. So far, it has been confirmed in Odyssey, Ridgeline, and Pilot. It is also possible that Honda is the most common car brand to use a comma pedal.

How to reproduce or log data

Some community member with comma pedal has the bug since 0.8 (I don't know the exact version that causes the issue) To reproduce the bug, they need to switch back to the official version and engage openpilot. The bug will appear randomly.

Device/Version information (please complete the following information):

Additional context

I have made a small change with a higher threshold on disengage openpilot when the gas pedal is not pressed. Many of the currently affected community members are using my folk. And the change is here: https://github.com/fraserxiong/openpilot/commit/ae10bc526a5800fe38c50ed82c89666e344aee65

Also made a wiki about the issue here: https://github.com/fraserxiong/openpilot/wiki/Noise-with-gas-pedal-issue

jasonmoreau commented 3 years ago

I am experiencing the same issue in my 2018 Toyota RAV4 XLE (non-hybrid).

antflores commented 3 years ago

Happens in my 2017 Pilot touring.

gricha01 commented 3 years ago

This happens in my 2019 Honda Passport also. (no forks/giraffes or anything added on) And this would happen with me on a straight road with no cars around. Sometimes it takes 3 or 4 times before it stays on. I would say 75 percent of the time it works on the 1st try.

adeebshihadeh commented 3 years ago

@fraserxiong want to open a PR to get this fixed? That threshold is quite a bit higher. We should get a route from each affected car to determine an appropriate new threshold.

fraserxiong commented 2 years ago

@fraserxiong want to open a PR to get this fixed? That threshold is quite a bit higher. We should get a route from each affected car to determine an appropriate new threshold.

Thanks for the reply. Will gather data and come up with a reasonable number. Might take a while.

CineXWorm commented 2 years ago

Not experiencing this on my VW Golf MK6 with comma pedal.

J3ffrey2020 commented 2 years ago

Having the same problem on a ridgelline, this makes the C2 useless if it randomly cancels itself when a car slows down infront of you! Is Comma offering a refund for people effected? I have a friend with the same car and a C3 and he hasn't had this happen to him.

adeebshihadeh commented 2 years ago

Is Comma offering a refund for people effected?

Nope, the comma pedal is community hardware, which we do not sell or support.

J3ffrey2020 commented 2 years ago

Is Comma offering a refund for people effected?

Nope, the comma pedal is community hardware, which we do not sell or support.

I should have mentioned mine is doing it with no pedal attached and stock hardware and software.

sshane commented 2 years ago

Out of 13 users/dongles, only two have a high 99.9 percentile interceptor gas value when car gas is 0, and the signal looks much noisier compared to other users with the same car. These two users: https://imgur.com/a/OvJFxDC, some of the rest: https://imgur.com/a/uxDX4vL

Looked at 173,956 segments, here's the stats from Honda users with pedals. These samples are only gathered when the car reports 0 gas applied by the user and the gas interceptor is above the current threshold, which would also include the gas interceptor:

Stats by dongle id:
67cc68f0290328c2/HONDA ODYSSEY 2018 (350 samples): avg: 1.204, 99th percentile: 6.771, max: 8.198
211d3271a862c848/HONDA ODYSSEY 2018 (940 samples): avg: 1.952, 99th percentile: 10.197, max: 17.976
809adcfce1b6f495/HONDA ODYSSEY 2018 (3591 samples): avg: 2.842, 99th percentile: 7.753, max: 16.325
2205ba1364b32b3e/HONDA PILOT 2017 (4417 samples): avg: 1.507, 99th percentile: 8.431, max: 26.421
22786e510b775801/HONDA CIVIC 2016 (843 samples): avg: 1.352, 99th percentile: 11.527, max: 27.882
54fd8451b3974762/HONDA RIDGELINE 2017 (268 samples): avg: 1.911, 99th percentile: 11.011, max: 28.199
4d5e075821d0d877/HONDA CIVIC 2016 (35 samples): avg: 2.291, 99th percentile: 9.178, max: 9.912
981ec27a7a4ad541/HONDA RIDGELINE 2017 (1064 samples): avg: 2.413, 99th percentile: 12.078, max: 27.31
a3f025079c99dde7/HONDA CIVIC 2016 (7745 samples): avg: 1.161, 99th percentile: 6.519, max: 41.343
a993952413a92fe9/HONDA RIDGELINE 2017 (1245 samples): avg: 2.512, 99th percentile: 10.865, max: 14.611
b9a21c12423207c5/HONDA CIVIC 2016 (204 samples): avg: 0.965, 99th percentile: 5.525, max: 8.071
bf960626d90a2b97/ACURA RDX 2018 (41 samples): avg: 1.845, 99th percentile: 11.144, max: 13.531
cfb32f0fb91b173b/HONDA CIVIC 2016 (2078 samples): avg: 1.261, 99th percentile: 12.086, max: 24.516

Stats by platform:
HONDA ODYSSEY 2018 (4881 samples): avg: 2.553, 99th percentile: 7.893, max: 17.976
HONDA PILOT 2017 (4417 samples): avg: 1.507, 99th percentile: 8.431, max: 26.421
HONDA CIVIC 2016 (10905 samples): avg: 1.195, 99th percentile: 8.452, max: 41.343
HONDA RIDGELINE 2017 (2577 samples): avg: 2.408, 99th percentile: 11.022, max: 28.199
ACURA RDX 2018 (41 samples): avg: 1.845, 99th percentile: 11.144, max: 13.531
sshane commented 2 years ago

Can any of you (@fraserxiong @antflores @gricha01 @J3ffrey2020) provide a route where this happens? Strange that some gas interceptors are this noisy and not following the car-reported gas sometimes, considering those segments above are when disengaged.

gricha01 commented 2 years ago

I have V0.8.13 release and it seems as though i am no longer getting this. thanks.

jlundstrom commented 2 years ago

I've been experimenting with changing the Pedal firmware to sample measurements instead of using point in time measurements for CAN messages and it's been effective at smoothing the values.

For the Panda SMPR1 (10.13.4) is set so that 480 cycles are used for sampling voltage/current (I'm guessing this is done due to noisy results), and the Pedal is using the default of 3 cycles. I'm guessing this is to minimize latency on passing pedal values through which we do not want to compromise on. Comments state there are 65536 cycles between each message so we have ample time to add smoothing for the reported values.

I've put together an implementation sampling the last 32 measurements for a ACCEL 1. Driving around and checking the results it seems to have solved this problem for me. I'm not sure if this is the type of solution we are looking for this problem, but figured I it wouldn't hurt to share. https://imgur.com/uyxmd9S https://github.com/jlundstrom/panda/commit/4bda3aaa0179c3359cb7e15b45220bec376d0e67 2205ba1364b32b3e|2022-02-27--15-38-34

sshane commented 2 years ago

Closing as this seems to be a hardware issue with these specific pedals