Calibrate Parameters with Vector CANape

This example shows how to view signals and tune parameters by using Vector CANape®. You must have already completed the steps in Prepare ASAP2 Data Description File.

You also must be familiar with the Vector CANape user interface. For information about the user interface, see the vendor documentation (

Prepare Project

  1. Build and download real-time application ex_slrt_cal_osc.

  2. Open Vector CANape.

  3. Create a Vector CANape project with project name ex_slrt_cal_osc.

    Accept the default folder.

Prepare Device

  1. From ex_slrt_cal_osc_slrt.a2l in your build folder, create an XCP device named ex_slrt_cal_osc_slrt.

    Do not configure dataset management.

  2. Select your local computer Ethernet adapter as the Ethernet channel

  3. Accept the remaining defaults.

  4. Upload data from the device.

Configure Signals and Parameters

  1. Open device ex_slrt_cal_osc_slrt, and then open ex_slrt_cal_osc_slrt.a2l.

  2. Add signals DampedOsc, SignalGenerator, L_1D, and L_2D in separate display windows.

  3. To make the waveform easier to evaluate, set the time and y-axis scaling.

    For example, try the following settings for DampedOsc:

    • y-axis min home value — –25

    • y-axis max home value — 25

    • Min home time-axis value — 0 s

    • Max home time-axis value — 0.1 s

    • Time duration — 0.1 s

  4. Open the measurement list.

  5. To set the required sample time for a signal, open the measurement properties for the signal. Select the required sample time from the measurement mode list.

    The default sample time is the base sample time.

  6. Add a graphic control on parameter Kg.

Perform Signal Measurement and Parameter Calibration

  1. Start the Vector CANape measurement.

  2. In Simulink® Real-Time™ Explorer, start the real-time application.

    The signal windows show the four waveforms, corresponding to the displays on the target computer screen.

  3. To shorten the ring time on DampedOsc, L_1D, and L_2D, set parameter Kg to, for example, 800.

  4. As required, toggle between calibration RAM active and inactive.

Related Topics

External Websites