Hacktoberfest 2026: những issue maintainer đã đánh dấu cho tháng Mười, đang mở và phù hợp người mới. Xem issue Hacktoberfest

Check the vehicle state before sending each command

Đang mở
#73 0 bình luận 0 reaction 0 người được giao Xem trên GitHub

Maintainer thường phản hồi trong vòng 1 ngày

Chưa có ai nhận issue này.

Đánh giá

Issue này chưa được đánh giá.

Mô tả

enhancement

Part of the prerequisites for real commands (tracking issue to follow). Related: #14, #11.

Problem

The generic "command availability" work (#14, contracts#13) is a larger feature and will come later. Until then, a command handler that just sends frames could, for example, open the charge port or close a window while the car is driving, or act on a state that went stale when the bus fell silent. All E-GMP commands are still "Not implemented" (#37–#42), so this can be settled before the first one lands.

Proposal

  • A shared check that runs before a command's frames are built. Each command declares the state it needs, and a command that doesn't hold is answered with a failed CommandResponse and a clear message. A dedicated status code comes with contracts#13.
  • State freshness counts as a precondition. Don't act on state older than N seconds, or while the bus is silent (see #11).
  • The response is always sent, including when the command is rejected because read-only is on or the identity isn't confirmed.
  • Consider a minimum interval between repeats of the same command, so a stuck button can't flood the bus.
  • Each command PR lists its preconditions in its description and in docs/. Candidates to settle per command from real behaviour: not driving (charge port, trunk and frunk), car awake, current state differs from the requested one.

Done when

There is a helper and tests with fixture states, the docs describe the rule, and the first implemented command uses it.

Ngôn ngữ chính
Rust
Star
1
Fork
0
Merge trung bình
12 giờ 49 phút
Pull request đã merge (30 ngày)
19

Chuẩn bị môi trường

Mở trong Codespaces

Khởi chạy dev container của dự án ngay trên trình duyệt, bằng tài khoản GitHub của bạn.

  • Không có Dockerfile hay tệp Docker Compose
  • Không có mẫu pull request
  • Không có hướng dẫn đóng góp

Bắt đầu từ đâu

  1. Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
  2. Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
  3. Fork repository và làm thay đổi trên một nhánh.
  4. Mở pull request có tham chiếu số hiệu của issue.

Issue khác của OpenCarControls/firmware

Tất cả issue của OpenCarControls/firmware

Issue tương tự

Thêm issue về Rust

Nhận issue mới trong hộp thư của bạn

Bản tóm tắt ngắn những issue GitHub phù hợp với người mới.