calling a dll
조회 수: 5 (최근 30일)
이전 댓글 표시
I wish to call my dll (simpledll)from Matlab R2007b; I have loaded the dll successfully. Then from the 'libfunctions' I get the function: "doublePtr changevar(double, doublePtr)" displayed. This looks ok to me, as all it does is inputs a value (double) & returns a value (double).
I tried calling it using the following: in1=2; [out1]=callib('simpledll','changevar',in1);
But I get the following error on the calling line: "Undefined function or method 'callib' for input arguments of type 'char'."
What does this mean; have I got the format for calling the dll wrong; what should I have put?
댓글 수: 0
채택된 답변
Friedrich
2011년 7월 11일
Hi,
this be because calllib is written with three l instead of two like you did.
댓글 수: 2
Kaustubha Govind
2011년 7월 11일
doublePtr changevar(double, doublePtr)
this seems to indicate that the function needs two inputs, but you are only providing one.
추가 답변 (1개)
Steve
2011년 7월 11일
댓글 수: 3
Kaustubha Govind
2011년 9월 27일
You said that libfunctions lists the function as "doublePtr changevar(double, doublePtr)" - this indicates that the function has 2 inputs. What is the corresponding signature for the function with one input?
참고 항목
카테고리
Help Center 및 File Exchange에서 Call C from MATLAB에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!