K64F512x Ethernet issue

cancel
Showing results for 
Search instead for 
Did you mean: 

K64F512x Ethernet issue

117 Views
Contributor II

I am coding the lwip FW on MK64F512x board.

The waveform of the TXD0/TXD1 on ping 46, 47 are without any signal and always keep on the low level.

It is seem that lwip does not act.

The SDK used is version 2.8.0.

I can read the phy information via MDC&MDIO.

The Link status is down, therefore the code is stuck on the "BOARD_PHY_NETIF_INIT_FN" function

The code is as below, 

int main(void)

{

struct netif netif;

ip4_addr_t netif_ipaddr, netif_netmask, netif_gw;

ethernetif_config_t enet_config = {
.phyAddress = BOARD_PHY_ADDRESS,
.clockName = BOARD_PHY_CLOCK_NAME,
.macAddress = configMAC_ADDR,
};

SYSMPU_Type *base = SYSMPU;

/* Init board hardware. */
BOARD_InitBootPins();
BOARD_InitBootClocks();
BOARD_InitBootPeripherals();

base->CESR &= ~SYSMPU_CESR_VLD_MASK;

time_init();

IP4_ADDR(&netif_ipaddr, configIP_ADDR0, configIP_ADDR1, configIP_ADDR2, configIP_ADDR3);
IP4_ADDR(&netif_netmask, configNET_MASK0, configNET_MASK1, configNET_MASK2, configNET_MASK3);
IP4_ADDR(&netif_gw, configGW_ADDR0, configGW_ADDR1, configGW_ADDR2, configGW_ADDR3);

lwip_init();

netif_add(&netif, &netif_ipaddr, &netif_netmask, &netif_gw, &enet_config, BOARD_PHY_NETIF_INIT_FN, ethernet_input);

netif_set_default(&netif);


PRINTF("netif_set_up ....\r\n");
netif_set_up(&netif);

while(1)

{

/* Poll the driver, get any outstanding frames */
ethernetif_input(&netif);

/* Handle all system timeouts for all core protocols */
sys_check_timeouts();

}

}

How can I figout out this issue ?

Thanks

0 Kudos
3 Replies

21 Views
Contributor II

Hi Alexis,

This is the custom board using K64F512x with IC+175D instead of the KSZ8081RNACA chip set and works on RMII mode.

Yes, we already set the configuration in the Init Pins and set up the chip.

0 Kudos

21 Views
NXP TechSupport
NXP TechSupport

Hello Andy,

The Init function prefined in the SDK is set to work with the KSZ8081RNACA, in this case, you should do the appropriate changes to work with your PHY.

Also, I will suggest checking the welding points and if there is no noise in the signal that could interfere with the communication.

Best Regards,

Alexis Andalon

0 Kudos

21 Views
NXP TechSupport
NXP TechSupport

Hello Andy Hsu,

Are you using one of our development boards or is this a custom board?

Did you already set the configuration in the Init Pins to match the ones of your PHY?

Best Regards,

Alexis Andalon

0 Kudos