It is currently Tue Sep 02, 2014 3:34 am




Post new topic Reply to topic  [ 3 posts ] 
 Is this good practice? 
Author Message
Trooper
Trooper

Joined: Wed Dec 01, 2010 7:02 pm
Posts: 21
Post Is this good practice?
I have a script that runs on the property change event to update an SQL tag. The PLC is connected wirelessly. I have it in its own scan class to account for the slower comms / latency. Most days, this is good enough to prevent overlays and errors from popping up in the writeToTag script. Some days, it is not. The script runs every few seconds and on the bad days can be quite annoying with the error popup window. My sloution was to use an 'if' in the script. The property change event fires as often as it did before but the writeToTag only happens 'if' data quality is GOOD. The way I see it, the SQL tag would not get written when data quality is BAD either way. I am preventing the server from attempting to write when it can not, saving some unnecessary comms. Any issues with this method?

Shawn


Tue Jun 05, 2012 10:50 am
Profile
Moderator
Moderator

Joined: Fri Dec 04, 2009 9:02 am
Posts: 177
Post Re: Is this good practice?
Others may chime in, but that sounds like a valid solution to me.


Tue Jun 05, 2012 10:53 am
Profile
General
General

Joined: Tue Mar 24, 2009 9:14 am
Posts: 880
Location: Hudson, MI
Post Re: Is this good practice?
I do the same sort of thing with some of my transaction groups, since they want us to kill the mains on some of our machines-- as if a few PLCs not running offsets the three constantly running 150hp air compressors... :roll:

_________________
Jordan

Duct tape is like The Force. It has a light side, a dark side, and it holds the universe together.


Tue Jun 05, 2012 11:00 am
Profile
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 3 posts ] 


Who is online

Users browsing this forum: No registered users and 2 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to: