The microcontroller uses usb, and the dll has many nice functions that I would not want to have to write again. Anyone has an example of code calling a function in another dll in flext? Thanks
-----Original Message----- From: Marc Lavallée [mailto:odradek@videotron.ca] Sent: Wednesday, February 18, 2004 12:03 PM To: rr Cc: pd-list@iem.at Subject: Re: [PD] Calling a function in a DLL from PD?
On Wed, Feb 18, 2004 at 11:38:46AM -0500, rr wrote:
I have a DLL that contains a set of functions to read and write ports
to
a microcontroller.
What so special about the communication protocol of the microcontroler? Does it work with a serial port using human readable commands? Because you might not need the DLL, and you could build a cross-platform patch.
I also have an OCX with the same functions Is it possible to call the functions in the DLL or OCX from pd? If so. could somebody point me in the right direction? Where would I script the call?
I think you'd have to program an object in C that uses the DLL.
As usual, I recommend flext.
--
Marc
Hallo, rr hat gesagt: // rr wrote:
The microcontroller uses usb, and the dll has many nice functions that I would not want to have to write again. Anyone has an example of code calling a function in another dll in flext?
You can call the functions of this library like you would do with any other library. A simple example is my fluid~ external, which #includes fluidsynth.h and then just calles the functions defined there, like the one which creates a fluid_synth instance. You will have to somehow link the dll, but this is common C programming stuff.
If it's USB, then maybe you could use some other object to talk to it. I don't know any on Windows, but on Linux, the linuxevent objects work just fine with USB-HID devices.
Frank Barknecht _ ______footils.org__
On Wed, Feb 18, 2004 at 01:36:03PM -0500, rr wrote:
Anyone has an example of code calling a function in another dll in flext?
Calling DLL functions from Flext is no different than calling them from any C/C++ program.
http://msdn.microsoft.com/library/default.asp?url=/library/en-us/vccore/html...
Marc