Thread Subject: Failed 'nidaq' adaptor registration

Subject: Failed 'nidaq' adaptor registration

From: Maxim

Date: 7 Mar, 2008 14:55:04

Message: 1 of 14

Dear friends,
I’ve got the following system configuration:
1) NI-DAQmx driver 8.5.0f5
2) MatLab Version 7.5.0.342 (R2007b)
3) Data Acquisition Toolbox Version 2.11
4) plug-in NI DAQ boards work nicely with NI software

My MatLab does not automatically register 'nidaq' adaptor,
neither I can do it manually.

>> daqregister('nidaq')
ans =
Unable to load adaptor:
C:\MATLABR2007b\toolbox\daq\daq\private\mwnidaq.dll.
Driver files or DLL for the specified adaptor could not be
found or are not installed.

Apparently it cannot find ‘nidaqmx.dll’, which is not
present on the PC.
Question: is there a compatibility problem (does The Data
Acquisition Toolbox™ software require Version 7.5 of the NI-
DAQmx drivers)?

Thank you for your advise,
Maxim

Subject: Failed 'nidaq' adaptor registration

From: Sherryl Radbil

Date: 10 Mar, 2008 13:48:16

Message: 2 of 14

Hi Maxim,

Are you on Windows XP or Vista?
In either case, do you have Administrator privileges?
If not, have a admin log in and do the registration.

If you find this solves the problem would you mind posting
back to answer the following question:
Which did you install first - MATLAB/DAT or NI drivers.

If this doesn't solve the problem please try to create a DAT
object on the soundcard, for example:
ai = analoginput('winsound')
and let us know what the results of that are.
At the same time please post the results of running the command:
daqsupport
(it's long, but very useful).
Best regards,
Sherryl

Subject: Failed 'nidaq' adaptor registration

From: Maxim

Date: 14 Mar, 2008 14:33:04

Message: 3 of 14

Yes,
It did solve the problem. Thank you.
However, why wouldn't it register the adaptor upon
installation?
The order of installation was the following:
1) MatLab 2006b
2) Ni DAQmx
3) MatLab 2007b
Regards,
Maxim

"Sherryl Radbil" <sherryl.radbil.dontspamme@mathworks.com>
wrote in message <fr3e70$g2u$1@fred.mathworks.com>...

Subject: Failed 'nidaq' adaptor registration

From: Sherryl Radbil

Date: 14 Mar, 2008 17:05:04

Message: 4 of 14

It wasn't registered for R2006b because when you installed
it the NI-DAQmx drivers were not installed.
I'm not sure why the install of 7b did not register.
In any event I'm glad that executing that command as admin
solved your problem.
Sherryl

Subject: Failed 'nidaq' adaptor registration

From: Nilanka

Date: 17 Mar, 2008 12:02:06

Message: 5 of 14

Hi,
I have the same problem and the same error message.

The problem is not with the admnistratiive priviledges or
the sequence of installing. (I installed nidaq drivers and
then MATLAB 7.0 release 14 Daq toolbox 2.5)
Please help !!!

I am using the NIDAQ driver 8.6 and the card nidaq PCI-6071E
The card works nicely with the labview Signal express
version 2.5
Im using winXP sp2

N.T.



