Ford: set vEgoCluster using cluster scale and offset
The scaling and offset values in the Cluster_Info_3_FD1 message allow us to nicely match the cluster speed. Unfortunately, that message is only present on the CAN FD platform.
We need to bump cluster_min_speed to 1.5 kph otherwise we don't report 0 when stopped, because of the added offset.
Thanks for contributing to openpilot! In order for us to review your PR as quickly as possible, check the following:
- Convert your PR to a draft unless it's ready to review
- Read the contributing docs
- Before marking as "ready for review", ensure:
- the goal is clearly stated in the description
- all the tests are passing
- the change is something we merge
- include a route or your device' dongle ID if relevant
This is the exact code that me and some other CANFD users are using to keep in sync the cluster speed and OP speed.
We have been running this code for 5-6 months.
We've moved the car interfacing code to our opendbc repository, which is now the new home for car ports and fingerprints. Please re-open your pull request against opendbc at your convenience by using this command below. This will transform all changes under selfdrive/car/ to opendbc_repo/opendbc/car/. Make sure you have initialized submodules beforehand and have checked out the latest opendbc commit.
PR_NUMBER=33045
curl -L https://github.com/commaai/openpilot/pull/$PR_NUMBER.patch | sed -e 's/selfdrive\/car/opendbc_repo\/opendbc\/car/g' | git apply -v --reject
Simply replace the PR number with your own. Once done, add the files, fix any conflicts, and open a new PR. Alternatively, you may start a new PR from scratch if that is easier for you.