Forum Discussion

Altera_Forum's avatar
Altera_Forum
Icon for Honored Contributor rankHonored Contributor
14 years ago

Does Ethernet need delay time when sending a packet?

Hi,when i try to send out a packet with a for loop.It can't be send.(i inspect through the wireshark).However, when i add the while loop like this:

while(1)

{

For(i=0;i<20;i++)

{

SEND PACKET;

}

}

It can send.I wonder is it there has a delay time that i need to include if i don't wan use the while loop.how long should i delay?Can anyone help me?Thank you.

1 Reply

  • Altera_Forum's avatar
    Altera_Forum
    Icon for Honored Contributor rankHonored Contributor

    Presumably the modified code sends lots of packets.

    If you are trying to send a single packet only (from a test program) you'll need to ensure the program doesn't exit/return immediately and that is likely to reset everything.

    I'm not sure what your 'SEND PACKET' does, but clearly it can also fail due to lack of buffers of fifo space (etc) in the MAC engine (unless your code runs slower than ethernet line rate).