Embedded and systems
XCP
XCP is an ASAM standard protocol for measuring internal variables of a running control unit and adjusting parameters without rebuilding the firmware. The variables are described in an A2L file.
Also known as: Universal Measurement and Calibration Protocol, A2L, ASAM MCD-1 XCP, calibration
Measurement and calibration
XCP has two main jobs:
- Measurement: internal values such as controller states, intermediate results or counters are read cyclically from the control unit, synchronised with its tasks
- Calibration: parameters, curves and maps are changed during operation to tune the behaviour
Which value lives at which memory address and how its raw value is converted is described in an A2L file, typically generated when the firmware is built.
XCP is the successor of CCP and runs over various transports, including CAN, Ethernet, USB and serial interfaces.
XCP in testing
From outside, a test only sees inputs and outputs. With XCP it can look inside: has the state machine reached the right state? Has the controller calculated the expected setpoint? This makes failures faster to locate and allows checks that would be impossible through the interfaces alone. Parameters can also be adjusted for individual test cases.