_msg_conv

Constants for the ".._type" attribute

CTRL constant int value Description
DPCONFIG_NONE 0 No conversion
DPCONFIG_CONVERSION_RAW_TO_ING_MAIN 33 Conversion raw into treated value
DPCONFIG_CONVERSION_RAW_TO_ENG_MAIN 33 Conversion raw into treated value

"_msg_conv.<i>._imp_edge" counter impulses

The following integer constants determine how counter impulses are converted. The detail number in the attribute refers to the index of the counter-impulse conversion among other conversions for the datapoint element (see attributes "_msg_conv.<i>._type" and "_cmd_conv.<i>._type"). "_msg_conv.2._imp_edge", for example, refers to a value whose second conversion in the direction of an alert is a counter-impulse evaluation (see dpSet()).

CTRL constant int value Description
DPATTR_COUNT_POS_EDGES 0 0->1 edge
DPATTR_COUNT_NEG_EDGES 1 1->0 edge
DPATTR_COUNT_ALL_EDGES 2 all edges
DPATTR_COUNT_POS_PULSES 3 1 impulse
DPATTR_COUNT_NEG_PULSES 4 0 impulse

"_msg_conv.<i>._type>, "cmd_conv.<i>._type> attribute

Datapoint elements can be added to a conversion using the following integer constants. First you have to define the "_msg_conv.._type" and afterwards the "_msg_conv.<i>_type" (see example). The detail number in the attribute determines the sequence of the conversions: "_msg_conv.2._type" refers to the second conversion of a value in the direction of an alert (see dpSet()).

CTRL constant int value Description
DPDETAIL_CONV_NONE 0 no conversion
DPDETAIL_CONV_LIN_INT 3 conversion using point curve factor
DPDETAIL_CONV_LOG 1 logarithm conversion
DPDETAIL_CONV_POLY 2 conversion according to a polynomial to the 4th degree
DPDETAIL_CONV_PREC 8 conversion with accuracy (rounding)
DPDETAIL_CONV_NULL_SUPP 4 conversion with starting-point suppression
DPDETAIL_CONV_TRIGGER 7 trigger function (conversion analogous -> digital)
DPDETAIL_CONV_COUNTER 9 conversion of counter impulses
DPDETAIL_CONV_INVERT 5 invert

exampleExample

Create a _msg_conv config with a configured trigger definition:

main()
{
  dpSetWait("TestDP_1.element:_msg_conv.._type",
  DPCONFIG_CONVERSION_RAW_TO_ENG_MAIN,
  "TestDP_1.element:_msg_conv.1._type",
  DPDETAIL_CONV_TRIGGER,
  "TestDP_1.element:_msg_conv.1._trig_lim", 10,
  "TestDP_1.element:_msg_conv.1._trig_up",TRUE);
}

Further details on the config "_msg_conv" you will find in the chapter Module PARA - _cmd_conv, _msg_conv (conversion).

Details about converting treated to raw values

see datapoint config "_cmd_conv"