nRF Command Line Tools: nrfdfu.dll 32bit version problem when updating nRF9160 firmware

Dear support team,

we use the Nordic nrfdfu.dll (64bit) in our Win11 C#/.Net application for modem update which works fine.
When we switch our application to 32bit process and change to the Nordic nrfdfu.dll (32bit) the modem update functionality no longer works. The communication start between PC application and nRF9160 modem seems to fail and the application hangs until we stop it after some minutes.


Via DllImport we use the following methods of the nrfdfu.dll: 

        [DllImport(nrfDfuDllName, EntryPoint = "NRFDFU_connect_to_mcuboot_target", CallingConvention = CallingConvention.Cdecl)]
        [DllImport(nrfDfuDllName, EntryPoint = "NRFDFU_connect_to_modemdfu_target", CallingConvention = CallingConvention.Cdecl)]
        [DllImport(nrfDfuDllName, EntryPoint = "NRFDFU_program_package", CallingConvention = CallingConvention.Cdecl, CharSet = CharSet.Ansi)]
        [DllImport(nrfDfuDllName, EntryPoint = "NRFDFU_close_connection", CallingConvention = CallingConvention.Cdecl)]
        [DllImport(nrfDfuDllName, EntryPoint = "NRFDFU_verify_package", CallingConvention = CallingConvention.Cdecl, CharSet = CharSet.Ansi)]

Do you have any idea what the reason could be?

Best regards,

Peter   

Parents
  • Hello,

    From the log messages you have shared:
    It looks like the error occurs when Windows tries to open the serial port (COM18), and the message is coming from Windows rather than dll. This typically happens if the serial port is already in use by another program (for example another instance of the application still running).

    To verify this, could you try connecting to COM18 using a 32-bit version of PuTTY? If PuTTY can open the connection, it would indicate that  DLL and worker executable are running correctly and that the issue is likely related to another application holding the port. If PuTTY cannot open it, then the port may currently be locked or there may be a Windows configuration issue.

    Kind Regards,

    Abhijith

Reply
  • Hello,

    From the log messages you have shared:
    It looks like the error occurs when Windows tries to open the serial port (COM18), and the message is coming from Windows rather than dll. This typically happens if the serial port is already in use by another program (for example another instance of the application still running).

    To verify this, could you try connecting to COM18 using a 32-bit version of PuTTY? If PuTTY can open the connection, it would indicate that  DLL and worker executable are running correctly and that the issue is likely related to another application holding the port. If PuTTY cannot open it, then the port may currently be locked or there may be a Windows configuration issue.

    Kind Regards,

    Abhijith

Children
Related