"Sherryl Radbil" <sherryl.radbil.dontspamme@mathworks.com>
wrote in message <fr3e70$g2u$1@fred.mathworks.com>...
> Hi Maxim,
>
> Are you on Windows XP or Vista?
> In either case, do you have Administrator privileges?
> If not, have a admin log in and do the registration.
>
> If you find this solves the problem would you mind posting
> back to answer the following question:
> Which did you install first - MATLAB/DAT or NI drivers.
>
> If this doesn't solve the problem please try to create a DAT
> object on the soundcard, for example:
> ai = analoginput('winsound')
> and let us know what the results of that are.
> At the same time please post the results of running the
command:
> daqsupport
> (it's long, but very useful).
> Best regards,
> Sherryl

Subject: Failed 'nidaq' adaptor registration

From: Nilanka

Date: 17 Mar, 2008 12:04:03

Message: 6 of 14

Hi,
I have the same problem and the same error message.

The problem is not with the admnistratiive priviledges or
the sequence of installing. (I installed nidaq drivers and
then MATLAB 7.0 release 14 Daq toolbox 2.5)
Please help !!!

I am using the NIDAQ driver 8.6 and the card nidaq PCI-6071E
The card works nicely with the labview Signal express
version 2.5

NT

Subject: Failed 'nidaq' adaptor registration

From: Maxim

Date: 17 Mar, 2008 12:56:07

Message: 7 of 14

The administrator has to grant "modify" privileges to the
DAQ toolbox user. The reason: apparently, when executing
>>daqregister('nidaq'), MatLab first looks
for ‘nidaqmx.dll’, since it is default value in
MatLab’s ‘mwnidaqmx.dll’; however ‘nidaqmx.dll’ simply does
not exist, since DAQmx uses static lib. But there is
NI ‘nicaiu.dll’ which contains DAQmx functions
(http://forums.ni.com/ni/board/message?
board.id=250&message.id=20608&requireLogin=False). MatLab
finds this value (from registry?) and has to rewrite the
default value in its file(s) (which?). However, if "modify"
privileges are not granted, MatLab’s files cannot be
modified and MatLab will not know that it should look
for ‘nicaiu.dll’.
Written above is completely a hypothesis of mine. I would
expect MathWorks and NI explain it explicitly in respective
software documentation, however they prefer to keep it an
esoteric knowledge. I have asked both MathWorks and NI, the
respective consultants appeared to … not know what dll is
needed, they even could not provide a prompt answer whether
NI DAQmx 8.6 driver is compatible with MW DAQ 2.11 toolbox!
I am really disappointed. I have spent huge amount of time
trying to sort it out. I wonder whether it is a general
American attitude towards customers (to keep them
dependent), or it is a problem of a too big and dominant
software producer (as MS, recently fined 2 bn. USD by EU
commission)?
Maxim

"Nilanka " <nilanka2@yahoo.com> wrote in message <frlmnj$1m8
$1@fred.mathworks.com>...
> Hi,
> I have the same problem and the same error message.
>
> The problem is not with the admnistratiive priviledges or
> the sequence of installing. (I installed nidaq drivers and
> then MATLAB 7.0 release 14 Daq toolbox 2.5)
> Please help !!!
>
> I am using the NIDAQ driver 8.6 and the card nidaq PCI-
6071E
> The card works nicely with the labview Signal express
> version 2.5
>
> NT

Subject: Failed 'nidaq' adaptor registration

From: Sherryl Radbil

Date: 17 Mar, 2008 13:03:08

Message: 8 of 14


Support for NI-DAQmx drivers did not come out until DAT 2.8.
Your PCI-6071E will run under both Traditional NI-DAQ as
well as NI-DAQmx, but with 8.6 you don't have Traditional.

So you'll need to do one of the following to use that device
with MATLAB:

1. Upgrade to a minimum of MATLAB R14SP3+ and DAT 2.8,
keeping with your NI-DAQ 8.6. This is your best and easiest
option, and you should upgrade directly to the newly
released MATLAB R2008a to enjoy all of the enhancements and
improvements made over the past many years.

2. Install the Traditional NI-DAQ drivers 7.3 or 7.4. I'm
not sure, but I believe you can't just install these older
drivers OVER 8.6 so you'll have to uninstall 8.6 first. Then
install the Traditional version you have, then reinstall
8.6. When done this way Traditional and MX coexist on your PC.

In any event, your current configuration is not supported
for the versions of software you have installed.

Sherryl


Subject: Failed 'nidaq' adaptor registration

From: RC

Date: 9 Apr, 2008 18:53:03

Message: 9 of 14

Hi Friends,

I am having a similar problem. My specs are as follows:

MATLAB version:
7.4.0.287 (R2007a)

Data Acquisition Toolbox version:
       Name: 'Data Acquisition Toolbox'
    Version: '2.10'
    Release: '(R2007a)'

NiDAQ Device: USB-6251 Mass Termination
NiDaq 8.5

Matlab does not show a nidaq adaptor installed and when I
enter: daqregister('nidaq')

ans =

Unable to load adaptor: C:\Program
Files\MATLAB\R2007a\toolbox\daq\daq\private\mwnidaq.dll.
Driver files or DLL for the specified adaptor could not be
found or are not installed.

Thank you for any input!


Subject: Failed 'nidaq' adaptor registration

From: Sherryl Radbil

Date: 9 Apr, 2008 20:55:04

Message: 10 of 14

"RC " <rumichu@hotmail.com> wrote in message
<ftj3af$eaj$1@fred.mathworks.com>...
> Hi Friends,
>
> I am having a similar problem. My specs are as follows:
>
> MATLAB version:
> 7.4.0.287 (R2007a)
>
> Data Acquisition Toolbox version:
> Name: 'Data Acquisition Toolbox'
> Version: '2.10'
> Release: '(R2007a)'
>
> NiDAQ Device: USB-6251 Mass Termination
> NiDaq 8.5
>
> Matlab does not show a nidaq adaptor installed and when I
> enter: daqregister('nidaq')
>
> ans =
>
> Unable to load adaptor: C:\Program
> Files\MATLAB\R2007a\toolbox\daq\daq\private\mwnidaq.dll.
> Driver files or DLL for the specified adaptor could not be
> found or are not installed.
>
> Thank you for any input!
>
>

Try logging in to the PC as Administrator, or someone who
has full administrator rights and then executing
daqregister('nidaq')

Subject: Failed 'nidaq' adaptor registration

From: RC

Date: 10 Apr, 2008 01:34:01

Message: 11 of 14

Hi Sherryl,
I did have full administrator rights when trying this. My
operating system is Microsoft Windows Vista.

-RC


"Sherryl Radbil" <sherryl.radbil.dontspamme@mathworks.com>
wrote in message <ftjaf8$sap$1@fred.mathworks.com>...
> Try logging in to the PC as Administrator, or someone who
> has full administrator rights and then executing
> daqregister('nidaq')

Subject: Failed 'nidaq' adaptor registration

From: Nilanka

Date: 10 Apr, 2008 14:58:02

Message: 12 of 14

Hey,

I corrected my problem. Just check the nidaq driver that
supports the Data acquisition toolbox version ur using. I
corrected my problem by removing the new drivers and
installing the legacy drivers for NIdaq



"RC " <rumichu@hotmail.com> wrote in message
<ftjqq9$iaj$1@fred.mathworks.com>...
> Hi Sherryl,
> I did have full administrator rights when trying this. My
> operating system is Microsoft Windows Vista.
>
> -RC
>
>
> "Sherryl Radbil" <sherryl.radbil.dontspamme@mathworks.com>
> wrote in message <ftjaf8$sap$1@fred.mathworks.com>...
> > Try logging in to the PC as Administrator, or someone who
> > has full administrator rights and then executing
> > daqregister('nidaq')
>

Subject: Failed 'nidaq' adaptor registration

From: Sherryl Radbil

Date: 10 Apr, 2008 15:02:05

Message: 13 of 14

Hi RC,

Under extremely rare circumstances, users with
Administrative privileges may not have permissions to modify
the registry under Vista. Before proceeding you should
check the following:

1) Contact your IT department and/or verify that you
actually have administrative privileges. Administrative
privileges are always required to register Data Acquisition
Toolbox adaptors.

