Multifunction DAQ

Showing results for 
Search instead for 
Did you mean: 

Unexpected power loss causes corruption inside of NI driver/configuration



We use the PCI-6220, PCI 6251, and USB-6221 in some of our solutions for customers on production lines that sometimes lose power at unexpected times.  We run the Runtime5 install of daqmx V8.9.  We have determined that during initial boot up of ths XP system is the most crucial time where a power loss (as NI is loading up) can "corrupt" the NI driver or registry.  We have seen two distinct failure modes that we can not reproduce on any of our systems that don't have NI cards but are fairly easy to reproduce on our systems that include an NI card:


Failure Mode 1 --> Calling the function "DAQmxGetSysDevNames" takes ~90 seconds to return.  When not "courrpt" this function returns in about ~20ms

Failure Mode 2 --> The XP Registry is corrupt.  The Administrative user on the system is wiped out due to some XP registry corruption.  While not specifically an "NI" corruption we don't see this failure mode on our non-NI solutions so I want to know what if any stuff NI does to the registry during the ni driver/services boot launch in XP


I need a non-UPS solution that prevents this from happening.  Short of that a lot more detail of what is going wrong would be helpful.  I have seen the technical bulletin ( about renaming config3.mxs and restoring the backup but I am hoping to prevent the situation from occuring in the first place and I want more info on Failure Mode 2.



0 Kudos
Message 1 of 4

Hi Lou_III


About this issue, I did some research and the behavior that you are experimenting is expected as you are interrupting a vital process of the computer, so there is a good chance that the registry gets corrupted. Having your computer to shut down unexpectedly during the boot up (with or without NI software on it) might put in risk your computer, not only the software but the hardware (power supply, mother board, bios memory or hard disk).

The best solution for you is to protect your computer to prevent future damages. Besides that, something you can do is to set restore points each day and try to do a system recovery.



0 Kudos
Message 2 of 4

There are parts of the world where power is spotty at best and to lose power unexpectedly in a factory environment is "normal".  UPS's are an option but have their own set of problems (batteries don't last forever, software compatibility, etc).  The rest of the system we sell is designed to protect itself from these situations that are known to occur.  Hardware drivers by other manufactures don't seem to suffer the same woes as we are experiencing with our current NI solution.


We have written our own interface to the NI cards using DaqMX drivers.  I wish there was a little more separation between writing a "simple" 6251 driver and having to use all the bloated NI services and Max backend/whatever, etc.  Is there any way to write a driver for an NI card that looks at the mapping of registers on the card, etc.  ie. Write a driver without daqmx in C++ or some other language.  Does NI publish the internal workings of their cards so if one wishes to do this they could start down that road?  I am desperate for a solution and I am willing to entertain other "crazy" ideas if anybody has any. 

0 Kudos
Message 3 of 4

Hello Lou_III,

There is a Measurement Hardware Driver Development Kit


The link points to a FAQ.  Referenced in the FAQ are "Register Level Programming Manuals."

I hope this is helpful.

Matthew H.
Applications Engineer
National Instruments
0 Kudos
Message 4 of 4