Hey all,
I'm trying to create a calc record that looks at previous values to increment a count. See below
record(calc, "RESULT_A")
{
field(SCAN, ".05 second")
field(INPH, "RESULT_A.LG")
field(INPA, "RESULTINPA")
field(INPC, "RESULTINPC")
field(INPB, "RESULT.LA")
field(INPE, "RESULTINPE")
field(INPD, "RESULT.LC")
field(INPG, "RESULTINPG")
field(INPF, "RESULT_A.LE")
field(CALC, "A#B?1:0+C#D?1:0+E#F?1:0+G#H?1:0")
}
If I change B to LA in the calc string above I get this error during dbLoadRecords
RESULT_A.CALC: Syntax error, unknown operator/operand in _expression_ "A#LA?1:0+C#D?1:0+E#F?1:0+G#H?1:0"
First I'd like to ask if the 'last' fields are usable this way. From the record reference manual it appears they are. Second, does anyone have a better way of just incrementing a count anytime the inputs change? Any help is very much appreciated.
Neil Hamilton Jr