Instrumented Assemblies > Using Sensors > XML File Format for Sensor Parameters
  
XML File Format for Sensor Parameters
The list of the parameters you want to set for a sensor is defined in an XML file. Set the same data for a parameter as you would set for it in the Parameters dialog box.
Parameter Name must be unique. Parameters used in communication with a ThingWorx server, must meet the ThingWorxnaming conventions. These conventions are generally stricter than the Creo Parametric naming conventions.
Parameter Data Type is one of Numeric, Integer, String, or Boolean. When a Data Type is not specified, the default Data Type is Numeric.
Parameters with the Numeric data type can have units. Value restrictions can be set for data types with units.
Access for a parameter can be Locked, Full, or Limited
The examples below are sample XML parameter format files for regular parameters and series parameters.
Regular Parameter Format
<?xml version="1.0" encoding="UTF-8"?>
<CreoParamSet>
<ScalarParameters>
<Parameter Name="DISTANCE">
<Unit>mm</Unit>
<Restricted Type="Range">
<GreatThan>23.5</GreatThan>
<LessEqual>48</LessEqual>
</Restricted>
<Accuracy>2.5e-08</Accuracy>
<Description>This is a linear Sensor to measure a Distance</Description>
</Parameter>
<Parameter Name="COUNTER">
<DataType>Integer</DataType>
<Value>43</Value>
</Parameter>
<Parameter Name="COLORS">
<DataType>String</DataType>
<Restricted Type="Enumeration">
<EnumElement>Red</EnumElement>
<EnumElement>Green</EnumElement>
<EnumElement>Blue</EnumElement>
</Restricted>
<Access>Locked</Access>
</Parameter>
<Parameter Name="VELOCITY">
<Unit>mm</Unit>
<Accuracy>1.000000e-09</Accuracy>
</Parameter>
</ScalarParameters>
</CreoParamSet>
Series Parameter Format
<?xml version="1.0" encoding="UTF-8"?>
<CreoParamSet>
<Parameter Name="PARAMETER_1">
<ValueKind>Series</ValueKind>
<Unit>mm</Unit>
.........<Argument>
<Unit>sec</Unit>
</Argument>
<Table>
<TableRow>
<Value Column="ARGUMENT">0.000000e+00</Value>
<Value Column="PARAMETER_1">0.000000e+00</Value>
</TableRow>
<TableRow>
<Value Column="ARGUMENT">1.000000e+00</Value>
<Value Column="PARAMETER_1">2.000000e+00</Value>
</TableRow>
<TableRow>
<Value Column="ARGUMENT">3.000000e+00</Value>
<Value Column="PARAMETER_1">4.000000e+00</Value>
</TableRow>
</Table>
</Parameter>
</CreoParamSet>