PLC that uses labview as language

umlphysics

Member
Join Date
Jun 2008
Location
Lowell, MA
Posts
4
I am relatively new to the PLC world, my company is looking for a PLC that uses Labview as its programming language or something that labview can be configured to work with. We want labview cause we are a student research facility and it will be much easier to understand the program in the PLC since we use Labview for countless other projects and measurements.

Any information would be greatly appreciated!!

Thanks,
~Dan
 
Dan,

...it will be much easier to understand the program in the PLC since we use Labview for countless other projects and measurements.
That is a debatable statement. For me it would not be true. If these students will be working in various workplaces, it might be wise to teach them some PLC programmming, as well as Labview. Who knows how long any particular language will be viable? Software changes as hardware gets upgraded.

I don't know of any PLC that is directly programmable using Labview. However, there are interface program methods that will allow Labview to be used with any PLC. National Instruments (the creator of Labview) uses OPC to work with many PLCs. That does not mean it will be simple or easy for students.

http://zone.ni.com/wv/app/doc/p/id/wv-263

Kepware OPC is another option. See this post at:

http://www.control.com/thread/1026243789

Posted by Fred Loveless on 22 February, 2008 - 4:59 pmIt really depends on which version of Labview you are using. 8.5 includes an NI OPC server and has a very nice OPC connection configuration. Older versions will require you to create and OPC or DDE data socket to connect to the server.

Your best option is to go to the NI forums for Lab view. There will be a Labview expert that can provide a VI for either option in the older versions.

You could also use Kepwares OPC server for this connectivity. one server supports both OPC and DDE conenctivity. I made the following notes a long time ago for doing OPC to KepserverEx in Labview 5.0. They may get you headed in the right direction.

Labview Notes

1. Create a new VI2. Save and name the VI. Ours is "Kepware OPC Demo.vi".
3. Using the Vi Front Panel use Control pallete Select Boolean then select the Round LED.
4. Place the LED in the Upper LEft corner of the display.
5. Click on the Edit text Icon in the Tool Pallet.
6. Select the LED lable and make it "Time Out From Server".
7. Repeat the process placing a secon LED below the first. Make its lable "Error Reading Items".
8. Next you are goint go select the rectangular Stop button from the Boolean pallette. Place this button directly below the two LED indicators and remove its lable.
9. Lastly, we are going to place a Waveform Chart in the display. In the Control Pallette select the Graph Icon and then form the Graph pallette selecxt the Waveform Chart. Place the chart in the upper right hand side of the display.
10. We will complete the project working in the VI diagram window. (Somewhere here show the tool pallete and the function window).
11. Now we need to Wire the controls together and create the OPC input.
12. First Lets add the Data socket items that we will be using.
13. In the Functions Pallet click on the Communications Icon.
14. From the Communications pallet select the Data Sockets Icon.
15. Select the Open Data Socket and place it in the VI Diagram.
16. Do the same for the Close Data Socket and the Read Double Data Socket. The latter is to input the correct data type into the Waveform Chart.
17. The last data socket to add is on the Advanced Data socket pallete and can be accessed by selecting the Advanced Data Socket Icon.
18. In the Advanced Data Socket Pallette select the Update Data Socket.
19. To make wiring easier we have re-arranged the objects in the Vi Diagram as seen below.
20. Now we need to add a timer. Click on the Timers Icon on the Functions Pallette
21. In the Timers Pallet select the "Wait untill Next MSEC" timer.Place it top center in the VI Diagram.
22. Click on Clusters on the Functions Pallette and select the Unbundle Cluster. Place it below the Read Double Data socket and to the left of the Error Reaing indicator.
23. Next on the Functions Pallette Select the Boolean Icon and from the Boolean pallette select the Not/Or decision control. Place it centerd below the Unbundle cluster and the Error indicator.
24. Now you need to wire up all of these objects.
25. Making sure you still have the select Cursor right click on the left side of the timer and select Create Constant.
26. Select the Edit Text cursor and change the text to 100. This means that the timer will trigger in multiples of 100 msec.
27. With the Select cusor right click on the upper left corner of the Open Data Socket. Select Create
Constant to create a Sting Constant for the OPC URL.
28. In the Tool Pallet select the Edit Text Cursor and enter the URL for the KepserverEx. The URL string will be "opc://localhost/KEPware.KEPServerEx.V4/Channel_1.Device_1.Float_ 1"
29. Next right click below that on the side of the Open Data Socket. Select Create a Constant.
30. In the Tool Pallete select the Operate Cursor and click on the right hand side of the ReadAutoUpdate constant and Change it to read
31. Now it is time to start Wiring the objects in the VI diagram together.
32. In the Tool Pallete select the Wire Cursor.
33. First we will wire the Data sockets so that data flows between them. At the upper right and left had corners of the data sockets are terminals for passing in and out data socket references respectively. The lower right and left hand corners are terminals for Error's in and out. We are going to wire these together. Start with the close Data Socket. You will notice that as soon as the Wire cursor is close to the objects their wire terminals become visible.
34. Because the Open Data Socket is set a little higher then the Update one you may find that the wires overlay each other. You should select these, with the select cursor, and separate them.
35. Next we will wire the Time Out indicator and the data out to the Waveform Chart from the Double Read Data Socket.
36. Now we will wire the Bundle to the error wires and then to the Boolean Not(or) switch and connect the error indictor.
37. Now wire the Stop button to the Not(or) switch.
38. Now as you are setup now you will only read once and stop. You need to place everything between the Open and close data sockets in a while loop.
39. In the functions pallet select the Structures Icon and from the structures pallete select the While Loop and draw a square around the items you want in the loop.
40. The last thing you need to do is wire the Not(or) to the Continue function of the While Loop
41. What this last piece does is make sure that as long as there are no errors or the stop button is not on then the loop will keep processing.
42. You will notice that the Run button on theButton bar has become a solid white arrow which means that the VI should run.

