commaai / opendbc

a Python API for your car
MIT License
1.93k stars 1.13k forks source link

GM Camera ACC ICE: ECM respects different brake signal than camera #1123

Open sshane opened 4 months ago

sshane commented 4 months ago

This is a stock ACC route where the user pressed the brake and caused an ACC fault we alerted for. It appears that the camera uses what we found for the Bolt, a single bit signal: ECMEngineStatus->BrakePressed as it stayed engaged until the ECM faulted. However the ECM might look at ECMAcceleratorPos->BrakePedalPos or EBCMBrakePedalPosition->BrakePedalPosition. These bugs are ridiculous!

I performed extensive tests to find an appropriate brake signal for the Bolt, so this looks like it might only apply for ICE GMs. Perhaps this only surfaces when ACC is braking itself as the user is adding little brake pressure compared to what is already being applied, and the ECM looks at the position.

image

dc7716b32bf25574/2024-05-24--18-30-20

garrettpall commented 2 months ago

I’m having the same issue with my SDGM car with OP long enabled (using custom hardware). I will do some testing this week

garrettpall commented 2 months ago

Using ret.brakePressed = ret.brake >= 8 seemed to fix the issue with my car. Will continue to test this week