Fiddling around with ethernet

Technical questions regarding the xTIMEcomposer, xSOFTip Explorer and Programming with XMOS.
DaveBest
Member++
Posts: 25
Joined: Mon Jan 18, 2010 3:36 pm

Fiddling around with ethernet

Postby DaveBest » Mon Mar 22, 2010 3:05 pm

Greetings,

we used for our application the ethernetstack 1V0 which seems to be quite optimistic with the mess that ethernet traffic can be. The mac parts expect a maximum packet size of 1500 Bytes which is the regular MTU. The uip stack is more generous and allocates 400 words = 1600 Bytes.

When using the xmos board as a webserver it advertises its windowsize etc. so nothing could go wrong. We now try to parse ethernet traffic / sniff the network traffic.
Using wireshark we see that sometimes tcp-traffic exceeds 1500 Byte and sends 1514 Bytes for example while serving a http-request.
So we try to "sniff" that and crash because the mac stack can't handle anything over 1500 Bytes.

The latest version of the ethernet stack 1V2 acknowledges this problem and reserves 1518 Bytes for packet size.
We fiddled about with the uipserver of 1V0 and adapted it for our use, so it works and don't want to mess with it as long as it is working.

Is it now possible to just use the mac part of the latest stack while still using the 1V0 uip parts for our application?
I already tried to exchange the mac files and directories and it seems to work, at the moment. I don't want to run into further problems later on.
DaveBest
Member++
Posts: 25
Joined: Mon Jan 18, 2010 3:36 pm

Postby DaveBest » Tue Mar 23, 2010 10:38 am

Okay, no negative responses or opinions yet, so i guess i'll go ahead.
User avatar
davelacey
Experienced Member
Posts: 104
Joined: Fri Dec 11, 2009 8:29 pm

Postby davelacey » Tue Mar 23, 2010 12:45 pm

Hi,
Looking back over the change logs it looks like this should be OK (though we only test with the versions aligned as in the tcp package). There are a few bugfixes in the latest tcp stack though so if you can manage to merge those in to your local changes that would have benefits.

Regards,
Dave
User avatar
shawn
XCore Addict
Posts: 238
Joined: Thu Dec 17, 2009 5:15 am

Postby shawn » Tue Mar 23, 2010 9:15 pm

Hey Dave Best,
The XC3 serves UDP from what I can tell and seems more robust than other kits.
You might what to check XC3 PDF, might help. I still have yet to get a kit so what
I am saying is just food for thought. ;)
DaveBest
Member++
Posts: 25
Joined: Mon Jan 18, 2010 3:36 pm

Postby DaveBest » Thu Mar 25, 2010 2:22 pm

XC2 is handling UDP just fine, its just other non-conform ethernet thats giving a hassle.

The XC3 hasn't got a lot of free pins, what with handling leds and 2 ethernet connections.

Right now trying to adjust our setup. Something bugs our input pins and seems to cause some crashes. All the while xgdb.exe crashes too.

Who is online

Users browsing this forum: No registered users and 1 guest