NI Linux Real-Time Discussions

cancel
Showing results for 
Search instead for 
Did you mean: 

Installing Mono or .NET Core on CompactRIO (cRIO) and NI Linux Real-Time

(I posted this in another part of the forums as part of a service request but didn't receive any help, so I am re-posting it here.)

 

I am investigating the feasibility of running .NET on a cRIO controller either using Mono or .NET Core. The idea would be to program the FPGA on the cRIO with LabVIEW but then write the host-side software with a .NET language, notably F#. This is really something I would like to move to almost immediately, as I would like to move away from LabVIEW as much as possible. This stems from my experience having deployed my actor framework extensions to both Windows and cRIO systems. My ideal scenario would be something like this:

 

Capture.PNG

 

This of course can be easily done on Windows due to the existence of .NET libraries that NI provides as well as LabVIEW's .NET integration (the ability to call .NET assemblies and even build LabVIEW code into .NET assemblies). However, on cRIO it is a different story. Most of it is complicated by NI's reliance on opkg, which seems like a non-standard package manager, and their own repository management.

 

On a cRIO and NI Linux Real-Time:

  1. Has anyone been successful in installing either Mono or .NET Core using packages?
    1. Did you use opkg?
    2. Or did you install another package manager?
  2. Has anyone been successful in building Mono or .NET Core from source?
  3. Bonus: Has anyone done one of the two above steps and been able to successfully run software on the cRIO using a .NET language?

Questions for National Instruments:

  1. Will Mono and .NET Core ever be added to NI's opkg repositories?
    1. This would be a huge benefit to customers looking to integrate .NET code into their cRIO development.
    2. Python is currently included in NI's repository, but in general, I have no interest in building large, reliable systems with Python. It's certainly nice to have it there, but it would be great if .NET was easily available on NI Linux Real-Time. F# can be used for scripting just as Python but can also build more robust code.
  2. Particularly with the development of .NET Core, it would be fantastic if LabVIEW could call and build .NET Core assemblies just as it can do so with .NET Framework assemblies on Windows. Will this happen?

As an interesting note, I was able to install Mono and then F# on a Raspberry Pi within the first day of getting a new one recently. The steps to do so followed directly from the installation documentation for both:

From there I was able to develop F# code on Windows 10 (due to better development environment) and then deploy and run the code on Mono on the Raspberry Pi without any changes. I don't think it should be easier to do this on a Raspberry Pi than on a cRIO.

 

As mentioned in this post, it would be wonderful if the experience of installing F# on NI Linux Real-Time could be as simple as:

opkg update
opkg install mono-complete
opkg install dotnet-sdk opkg install fsharp

A very nice bonus would be Visual Studio Code bundled as a package as well.

 

Note that having a newer, modern cRIO running Windows would practically get rid of all these issues. There are Windows-based cDAQ systems and the legacy cRIO-9082, but the cDAQ systems must use an Ethernet expansion chassis like the NI 9149 to get FPGA and RS-232 C-Series module support.

Message 1 of 2
(2,483 Views)

Hi there, 

 

Starting in LabVIEW 2017, Mono is included as a feed in our opkg repo. If you want to use Mono in LabVIEW 2016, you can reference these steps: Getting Mono running on your target. Just note that using Mono on LinuxRT is not officially supported by NI. 

 

To address your other question, no, there are currently no plans to include .NET support on LinuxRT. However, I recorded your feedback to reference in the future, so thank you for posting here and letting us know your thoughts. 

 

Also, just to set expectations, there are no current plans to create a refreshed Windows cRIO. NI's expectation is that most users requiring Windows will be using PC or PXIe targets. 

 

Please keep the requests/feedback coming! 

Thanks,

Rita Prather
Software Product Manager
rita.prather@ni.com
National Instruments
0 Kudos
Message 2 of 2
(2,410 Views)