AnsweredAssumed Answered

MDIO issue of ADuCM322

Question asked by Kevintsai on Jan 3, 2018
Latest reply on Jan 16, 2018 by Kevintsai

Hi,

I'm using the ADuCM322's MDIO interface (Clause 45) and the SUB-20 development tool recommended on the ADI web page. When I send an address frame (address 0x8000) from SUB-20, if MDC speed set to 4MHz, the ADuCM322 will get 0x4000 value; if I do not specify the MDC speed (the actual measurement of about 800K ~ 1.4MHz) ADuCM322 will be 0x6000 value. Why??

 

MDIO Initial:

pADI_GP3->GPCON = 0x0555; //Put MDIO on P3.
pADI_MDIO->MDCON = 0x0006; //MDIO drive Push-pull ; MDIO PHY used 3 bits
pADI_MDIO->MDPHY = 0x0700; //DEVADD = 00001 ; PHYSEL = 11000 (PRTADD0 ~ PRTADD2)
MDIO_STA = pADI_MDIO->MDSTA; //Read the MDSTA register to clear any interrupt
pADI_MDIO->MDIEN = 0x000F;

NVIC_ClearPendingIRQ(MDIO_IRQn); //Clear any pending interrupt in the Cortex
NVIC_SetPriority(MDIO_IRQn, 3);
NVIC_EnableIRQ(MDIO_IRQn); //Enable MDIO interrupt source in NVIC.

Outcomes