Filter löschen
Filter löschen

communicate with extern .dll file

1 Ansicht (letzte 30 Tage)
martijn
martijn am 20 Dez. 2011
I have .dll file from a programm what you can use to export real time data. I want to get data from this .dll file, there´s a devolepers kit from this programm were there are examples of how you can excess this data.
the file:
I'm trying to load the library using:
loadlibrary('sflib32.dll',sflib32.h')
in the sflib32.h file is a description of how to use the file:
This module can be used to interface with the DAC740.DLL using run-time linking. Usage: 1. Construct an object of the DAC740 class. 2. Call GetDllInstance to see if the dll was loaded up ok (!NULL means that it was loaded up ok, NULL => error). 3. Call InitDac740 to initialize the library 4. Use any functions as desired 5. Call UnInitDac740 before destroying the object 6. Delete the object.
I'm using matlab r2007b, have little expercience in c++.
First I selected the microsoft visual studio 8 compiler and loaded the library. I'm getting a syntax error in #ifdel/#ifndef.
According the help file you can acces data by using the following command:
Dac740->SFLoadConfig(NULL, CURRENT_DATA)
How can I implemend this function in the h file?
  1 Kommentar
Kaustubha Govind
Kaustubha Govind am 20 Dez. 2011
Please be more specific. What is the command you use to load the library, and paste the exact error that you receive.

Melden Sie sich an, um zu kommentieren.

Antworten (0)

Kategorien

Mehr zu C Shared Library Integration finden Sie in Help Center und File Exchange

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by