FTDI Community

Please login or register.

Login with username, password and session length.
Advanced Search  

News:

Welcome to the FTDI Community!

Please read our Welcome Note

Technical Support enquires
please contact the team
@ FTDI Support


New Bridgetek Community is now open

Please note that we have created the Bridgetek Community to discuss all Bridgetek products e.g. EVE, MCU.

Please follow this link and create a new user account to get started.

Bridgetek Community

Author Topic: FT4222 - Problem with 64 bit dll after Windows security update  (Read 27416 times)

urbanvibes

  • Newbie
  • *
  • Posts: 5
    • View Profile
FT4222 - Problem with 64 bit dll after Windows security update
« on: February 24, 2023, 08:56:32 AM »

I have a setup where 64 bit versions of ftd2xx and LibFT4222 dll's are called through Matlab, this originally worked fine on one PC, but failed on another one.
We had a debug session where we concluded that the first call to a LibFT4222.dll function returns FT4222_DEVICE_NOT_SUPPORTED. We compared installed dll's, made sure we had the same versions, but the same code still only worked on one machine. The morning after I restarted my PC after a Windows update, and now the error was on both machines.

I have attached a C++ test program created in Visual Studio, this works fine when compiling/running in 32 bit, but fails when compiling/running 64 bit.
(The dll paths are relative to my test setup, they might need modification before running)

Any ideas?
Sincerely
Torbjørn Biering Tvermosegaard
Logged

FTDI Community

  • Administrator
  • Hero Member
  • *****
  • Posts: 899
    • View Profile
Re: FT4222 - Problem with 64 bit dll after Windows security update
« Reply #1 on: February 24, 2023, 03:56:09 PM »

Hello,

Which version of the D2xx driver and LibFT4222 library are you using?

Which version of FT4222H IC are you using?

If you can send an email to your local technical support team we can take a look into your issue further:

https://ftdichip.com/technical-support/

Best Regards,
FTDI Community
Logged

urbanvibes

  • Newbie
  • *
  • Posts: 5
    • View Profile
Re: FT4222 - Problem with 64 bit dll after Windows security update
« Reply #2 on: February 25, 2023, 02:07:50 PM »

I have sent a mail to EMEA region support, with this additional info:

Ftd2xx version is file: 3.2.16.1 Product: 2.12.36.4
LibFT4222 version is: 1.4.4.155 and same product version (but they come from LibFT4222-v1.4.5.zip)
The chip seems to be FT4222HQ 1911-D

Sincerely Torbjørn
Logged

urbanvibes

  • Newbie
  • *
  • Posts: 5
    • View Profile
Re: FT4222 - Problem with 64 bit dll after Windows security update
« Reply #3 on: February 27, 2023, 01:39:42 PM »

For anyone else affected by this here is an update on this issue after communicating with FTDI-UK:
Quote
Hi Torbjørn,
We think it most likely came from a Windows 10 security Update from August and seems to have an affect around memory allocation

The LibFT4222.dll is working using this configuration:
Using Visual Studio 2022 V17.2 after uninstalling 2x Windows 10 security patches from August: KB5015730 and KB5012170
Using Visual Studio 2022 V17.3 is still not working even after uninstalling the 2 security patches. The Visual Studio 17.3 Update includes security fixes.

We have an internal bug raised for this but I don’t have any specific time frame for a fix at this time 

Regards
[name removed by me(Torbjørn)] (FTDI-UK)


Furthermore I ran the test program on a Windows 11 machine with the exact same result.

Sincerely Torbjørn
« Last Edit: February 27, 2023, 02:34:36 PM by urbanvibes »
Logged

FTDI Community

  • Administrator
  • Hero Member
  • *****
  • Posts: 899
    • View Profile
Re: FT4222 - Problem with 64 bit dll after Windows security update
« Reply #4 on: February 27, 2023, 04:42:56 PM »

Hello,

Please ensure that you are opening the correct interface.

For example, FT4222H in Mode 0:

Interface A is for SPI/I2C control.
Interface B is for GPIO control.

If you open the wrong interface in your software this can lead to issues.

It's worthwhile checking your mode configuration and application software as uninstalling Windows Security patches should not be the solution.

Best Regards,
FTDI Community
Logged

urbanvibes

  • Newbie
  • *
  • Posts: 5
    • View Profile
Re: FT4222 - Problem with 64 bit dll after Windows security update
« Reply #5 on: February 27, 2023, 05:07:06 PM »

Hi "FTDI Community"

The device is in CNFMOD2 (Quad SPI master) and as the attached example shows the exact same code works when the application is 32bit and uses 32bit dll's.

You seem to have not read my previous post properly, the quote from FTDI support confirms there's an issue with the 64bit dll's and an internal bug has been raised. This should be of major concern for FTDI, as this problem will spread (for 64bit applications) when customers computers are updated.

It would not work to uninstall security patches in my case anyway, as I'm using Matlab for the "real" application, the attached test program was made to rule out Matlab in the equation, so I would not be able to use a previous version of Visual Studio - since I'm not using Visual Studio.

I hope there will be a solution from FTDI soon, as the workaround is quite tedious. If you are too busy, I'll gladly take a look at the source code, but I guess that's something you keep to yourselves :-)

Sincerely Torbjørn
Logged

FTDI Community

  • Administrator
  • Hero Member
  • *****
  • Posts: 899
    • View Profile
Re: FT4222 - Problem with 64 bit dll after Windows security update
« Reply #6 on: February 28, 2023, 04:20:13 PM »

Hello,

You are already are in contact with us via email and we'll reach out to you again to review your code.

We had a similar issue reported in the past and although it looked to be an issue with Windows Update and the 64-bit dll it turned out not to be the case as the application software was opening the wrong interface.

Best Regards,
FTDI Community
Logged

urbanvibes

  • Newbie
  • *
  • Posts: 5
    • View Profile
Re: FT4222 - Problem with 64 bit dll after Windows security update
« Reply #7 on: March 02, 2023, 07:55:47 AM »

Hi again

Yes you requested contact by email, but I relayed information here, as it might be relevant to others. Not much point in having a community, if issues that are discussed here are moved to mail conversations that are not public.

As my previous post states, I'm not opening the wrong interface. In the original post and in my first mail, I attached an example program that works when compiled and running with 32bit dll's but fails when compiled and running with 64bit dll's.

As I understand it you will now test my example code, I look forward to the result:-)

Sincerely Torbjørn
Logged

FTDI Community

  • Administrator
  • Hero Member
  • *****
  • Posts: 899
    • View Profile
Re: FT4222 - Problem with 64 bit dll after Windows security update
« Reply #8 on: March 02, 2023, 04:15:36 PM »

Hello,

We're working with you on this issue via email and we can post the final resolution on this forum once we know.

This will be more helpful for other community users rather than speculating what the issue is without knowing the root cause.

Best Regards,
FTDI Community
Logged