2) If you are using Windows Vista with User Account Control
(UAC) enabled, you need to verify that you are running
MATLAB in elevated mode.

3) Execute the following command in MATLAB.

system(['regsvr32 '
fullfile(matlabroot,'toolbox','daq','daq','private','mwnidaqmx.dll')])

The dialog box should produce an error message saying the
"Return code was: 0x8007005". This error code means
E_ACCESSDENIED. If the command produced a different error,
then you have a different issue.

If you are confident that both of the above are satisfied,
the issue may be that users in the "Administrators" group do
not have permissions to modify or create the necessary
registry keys. Each key in the registry has its own
permissions settings.

In order to resolve this issue, you need to track down the
individual keys for which you do not have permissions and
modify the permissions of those keys. One way to do this is
to use Process Monitor. Process Monitor is an advanced
monitoring tool for Windows that shows real-time file
system, Registry and process/thread activity. Process
Monitor can be downloaded from:

http://technet.microsoft.com/en-us/sysinternals/bb896645.aspx

After installing Process Monitor, start the application and
have it capturing events. please have it monitor the
registering of DLL. You can then execute the following
command again:

   system(['regsvr32 '
fullfile(matlabroot,'toolbox','daq','daq','private','mwnidaqmx.dll')])

Then stop the event capture. Process Monitor should have at
least one entry with an Access denied error. The Process
monitor generates quite a lot of output in one second. Make
sure to stop monitoring quickly after the above command has
completed.

