You need to use both the alarm value (for the trigger - set to ‘x
’) and the include the frequency value (for the e-mail - set to ‘y
’). You then need to set the e-mail condition trigger to only evaluate when the alarm is triggered, i.e., ExpressionText=x > 0
.
You will need to process values continuously to pull this off, so frame rate will need to match frequency rate, e.g., 30, and you will need to set UseLatestVaues
to false
so that measurements are processed at their native rate.
Also, since the alarm value will arrive rarely and the frequency value will arrive consistently, the alarm value will be substituted with a sentinel value which defaults to NaN
. We set sentinel value to -1
instead to produce a cleaner negative answer to the expression condition of x > 0
which will be evaluated with each received frequency. See updates to connection string below:
Email Notifier connection string
From=abc@Test.com.au; SmtpServer=Test; Subject=OpenHistorian Alarm;
Body={The frequency value (y) is {y:N3}.}; ToRecipients=abc@Test.com.au;
VariableList={x = AL-HIGH:ABCX!TP!ABC:FREQ; y = PPA:20274};
ExpressionText=x > 0; FramesPerSecond=30; LeadTime=5.0; LagTime=5.0;
UseLatestValues=false; SentinelValue=-1.0