UDSLib: ISO 14229 Stack for Production
Portable, MISRA-aligned UDS (ISO 14229-1) stack with deterministic memory, Zephyr/native ISO-TP support, and built-in tooling.
Licensing
- Community: PolyForm Noncommercial 1.0.0 (noncommercial only). See
LICENSE.
- Commercial: 5,000 EUR, includes integration support (up to 40h) and 1 year of updates/support. See
COMMERCIAL_LICENSE.md or email [email protected].
- Evaluation: Development/testing allowed under the community license. No production/for‑profit use without the commercial license.
Key Capabilities
- Services: all 27 of 27 ISO 14229-1 application services (0x10/11/14/19/22/23/24/27/28/29/2A/2C/2E/2F/31/34/35/36/37/38/3D/3E/83/84/85/86/87). See docs/SERVICE_COMPLIANCE.md.
- Safety & Quality: Deterministic, zero-malloc memory model; NRC priority enforcement; Safety Gate callbacks; MISRA-C:2012 checked in CI (no mandatory-rule violations, deviations documented).
- Transports: Zephyr ISO-TP sockets or built-in ISO-TP fallback (static buffers) with CAN-FD support.
- Tooling: Host simulator, Wireshark dissector, Python
pyudslib harness, Dockerized CI scripts.
Quick Start (Linux)
sudo apt-get install build-essential cmake libcmocka-dev
mkdir build && cd build
cmake ..
make
ctest --output-on-failure # optional: run tests
Run host simulator:
./examples/host_sim/uds_host_sim
Integrate
- Provide time source, TX/RX buffers, and transport send function via
uds_config_t.
- Call
uds_input_sdu() with complete SDUs; call uds_process() periodically to drive timers.
- For Zephyr, use the native ISO-TP wrapper; for bare metal, use the internal ISO-TP fallback.
Session Analysis & Reporting
Generate a visual HTML dashboard to analyze UDS sessions (CAN-FD/ISO-TP):
# 1. Run simulation with capture (CAN-FD mode, Default)
./run_capture.sh
# Option: Run in Classic CAN mode (8-byte frames)
./run_capture.sh classic
# 2. View the generated report
# Open 'artifacts/capture/session_report_fd.html' (or '..._classic.html')
The analyzer includes:
- Visual Interface: Dark-mode HTML dashboard.
- Rich Details: Decodes timestamps, specific services, and raw payloads.
- Flow Analysis: Visualizes TX/RX direction and ISO-TP frame types (SF/FF/CF/FC).
Repository Structure
include/uds/ public API headers
src/core/ protocol logic
src/transport/ ISO-TP fallback
examples/ host simulator and integration templates (index)
extras/ Wireshark dissector, Python bindings
docs/ architecture, integration, transport, and testing guides
Support & Licensing
Commercial inquiries: [email protected]
Community questions: open an issue on GitHub.
Documentation
For deeper dives into the project’s design and future, please refer to the following documents:
- Architecture - Design philosophy, component diagrams, concurrency model, and transport strategy.
- Service Compliance - Authoritative ISO 14229-1 service matrix.
- OSAL - Two-context concurrency model and RTOS integration.
- Roadmap - Project phases and upcoming features.
评论