03-11-2010 01:16 AM
03-11-2010 08:10 AM
Kwaris,
You determine whether the cRIO will operate in Scan Mode when you first add it to the project (it would help to know what specific hardware you're working with, as Scan Mode is not supported with some chassis). You can also right click your chassis in the project and change it in the properties. From there, you should be able to create a VI for your real-time controller (right click > new > VI). Now you can drag and drop the I/O variables from the modules in your project onto the VI and get the data out. However, you'll have to transfer this data somehow from the real-time target to the host computer: Real-Time VI to Host VI Communication Methods
All of the above is outlined here:Using NI CompactRIO Scan Mode with NI LabVIEW Software
If you're just getting started with the cRIO, this is a very useful resource: NI CompactRIO Developers Guide
Keep in mind there are some performance trade-offs when using CompactRIO Scan Mode. For example, the specialty digital functionality supports up to 1 MHz counters versus the 20 MHz counters achievable with LabVIEW FPGA. Depending on what your high frequency rates are, you may have to go that route.
Hope this helps!
03-11-2010 01:28 PM
Thanks Misha,
This information and links were very very helpful. I want to confirm two things please:
I followed the link through to transfer data from target to vi, at one place there was information that in Labview 8.0 onward , shared variables are RT FIFO enabled. So is it ok just to drag and drop inputs in MODs as it drops into block diagram as shared variables or there's something more to it?
Secondly, in NI cRIO link, it is instructed that to create i/o alias in library and drag/drop aliases. What is the best thing to do?
Many thanks in advance for help
Cheers
03-11-2010 02:22 PM
kwaris,
Sorry, I have to correct something that I said above - since the Scan Engine I/O variables behave pretty much exactly like shared variables, you can actually just drag and drop those into your PC Host VI. That will probably be the fastest way of acquiring the data.
Also, as soon as you added the cRIO to the project and detected the module, right click the chassis and hit Deploy. Now you should be able to monitor the values for all channels in the Distributed System Manager (available from the Tools menu) by selecting your target.
Hope this helps!