LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Cannot Import Shared Library

Solved!
Go to solution

I get the following errors for various functions.

 

1.

 

PREF0 PREF1 PICO_STATUS PREF2 PREF3 (ps5000aFlashLed)
(
int16_t handle,
int16_t start
);

The following symbols are not defined:
PICO_STATUS; int16_t;

Undefined symbols can prevent the wizard from recognizing functions and parameters. To correct this problem, check the header file to determine if you must add preprocessor definitions. Click the Back button to return to the previous page of the wizard to add a preprocessor definitionsl (for example, "NIAPI_stdcall = __stdcall" or "NIAPIDefined = 1").

The following header file was not found in the specified header file or one of the referenced header files:
- stdint.h

To fix, click the Back button to go to the previous page and add the header file path to the Include Paths list.

 

2.

 

The function cannot be imported into LabVIEW. This might be caused by one of the following problems:

The function is not declared in the header file but is exported in the library.

Check the header file to make sure it contains declarations of the function.

Undefined symbols can prevent the wizard from recognizing functions and parameters. To correct this problem, check the header file to determine if you must add preprocessor definitions. Click the Back button to return to the previous page of the wizard to add a preprocessor definitionsl (for example, "NIAPI_stdcall = __stdcall" or "NIAPIDefined = 1").
DYNLINK;PREF0;PREF1;PREF2;PREF3;WIN32;_USRDLL;__cplusplus;

The following header file was not found in the specified header file or one of the referenced header files:
- stdint.h

To fix, click the Back button to go to the previous page and add the header file path to the Include Paths list.

 

 

 

The attachment has the dll and .h file from which I am trying to import functions. As well as a screenshot of the error.

 

 I would sincerely appreiciate any help.

 

Message 1 of 3
(5,652 Views)
Solution
Accepted by topic author Lanom

Hi Lanom,

 

My name is George and I work as an Applications Engineer at National Instruments. I’ve been looking into your problem with importing a shared library into LabVIEW.

 

For error 1 you are trying to include stdint.h in your header files but you either do not have this file or the wizard cannot find this file. I have included the path to where I found the file below, if you find and add this file to the folder that contains the other header files and add that folder as an included path in the shared library import wizard this error should be fixed.

 

C:\Program Files (x86)\National Instruments\CVI2013\include\ansi\stdint.h

 

Error 2 is being caused by functions being undefined. You have 2 functions, “ps5000ApplyFix()” and “ps5000aConvertStreamingDataInternal()”, that have not been defined in the same way as your other functions and so cannot be imported. If you define these 2 in the same way you have defined the others this should be fixed. You also appear to have a duplicate of all of your functions included in the .dll that are not defined. If these functions with "-2" are not intentional re-create the .dll file without these functions and this error should be fixed. If these functions are intentional then they will also need to be defined like the others.

 

Let me know if this fixes your problem and if you have any more questions with these steps or you have any other problems let me know and I will do my best to help.

 

Regards,

 

George

0 Kudos
Message 2 of 3
(5,541 Views)

Thank you George!

0 Kudos
Message 3 of 3
(5,528 Views)