Measurement Studio for .NET Languages

cancel
Showing results for 
Search instead for 
Did you mean: 

measurement studio application using daq mx deployment

i have made an .NET 1.1 application using measurement studio 8.0.1 in which i communicate with a NI-9233 using DAQ-mx 8.5.
 
How do i deploy this application? Can i setup the .NET setup project to install the DAQ-mx drivers?
 
regards,
Jesper
0 Kudos
Message 1 of 7
(5,884 Views)
Hi Jesper,

There isn't a direct way to bundle the DAQmx drivers into a Visual Studio setup project. If you want to automate everything, then your options are:

Option 1) Use a batch file to launch your Visual Studio and DAQmx setup programs. This batch file will launch your Visual Studio setup installer that you create and then launch the downloadable DAQmx driver.

Option 2) If you have LabWindows/CVI 8.0 and later, you can create a LabWindows/CVI installer that will distribute your Visual Studio application, the DAQmx driver, and the appropriate Measurement Studio merge modules.  The needed merge modules for Measurement Studio are referenced in the Deploying Measurement Studio Windows Applications help topic in the NI Measurement Studio Help.

One thing I wanted to mention that helps ease your installation time, is that DAQmx does have several different "watered-down" Run-Time Engine versions.  The Run-Time Engine versions are currently only available for DAQmx 8.3 but the DAQmx 8.5 ones should be available soon on the website. You can take a look at the 8.3 ones here to give you an idea of what options are there.  Or you can always just install the normal 8.5 DAQmx installer. 

For more information on deploying Measurement Studio applications, check out the KnowledgeBase Distributing Measurement Studio Applications in Microsoft Visual Studio 2003/2005 and the Measurement Studio help topic "Deploying Measurement Studio Windows Applications".

Hope this helps!

Best Regards,
Jonathan N.
National Instruments
0 Kudos
Message 2 of 7
(5,884 Views)
Hi Jonathan,

Thanks for your reply. Your replies are always particularly helpful.

I've been very busy and I'm up for air, here. Smiley Very Happy

Would you please tell me if there is something that our installation program can check to see if the DAQmx drivers are installed, and if so, what version?

Thanks.

Best Regards,
Matthew

0 Kudos
Message 3 of 7
(5,799 Views)
Hi Matthew,

The way that we do it is:

1) Check the registry for the HKEY_LOCAL_MACHINE\SOFTWARE\National Instruments\NI-DAQmx\CurrentVersion\Path key.
2) If the key is not there, then you know that DAQmx is not installed.
3) If the key is there, then we check on the actual computer for that path to make sure that it exists. The reason we do that is to make sure that there is not a corrupt installation that left behind registry keys.

Hope that helps!

Best Regards,
Jonathan N.
National Instruments
0 Kudos
Message 4 of 7
(5,788 Views)


1) Check the registry for the HKEY_LOCAL_MACHINE\SOFTWARE\National Instruments\NI-DAQmx\CurrentVersion\Path key.
2) If the key is not there, then you know that DAQmx is not installed.
3) If the key is there, then we check on the actual computer for that path to make sure that it exists. The reason we do that is to make sure that there is not a corrupt installation that left behind registry keys.


Any chance someone has a simple code-snippet to do this?

0 Kudos
Message 5 of 7
(5,331 Views)
Hi Tyzack,

There is a variety of ways to go about checking this registry key. In most cases, you need to make sure you are using the Microsoft.Win32 namespace.  One quick solution is as follows:

RegistryKey registryKey = Registry.LocalMachine.OpenSubKey(@"SOFTWARE\National Instruments\NI-DAQmx\CurrentVersion");

if (registryKey != null)
{
    Object regValue = registryKey.GetValue("Path");
    if (regValue != null)
        Console.WriteLine("Registry key exists");
    else
        Console.WriteLine("Registry key does not exist");
}


Best Regards,
Jonathan N.
National Instruments
0 Kudos
Message 6 of 7
(5,327 Views)

Hi,

 

I have an Measurement Studio app (VS 2005) that uses DAQmx 8.9.5 and I am looking at ways to automate installation of the device drivers along with the application itself (there is an option to do this if you were developing an app in LabVIEW). Are the solutions suggested in the previous posts of this thread still the only way to do this or has things changed in the last few years?  

 

Has anyone been successfull in adding the National Instruments Device Drivers as a Pre-Requisite installation package to the setup project of a Measurement Studio app? This involves creating a custom bootstrapper package within your C:\Program Files\Microsoft Visual Studio 8\SDK\v2.0\BootStrapper\Packages folder ((http://msdn.microsoft.com/en-us/magazine/cc163899.aspx). 

 

The way I understood it, the bootstrapper installation file has to be a single windows installer executable and the Device Driver (core) installation package that I downloaded from NI is not single file but rather a collection of files with a setup file along with support and product folders. I zipped these files into a self executing archive, but that approach does't seem to work. It packages the installer correctly, but during installation the installer assumes that the Device Drivers have been installed as soon as it is unzipped and thereby both the device driver installation and my app installtion simultaneously are launched simultaneously creating a conflict.

 

Please advise.

 

thanks much,

~Vipin

0 Kudos
Message 7 of 7
(4,313 Views)