Sign in to follow this  
Followers 0
robbieb531

Email using a Control Logix and Enet Card

2 posts in this topic

Anyone know how to email more than one address using the MSG instruction in Logix 5000? i have everything configured just like the Allen Bradley manual for 1756-Enet cards suggest but it only shows how to send to one address. Do i have to have another MSG instuction for each email address?

Share this post


Link to post
Share on other sites
What I do is use a series of ASCII inserts and a status marker to build the email message, then I send the message to the first recipient and clear the string that i have used for the message and start setting up the next one in the same manor. When I need to do this I create a UDT with all email addresses I have to send to and all messages I need to send. The UDT also includes some status bits to set and reset for who has had the message sent to them. I also use a simple ADD function to add 1 to a register every few second and use this for a rolling trigger for the messages. Once all recipients have had the message sent to them I clear all their status bits and look to see if there are any other messages that need to be sent. It can get some what complicated so I use the status marker to keep track of what is going on. Be low is a example of what I am talking about, hope it makes scene. If message_needed_trigger EQU 1 and one of the recipients sent bits are 0 then if email_MSG.EN is 0 then ( this would be the MSG instructions control tag) MOV 1 to status marker if status_marker EQU 1 then CLR email_message and MOV 2 to status_marker if status marker EQU 2 then if recipient_one_message_sent is 0 then insert email_address_1 into email_message and MOV 3 to status_marker (the email address will contain the To: dan@xyz.com From: systemPLC@xyz.com Subject:) if status_marker EQU 3 then if message_rolling_trigger is 1 then insert message_1 into email_message start at email_message.LEN and MOV 4 to status_marker (now the message is complete and ready to be sent) if status_marker EQU to 4 then MOV email_message.LEN to email_MSG.REQ_LEN and MOV 5 to status_marker ( this is when we move the message length into the MSG control tags length) After all then is done and the status_marker is EQU to 5 the message get triggered and sent. On the .DN bit I do a little house keeping i.e. clear the status_marker and set the bit that the recipient 1 has received the message. I hope this makes scene and I apologize if it does not, sometime I have a hard time explaining things. This is the basic setup I use, and should get you started, I also program a way for a user to insert and enable recipients through an HMI. If you need more help let me know.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!


Register a new account

Sign in

Already have an account? Sign in here.


Sign In Now
Sign in to follow this  
Followers 0