KydeX Posted March 30, 2017 Report Share Posted March 30, 2017 Hi. I have a Vision 350 with ethernet module. I am connecting to the PLC via a remote device (Sitemanager from Secomea). This device can listen for messages on specific TCP/UDP port. The default port is 26864 for both. It can then trigger alarms and send SMS or email messages to the recipient. To do it, I need to send a message in the format: /UserName/PassWord/MobilNumber/AlertText. Username and password is optional. A typical message could be example: /+4511223344/Message text 1 to be send. So, my question is, can I use any of the TCP/IP functions in the 350 to send a message string like this to a specific port? Link to comment Share on other sites More sharing options...
Cam Posted March 30, 2017 Report Share Posted March 30, 2017 You should be able to use the Protocol TCP/IP: Send to do what you need, FB>protocol TCP/IP I've done something similar using serial and that protocol FB, I've never tried it on TCP/IP before. Link to comment Share on other sites More sharing options...
KydeX Posted March 31, 2017 Author Report Share Posted March 31, 2017 I've now used the FB Protocol. I followed the guide in the instructions. I've initialized the ethernet card and the socket 0 during powerup, and also the protocol. Socket 0 is initialized as TCP and to port 26864 (This is the default listening port on the Sitemanager). Whenever there is an alarm that should trigger an alert message, I use the connect socket 0 FB and then the Send TCP FB. In the Sitemanager logfile, I can read that it has received a message request from the Visio, but that the request times out because the request is incomplete. I am guessing that the message format from the Visio might not be correct? I am not sure how to be able to do this. Does the message have to be send on specific socket or port from the Visio perhaps? Edit: I made it work. It had to do with the timing of sending the message. I was trying to send the message before the socket was properly connected. If I used the SB for "socket connected" as a trigger for sending the message, it worked. Link to comment Share on other sites More sharing options...
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now