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.

TMDS243EVM: Customer Board use two DP83867 for EtherNet

Part Number: TMDS243EVM
Other Parts Discussed in Thread: SYSCONFIG

Tool/software:

Hi Ti Expert,

   Our own designed board's hardware are like this: CPSW0 + two DP83867 for EtherNet.

   For IIC EEPROM, my board are the same as EVM.

   I use the demo enet_lwip_cpsw_am243x-evm_r5fss0-0_freertos_ti-arm-clang to test my board. My SDK is mcu_plus_sdk_am243x_11_00_00_15.

   The following is my steps.   

       1 I change Phy to DP83867and modify Phy address, checked Strapped Mode in Sysconfig.

       2 Modify MDIO/MDC pin according to my board.

       3 Ensure the pins of RGMII is the same as my board.

 When debug, I always stuck here     

    status = EEPROM_read(gEepromHandle[CONFIG_EEPROM0], I2C_EEPROM_MAC_DATA_OFFSET, macAddrBuf, (macAddrCnt * ENET_MAC_ADDR_LEN));

 For the EVM board, macAddrBuf = 16, and for my board macAddrBuf = 255. This macAddrBuf is read out from EEPROM.

 I've check the code, before the reading of EEPROM, there seems no writing for the EEPROM.

 Here is my question, how this 16(macAddrBuf, offset 0x40) be stored in the EEPROM of EVM first time?

 How could I initial my EEPROM to continue my test?

BR,

