Discover MakerZone

MATLAB and Simulink resources for Arduino, LEGO, and Raspberry Pi

Learn more

Discover what MATLAB® can do for your career.

Opportunities for recent engineering grads.

Apply Today

Thread Subject:
calling c/c++ function in m-code

Subject: calling c/c++ function in m-code

From: Cotte J-M

Date: 9 Jan, 2002 06:14:48

Message: 1 of 6

hi all,


I have a driver for an itl09 written in C++ and i'd like to call
function from this driver in m-files(i don't want to rewrite all in m-
code).
Does anyone know if it's possible?


I got the matlab compiler,math library,graphic library,instrument
control toolboxes.

Subject: calling c/c++ function in m-code

From: sturla@slettdette.molden.net.invalid (Sturla Molden)

Date: 9 Jan, 2002 11:55:01

Message: 2 of 6

On Wed, 9 Jan 2002 06:14:48 -0500, "Cotte J-M" <jmcotte@aol.com>
wrote:

>hi all,
>
>
>I have a driver for an itl09 written in C++ and i'd like to call
>function from this driver in m-files(i don't want to rewrite all in m-
>code).
>Does anyone know if it's possible?
>
>
>I got the matlab compiler,math library,graphic library,instrument
>control toolboxes.

Yes you can do this.

You need to write a C mex file. Follow the instructions in the
"External Interfaces" manual.


Sturla Molden

Subject: calling c/c++ function in m-code

From: Michael Robbins<michael.robbins@us.cibc.com>

Date: 9 Jan, 2002 13:00:00

Message: 3 of 6

Lars Gregersen also has a function that eliminates the need for a C-MEX file,
but I haven't tried it yet.

Michael Robbins, CFA
Director, Debt Capital Markets
CIBC World Markets Corp., Canadian Imperial Bank of Commerce
New York, NY USA
michael.robbins@us.cibc.com , robbins@bloomberg.net

Subject: calling c/c++ function in m-code [URL included]

From: Michael Robbins<michael.robbins@us.cibc.com>

Date: 9 Jan, 2002 13:19:00

Message: 4 of 6

>Lars Gregersen also has a function that eliminates the need for a C-MEX file,
>but I haven't tried it yet.

http://www.2-control.com/software/matlab/windowstoolbox/calldll.html

Michael Robbins, CFA
Director, Debt Capital Markets
CIBC World Markets Corp., Canadian Imperial Bank of Commerce
New York, NY USA
michael.robbins@us.cibc.com , robbins@bloomberg.net

Subject: calling c/c++ function in m-code

From: marwic@bluemail.ch (marwic)

Date: 9 Jan, 2002 14:44:17

Message: 5 of 6

You could wrap your C++ code to an ActiveX control and use this ActiveX control
in ML.

On Wed, 9 Jan 2002 06:14:48 -0500, "Cotte J-M" <jmcotte@aol.com> wrote:

>hi all,
>
>
>I have a driver for an itl09 written in C++ and i'd like to call
>function from this driver in m-files(i don't want to rewrite all in m-
>code).
>Does anyone know if it's possible?
>
>
>I got the matlab compiler,math library,graphic library,instrument
>control toolboxes.

Subject: calling c/c++ function in m-code [URL included]

From: jm cotte

Date: 9 Jan, 2002 11:49:19

Message: 6 of 6

Ok thanks all!


i'm gonna try this and see what i can get out of matlab.

Tags for this Thread

No tags are associated with this thread.

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.

Contact us