8000 Tesla: move safety out of debug by sshane · Pull Request #2285 · commaai/opendbc · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

Tesla: move safety out of debug #2285

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 2 commits into
base: master
Choose a base branch
from
Open

Tesla: move safety out of debug #2285

wants to merge 2 commits into from

Conversation

sshane
Copy link
Contributor
@sshane sshane commented May 23, 2025

No description provided.

@sshane sshane requested a review from adeebshihadeh May 23, 2025 01:15
@github-actions github-actions bot added the car safety vehicle-specific safety code label May 23, 2025
Copy link
Contributor
@adeebshihadeh adeebshihadeh left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Still reviewing the steering checks, but here's comments so far.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

let's move RAD_TO_DEG, ISO_LATERAL_ACCEL, and anything else like EARTH out of here

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

let's put our jerk limit in the constants file too and leave a comment that it's lower than ISO

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

why is there a check for limits.inactive_angle_is_zero? should be constant within a safety mode

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

standardize on chksum or checksum

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

was TESLA_MAX_SPEED_DELTA verified with data?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

why is there a check for limits.inactive_angle_is_zero? should be constant within a safety mode

It was copied from the standard angle check function, the plan was to combine the two functions. But I think we should refactor the current angle function before doing that as it's way too big

Copy link
Contributor Author
@sshane sshane May 24, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

for brake press, IBST_driverBrakeApply has a fault state we should check

Usually, quality flags describe the signal they protect (ESP_wheelSpeedsQF). That's a generic iBooster status that may or may not be relevant to driver brake press.

Edit: Ah, I see IBST_driverBrakeApply=FAULT #2292

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

pull out the invalid speed check, nothing in modes/ should touch controls_allowed. these files are just parsers.

#2294

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

tesla_steer_angle_cmd_checks should be moved. again this file should essentially be a parser

#2298

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

moved some constants: #2300

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
car safety vehicle-specific safety code
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants
0