Device description file: How to define a target value (TargetValue section)

 

Name Type Def Tmp Incl Description
Type Attr 0 .. 1 0 .. 1 Possible values:

  • TargetValue
  • empty
<BitConverter> Elmt 1 1 The format of the value on the target device. Possible values:

  • Int16BitConverter
  • Int32BitConverter
  • Int8BitConverter
  • FixedPoint5_23BitConverter
  • FixedPoint16_16BitConverter
  • FixedPoint8_24BitConverter
  • FixedPointConverter (Attributes  DigitsBeforeDecimal- no of digits before decimal separator, DigitsAfterDecimal – no of digits after decimal separator. Supported fixed point bit formats are 16, 24 and 32. All bit formats are signed. Unused bits are not supported: DigitsBeforeDecimal+ DigitsAfterDecimal must be equal to 16, 24 or 32. Example : <BitConverter DigitsBeforeDecimal = “2” DigitsAfterDecimal = “22”>FixedPointBitConverter</BitConverter>
  • FloatBitConverter
  • UInt16BitConverter
  • UInt32BitConverter
  • UInt8BitConverter
  • Float16BitConverter
<Encode> Elmt 0 .. 1 0 .. 1 Conversion formula, written in C# code, and executed before the value is sent to the target device. e.g., 20 * Math.Log10(value). It must be the inverse of <Decode> formula.
<Decode> Elmt 0 .. 1 0 .. 1 Conversion formula, written in C# code, that is executed after a value is read back from a target device. e.g., Math.Power(10, value / 20). It must be the inverse of <Encode> formula.
<Mask> Elmt 0 .. 1 0 .. 1

A bit mask that can be defined to limit the update of the target device memory to specific bits. The main use case is in conjunction with an EnumSV.

If a single bit of the mask is:

  • 0 => bit of the memory cell is not used
  • 1 => bit of the memory cell is used

e. g. 0x08 => bit three is used – the reset is ignored.

 

_________________

Rate this post!