Home

Profibus

Net Theory

Service

Products

Download Docu

EC32

RTC-32

New: Preventive Maintenance Issues

Disclaimer


RTOS-32


Statistic

Private

Translate

 


ICS

Industrielle Automatisierungssysteme GmbH

 
           
Home News Products Company Profile EC32-Info Download Contact
 

Network Theory Part II

ARP
E
ach network interface card manufactured has a worldwide unique hardware address. The ARP (address resolution protocol) provides a mechanism for retrieving the hardware address from an unknown host based upon the IP address. If the target host is not in the local network a router is used for the transport of the request.
ARP Request: To whom belongs the address 172.16.231.64 ?

Example:
Request to ALL:

Transmitter hardware address 0x00C03D002AD9
Transmitter IP address 172.16.231.12
Target hardware address 0xFFFFFFFF
Target IP address 172.16.231.64

Response to Transmitter

Transmitter hardware address 0x00C03D004A05
Transmitter IP address 172.16.231.64
Target hardware address 0x00C03D002AD9
Target IP address 172.16.231.12


The relation between IP address and physical address is stored in a table in the NIC and will be deleted after a timeout.

Transport Layer
The IP address has the only purpose to address a host system. Each host in turn could run multiple applications, e.g. a web browser, TELNET or FTP. In order to address a certain application, TCP and UDP provide mechanisms to do so.
For known applications so called well known ports are used. A complete list of those service could be obtained from:
ftp://ftp.isi.edu/in-notes/iana/assignments/port-numbers or
http://sunsite.auc.dk/RFC

The following is just a short example:

Application

Port

Protocol Description
ftp 21 UDP/TCP File-Transfer
telnet 23 UDP/TCP Telnet
smtp 25 UDP/TCP Simple Mail Transfer
domain 53 UDP/TCP Domain Name Server
tftp 69 UDP/TCP Trivial File Transfer
www-http 80 UDP/TCP Worl Wide Web HTTP
sftp 115 UDP/TCP Simple File Transfer Protocol
snmp 161 UDP/TCP SNMP


Format of UDP
The features of UDP are limited to the recognition of the port number. The delivery of a datagram via the network is not guaranteed. The protocol does not guarantee the correct sequence of fragments via the network. All this has to be done by a higher level layer.
Remark of the author: This is not true with UDP driver implemented in EC32. This driver has a feature which guarantees a secure delivery via the network!
On the other hand, UDP has a much lower overhead than TCP and provides a higher throughput. In addition all mechanisms for establishing and terminating a connection as they are used with TCP have not to be used.

0 16 31
UDP Source port UDP destination port
UDP message length UDP checksum
Data

TCP Transport control protocol
TCP removes the burden of security measures from the higher level application layers.
TCP is connection oriented, which means that prior to sending any data a virtual connection between the two end-points has be established. An end-point is made up by an IP address and a port-number.
The communication is full-duplex, e.g. both partners are allowed to send at the same time. The protocol is transparent, data delivered in a certain form to the TCP interface are presented in the same way at the adjacent side. The packet size is adjustable in wide ranges of 1 byte to a couple of megabytes as long as the hardware being used allows this.

Format of a TCP packet

0 4 10 16 24

31

Source Port

Destinationport

Sequence number
ACKNOWLEDGMENT NUMBER
HLEN RESERVED CODE BITS WINDOW
CHECKSUM URGENT POINTER

OPTIONS

Padding
Data

Source port port number of the application of the transmitter
destination port port number of the application of the receiver
Sequence No. Offset of the first data bytes relative to the beginning of the data
Acknow. No. sequence number to be expected in the next packet
HLEN length of the TCP header in DWORDS (32 bit)
Code Bits
1 URG urgent data, see urgent pointer
2 ACK segment contains ackn.
3 PSH deliver received data immediately
4 RST reset connection
5 SYN establish connection and sync the sequence numbers
6 FIN no more data, close connection
Window Number of bytes the receiver is able to handle.
Checksum Checksum over the TCP datagram
Urgent pointer if the flag URG is set, this value specifies the offset of the first byte after the urgent data
Options if necessary: most important: maximum segment size

  Next page: Socket Interface 1


back to previous page
 

 

         
Home Search Sitemap Our friends Security FAQ Contact

 

© 2004 ICS GmbH. All rights reserved. - Last update: December 12, 2004 - Webadmin: service@ics-control.com