I have a question about deploying the source libraries on the robot.
When we run it, All files are loaded to the ram. It takes a while and I don’t want to waste time on that. All the basic libraries are loaded, I though if there is a way that the basic libraries are located on the flash memory, so it won’t need to load every running.
Can I do it somehow ?
How do we run the code in the competition itself? We build it on the robot ?
Or run it as we do now ?
As far as I know, there is no way to selectively save files to the cRIO’s ROM.
If you want to run code on your robot while not tethered to a programming laptop, simply “Build” the code from the project explorer windows and “Run as Start-up.” This will save the program in the cRIO’s ROM and allow it to run at any time (at a tournament or otherwise).
If you run the same program several times, even with modifications, the environment uses the RAM VIs as cache and runs very quickly. But as you mentioned, when you reboot the cRIO, the RAM cache has to be rebuilt.
Once your code is complete or largely complete, you can transition to the Build and Run as Startup. This will boot the controller directly into your app on power-up.
For example we ran the program before. We have xxx.Vi running.
We stopped and we ran again but with modifications in the xxx.VI file.
Will it overwrite it ?
Yes. If xxx.vi is dependent on a.vi and b.vi, and you change xxx.vi and press run, LabVIEW will redeploy xxx.vi but reuse a.vi and b.vi. If you change nothing, but simply rerun the robot with a different configuration, no code will be deployed, LabVIEW will compare all VIs and determine that nothing changed.
As I mentioned before, the cache is cleared when the cRIO reboots.
Once the code is complete, right click on the build specification and Build and then Run as Startup. You can then switch back and forth as needed between these two types of running.