11-15-2005 04:12 AM
11-15-2005 07:09 PM
11-17-2005 06:45 AM
Thanks a lot!
I'll try this as soon as I can (a little technical problem). my goal is to process images which was acquired with NI device using MALAB.
Before trying to use the activeX component using the MATLAB GUI, I've tried to use the DLL, a try which led to MATLAB's crash, I have probably made a big mistake, so maybe you can help me with that too?
This is the MATLAB script which I was trying to run:
loadlibrary('C:\WINNT\system32\imaq.dll','C:\Program Files\National Instruments\NI-IMAQ\include\niimaq.h','alias','imaqlib');
name='img0';
Iname=int8(name);
pname=libpointer('int8Ptr',int8(name));
intrfc=libpointer('uint32Ptr',0);
[err pname intrfc] = calllib('imaqlib','imgInterfaceOpen',pname,intrfc)
sId=libpointer('uint32Ptr',0);
[err sId]=calllib('imaqlib','imgSessionOpen',intrfc,sId)
[err]=calllib('imaqlib','imgGrabSetup',sId,1)
img=libpointer('voidPtrPtr',0);
[err img]=calllib('imaqlib','imgSnap',sId ,img)
MATLAB crashes on the call to "imgSnap".
Thanks again!Amnon.
11-17-2005 07:11 AM
Updating-
The command you've suggested doesn't work. an error occurs, as following:
??? No appropriate method or public field Item for class Interface.CWIMAQControlsLib_CWIMAQ_1.Images.
Since I've tried to use this activeX in VB too, I know there are methods which exist when using VB, but does not appear
when trying to use the "methods" command in MATLAB. The same is for the field 'Item' of 'Images'- MATLAB doesn't
recognize it.
Hope you can help me further on this,
Amnon.
11-18-2005 03:22 PM