My team has a Labview project written for a robot that had a cRio.
We’d like to use a RoboRio to develop code and teach programming with.
The saved project was built for the cRio. Is there an easy way to convert an existing LabView project? What’s an efficient way to do it other than make a new project for the RoboRio and start copying piece-by-piece?
Open your project.
Right-click on the top row – Project XXX.lvproj and select New >> Targets and Devices.
In the dialog, add a roboRIO ( either existing or by type).
Drag the VIs from the cRIO target to the roboRIO.
Right-click on the target, open the Properties dialog and set the IP or name.
Right-click to remove the old target.
The code links to WPILib code. Changing the target type from cRIO to roboRIO or simulated will link to different libraries and will allow for conditional compilation where needed.
This will not update channel constants, and in particular, cRIO I/O was 1-based and roboRIO is 0-based. So depending on how you make PWM and other electrical connections to the roboRIO, you may need to change those. But generally, yeah. It will either run or will tell you a few things that broke.