FreeRTOS + TCP and ARP info

dsherman26 wrote on Friday, September 08, 2017:

I’ve been working on getting FreeRTOS + TCP working on a Freescale Kinetis K60 tower board. I have DHCP working and I can get an IP address from a DSL modem I’m using as the DHCP host (COMTREND CT-5374). I can see the tower boards DHCP address in the router’s DHCP table, but the ARP table does not show the tower board. Is there some step I need to do to make the router aware of it? I can’t ping it because the router reports that it is unaware of the IP address.

heinbali01 wrote on Sunday, September 10, 2017:

Hi Dave, it is difficult to see from a distance why you can not ping your device.

In my own testing environment, I have devices behind a router with WAN/LAN, as well as behind a LAN switch.

If you have a switch, I would try that first: either with a fixed IP-address, or by running a DHCP server on your laptop.

Have you also tried without DHCP?

#define ipconfigUSE_DHCP	0

Can you confirm that your laptop and your “tower board” have the same network address? For instance 192.168.1.10 and 192.168.1.11 ?

It would be very strange if a router does not pass ARP messages between the LAN ports ( “ETH1” to “ETH4” ). Also the device will send-out so-called gratuitous ARP messages every 20 seconds:

#define arpGRATUITOUS_ARP_PERIOD       ( pdMS_TO_TICKS( 20000 ) )

These packet help detecting IP-address conflicts. A switch or a LAN router must forward these packets as well and you should see them when running WireShark.

I would also check the properties of “ETH1” to “ETH4” in the router’s setup-page. Does the router allow communication between those ports?

dsherman26 wrote on Thursday, November 02, 2017:

Thank you, sorry for the delay getting back. I figured out it was because the stack was replying to the arp request at the beginning of the ping, and sending the arp information back. The hardware was configured to add the checksum, but I had to make sure the checksum was zeroed before replying, otherwise the hardware would get the checksum wrong. The arp table I’m not sure of, the router still does not show it, although I can ping it now.