[En-Nut-Discussion] NutUdpSendTo problem

Harald Kipp harald.kipp at egnite.de
Mon Feb 9 20:40:20 CET 2004


Hi Francois,

At 18:42 07.02.2004 -0600, you wrote:
>I wonder if you guys can spot me doing something obviously wrong here.  I call
>NutUdpSendTo and always get a -1 return.  I see from the mail list archives
>that there was a buffer handling problem in NutUdpSendTo in the past, but I've
>checked my source and not only does this problem seem unrelated, but I have
>the patch for the buffer handling issue.  If I change the dest ip to
>207.252.251.233 and run ethereal on the dest node then I get 0 returns from
>NutUdpSendTo and the activity light on the ethernut lights up, but the packet
>is never seen at the destination.

Indeed. If 216.127.80.16 produces errors and 207.252.251.233 doesn't,
then this is obviously no buffer problem.

Frankly, I do not have the slightest idea, why Ethereal
doesn't show the UDP packet on 207.252.251.233 after you
set the destination to this IP.

I have to admit too, that I never tried routing with
with Ethernut's UDP, but, as routing is implemented
in the IP layer and used by TCP too, I'm quite sure
that this should work.

I checked your network/netmask setup twice, but it
looks OK to me.

In your output
EEPROM/DHCP/ARP config failed
never appears, so you are using DHCP. May be there's the
problem. Can you please try to use

NutNetIfConfig("eth0", mac, ip_addr, ip_mask);
NutIpRouteAdd(0, 0, inet_addr("207.252.251.233"), &devEth0);

instead of NutDhcpIfConfig()?

Still, Ethereal _must_ show something...at least the
ARP request from Ethernut.

Harald





More information about the En-Nut-Discussion mailing list