For example, you may see that you do not have permissions to
set the registry entry "HKCR\mwnidaqmx.adaptor.1". Below is
the Process Monitor line where the error is reported. The
output below was exported into CSV format.

"28381","3:10:18.6384469
PM","regsvr32.exe","1364","RegCreateKey","HKCR\mwnidaqmx.adaptor.1","ACCESS
DENIED","Desired Access: Set
Value","C:\WINDOWS\system32\regsvr32.exe","regsvr32
mwnidaqmx.dll"

This means that you can not set this specific key or perhaps
its parent key. HKCR stands for "HKey_CLASSES_ROOT". In
order to remedy the issue you will need to modify the
permissions in the registry. Modifying the registry is
risky; therefore we recommend backing up the registry and
any critical data on the computer prior to proceeding.

What you need to do is run "regedit" (from Start->Run) and
then right-click the HKey_CLASSES_ROOT top level folder and
select "permissions". If necessary change the permissions
on the key to grant local Administrators ‘Full Control’.
Below are some screen shots showing permissions from a good
entry. If this key already has full control then search for
the subkey "mwnidaqmx.adaptor.1" and verify its permissions.
 Then try registering mwnidaqmw.dll again.

This may not resolve the issue completely, as other keys may
also be affected. You may need to repeat the process of
using Process Monitor to find what commands fail with the
"ACCESS DENIED" error message and adjust their permissions also.

Let us know how you make out,
Sherryl

Subject: Failed 'nidaq' adaptor registration

From: RC

Date: 10 Apr, 2008 19:55:03

Message: 14 of 14

Sherryl, thanks for your reply. It turns out that although
I had administrator privleges, I needed to be the actual
Administrator user inorder to do the registration. In
order to access the Administrator account I had to unblock
it in Windows Vista also. Thanks so much for replying and
your help.

Best,
RC

Tags for this Thread

Everyone's Tags:

Add a New Tag:

Separated by commas
Ex.: root locus, bode

What are tags?

A tag is like a keyword or category label associated with each thread. Tags make it easier for you to find threads of interest.

Anyone can tag a thread. Tags are public and visible to everyone.

Tag Activity for This Thread
Tag Applied By Date/Time
registration Sherryl Radbil 10 Apr, 2008 11:12:21
dat Sherryl Radbil 10 Apr, 2008 11:12:16
vista Sherryl Radbil 10 Apr, 2008 11:12:11
dat vista registration Sherryl Radbil 10 Apr, 2008 11:05:21
rssFeed for this Thread

Public Submission Policy

NOTICE: Any content you submit to MATLAB Central, including personal information, is not subject to the protections which may be afforded information collected under other sections of The MathWorks, Inc. Web site. You are entirely responsible for all content that you upload, post, e-mail, transmit or otherwise make available via MATLAB Central. The MathWorks does not control the content posted by visitors to MATLAB Central and, does not guarantee the accuracy, integrity, or quality of such content. Under no circumstances will The MathWorks be liable in any way for any content not authored by The MathWorks, or any loss or damage of any kind incurred as a result of the use of any content posted, e-mailed, transmitted or otherwise made available via MATLAB Central. Read the complete Disclaimer prior to use.

Contact us at files@mathworks.com