There might be multiple causes that can cause this since the error is very generic.
- Make sure that the latest version of NI-VISA (5.1 or later) is installed. Older versions of NI-VISA (5.0) are missing some required header files.
- Using IVI-C drivers (such as NI-DCPower) with 64-bit MATLAB (R2014a and earlier) installations require a properly installed and configured C++ compiler (as opposed to 32-bit MATLAB installations, which include a compiler)
Run mex -setup to check whether a valid compiler has been configured.
If there is no compiler configured, then the expected error would be:
>> ictObj = icdevice('nidcpower.mdd', 'DAQ::PXI1Slot1', 'optionstring','simulate=true');
Error using icdevice (line 233)
A 'Selected' compiler was not found.
You may need to run mex -setup.
However, in case of a failed Windows SDK 7.1 installation, the error might be:
>> ictObj = icdevice('nidcpower.mdd', 'DAQ::PXI1Slot1', 'optionstring','simulate=true');
Error using icdevice (line 233)
Failed to load shared library.
Best Answer