Setting up Signal Name Mapping File
Signal Mapping is a feature of MxVDev that enables you to change the names of Signals in a TestCase so the TestCase can be re-used in more than one test environment. The mapping is applied when the TestCase (.mxc) file is loaded into MxVDev. You can also use the Connecting Signals dialog or the Name Mapping Transform for the same purpose.
Suppose that you create a suite of TestCases that run against a model, and you want to run the same tests in a SIL or HIL test environment. Part of the mapping of the TestCases from one environment to the next may be a name change. The name change, along with a linear scaling/offset change (if needed) can be accomplished with the MxVDev Mapping file.
The Signal Name Mapping file is selected under Other Files tab on the Project Settings dialog. Once selected, it can be enabled or disabled using the associated check box.
The Signal Mapping file is a Comma Separated Value file with two or four columns. The columns are described as follows:
•TestCaseName - The name of the Signal in the file being loaded or imported
•MappedName - The name that you want to be used in the TestCase in MxVDev, once the TestCase is loaded. This will usually correspond to an existing name in the Signal Dictionary.
•Scaling - The Scale factor to be applied to the Signal Value that is read from the TestCase Set to One if no scaling is required. This column is ignored when importing from a CSV file.
•Offset - The Offset to be added to the Signal Value that is read from the TestCase Set to Zero if no offset is required. This column is ignored when importing from a CSV file.
•The Scaling and Offset columns are optional. If omitted, scaling is set to 1 and the offset is 0.
•When the project file is opened, the mapping file is opened.
•When XML TestCase (.mxc) file is loaded, transformations are applied only if a Signal name match is found.
•Typically, the map file has the extension "csv", and is located in the project directory.
•Reverse Name and Scaling/Offset transformations are applied when the TestCase is saved.
•A comment can be added on the second line. Be sure to enclose it with quotes.
In the example below, the name of the Signal DEGREES_C, when used in any TestCase in the project, is transformed to DEGREES_F as the TestCase is loaded. Scaling or offset is applied to convert from Celsius to Fahrenheit (F=(9/5)*C+32). In the second example, only scaling is applied, to convert from Centimeters to Inches (cm=(1.0/2.54)*inch).
TestCaseName,MappedName, Scale, Offset
"Metric to US"