W5100E01-AVR WIZnet, W5100E01-AVR Datasheet - Page 81

no-image

W5100E01-AVR

Manufacturer Part Number
W5100E01-AVR
Description
Development Boards & Kits - AVR W5100 EVAL BOARD BASED ON AVR
Manufacturer
WIZnet
Datasheet

Specifications of W5100E01-AVR

Rohs
yes
Product
Development Boards
Tool Is For Evaluation Of
ATMEGA128
Core
AVR8
Interface Type
LAN, RS-232
Operating Supply Voltage
5 V
Data Bus Width
8 bit
DHCP_Timeout is 1, getIP_DHCPS() returns failure after releasing the DHCP Timer.
When it failed to obtain network information from DHCP server, EVB B/D sets network configuration using
default network information or previously obtained network information.
<Table 3-35> is a definition of State, Timeout , and Retry Count of DHCP Client.
At getIP_DHCP(),‘DHCP_XID’ is variable to set up xid Field of DHCP message in <Fig 3.26: DHCP Message
Format>, it must be unique and maintain the same value until Lease Time of network information is expired.
DHCP_XID is fixed with ‘0x12345678’ on here, but it’s recommended to use the random value.
Be advised to set source IP address as ‘0.0.0.0.’ when initializing W5100 for communication with DHCP
server. You can use any IP address to set Source IP address of W5100, but using ‘0.0.0.0’ is better because
‘0.0.0.0’ corresponds to Class A in IPv4 addressing and it’s a Null IP address that is not actually used. For
this reason, there is no chance for collision with other network.
For DHCP server to transmit UDP broadcast packet, note that Flag field MSB of DHCP message must be set
1. Refer to <Fig 3.26: DHCP Message Format>.
<Table 3-36> is a part of code that sets up Flag field
Third, management of network information obtained from DHCP server can be performed by
check_DHCP_state(). <Fig 3.30> shows DHCP message flow due to DHCP client state change in the
check_DHCP_state() process.
#define STATE_DHCP_DISCOVER 1
#define STATE_DHCP_REQUEST 2
#define STATE_DHCP_LEASED
#define STATE_DHCP_REREQUEST 4
#define STATE_DHCP_RELEASE 5
#define MAX_DHCP_RETRY
#define DHCP_WAIT_TIME
#define DHCP_FLAGSBROADCAST
pRIPMSG->flags = htons(DHCP_FLAGSBROADCAST);
Define
© Copyright 2007 WIZnet Co., Inc. All rights reserved.
<Table 3-34: DHCP Client State & Timeout Definition>
<Table 3-35: DHCP Message Flag Field Setup>
3
3
5
RELEASE Transmission
DISCOVERY Transmission
OFFER Receiving & REQUEST Transmission
ACK Receiving, Acquiring Network Information
After obtaining Network Information, REQUEST
Retransmission
Number of Same DHCP Message Transmission, 3
times
Waiting time for receiving DHCP Message, 5 sec.
0x8000
Description
71

Related parts for W5100E01-AVR