system.tag.addTag - alarmConfig

Following the example from the manual, I am able to successfully create tags with alarms on the fly. Only problem left is trying to set the “mode” attribute - I would like the alarm trigger to be != 0. Here is what I have:

[code] system.tag.addTag(parentPath = “QA/Messages”, name = tagName,
tagType = “MEMORY”, dataType = “Boolean”, value = 1,
alarmConfig = {“QArequest”: [[“name”, “Value”, “QArequest”],

[“mode”, “Value”, “Not Equal”],

		["NotificationList", "Value", notify], 
		["activePipeline", "Value", pipeline], 
		["ackMode", "Value", "Unused"], 
		["RequestType", "Value", type], 
		["RequestID", "Value", id], 
		["CustomEmailSubject", "Value", "QA Notification"], 
		["CustomEmailMessage", "Value", message]]})


This works great except when I uncomment the 4th line I get:

QArequest exception occurred: (<type ‘com.inductiveautomation.ignition.client.gateway_interface.GatewayException’>, com.inductiveautomation.ignition.client.gateway_interface.GatewayException: Alarm property ‘mode’ is invalid or value is an incorrect data type, <traceback object at 0x3>)

When I manually change the alarm on the tag to trigger != 0, then query the alarm properties, it returns:

mode Value Not Equal
setpointA Value 0.0
NotificationList Value BryceEmail
RequestType Value 2
CustomEmailMessage Value QA Tasting Approval requested by STB at 11:13:53 to Begin Packaging ST4381-82 1
activePipeline Value Email Alarms
RequestID Value 28
name Value QArequest
CustomEmailSubject Value QA Notification
ackMode Value Unused

So where am I going wrong getting an invalid “mode”??

Bryce Troy
Control Systems Engineer
Left Hand Brewing Company

I’m guessing it is expecting an integer value. Try changing it to [“mode”, “Value”, “0”] or [“mode”, “Value”, 0].

If that works it’s just a matter of figuring out the mode enumerations.

You called it. An integer value of 1 comes out as “Not Equal”. So this works:

["mode", "Value", 1], 	[i]# Not Equal[/i]

Thanks - Bryce

I realize I am replying to an old post, but I am not able to reproduce all that I see there.

In particular the NotificationList. I have my emails working with the roster set up in my pipeline. But when I populate NotificationList it has no effect. I was hoping it would override the recipients in the pipeline.