Sending SNMP trap - old forum post

aurore

Joined on 07-29-2005
Posts 7
SNMP and windows xp error

Hello, I have an opto22 SNAP-UP1-M64. I did a program with IoControl and I did the HMI with IoDisplay. I would like that the opto22 send a SNMP trap when an alarm occurs that is to say when a digital point has as value 1. How can I do? I have seen that I can use the scratch pad bit but I have not understood. Can you help me? Thanks a lot Best regards
Report
07-29-2005, 5:26 PM
rhernandez

Joined on 11-26-2003
Madrid - SPAIN
Posts 42
Re: SNMP and windows xp error

Hello Aurore. Your first question has two solutions: 1. Use the built-in event-reaction feature of the UP1. 2. Use ioControl to decide what and when to send. Solution #2 allows you to customize message a lot and complicate the logic but I think it is better to start with a simple feature, so I’ll focus on approach #1. You are right, the ScratchPad bits are involved here. If you are not sure about the purpose of the ScratchPadBits, Think of them as a second virtual digital point bank. All you need is the Inspect tool of ioManager to get the traps going out. (Supose you want to send the message “Lights turned on” when digital point #4 turns on) Step 1. Configure SNMP. - Click on Communications->SNMP. - Locate the “public” community and enable Traps. - Then scroll down till you see the host 0 entry, configure its community to “public” and type in the IP address of the target computer for SNMP traps. - Don’t forget to press the [Apply] button. Step 2. Setup the triggering event. - Click on Events->Digital Events - Configure event #0: In the 1st section you enter a mask that the digital bank (or scratch pad) should stick to in order to trigger the event. Since we want the event to trigger when point #4 is ON, we enter 00000000 00000010 as our Digital ON mask. - Now the reaction. All we can do at this point is to reflect the event in the ScratchPad. We indicate, again using a mask, which bits must turn on and which ones off. In our sample we raise bit #0, so we enter 00000000 00000001 in the reaction ScratchPad bits ON field - Again press the [Apply] button Step 3. Setup the event message. - Click on Events->Event Messages - Type in the message text. - Enter the Scratch Pad State that activates the message. Another 2 masks. Since we have used ScratchPad bit #0, we enter 00000000 00000001 again in the ScratchPad Trigger ON field. - Enable SNMP trap - Press the [Apply] button Finished? - Not yet! We now have instructed the UP1 to activate the message when point #4 turns on. But when that point turns off, the UP1 will not deactivate the message, thus, next time the point turns on, there will not be a corresponding SNMP trap going out. We need to set up a second digital event. Step 4. Setup the clearing event. - Click again on Events->Digital Events - Configure event #1: now we enter the mask 00000000 00000010 in the Digital OFF section. - And for the reaction we enter 00000000 00000001 in ScratchPad bits OFF - Again press the [Apply] button Step 5. One more thing to do: Store config to flash and restart the UP1. That can be done using the [Status Write] button Summary The bit #0 of the ScratchPad acts as mirror of digital point #4. It also activates and deactivates the event message #0 who happens to be an SNMP trap. I hope this helps. I know there are a lot of dark points in my explanation but if I extend more I’ll end up writting back the user’s manual. Do not hesitate to post back any doubt you still have.
Report
08-01-2005, 1:19 AM
aurore

Joined on 07-29-2005
Posts 7
Re: SNMP and windows xp error

Hello, I succeed to send SNMP Traps. thanks very much.Best regards. Aurore Tondeur Thales Communications Lambersart - France.