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.

TMS570LC4357: MDIO and dp83640 PHY initialization on the TMDX570LC43HDK dev kit

Part Number: TMS570LC4357
Other Parts Discussed in Thread: TMDX570LC43HDK, DP83640, HALCOGEN,

I have used the HalCoGen to create MDIO and dp83640 PHY code for the TMDX570LC43HDK, but it times out when trying to read PHY registers. I have ensured that we have the correct clock speeds setup, the S2 DIP switch is set to ethernet on, and nothing else. I have attempted to probe the MDIO CLK signal on the PHY, but it doesn't appear to have a clock signal on it. I have tried a couple of different dev kits to ensure it wasn't a unique hardware issue. Does anyone have other ideas for next steps?

  • Actually I just noticed that the PHY is setting the USERACCESS0[ACK] bit, so something is working, but the PHY is returning 0s as its PHYIDR registers which causes the code to try the read again. These should be non-zero according to the datasheet

  • Hmmm, the ACK bit gets set no matter what the PHYADDR is.

  • The MDIO ALIVE register also shows 0xFFFFFFFF indicating there is a PHY at every address 0-31. This seems like it might be a hardware issue with this dev kit? I'm about out of ideas

  • Hi Kendall,

    First i will explain the step-by-step process to execute the LwIP demo on the TMS570LC4357 HDK board using static IP. 

    Just try to verify whether you followed all the steps i mentioned or not from your end.

    1. First, I changed the S2-4 switch to the ETHERNET ON
    2. Now I connected an ethernet cable between my Laptop and HDK board, and opened CMD and verified the ipconfig. I got the IP address and subnet mask as below:
    3. Based on the above IP address and subnet mask, I configured the static IP address in HDK LwIP code as below
    4. Now I build the project and load it into the HDK board.
    5. Once I load the project into the HDK board, I also opened a serial window with below configurations.
    6. Now I reset the board and verified the serial com data

      As you can see, I got PHY ID and device IP address also got SET now.
    7. Now I opened a browser and accessed the server IP address.

      As you can see that I was able to access the server page, so the demo is working as expected.

    Just make sure you are doing all these steps correctly. And i am attaching my tested project for your reference:

    3364.LwIP.zip

    --
    Thanks & regards,
    Jagadish.

  • I am trying to run a custom bare-metal application which I can't send you. Though the EMAC, MDIO, and PHY drivers are directly from the HalCoGen.

    I tried running the LwIP demo, but I cannot connect to these boards over USB in the code composer. After building it just says this: Texas Instruments XDS100v2 USB Emulator_0/CortexR5 : Target must be connected before loading program.

    And I have changed the S2 switch to be for USB.

  • Though I did have a thought. Due to the fact that USB and Ethernet can't be used simultaneously I had a theory that maybe JTAG and Ethernet can't be used simultaneously. Do you know if there is any validity to this?

  • It turned out to be a pin muxing issue with some of the MII pins. It is all working now.