DP83826AI: EtherCAT connection recovery

Part Number: DP83826AI

Hello,

I have created a single port ECAT slave using XMC4800 and DP83826AI.
SSC tool (from Beckhoff) was used to generate the ECAT libraries.
I have the following setup in hotlink:

Master --(cable1)-- Slave 1 --(cable2)-- Slave 2 = my ECAT slave

When cable2 is unplugged and replugged again, I have no issue in ECAT connection recovery.
However, when cable1 is unplagged and replugged, sometimes, my slave cannot establish ECAT connection.
What is the right way to reestablish the connection?

I check the DP83826AI registers and found these bits, but not sure which to use and whether it will negatively affect the ECAT network and other connected slave(s)
1. BMCR[9] to restart Auto-negotiation
2. BMCR[15] to SW reset the PHY
3. PHYRCR[14] to digital reset the PHY
4. PHYRCR[15] to Hard reset the PHY

 

  • Hi,

    Is the DP83826A indicating that the Ethernet link is up? What is the MSE (Mean square error) value indicated by register 0x218 of the PHY? 

    If the link is up and the signal has minimal error, this points to the PHY functioning correctly and the root of the issue being elsewhere.

    Best regards,

    Greg

  • Hi Gregory,

    after connecting the upstream cable (Cable1), the link status (PHYSTS[0] =0) and MSE_Val keep changing within 100.
    In this case, what is the best way to recover/reestablish the connection?

    with best regards,

    Taji

  • Additionally, when cable1 is reconnected, initially Link ACT LED blink for a brief time then it remains off.

  • Hi Taji,

    Can you please send a register dump of registers 0x0 - 0x10 of the PHY when it is in this state? Is there any change in the state of the connection when you disconnect and the reconnect the upstream cable if you write register 0x1f = 0x4000 to soft reset the PHY? 

    Best regards,

    Greg

  • Hello Greg,

    Here is the register dump in normal operation, during fault state and after SW reset

      Normal Operation During fault after SW reset
    PHY Reg 00 0x3100 0x3100 0x3100
    PHY Reg 01 0x7869 0x7849 0x7849
    PHY Reg 02 0x2000 0x2000 0x2000
    PHY Reg 03 0xA134 0xA134 0xA134
    PHY Reg 04 0X01E1 0x01E1 0x01E1
    PHY Reg 05 0xC1E1 0xC1E1 0xC1E1
    PHY Reg 06 0x000F 0x000F 0x000F
    PHY Reg 07 0x2001 0x2001 0x2001
    PHY Reg 08 0x0000 0x0000 0x0000
    PHY Reg 09 0x0020 0x0020 0x0020
    PHY Reg 0A 0x0002 0x0002 0x0002
    PHY Reg 0B 0x0001 0x0001 0x0001
    PHY Reg 0C 0x0000 0x0000 0x0000
    PHY Reg 0D 0x401F 0x401F 0x401F
    PHY Reg 0E 0x0051 0x0051 0x0051
    PHY Reg 0F 0x0010 0x0010 0x0010
    PHY Reg 10 0x0815 0x0814 0x0814

    the SW reset does not change anything; it is stuck in no-link established state.

    with best regards,

    Taji

  • Hello,

    I am stepping in for Greg while he is traveling. 

    During normal operation, I see that Reg 0x1 value is not expected. This should be reading 0x786D. Can you please re-read to confirm? This register is known to latch low at times. Alternatively, you may instead use Reg 0x10 which I also see.

    How fast are you reading register after reset? The PHY is working initially, so I would expect a reset to also re-establish link. Can you also cross corroborate against the link pin LED1?

    Sincerely,

    Gerome