10-23-2020 05:40 AM
Would just like to chip in and say just because .NET Core can do cross platform, doesn't mean all driver and tooling needs to support all platforms... a .NET Core project can example easily be build against Windows runtime only.
That said it would be nice to example be able to use Measurement Studio, and DAQmx drivers from more lightweight devices for Industrial IoT scenarious.
We're also example using Teststand(for now...) on production line, at the moment, using custom result recording to Azure Cloud for data analysis etc, and there we're using Microsofts .NET dll's, and that works fine since they support .NET 4.5+ but at some point newer versions of those dll's will only be for .NET Core.
04-25-2021 09:38 AM
.NET Core leaves the runtime to be updated via Windows Update, and the version your application uses ships with your application. That's alot better for maintenance and easier for the customer when they don't have to install a new version of the framework when you compile against a newer version.
It also has alot better support for databases, command line interface generation of entity framework models (scaffolding) -- the dialog they had for years to do this was extremely buggy and sometimes would error out and you couldn't generate anything but errors.
Project files -- the new SDK version of the project file is SO much cleaner and clearer than it's been. Doing a diff you can clearly tell what changes have been made.
Sqlite and JSON support...
04-26-2021 06:07 AM
I've recently had success using the NI APIs with .NET 5 (Core) libraries/apps. However, I have not been able to reference/call them within TestStand. For example, you can see the classes/methods when trying to use within the Sequence Analyzer config.
04-26-2021 06:32 AM
That's kind of the whole issue.
Dotnet core (soon to be dotnet 5) can easily run most "legacy dll's" such as the teststand api ones, aslong as the compile target is set to windows, it's the other way that's the major issue: that none of NI's tools currently support dotnet core, and no clear plan other than a very vague answer in another topic that they are working with microsoft on it (Re: .NET Core Support - NI Community), which i see you commented on aswell 🙂
Hell even if they opened up their software a bit more, i'm sure the community(or NI partners) would be able to make an "adapter" for any language, took years for python support in teststand as an example.
04-26-2021 06:39 AM
"That's kind of the whole issue." Yup, completely agree. There have been many times we started down the .NET Core path, but had to move back to "full framework" due to these limitation. Maybe one day 😀.
04-08-2022 08:20 AM
… one year after… is there something new in this arena ? What are the plans at N.I. to support .Net Core modules?
Thanks to anyone having more news on this.
Christophe
07-05-2022 05:58 AM
DLL: c:\windows\system32\nicaiu.dll
header file: C:\Program Files (x86)\National Instruments\NI-DAQ\DAQmx ANSI C Dev\include\NIDAQmx.h
documentation: C:\Program Files (x86)\National Instruments\NI-DAQ\Docs\cdaqmx.chm
Measurement Studio assemblies aren't compatible with .NET core and beyond, so I started making my own wrappers around NI DLL's.
So far the only problem I've found, is that the DLL reads as 64 bit, but will only work for C# if you compile as x86 (even though the driver is listed as 32 and 64 bit - https://www.ni.com/en-us/support/downloads/drivers/download.ni-daqmx.html#445931). Which is also the same experience you get with Measurement Studio .NET assemblies.
Dump of file c:\windows\system32\nicaiu.dll
8664 machine (x64)
Dump of file c:\windows\SysWOW64\nicaiu.dll
14C machine (x86)
06-25-2024 05:10 AM
Measurement Studio isn't compatible with Visual Studio 2022 - Is difficult to keep using VS2019 especially when .NET 5.0 is outdated
Measurement Studio isn't compatible with .NET 5.0 but uses old Framework 4.8
Anyways, according to NI, it isn't required to install MS in order to speak with Daqmx cards, so I install all libs and tried to refer those in my project - as expected, it wasn't possible.
I then copied files manually and tried to refer as assembly, again incompatibility issue
I am unable to integrate DaqMx to Core or .NET 6.0. Not only this, I am unable to interface Daqmx.dll in my 6.0 project.
What is the solution you can suggest? We have heavy dependence on NI USB Cards and can not stick to old and outdated Visual Studio / Framework
07-02-2024 03:05 AM
There have been several attempts to create a .Net Interop layer for DAQmx and other NI drivers that calls the NI DLL directly. Some have even published their (partial) work on git and other platforms. It's not rocket science to do an Interop interface, just a damn lot of work, since the DAQmx API is huge!
07-04-2024 03:37 AM
Yes, I have seen such projects.
- I was also thinking of integrating my old application dll (which I wrote in 4.8 and refers to DaQmx dlls) into my core project by making DllImport calls.
- but that kills my flexibility, as I have to keep on maintaining my old 4.8 project for every small change which is needed in new project.
- Or another approach is to use DllImport directly with DaQmx, but that's a lot of work because all classes and structs have to be reflected in my new core project too.