Error 13 – Call Library Function Node in Built Executable and Installer

Home / Topic / Error 13 – Call Library Function Node in Built Executable and Installer

Home Forums FTDI FT4222 LabVIEW Driver Discussions Error 13 – Call Library Function Node in Built Executable and Installer

Viewing 14 reply threads
  • Author
    Posts
    • #3063
      Infant Anto Abishek
      Participant

      Hi Ajay,

      While working with development  code we are able to communicate with FT4222H device and the code is working, but after building EXE and running it we are unable to communicate with the device. It seems there is a problem with FTDI Driver. We have followed your instructions during EXE building/installation .We have tried to build an installer and install it in a clean/New PC without any LabVIEW or LabVIEW Runtime.

      After installation, when we try to run the EXE we are getting the following error#

      Error Code 13 Call Library Function Node

      We tried with different new/clean Laptop also, but still the problem persists . While running the same EXE in a PC with LabVIEW development system, EXE is working fine without any error. Do we have to install any other drivers?

      This is the EXE build Property window.

      Build Specification Source File Settings.png

      We have also shared the FTDI driver window in System32 for your referenceFTDI Driver in Windows System32 Folder.png

      We have already released the software to the customer, since it is not working he has made a serious escalation.

      Can you please help us to solve this issue since we have to release the final working version of the software to the customer on 31st  March.

       

      Regards,
      Infant Anto Abishek

    • #3069
      Ajay
      Keymaster

      Hi Infant,

      In most cases you don’t require to install FTDI installer separately on the destination PC.   When the executable runs, the FTD2XX.dll is expected in the “data” folder in parallel to executable file location.  Can you please confirm the folder target for FTD2XX.dll is at data folder?

      FYR: Below is the screenshot of the logic used to find the DLL location in driver.

      FTD2XX DLL resides inside Data Folder in parallel to Executable

      Thanks,
      AJ

    • #3072
      Infant Anto Abishek
      Participant

      Hi Ajay,

      As you have mentioned the FTD2XX.dll is located in the data folder. I have attached the Screenshot of the EXE data folder.

      FTD2XX and LibFT4222 DLL on data folder


      Regards
      Infant Anto Abishek

       

    • #3074
      Ajay
      Keymaster

      Hi Infant

      Have you installed FTDI Driver on the target machine?  Can you try installing this FTDI Driver CDM21228_Setup.zip here before executing the EXE?


      Thanks,
      AJ

    • #3076
      Nirmal Shyam Kumar
      Participant

      Hi Ajay,

      Thanks for the suggestion and I would like to respond on behalf of Infant.

      Our Typical execution steps are:

      1. Run the LabVIEW Installer (Exe and Installer created per guidelines) in the Clean machine
      2. Run the FTDI CDM Driver (the same one you mentioned in the link)
      3. Run the Executable (as mentioned by Infant, we have verified the folder to carry FTD2XX.dll)

      On skipping step 2, we get FTDI driver error and at times the device is not listed in the Windows Device manager

      Strangely if a system has LabVIEW (nothing else related to FTDI driver), the Executable works fine when the above steps are followed.  If the system doesn’t have LabVIEW, then we observe the FTDI driver error as indicated by Infant.

      It looks like something with DLL and FTDI Driver. But we are not sure about the root cause.

      Best Regards,
      Nirmal Shyam Kumar.S

    • #3078
      Ajay
      Keymaster

      Hi Nirmal/Infant,

      This looks strange to me as well, as this scenario has never been faced for over 3+ years this driver out to help various developers.  We would need to systematically analyze these.  By any chance would you be able to run the dependency walker on the target system as explained in this link?  Dependency Walker is software to figure out if all dependencies of the DLL are available on the system.  If you can send the screenshot of the dependency walker where warnings or missing dependencies are mentioned, we can figure out why we’re facing this issue and what is missing.

      Since you’re telling that EXE works well if the PC has LabVIEW installed, &, not working in PC where LabVIEW is not yet installed, I presume that it’s most likely the built installer might be missing some necessary component that should be installed.

      Thanks,
      AJ

    • #3080
      NIRMAL SHYAM KUMAR
      Participant

      Hi Ajay,

      Yes it is very odd and we did try with Dependency Walker and we are not very familiar with the utility and hence find difficult to get some inferences. It would really be of help if we can discuss over a 30 minutes call sometime today. we will also be able to share our screen and give better insight on problem statement/analysis. If that is acceptable, please let know convenient time and we can share with you a TEAMS invite.

       

      Best Regards,

      Nirmal Shyam Kumar.S

       

    • #3090
      Nirmal Shyam Kumar
      Participant

      Hi Ajay,

      Would like to update, a follow up of our discussion over the call:

      We did try installing LabVIEW in the clean PC and unexpectedly the SW did not work as it was in case with SW working on machines that has LabVIEW pre-installed

      So we are confused again on the missing piece. Do you have any alternate suggestions?

      Meanwhile, we are trying to compare the reports exported from Dependency Walker and shall share with you possibly tomorrow

      Best Regards,
      Nirmal Shyam Kumar.S

    • #3094
      Ajay
      Keymaster

      Nirmal

      Are the source code and built executable runs without error in the newly installed clean PC?

      Thanks
      AJ

    • #3095
      NIRMAL SHYAM KUMAR
      Participant

      Hi Ajay,

      Unfortunately, the source code and exe did not work in the clean PC after LabVIEW installation

      And, no improvement despite installing the Visual Studio (latest 22) version

      Any thoughts on what version of VC DLL /Visual studio is required?

      And, any other thing that you would want us to check.?

      Best Regards,
      Nirmal Shyam Kumar.S

    • #3097
      Ajay
      Keymaster

      Hi Nirmal,

      I suspect some other driver could be conflicting as we noticed USB2ANY in yesterday’s meeting.  By clean PC, I’m not sure if you mean freshly installed Windows, maybe that could help you.

      Since this discovery explains that the root cause of error-13 is not on the driver level (because the error occurs in one PC and doesn’t occur on another PC at the source code level), I would say it’s out of the scope of the FT4222 driver delivery.  I would recommend taking the consultation route if you would like me to support you further.


      Thanks,
      AJ

    • #3098
      NIRMAL SHYAM KUMAR
      Participant

      Hi Ajay,

      Thank you for supporting us in fixing the issue.

      And as we infer could infer, things don’t add up but something looks off with FTDI drivers

      Anyway, will check further and reach out on any help required

      Best Regards,
      Nirmal Shyam Kumar.S

    • #3089
      Ajay
      Keymaster

      Hi Nirmal/Infant,

      As we discussed over the call, please try to install LabVIEW on the Error PC and confirm that it’s working as you assume in this problem statement.

      If the error goes away, then it means some LabVIEW components are not packed as part of the installer.

      If the error still persists after LabVIEW installation, then the root cause of the error would be different.  It could be a conflict with other drivers installed (like USB2ANY which we noticed in the project and executable build).

      Also, you may compare the Dependency Walker logs between working PC and non-working PC (Erroring PC) to figure out any dependencies missing on non-working PC.  As we discussed you may not be able to directly copy over the missing DLLs in this case, but you would need to figure out an installer relevant to that (eg., VC++ Run time installer for missing C++ DLL)

      Thanks,
      AJ

    • #3122
      NIRMAL SHYAM KUMAR
      Participant

      Hi Ajay,

      We figured out that VC++ 2010 redistributable was the missing piece and it fixed things

      Thank you for the support.

      Best Regards,
      Nirmal Shyam Kumar.S

    • #3124
      Ajay
      Keymaster

      Good finding Nirmal..!  All the best & feel free to get in touch on any more struggle.  Now this thread can be closed.

      Thanks
      Ajay.

Viewing 14 reply threads
  • You must be logged in to reply to this topic.