05-13-2025 07:38 AM - edited 05-13-2025 07:39 AM
Hi everyone,
I'm trying to run a Simulink model in real time on a CompactRIO (cRIO) that runs NI Linux Real-Time x64. The model is built in Simulink using Simulink Coder and Embedded Coder.
My setup:
Target: cRIO-9045 (NI Linux Real-Time x64)
Host PC: Windows 10
LabVIEW: 2021 32-bit
LabVIEW Real-Time Module: installed
MATLAB/Simulink (2023b) with Simulink Coder and Embedded Coder
What I want to achieve:
Run a Simulink-generated model on the cRIO in real time
Without rewriting the model in LabVIEW or using VeriStand
I’m looking for a workflow that allows me to integrate the model execution into LabVIEW RT or the cRIO system in general
What I’ve figured out so far:
The Model Interface Toolkit is not an option for cRIO targets as it is only available for LabVIEW 64-bit but this is not supported for RT targets, so I’m using LabVIEW 2021 32-bit
I considered calling a compiled shared library (.so) from LabVIEW RT via the Library Function Node, but I haven’t been able to retrieve the .so file from the Simulink build process
I haven’t yet managed to cross-compile for NI Linux RT x64 from my Windows machine using the NI toolchain
I’m aware that the .so must be compiled specifically for NI Linux RT x64 to be usable on the cRIO
My questions:
Has anyone successfully run a Simulink-generated model on a cRIO in real time (without VeriStand)?
Is there a reliable way to generate a .so from Simulink that can be used on NI Linux RT x64?
If not via the Library Function Node, are there other methods to execute a Simulink-generated model on the cRIO?
Are there example projects or workflows available for this kind of integration?
I'm open to any working approach!
Thanks in advance for any advice or shared experience!
— Nick
05-13-2025 06:07 PM
The Model Interface Toolkit 2021 is an awkward version. VeriStand was migrated to 64-bit platform hence it only supports 64-bit LabVIEW. However, LabVIEW Real-Time module does not support cRIO development until 2022 Q4.
What I sugggest:
Use LabVIEW 2020 32-bit and you can use LabVIEW Model Interface Toolkit.
Then
05-14-2025 12:17 AM
Hi
ZYOng's statement is documented in this NI knowledge article :
https://knowledge.ni.com/KnowledgeArticleDetails?id=kA03q000000wyyWCAQ
LabVIEW Real-Time Module 64-bit is available as of version 2021, however, it only supports the following subset of the hardware supported in the 32-bit version:
Regards