UPGRADE YOUR BROWSER

We have detected your current browser version is not the latest one. Xilinx.com uses the latest web technologies to bring you the best online experience possible. Please upgrade to a Xilinx.com supported browser:Chrome, Firefox, Internet Explorer 11, Safari. Thank you!

cancel
Showing results for 
Search instead for 
Did you mean: 
Participant heiyux
Participant
3,524 Views
Registered: ‎02-19-2009

Ethernet Cable plug in after ZYNQ bootup with TCP sever

Jump to solution

Hi there,

 

 I'm working around with Lwip in ZYNQ. And so far I get the data transfered between PC & ZYNQ board. And get a speed approximately about 700Mb/s.

 But now I have a question about the power up.

 In the design, I have the Ethernet Cable pluged, and then power up the board and load the program, everything works

fine. BUT in the real use, I may power up and get the zynq boot first, then plug in the ethernet cable. I found in this case, the zynq TCP sever will not init successfully.

 How can I do the cable plug after the boot, what should I do in my code ?

 

Thank you very much!

 

Day

0 Kudos
1 Solution

Accepted Solutions
Voyager
Voyager
6,534 Views
Registered: ‎04-13-2015

Re: Ethernet Cable plug in after ZYNQ bootup with TCP sever

Jump to solution

When the IP stack is started, the first thing done is to get the Ethernet PHY going up, establishing communication with the other end to select the speed & full/half duplex.

As your cable is not plugged-in, the PHY start-up fails.

You need to manually start the PHY handshake when the cable is plugged.

From what I remember, there is a bit indicating the link change (cable plug/unplugged) in the interrupt status register of the EMAC.

It can be use to trigger an interrupt and in the ISR to check if the cable just got plugged-in or unplugged.

 

 

 

0 Kudos
3 Replies
Voyager
Voyager
6,535 Views
Registered: ‎04-13-2015

Re: Ethernet Cable plug in after ZYNQ bootup with TCP sever

Jump to solution

When the IP stack is started, the first thing done is to get the Ethernet PHY going up, establishing communication with the other end to select the speed & full/half duplex.

As your cable is not plugged-in, the PHY start-up fails.

You need to manually start the PHY handshake when the cable is plugged.

From what I remember, there is a bit indicating the link change (cable plug/unplugged) in the interrupt status register of the EMAC.

It can be use to trigger an interrupt and in the ISR to check if the cable just got plugged-in or unplugged.

 

 

 

0 Kudos
Highlighted
Participant heiyux
Participant
3,355 Views
Registered: ‎02-19-2009

Re: Ethernet Cable plug in after ZYNQ bootup with TCP sever

Jump to solution

Hi,ericv

 

  thanks very much.

 

I read the link status from the phy chip, and initialize the

 

LwIP after cable is pluged in. It works fine.

 

  Now I'm working with cable plug/unplug during usage. I don't

 

now what to do to reinitialize after unplug/plug cable.

 

  I'll keep trying for that.

 

Thanks.

 

Day

0 Kudos
Voyager
Voyager
3,317 Views
Registered: ‎04-13-2015

Re: Ethernet Cable plug in after ZYNQ bootup with TCP sever

Jump to solution

Unless you have the IP address hard coded in your application, the IP address for your board is dynamic and assigned through DHCP.

If that's the case, when lwIP is started, lwIP's DCHP client is also started to obtain the IP address for your board..

You'll need to re-start the DHCP client after the PHY is up and running.

0 Kudos