http://www.kepware.com

Fred Loveless
Support Manager
Kepware Technologies
 
Last edited:
Hi Dan, This is a really old message, so you probably found your solution by now. But others in the same situation might want to look at NI's Compact Rio hardware. It's not exactly a PLC. But in my opinion (as another LabVIEW programmer) if offers a lot more flexibility than traditional PLCs do.
 
Lacie the issue with us is that the lab uses labview everywhere. I know it would be great for others to learn certain PLC programming, but every company is slightly different. Labview is basically a more advanced block diagram programming. The reason we want Labview is the fact that they are learning it already so, in order for a new student to modify the program is would minimize the down time and loss of $ due to that fact they do not have to learn Labview again. This is why we want Labview.

The CompactRio series by NI is great, but way to advance for what we need it to do! Which isn't bad, but since its so advanced so is the price. To get a CRio systems with all of the I/O's we would have needed it would have cost twice the amount it would have costed for me to learn Siemmens PLC block diagram.

But thank you, we ended up using a mac mini and 2 usb DAQ's for what we needed.

~Dan
 
But thank you, we ended up using a mac mini and 2 usb DAQ's for what we needed.

~Dan

Glad to hear that you found a solution.

Our shop here also uses LabVIEW quite frequently for our tester applications. Although on large test/assembly lines our customers often insist on PLCs for pallet movement. It makes them feel more comfortable if their own technicians can get in there and screw up the code. This also helps keep up busy with service calls. So it's win-win.

NI recently introduced an Ethernet IP driver to directly communicate with PLCs. http://decibel.ni.com/content/docs/DOC-4065

Currently I'm working on a large project that will combine a ControlLogix L61 with four LabVIEW PCs and a whole lotta remote IO and devices. It's going to be interesting.
 
sounds like your going to be busy with that for a long time. Yea for the short term applications we use Labview due to the fact that its so easy to program, for long term applications and sell-able products we use FPGA's to control everything, we don't need a PLC's for the products. Its great when people crack open our systems and figure out what code we are using and then hack into it and change the code, they think its new and great but they have no clue on what it screws up. So they send our IT down for service calls at least once a week. Thank you for your interest and your help.

~Dan
 

Similar Topics

Hello, I've recently tried to upgrade my PLC controller from a L72 to L84ES and everything seemed to work, all buttons and screens as far...
Replies
9
Views
2,616
Kindly, what is the status of the digital outputs, while waiting for the plc to complete its startup (when we power off then power on the supply)...
Replies
6
Views
2,785
We have a standard to install fusible TB's at PLC AI/AO channels and knife TB's at PLC DI/DO channels. Also the 24 vDC field power supply to all...
Replies
11
Views
4,094
Hi Chaps, I'm using a Logix 5555 processor as a test bed. 1756-L55/A: series A rev 1.4 I took it out of an old machine. My problem is whenever...
Replies
3
Views
3,612
Hi All Which plc make uses file extensions .upr and .dpr I thought unitronics - but not the case
Replies
7
Views
3,330
Back
Top Bottom