Chunyang 

  • Hi Ti Expert,

       update my progress,

       After wrote 0x10 to address 0x40, and 0x70 to address 0x42 for my EEPROM (have no idea whether it should be done like this)

       I can get over the initial, and get the print out log like the following, but my board is not like EVM can get IP address for both Ethernet ports.

       Looking forward to your supporting. 

    BR,

    Chunyang 


    ==========================
    ENET LWIP App
    ==========================
    Enabling clocks!
    EnetAppUtils_reduceCoreMacAllocation: Reduced Mac Address Allocation for CoreId:1 From 4 To 3
    Mdio_open: MDIO Manual_Mode enabled
    Open MAC port 1
    EnetPhy_bindDriver: PHY 2: OUI:000000 Model:00 Ver:00 <-> 'generic' : OK
    Open MAC port 2
    EnetPhy_bindDriver: PHY 1: OUI:000000 Model:00 Ver:00 <-> 'generic' : OK
    PHY 0 is alive
    PHY 1 is alive
    PHY 2 is alive
    PHY 3 is alive
    PHY 4 is alive
    PHY 5 is alive
    PHY 6 is alive
    PHY 7 is alive
    PHY 8 is alive
    PHY 9 is alive
    PHY 10 is alive
    PHY 11 is alive
    PHY 12 is alive
    PHY 13 is alive
    PHY 14 is alive
    PHY 15 is alive
    PHY 16 is alive
    PHY 17 is alive
    PHY 18 is alive
    PHY 19 is alive
    PHY 20 is alive
    PHY 21 is alive
    PHY 22 is alive
    PHY 23 is alive
    PHY 24 is alive
    PHY 25 is alive
    PHY 26 is alive
    PHY 27 is alive
    PHY 28 is alive
    PHY 29 is alive
    PHY 30 is alive
    Starting lwIP, local interface IP is dhcp-enabled
    [LWIPIF_LWIP] NETIF INIT SUCCESS
    Host MAC address-0 : c0:d6:0a:ec:b1:da
    Host MAC address-0 : 70:03:04:05:06:07
    Starting lwIP, local interface IP is dhcp-enabled
    [LWIPIF_LWIP] NETIF INIT SUCCESS
    [LWIPIF_LWIP] Enet has been started successfully
    [0]status_callback==UP, local interface IP is 0.0.0.0
    [1]status_callback==UP, local interface IP is 0.0.0.0
    UDP server listening on port 5001
    5.158s : CPU load = 6.68 %
    10.158s : CPU load = 3.76 %

  • update my progress, 

    If I remove Strapped Mode selection from Sysconfig, I got the following log

    ==========================
    ENET LWIP App
    ==========================
    Enabling clocks!
    EnetAppUtils_reduceCoreMacAllocation: Reduced Mac Address Allocation for CoreId:1 From 4 To 3
    Mdio_open: MDIO Manual_Mode enabled
    Open MAC port 1
    EnetPhy_bindDriver: PHY 2: OUI:000000 Model:00 Ver:00 <-> 'generic' : OK
    Open MAC port 2
    EnetPhy_bindDriver: PHY 1: OUI:000000 Model:00 Ver:00 <-> 'generic' : OK
    PHY 0 is alive
    PHY 1 is alive
    PHY 2 is alive
    PHY 3 is alive
    PHY 4 is alive
    PHY 5 is alive
    PHY 6 is alive
    PHY 7 is alive
    PHY 8 is alive
    PHY 9 is alive
    PHY 10 is alive
    PHY 11 is alive
    PHY 12 is alive
    PHY 13 is alive
    PHY 14 is alive
    PHY 15 is alive
    PHY 16 is alive
    PHY 17 is alive
    PHY 18 is alive
    PHY 19 is alive
    PHY 20 is alive
    PHY 21 is alive
    PHY 22 is alive
    PHY 23 is alive
    PHY 24 is alive
    PHY 25 is alive
    PHY 26 is alive
    PHY 27 is alive
    PHY 28 is alive
    PHY 29 is alive
    PHY 30 is alive
    Starting lwIP, local interface IP is dhcp-enabled
    [LWIPIF_LWIP] NETIF INIT SUCCESS
    Host MAC address-0 : c0:d6:0a:ec:b1:da
    Host MAC address-0 : 70:03:04:05:06:07
    Starting lwIP, local interface IP is dhcp-enabled
    [LWIPIF_LWIP] NETIF INIT SUCCESS
    [LWIPIF_LWIP] Enet has been started successfully
    [0]status_callback==UP, local interface IP is 0.0.0.0
    [1]status_callback==UP, local interface IP is 0.0.0.0
    UDP server listening on port 5001
    EnetPhy_enableState: PHY 2: no supported caps found
    EnetPhy_enableState: PHY 1: no supported caps found
    EnetPhy_enableState: PHY 2: no supported caps found
    EnetPhy_enableState: PHY 1: no supported caps found
    EnetPhy_enableState: PHY 2: no supported caps found
    EnetPhy_enableState: PHY 1: no supported caps found

  • Hi Chunyang,

    1. You can use EEPROM APIs to write into the EEPROM with the MAC addresses that you want to populate in the EEPROM.
    2. Currently, the application is binding to generic PHY driver instead of the correct PHY driver. Please check if the MDIO config is correctly populated. Check for the MDIO operating mode. 

    From the logs, looks like you have populated the EEPROM with the correct values. Please check the PHY driver binding and PHY config.

    Regards,
    Teja.

  • Hi Teja,

       I‘ve double checked my board's Pins, MDIO/MDC, clk of the Phys and Phy address,  there is no problem.

       I can see there some data on MDIO and MDC with an oscillometer when my project running.

       I am trying to analyse the code of ti_enet_open_close.c... that generated by CCS, but they are hard to understand. 

       Could you please guide me to do the checking of MDIO's configuration?

    BR,

    Chunyang 

  • Hi Teja,

       For my board, the MDIO/MDC are directly connecting to MCU, not like the EVM through a FET switch.

       I compared MDIO/MDC signal between my board and EVM. 

       EVM: both 3.3V, and normal High, data Low.

       My borad, MDC just as EVM. But MDIO normal Low, and data High, and the high voltage level only 0.9V.

       I am sure there is a Pull-up resister for my MDIO as EVM.

       This is my issue by now.

        

       And should I check Enet(CPSW)->Board Config->"Costumer Board "?

       If I check it, there is warning in ETHPHY (Enet CPSW/ICSS): Warning : Ethphy device is not linked to a network peripheral

    BR,

    Chunyang 

  • Hi Chunyang,

    You can find the MDIO config in sysconfig-gui in the following location:

    Enet (CPSW) > MDIO Config > Operating Mode: Currently, the application suggests it is in Manual mode. Please update this to normal mode

    Enet (CPSW) > MDIO Config > MDCLK Frequency: Currently set as 2.2 MHz. You can keep this the same, or reduce the frequency to 1 MHz for more stable debug setup. This can be lowered to a minimum of 200 KHz.

    It is preferable to set the custom board option, and add the custom_board related board config to be added to the application. You can find more details in the MCU+ SDK. Please find the resource here: https://software-dl.ti.com/mcu-plus-sdk/esd/AM243X/latest/exports/docs/api_guide_am243x/enet_migration_guide_top.html#CustomBoardSupport

    After enabling the custom board, please make sure the mux configuration which is present in the default application is not effecting your pin configurations.

    Please let us know the observations once these test are performed.

    Thanks and regards,
    Teja,

  • Hi Teja,

       Thanks for your efforts, my issue is fixed.

        The wrong voltage level of MDIO is caused by the wrong configuration of GBE_PHY1_GPIO0 and GBE_PHY1_GPIO1 by hardware side.

        Now, my board work well with two DP83867 for EtherNet.

    BR,

    Chunyang