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.

How to run HUA via SGMII interface 1?

Hi


I am porting the HUA app to our board which has C6678. After modified some settings in the platform_lib and the GEL file (basicaly about the SGMII SerDes and DDR3 -- the refclk differs from the EVM), rebuild the project, the HUA app runs well. However, it can only work on SGMII interface 0, what should I do if I want to run the app on SGMII interface 1? (the two SGMII interfaces both connect to PHYs in our platform)


Thanks in advance!


Han

  • Not sure if it can work on your board. Can you please try out the following in your board?

    The solution could be like modifying the source code and then recompile the dependent applications/libraries.

    pdk_C6670*\packages\ti\platform\evmc6670l\platform_lib\src\platform.c
    has the list of EMAC ports for the EVM as below.
    PLATFORM_EMAC_PORT_MODE emac_port_mode[PLATFORM_MAX_EMAC_PORT_NUM] =
    {
        PLATFORM_EMAC_PORT_MODE_AMC,
        PLATFORM_EMAC_PORT_MODE_PHY
    };

    EMACInit_Core function under pdk_C6670*\packages\ti\transport\ndk\nimu\src\nimu_eth.c file has the below check.

    #ifndef SIMULATOR_SUPPORT
        for (i = 0; i < PLATFORM_MAX_EMAC_PORT_NUM; i++)
        {
            platform_get_emac_info (i, &emac_info);
            if (emac_info.mode == PLATFORM_EMAC_PORT_MODE_PHY)
            {
                break;
            }
        }
        if (i < PLATFORM_MAX_EMAC_PORT_NUM)
        {
            gTxPort = emac_info.port_num;
            memcpy(ptr_pvt_data->pdi.bMacAddr, emac_info.mac_address, 6);
        }
        else
        {
            platform_write ("Error: Unable to find a TX EMAC port\n");
            return -1;
        }
    #else
        {
            gTxPort = 1;
            platform_get_emac_info (1, &emac_info);
            memcpy(ptr_pvt_data->pdi.bMacAddr, emac_info.mac_address, 6);
        }
    #endif

    Looking at this it appers that nimu eth driver is initialing port1 (which ever has *MODE_PHY). So, to use the other port,
    interchaning the configurations (like making port0 to have MODE_PHY) might solve your issue.

    Please note that after building Platform Lib, please rebuild Nimu_ETH driver and then the application.

     

    -Thanks,
    Aravind

  • Hi.

    I encountered a similar problem.
    If you change emac_port_mode, then the work begins the first of port(phy interfaces) found. But only one of them!

    I would like to get both working port.
    As I understand it requires a different NIMU-driver with the support of two ports (interfaces)  in EMAC

    Is there such a driver, and if so, where can I find?