openpilot
openpilot copied to clipboard
HKG: Can-fd resume from standstill improvement
Description Resume from standstill fails to work 1/5 times in a given drive in my hda1 EV6 (and others as well). To solve this problem I have employed the same technique as used in non-canfd hkg cars. I propose sending 5 "resume" button presses at a time. I attempted sending 25 button presses as is currently done with non-canfd cars, but this resulted in a communications error. 5 button presses appears to improve the resume from standstill (no failures in 3 days of driving) and does not give the communications error.
Verification This fix has been employed for a few days now by a few users in a fork created specifically for hda1 ev6 and I5 cars (hoomoose:hda1ev6i5) since master does not have the prerequisite resume from standstill fix needed for hda1 ev6 and I5. In three days of driving with this fix, I have not had a failure of resume from standstill (yet...). However, this fix would affect all can-fd cars with the cruise_buttons signal and can/should be tested by hda1 and hda2 cars.
Prerequisite For testing on an HDA1 car, the hda1 fix is a prerequisite: https://github.com/commaai/openpilot/pull/26069
I had my first failure with this method, so it is not perfect. Just thought I would report this.
@hoomoose Have you tried something similar to this PR?
- https://github.com/commaai/openpilot/pull/25579
I just tested out the solution offered by Sunnyhaibin, and have committed the changes. In one day of driving through rush hour traffic, I had no errors and 100% resume rate. I would estimate success was 14/14. I do not think a conclusion was reached whether to merge the previous PR, but it certainly seems to cause no negative issues with an EV6 and would appear (with limited data from one can-fd car) to offer success. What would be a next step - have more cars try this out?
I just tested out the solution offered by Sunnyhaibin, and have committed the changes. In one day of driving through rush hour traffic, I had no errors and 100% resume rate. I would estimate success was 14/14. I do not think a conclusion was reached whether to merge the previous PR, but it certainly seems to cause no negative issues with an EV6 and would appear (with limited data from one can-fd car) to offer success. What would be a next step - have more cars try this out?
@hoomoose Provide the route(s) with the resume tests should be sufficient for review.
Now that HDA1 resume is in master, can you try master for a bit and see if you still have problems?
Installing as I type - thanks!
In driving through downtown to and from my rec center on the new Master with no modifications from me (which is awesome by the way!), I had the following results. To gym 4/6 successful resumes (Route 68d6a96e703c00c9|2022-10-19--16-28-36) From Gym 7/8 successful resumes (Route 68d6a96e703c00c9|2022-10-19--17-49-42) (and 1 false positive where the car resumed but the car in front wasn't moving, but that's a success in my book.) Overall successful resume rate 11/14. I am happy to keep driving as is to get more data, but I would say this has been typical of my experience all along before trying to do improvements. Others who post (can-fd with hda1 and hda2) seem to have similar experiences of the ~15 -25% failure rate. Do you have a similar experience with your EV6? I will also try this fix again after re-basing with current master to see if I have the same success rate as I previously posted and I will post routes.