Test and Measurement Forum

MATLAB Error

Post your MATLAB discussions here

MATLAB Error

Postby ncalvert » Mon Jan 14, 2013 5:35 pm

Hello,

I recently got a PS3406A, and I am trying to connect it to MATLAB.

I downloaded the SDK and the MATLAB drivers, and installed the USB drivers.

I then connected the scope to my computer and ran MATLAB. Upon running any of the examples I get the following error:

Code: Select all
Error using instrument/delete (line 82)
Operation failed: An error occurred while executing the driver disconnect code.
Library was not found
If this error is not an instrument error, use MIDEDIT to inspect the driver.

Error in icdevice (line 279)
                delete(obj);

Error in PS3000a_IC_Generic_Driver_2buffers_Streaming_SimpleTrig (line 59)
ps3000a_obj = icdevice('PS3000a_IC_drv', 'AR911/031'); % Specify serial number as 2nd argument if required.


Have I missed a step out, or is there something else wrong?

Here is the output of 'ver' on my MATLAB

Code: Select all
-------------------------------------------------------------------------------------------------------
MATLAB Version: 8.0.0.783 (R2012b)
MATLAB License Number: 649021
Operating System: Microsoft Windows 7 Version 6.1 (Build 7601: Service Pack 1)
Java Version: Java 1.6.0_17-b04 with Sun Microsystems Inc. Java HotSpot(TM) 64-Bit Server VM mixed mode
-------------------------------------------------------------------------------------------------------


Many thanks in advance,

Nick
ncalvert
Newbie
 
Posts: 0
Joined: Mon Jan 14, 2013 5:31 pm

Re: MATLAB Error

Postby Hitesh » Tue Jan 15, 2013 9:39 am

Hi Nick,

Please ensure that the location of the PS3000a.dll and ps3000aWrap.dll files are on the MATLAB path - I believe this is what the 'Library was not found' error is referring to.

The other change you can make in the script is to change the following line:

Code: Select all
addpath('C:\Pico SDK\PS3000asdk_r10_4_3_1');


to

Code: Select all
addpath('C:\Pico SDK\PS3000asdk_r10_4_3_5');


assuming that you have created a folder called 'Pico SDK' where you have extracted the SDK folder to.

The version number of the SDK was changed when the MATLAB driver and 3000 MSO devices were released.

If you are using a 64-bit version of MATLAB, the dll is a 32-bit version so will be incompatible. You would need to use a 32-bit version of MATLAB.

I hope this helps.
Hitesh

Technical Specialist
Pico Technology
Hitesh
Site Admin
Site Admin
 
Posts: 2063
Joined: Tue May 31, 2011 3:43 pm
Location: St. Neots, Cambridgeshire

Re: MATLAB Error

Postby ncalvert » Tue Jan 15, 2013 12:23 pm

Hi Hitesh,

Looks like it was the 64bit problem! Reinstalling the 32bit version of MATLAB has solved the problem.

Many thanks,
Nick
ncalvert
Newbie
 
Posts: 0
Joined: Mon Jan 14, 2013 5:31 pm

Re: MATLAB Error

Postby Hitesh » Tue Apr 16, 2013 8:57 am

Hi,

Just an update to say that we now have 64-bit dlls in the SDKs for current product ranges.

64-bit wrapper dlls are provided in some of the SDKs. Remaining 64-bit dlls will be added in due course but source code is available to build these if they are not present.

Thanks,
Hitesh

Technical Specialist
Pico Technology
Hitesh
Site Admin
Site Admin
 
Posts: 2063
Joined: Tue May 31, 2011 3:43 pm
Location: St. Neots, Cambridgeshire


Return to MATLAB

Who is online

Users browsing this forum: No registered users and 0 guests