When using a user programmed FPGA VI and the scan engine at the same time, the cRIO can be run in a setup commonly referred to as hybrid mode. While in hybrid mode, the scan engine will use two of the available DMA FIFOs and the scan engine modules will take up a portion of the FPGA space resulting in a longer compile time.
Complete the following steps to run the 951x in a Hybrid configuration with your cRIO:
- Create a new project, then add the target cRIO to it.
- Set the cRIO to Automatically Discover Modules and select the Scan Interface from the properties menu.
- Add the FPGA target by right-clicking the chassis and selecting New >> FPGA Target.
- When prompted to deploy select Deploy Now.
- Drag and drop the FPGA modules to the FPGA target. The 951x Modules are not to be moved under the FPGA target.
Drag and drop the FPGA modules to the FPGA target
After completing these steps, you will be able to run your cRIO in hybrid mode, using the 951x modules under the scan engine and additional C Series modules under the FPGA target with user defined FPGA code. Upon adding an FPGA target and setting your cRIO to hybrid mode, you will need to compile and run the FPGA bitfile before interacting with your SoftMotion axes. Complete the following additional steps to communicate with the 951x modules. If you are already using a custom FPGA VI, skip step 1.
- Add a VI under the FPGA target. Save the VI and compile a bitfile.
- After compilation is finished, run the FPGA code. You will need to always run the FPGA bitfile before communicating with your 951x modules.
- Next add the SoftMotion Axis by selecting New >> NI SoftMotion Axis. The axis should automatically bind to the 951x module.
- Right-click on the SoftMotion Axis and select Deploy. Note that the bitfile must be running during this operation, and remain running until the Scan Engine stops (i.e., when it is put into configuration mode). Otherwise SoftMotion will be unable to communicate to the module.
- If the Scan Engine was not transitioned to Active Mode when deploying the axis, right-click on the controller and select Utilities >> Scan Engine Mode >> Switch to Active.
- With the cRIO scan engine active, you can use the Interactive Test Panel or SoftMotion VIs to interact with any 951x modules that are bound to a SoftMotion Axis.
The FPGA code must be running before the 9514 module is deployed to the target to avoid errors during deployment. This is because the module cannot be detected by LabVIEW Real Time without a programmed FPGA VI. If a real time VI will not deploy correctly, run the FPGA VI using the Run arrow.
If you experience errors while deploying the bitfile or to interact with the 951x module using a deployed VI rather than the Interactive Test Panel from the project, you will need to use an initialization sequence to ensure the FPGA code is running and the scan engine is in active mode. The initialization sequence must be the first RT code to execute on the target in order to initialize the motion hardware properly. See this link
for example initialization sequences.