Example Code

Update System Definition File for New XCP/CCP Master A2L File

Products and Environment

This section reflects the products and operating system used to create the example.

To download NI software, including the products shown below, visit ni.com/downloads.

    Software

  • ECU Measurement and Calibration Toolkit

Code and Documents

Attachment

Description

Overview

In NI VeriStand, A2L files are required to operate the ECU Measurement & Calibration Toolkit XCP CCP Master custom device. During testing and development ECUs, A2L files may be continually modified. When this happens, the NI VeriStand user must update the existing system definition A2L file with the new one. This process can cause mappings and aliases to break in the process and does not remove Characteristics/Measurements that no longer exist. This example was created ease that process. The Update System Definition A2L.vi will remove all characteristic and measurement channels not found in the new A2L file from an existing system definition. It will also delete all mappings and aliases associated with the old characteristics and measurements. It will then replace the A2L file reference with the new file. Note that this process does not add new characteristics or measurements to the system definition file.

 

Steps to Implement

  1. Download and extract the attached .zip file.
  2. Open the Update System Definition A2L.lvproj.
  3. Open the Update System Definition A2L.vi.
  4. Set the OLD A2L to the file path of the old A2L file referenced in the system definition file.
  5. Set the NEW A2L to the file path of the new A2L file which will replace the old A2L file.
  6. Set the System Definition File to the path of the system definition file which will be modified.
  7. Run the VI.
  8. Old Characteristic Count indicates the number of Characteristics removd.
  9. Old Characteristics indicates which Characteristics were removed.
  10. Old Measurements Count indicates the number of Measurements removed.
  11. Old Measurements indicates which Measurements were removed.

 

2014-04-30_1352.png

 

Requirements

This example was developed in LabVIEW 2012 for VeriStand 2012 and ECU Measurement & Calibration Toolkit 2.3.1. Users in newer versions of LabVIEW will be required to upgrade the VI and relink the .NET library to their version of NI VeriStand.

National Instruments
Senior Systems Engineer

Example code from the Example Code Exchange in the NI Community is licensed with the MIT license.

Contributors