This is a discussion on SQL to PLC to diverter gate, can this be done? within the SQL Server forums, part of the Microsoft SQL Server category; --> First, I know nothing about PLC's, but I was wondering is there a way to extract data from a ...
| |||||||
| Register | FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read |
| ||||
| First, I know nothing about PLC's, but I was wondering is there a way to extract data from a SQL database file, feed that to a PLC is some manner, and then have the PLC trigger a diverter gate based on the value in the table exceeding a certain value, to divert parts to another location. Am I off base, or is there something out there that will allow or help me to do this. Any help would be greatly appreciated. |
| |||
| Hi This will depend on the method the PLC is programmed. You can pull data from a SQL Server database using many different interfaces A starting place may be http://msdn.microsoft.com/library/de...asp?frame=true In general using the database as a realtime system is not what they are designed for. You may want to implement an event from a trigger using a COM object and the sp_OA* procedures or possibly using the existance of a file as an event (or similar using some form of polling). It may also be possible to do this with Notification Services http://msdn.microsoft.com/library/de...asp?frame=true If using a trigger you should make sure that it is not left waiting for something to happen as this will extend the duration of your transactions. John "Razorbak71" <razorbak71@yahoo.com> wrote in message news:c4aa35eb.0311061930.1262a64c@posting.google.c om... > First, I know nothing about PLC's, but I was wondering is there a way > to extract data from a SQL database file, feed that to a PLC is some > manner, and then have the PLC trigger a diverter gate based on the > value in the table exceeding a certain value, to divert parts to > another location. > > Am I off base, or is there something out there that will allow or help > me to do this. Any help would be greatly appreciated. |
| ||||
| In article <c4aa35eb.0311061930.1262a64c@posting.google.com >, razorbak71 @yahoo.com says... > First, I know nothing about PLC's, but I was wondering is there a way > to extract data from a SQL database file, feed that to a PLC is some > manner, and then have the PLC trigger a diverter gate based on the > value in the table exceeding a certain value, to divert parts to > another location. > > Am I off base, or is there something out there that will allow or help > me to do this. Any help would be greatly appreciated. This is done all the time in control systems - been doing it for almost 10 years myself. There are many ways to do this, but it depends on which PLC you are using. Most common methods are a VB app speaking DDE to a PLC communications app that lets you specify a address/data type. Other methods include HMT/MMI screen applications that already have the ability to interface with the database and PLC and act as the middle (communications) path. There are also things like RSSQL by AB/Rockwell that make this real nice. Keep in mind one thing - do not write the set-points directly to the registers used to control the gate. Put the set-points in a holding area, check them for valid range, then move them to the set-point area. My email address is shown below (remove the 999) if you want to email me about this. -- -- spamfree999@rrohio.com (Remove 999 to reply to me) |