AM2434: Re-config IP address settings in running app from code

Part Number: AM2434

Tool/software:

Hello,
As discussed in the following forum thread: https://e2e.ti.com/support/microcontrollers/arm-based-microcontrollers-group/arm-based-microcontrollers/f/arm-based-microcontrollers-forum/1363088/am2434-am2434?tisearch=e2e-sitesearch&keymatch=AM2434%20EI_API_ADP_setIpConfig%28%29 
, we are also attempting to reconfigure our adapter's IP settings through code using the EI_API_ADP_setIpConfig API.

This API functions properly when called during initialization on start and when changing IP settings using the ODVA Molex tool is called right before our call (because ODVA EIP tool stops the current session).

However, we are unable to change the settings while the code application is running (from app task run, without ODVA EIP tool). Despite updating the IP configuration parameters in the code, EEPROM, and calling the EI_API_ADP_setIpConfig function, there is no change on adapter or error returned.

We must perform a device reset for our changes to be successfully applied to the adapter.

What steps are necessary to apply the changes immediately to the adapter after calling EI_API_ADP_setIpConfig? We also attempted to reinitialize the adapter with the EI_API_ADP_init call, but it was not effective.

We need to stop the current session, after change the IP settings, and start a new session with the updated IP settings, which api calls are used for this steps?

Thank you, Matej.

  • Hi Matej,

    Could you please tell me which SDK version you are currently using?

    Additionally, have you tried using the EI_API_ADP_setIpConfig function with the last parameter set to true? For example:
    errCode = EI_API_ADP_setIpConfig(pAdapter,
                                    configurationControl,
                                    ipAddr,
                                    ipNwMask,
                                    ipGateway,
                                    nameServer1,
                                    nameServer2,
                                    aDomainName,
                                    true);
    Best regards,
    Pourya
  • Hi Pourya,
    we are using mcu plus sdk 10.01.00.32 and ind comms sdk 9.02.00.24.
    We also changed the last parameter to 'true', but in the first case, there was an error asserting NULL from the EIP stack.

    After conducting tests, we found that the EI_API_ADP_setIpConfig function, with the last parameter set to apply changes as 'true', can only be called after the EI_API_ADP_init function.

    In this scenario, the adapter successfully applies changes to the adapter. Before initialization, it's possible to only set the parameters of the IP address configuration, but without applying the changes flag - false.

    Thank you, Matej.