Forum Discussion
Altera_Forum
Honored Contributor
17 years agoDE2_UDP example for download here free (feedbacks are wellcomed)
Hi all.
My goal is to get about 3Mbytes/sec data transfer rate from my DE2 board to PC. Here in this example I get about 1.2 Mbytes/sec. I'll accept comments about, how to speed up this, as well as suggests to improve the code, and some feedback from people that have interest in this theme. Could be in this thread or private. You can download the full project from: http://www.btxsistemas.com.ar/net2.zip I've used Quartus II 7.2 full suite. And the Wireshark software (http://www.wireshark.org/) like a net sniffer, but also, I've included in the main project folder, a UDP reciever to test the comunication between the DE2 board and the PC, if you wont to download the wireshark. Don't forget to specify your IP address and your MAC address in the NIOS hello_word "C" code to get it work properly. The main project is a modification of the DE2_NET demostration code that comes with the DE2 board. Have fun, and I'll be waiting for some comments.94 Replies
- Altera_Forum
Honored Contributor
Hi Dison, sorry for the delay to answer.
Yes, yingfang18 is right. Do you mean, where is the payload data in my code ?? Cheers. Alberto. - Altera_Forum
Honored Contributor
--- Quote Start --- Hi Dison, sorry for the delay to answer. Yes, yingfang18 is right. Do you mean, where is the payload data in my code ?? Cheers. Alberto. --- Quote End --- hey,BTXSistemas! thanks for your replay firstly! but sorry that i do not mean that ,it's my faults i should refer to some books about it like yingfang18 said ,at the beginning,i dont know the TXT[42] very well,just the headers,but i do now ! it's {mac header,ip header,UDP header}. do u have an the example with lwip,i'v get stuck with it for long ,can u help me ?i 'll be appreciated - Altera_Forum
Honored Contributor
So sorry Dison, I've not any about lwip.
Cheers. Alberto. - Altera_Forum
Honored Contributor
Hello Alberto.
When I was first working on ethernet comms on the DE2, found your posts very helpful. You may be interested to know I have been able to get TCP/IP communications working on the DE2 using the latest Nichestack and Simple Socket Server reference design provided by Altera. See my post here: http://www.alteraforum.com/forum/showthread.php?p=95360 Feedback is very much welcomed! Source code/project directory is provided as a starting point for the forum community. I will post updates/future revisions as they become available! - Altera_Forum
Honored Contributor
Hello,
I will try to get into it, but it looks like too big of a mountain to climb at this point. It seems like a lot of trouble for just simple sending of few bytes of data there and back. I wish there were some examples of a similar system... Thanks picture recovery (http://www.datadoctor.biz) - Altera_Forum
Honored Contributor
--- Quote Start --- Hello, I will try to get into it, but it looks like too big of a mountain to climb at this point. It seems like a lot of trouble for just simple sending of few bytes of data there and back. I wish there were some examples of a similar system... Thanks picture recovery (http://www.datadoctor.biz) --- Quote End --- The UDP example provided by BTXSistemas is a brilliant starting point. However, it's true the socket server/TCP-IP way is indeed more tricky, but is very robust and gives you guaranteed/reliable delivery of complex data structures and two-way communication. In addition, I have developed a custom hand-shaking protocol which can be used to synchronise data transmission/reception between two devices - allows for transmission of complex data including multidimensional pointer arrays! - Altera_Forum
Honored Contributor
--- Quote Start --- I have resolve the problem,and I found the bps is 5.9M/s,sound very good,thank you all the same for offer your code for us,you are so good. Next,I will read your code ,if I improve the bps when I modify the code,I will tell you,thanks! --- Quote End --- Hi. Could you tell me how you resolved that problem?? I'm in the same situation at this moment. Thanks a lot!!! - Altera_Forum
Honored Contributor
Thanks! Will certainly give this a look soon!
- Altera_Forum
Honored Contributor
HI.
I modified your project to make my board sends ping messages to my PC. I can see, via wireshark, those messages. But it's so strange that my PC doesn't send any echo reply. Wireshark shows incoming ping messages (from the board) but doesn't show any echo reply from the PC. I tried to send a ping from another PC to mine, and it was successful. I mean, wireshark shows me both, echo requests (from the other PC) and echo replies (from my PC). What could be the problem? Can anybody help me? Thanks a LOT. - Altera_Forum
Honored Contributor
Hi,
Using your code I can send upd to PC correctly, but the received udp always 64 bytes long in which only the ip addresses were correct.Can you give me some ideal for this issue? Thank you in advance.