Global Sources
EE Times-India
Stay in touch with EE Times India
EE Times-India > Embedded

Address issues in embedding TCP/IP (Part 4)

Posted: 30 Apr 2013     Print Version  Bookmark and Share

Keywords:TCP-IP  network controllers  RAM 

In Part 4, we look into the different requirements in relation to networks. Here are the links to the previous instalments: Part 1, Part 2 and Part 3.

µC/TCP-IP supports multiple network interfaces if the hardware has multiple network controllers. Network Interfaces are used to represent an abstract view of the device hardware and data path that connects the hardware to the higher layers of the network protocol stack. In order to communicate with hosts outside the local host, the application developer must add at least one network interface to the system. The data size for network interfaces is calculated as:

Timer requirements
µC/TCP-IP manages software timers used to keep track of various network-related timeouts. Each timer requires RAM. The data size for timers is calculated as:

ARP cache requirements
Address resolution protocol (ARP) is a protocol used to cross-reference an Ethernet MAC address and an IP address. These cross-references are stored in a table called the ARP cache. The number of entries in this table is configurable. The data size for the ARP cache is calculated as:

IP requirements
A network interface can have more than one IP address. The data size for IP address configuration is calculated as:

ICMP requirements
Internet Control Message Protocol (ICMP) transmits ICMP source quench messages to other hosts when network resources are low. The number of entries depends on the number of different hosts. It is recommended to start with a value of 5. The data size for ICMP source quench is calculated as:

IGMP requirements
The Internet Group Management Protocol (IGMP) adds multi-casting capability to the IP protocol stack. The data size for IGMP host groups is calculated as:

Connection requirements
A connection is aµC/TCP-IP structure containing information regarding the IP protocol parameters required to identify two hosts communicating with each other. A connection is a structure that is used for all Layer 4 protocols (UDP and TCP). The data size for connections is calculated as:

TCP requirements
In addition to the connection data structure defined previously, a TCP connection requires additional state information, transmit and receive queue information as well as time-out information to be stored in a specific TCP connection data structure. The data size for the TCP connections is calculated as:

Sockets requirements
As seen in section Layers 5-6-7 – The Application, the interface between the application and the TCP/IP stack is defined as a socket interface. For each socket that the application wants to open and use, a socket structure exits that contains the information about that specific socket.

The data size for sockets is calculated as:

TCP-IP internal data usage
This represents the amount of data space needed forµC/TCP-IP's internal data structures and variables, and varies from about 300 to 1900B depending on the options configured.

Lines 1 to 8 in the table provide data sizes that may vary as the number of each element is determined at configuration time. You could build a spreadsheet to reproduce the table above using the equations described above. Line 9 is the fixed internal data usage forµC/TCP-IP. With such a configuration, we see that the system total RAM usage exceeds 40 K.

About the author
Christian Legare is from Micrium.

To download the PDF version of this article, click here.

Comment on "Address issues in embedding TCP/IP (..."
*  You can enter [0] more charecters.
*Verify code:


Visit Asia Webinars to learn about the latest in technology and get practical design tips.


Go to top             Connect on Facebook      Follow us on Twitter      Follow us on Orkut

Back to Top