This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

[FAQ] PROCESSOR-SDK-AM64X: Configure Static IP with MCU+ SDK enet_lwip_cpsw or enet_lwip_icssg example

Other Parts Discussed in Thread: DP83869

Problem Statement:

Can you please share steps to configure Static IP with MCU+ SDK enet_lwip_cpsw or enet_lwip_icssg example ?


  • Solution:

    Static IP configuration steps for lwip icssg/cpsw example: ( Note: Below is for ICSSG example same can be done for cpsw example also)

    1. Uncomment following macro in file mcu_plus_sdk\examples\networking\lwip\enet_lwip_icssg\lwipcfg.h

    /* #define USE_DHCP    0 */
    /* #define USE_AUTOIP  0 */


    2. For setting the IP address, Default gateway and Subnet mask use following lines in file mcu_plus_sdk\examples\networking\lwip\enet_lwip_icssg\lwipcfg.h

    #define LWIP_PORT_INIT_IPADDR(addr)   IP4_ADDR((addr), 192,168,1,200)   -> Defines IP address in format
    #define LWIP_PORT_INIT_GW(addr)       IP4_ADDR((addr), 192,168,1,1)          -> Defines Gateway in format
    #define LWIP_PORT_INIT_NETMASK(addr)  IP4_ADDR((addr), 255,255,255,0) -> -> Defines Gateway in format
    3. Recompile the example (recompiling any lib is not required) after following changes and it will set example in static ip mode with the IP address provided in step 2.

    Test to ensure configuration was successful:

    1. CCS log in uart terminal will print the local dhcp address as:

    DUT side:
    Enabling clocks!
    Starting lwIP, local interface IP is
    CPSW_3G Test on MAIN NAVSS
    EnetPhy_bindDriver: PHY 3: OUI:080028 Model:0f Ver:01 <-> 'dp83869' : OK
    PHY 3 is alive
    PHY 15 is alive
    Host MAC address: f4:84:4c:f9:88:ca
    [LWIPIF_LWIP] Enet has been started successfully
    status_callback==UP, local interface IP is
    UDP server listening on port 5001
    Cpsw_handleLinkUp: Port 1: Link up: 1-Gbps Full-Duplex
    MAC Port 1: link up
    2. Ping DUT at the configured IP(Ex : ping
    Open command prompt/Terminal and give following command:  ping
    Note : Client Side PC needs to configured in static IP with same gateway and netmask address. (For Windows PC:
    3. Iperf test also can be run using following documentation (See section Measuring the throughput using Iperf) 
    Note: This is based on  AM64x MCU+ SDK 08.06.00.