Skip to content

feat(services,cli): log --ids reads raw bytes by identifier over KWP2000 and UDS - #23

Open
JoeeDeveloper wants to merge 1 commit into
mainfrom
chore/issue-audit
Open

JoeeDeveloper wants to merge 1 commit into
mainfrom
chore/issue-audit

Conversation

@JoeeDeveloper

Copy link
Copy Markdown
Owner

Closes #7.

Summary

  • opendiag log --ids 0x01,0x02 reads KWP2000 local identifiers (0x21) and --ids 0xF190 UDS data identifiers (0x22) at a steady rate and writes time_ms,id,length,hex CSV. Works with --replay and --trace.
  • Nothing is decoded. A search found no authoritative public source for the VAG measuring-block byte layout over KWP2000 (only an unverified community snippet), so decoding to (formula, a, b) would be a guess. The bytes are logged as they arrive; the finding is recorded in docs/sources.md.
  • New RawData trait and Module::raw_data() (also forwarded through VehicleModule, so BMW UDS ECUs get it too); the logging schedule is shared with log_csv via one run_rounds helper.
  • The KWP simulator gains 0x21 (unknown id answers requestOutOfRange); demo module has local ids 0x01 and 0x02 whose last byte moves between reads.
  • Refreshes the stale "Not done" line in CLAUDE.md and the README after an audit of the issue tracker (TP2.0 transport/client for VAG CAN modules #5, Wire KWP2000 and KW1281 into opendiag-services and the CLI #6, Open data format v0: JSON Schema, validator, contribution guide #8 were already implemented and are closed).

Not covered

  • The serve dashboard still shows KW1281 measuring blocks only; raw identifiers are CLI-only for now.
  • KW1281 modules refuse --ids and use --groups.
  • Simulator-only: nothing here has read a real KWP2000/UDS module.

Test plan

  • fmt, clippy -D warnings, cargo test --workspace (415 passed, 0 failed)
  • 7 new service tests (hex output, grid, unknown id, unsupported id, empty/zero interval, duration limit, KW1281 refusal) and 3 new CLI tests incl. record-then-replay for KWP2000 and UDS

🤖 Generated with Claude Code

https://claude.ai/code/session_01Xe1HmJJjhbWaBGaF6FKosA

…000 and UDS

ReadDataByLocalIdentifier (0x21) and ReadDataByIdentifier (0x22) are logged as uninterpreted hex. No public source was found for the VAG measuring-block layout over KWP2000, so nothing is decoded (see docs/sources.md). Also refreshes the stale status line in CLAUDE.md and the README.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01Xe1HmJJjhbWaBGaF6FKosA
@JoeeDeveloper JoeeDeveloper added this to the Phase 3 - Read-only MVP milestone Nov 24, 2026
@JoeeDeveloper JoeeDeveloper added enhancement New feature or request area:vag VAG: KW1281, KWP2000, TP2.0, UDS area:services Services layer and guarded write flow area:cli Command line interface labels Nov 24, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area:cli Command line interface area:services Services layer and guarded write flow area:vag VAG: KW1281, KWP2000, TP2.0, UDS enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Live data over KWP2000 and UDS as raw bytes (KW1281 and BMW logging already exist)

1 participant