BusWorks® Model 989EN U
ser’s Manual Modbus TCP/IP Digital I/O & Counters
_________________________________________________________________________________
_______________________________________________________________________________________
Acromag, Inc. Tel:248-295-0880 Fax:248-624-9234 Email:
39
Subnets are further broken down into three size classes based on the 4
octets that make up the IP address. A Class A subnet is any subnet that
shares the first octet of the IP address. The remaining 3 octets of a Class A
subnet will define up to 16,777,214 possible IP addresses (2
24
– 2). A Class
B subnet shares the first two octets of an IP address (providing 2
16
– 2, or
65534 possible IP addresses). Class C subnets share the first 3 octets of an
IP address, giving 254 possible IP addresses. Recall that the first and last
IP addresses are generally used as a network number and broadcast
address respectively, and this is why we subtract 2 from the total possible
unique addresses that are defined via the remaining octet(s).
For our example, the default IP address of this unit is 128.1.1.100. If we
assume that this is a Class C network address (based on the default Class
C subnet mask of 255.255.255.0), then the first three numbers represent this
Class C network at address 128.1.1.0, the last number identifies a unique
host/node on this network (node 100) at address 128.1.1.100.
A
Subnet Mask
is used to determine which subnet an IP address belongs to.
The use of a subnet mask allows the network administrator to further divide
the host part of this address into two or more subnets. The subnet mask
flags the network address portion of the IP address, plus the bits of the host
part that are used for identifying the sub-network. By convention, the bits of
the mask that correspond to the sub-
network address are all set to 1’s (it
would also work if the bits were set ex
actly as in the network address). It’s
called a mask because it can be used to identify the unique subnet to which
an IP address belongs to by performing a bitwise AND operation between
the mask itself, and the IP address, with the result being the subnetwork
address, and the remaining bits the host or node address.
For our example, if we wish to further divide this network into 14 subnets,
then the first 4 bits of the host address will be required to identify the sub-
network (0110), then we would use “11111111.11111111.11111111.
11110000” as our subnet mask. This would effectively subdivide our Class
C network into 14 sub-networks of up to 14 possible nodes each.
With respect to the default settings of this device:
Subnet Mask 255.255.255.0 (11111111.11111111.11111111.00000000)
IP Address: 128.1.1.100 (10000000.00000001.00000001.01100100)
Subnet Address: 128.1.1.0 (1000000.00000001.00000001.00000000)
The subnetwork address of 128.1.1.0 has 254 possible unique node
addresses (we are using node 100 of 254 possible). Nodes 0, 10, and 255
are typically reserved for servers and may yield poor results if used.
DHCP refers to Dynamic Host Configuration Protocol and is a method used
to assign temporary numeric IP addresses as required. A DHCP server
maintains a pool of shared IP addresses which are dynamically assigned
and recycled. When a DHCP device wants to use a TCP/IP application, it
must request an IP address from the DHCP server.
The DHCP server will check the shared supply, and if all addresses are in
use, the server will send a busy signal to the client which tells it to try again
later. Static IP addresses will ensure a connection every time, but dynamic
addresses do not.
ABOUT MODBUS
TCP/IP
IP Addressing
TIP: The first node (0), node
10, and the last node (255 for
our example) are typically
reserved for servers and may
yield poor results if used.
Dynamic Host
Configuration Protocol
(DHCP)