Control Solutions is your source for LonWorks I/O.

How do I set up an SNMP trap?

Modbus register data is placed in local registers using Read Maps and Write Maps. Each local register is accessible by standard SNMP Get and Set requests. Threshold "rules" determine when traps are sent. The image below is an actual screen shot of a threshold rule that will result in a trap when the Modbus data mapped to local register 7 exceeds a level of 1000. Data values are scaled to any units you decide. You find the threshold rules in the System->Action Rules->Thresholds page.

Additional configuration pages allow setting the IP address or Host Name of one or more SNMP managers that v2c traps are to be sent to. Traps may be repeated periodically for as long as the rule tests true. Trap data includes the register name and number, data value that caused the trap, the event name, test type, and test threshold.

Once you have the Threshold Rule set up, you need to go to the IP Network->SNMP Setup->Trap Enable page and check off whether to trap on true, false, or both, and also which group(s) to send the trap to. The following is what you would see for the above rule:

The other tabs under IP Network->SNMP allow you to set up the SNMP manager IP addresses or host names for each of up to 3 groups.

How do I prevent spurious traps when the test value is hovering around the threshold?

Hysteresis will prevent spurious traps near the threshold. In the following example, the trap will occur when register 7 reaches a level of 1000. If register 7 drops below 1000 by a margin less than 50, then returns to above 1000, the trap will not repeat. The value of register 7 must drop below 950 and return to over 1000 before the trap will repeat.

How do I generate a trap only after the condition has existed for a minimum time?

The on/off time qualifications are used to add time to the criteria. The following example shows a minimum on time of 30 seconds. This means the data in register 7, placed there by a Read Map, must exceed a level of 1000 for at least 30 seconds before a trap will be generated. If the minimum off time was also set, the rule must test false for that amount of time before it can repeat the "true" trap.