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.

RTOS/TM4C1292NCPDT: Issue in External PHY configuration through MII interface

Part Number: TM4C1292NCPDT

Tool/software: TI-RTOS

Hi,

I have modified tcpEcho project of TM4C1294-XL sample code to work for my board which has TM4C1292NCPDT controller and External Ethernet Switch- KSZ8463FML connected through MII interface.

I have configured the Ethernet Switch using SPI interface to work in 100-FX mode, Full duplex and Auto negotiation disabled before Board_initEmac() function is called. and i also modified the code in EMACSnow.c file to configure external PHY and updating the Link status.

Now everything works perfectly as described in tcpEcho readme.txt file while programming the controller at fisrt time through CCS debugger and Run. and ping command also working perfectly in this case.

But if reboot or dynamically change the link, its not working. Ping command response says " Destination is unreachable ". we can also able to observe the link status change in CCS console window while link status is changing by adding System_printf().

i have attached the code here. 

Can you please suggest what could be the issue?

1325.tcpEcho.zip

Regards

Bala

  • Hi Bala,

    What do you mean by reboot...power cycle or CCS reset?

    What happens after a power cycle (without CCS attached). Does it work then?

    Todd
  • Hi Todd,

    I meant reboot is Power Cycle. 

    After power cycle or Dynamic link change it does not work.

    Its working when first time, when its programmed through CCS and Execute Run.

    Regards

    Bala

  • Is it just the networking portion not working after a power cycle? Do you get to main() and to tasks after BIOS_start?
  • Hi Todd,

    I believe networking portion is not working. Please find the latest code which i tested today and capture the wireshark log which also attached here. during wireshark capture, i have executed ping command from test PC. DUT IP address is 192.168.1.100 and test PC ip address is 192.168.1.3.

    After power cycle, My DUT is responding for three ping request and after that there is no response. this you can see it in the bottom of the wireshark log. so this is ensuring that BIOS and NDK has started and running. but after some time its failing. i will not be able to watch through CCS console log since its failing on next power cycle, so debugger is disconnected.

    4807.tcpEcho.zipwireshark log.txt

    Regards

    Bala

  • Bala,

    Do you have to make HW changes to the LP? I tried it and it was stuck in EMACReset.

    Also, I noticed the project was not using the driverlib that was shipped with that version of TI-RTOS. You had the following compiler search path setting: ${COM_TI_RTSC_TIRTOSTIVAC_INSTALL_DIR}/products/TivaWare_C_Series-2.1.4.178

    Todd
  • Hi Todd,

    >>>>Do you have to make HW changes to the LP?
    i am not getting your point. can you please elaborate? I have removed EMACReset since i am facing the problem in power cycle i.e. anyhow MAC will be reset during power cycle. But it doesn't help.

    >>>Also, I noticed the project was not using the driverlib that was shipped with that version of TI-RTOS. You had the following compiler search path setting: ${COM_TI_RTSC_TIRTOSTIVAC_INSTALL_DIR}/products/TivaWare_C_Series-2.1.4.178.

    This is i have tried because somebody suggested in the e2e forum that this version has updated Tivaware library.

    Regards
    Bala
  • HI Todd,

    adding more information, i am using uDMA and SPI operation in my application. as per TI Employee suggestion i have changed to latest version of tivaware libraray. please refer the thread here
    e2e.ti.com/.../2340245
  • Are you using the TM4C129 LaunchPad? Did you change any jumpers? Did you modify the board in anyway?
  • 7380.tcpEcho.zipHI Todd,

    I have TM4C129 LaunchPad. The code which is attached with this thread is modified to TM4C1292NCPDT controller which is having external PHY configuration. So i did changes in EMACSnow.c file to adapt the changes for external PHY configuration as suggested by below thread.

    everything works fine, but when you do, power cycle its not working.

    the only change i did in EMACSnow.c is EMACPHYConfigSet(EMAC0_BASE, EMAC_PHY_TYPE_EXTERNAL_MII | EMAC_PHY_INT_EXT_FULL_DUPLEX); in line no. 912. and Configured my External Ethernet Switch before Board_initEMAC() function in the main function.

    i am not able to narrow down using System_printf(), since the problem only on next power cycle. can you please suggest the solution?

    Regards

    Bala

  • I'm sorry, but I could not get this one to run past EMACReset either. You can try using the LEDs or debug output via the UART to help figure out what is going on.