Choco OS  V.0.16.9.0
Join to the chocolate world
oc_dhcp.h File Reference

Contains definitions of DHCP. More...

#include <oc_stdtypes.h>
#include <oc_compiler.h>
#include <oc_net.h>
#include <oc_netif.h>

Go to the source code of this file.

Data Structures

struct  PACKED
 stores IPv6 address More...
 

Macros

#define oC_DHCP_MAGIC_COOKIE   0x63825363
 Magic cookie for the DHCP message.
 
#define oC_DHCP_END_OPTION   0xFF
 Value for marking last entry in the options array.
 
#define oC_DHCP_OPTIONS_BUFFER_SIZE   600
 stores maximum number of bytes reserved for options in DHCP message
 

Typedefs

typedef struct PACKED oC_Dhcp_Message_t
 stores DHCP message More...
 

Enumerations

Functions

oC_ErrorCode_t oC_Dhcp_SendMessage (oC_Netif_t Netif, oC_Dhcp_Message_t *Message, uint16_t Size, oC_Time_t Timeout)
 sends DHCP message to DHCP server More...
 
oC_ErrorCode_t oC_Dhcp_ReceiveMessage (oC_Netif_t Netif, oC_Dhcp_Message_t *outMessage, oC_Time_t Timeout)
 receives DHCP message from DHCP server More...
 
oC_ErrorCode_t oC_Dhcp_RequestIp (oC_Netif_t Netif, oC_Time_t Timeout)
 performs DHCP IP request procedure More...
 
oC_ErrorCode_t oC_Dhcp_SendDiscovery (oC_Netif_t Netif, oC_Time_t Timeout)
 sends DHCP discovery message to DHCP server More...
 
oC_ErrorCode_t oC_Dhcp_ReceiveOffer (oC_Netif_t Netif, oC_Time_t Timeout)
 receives offer from the DHCP server More...
 
oC_ErrorCode_t oC_Dhcp_SendRequest (oC_Netif_t Netif, oC_Time_t Timeout)
 sends request message to the DHCP server More...
 
oC_ErrorCode_t oC_Dhcp_ReceiveAcknowledge (oC_Netif_t Netif, oC_Time_t Timeout)
 receives ACK message from DHCP server More...
 

Detailed Description


Author
Patryk Kubiak
Note
Copyright (C) 2016 Patryk Kubiak patry.nosp@m.k.ku.nosp@m.biak9.nosp@m.0@gm.nosp@m.ail.c.nosp@m.om

This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.

You should have received a copy of the GNU General Public License along with this program; if not, write to the Free Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA

Definition in file oc_dhcp.h.

Enumeration Type Documentation

Enumerator
oC_Dhcp_OptionLength_SubnetMask 

Length in bytes for option oC_Dhcp_Option_SubnetMask.

oC_Dhcp_OptionLength_TimeOffset 

Length in bytes for option oC_Dhcp_Option_TimeOffset.

oC_Dhcp_OptionLength_RouterMin 

Minimum length in bytes for option #oC_Dhcp_Option_RouterMin.

oC_Dhcp_OptionLength_DnsServerMin 

Minimum length in bytes for option #oC_Dhcp_Option_DnsServerMin.

oC_Dhcp_OptionLength_HostnameMin 

Minimum length in bytes for option #oC_Dhcp_Option_HostnameMin.

oC_Dhcp_OptionLength_DefaultTTL 

Length in bytes for option oC_Dhcp_Option_DefaultTTL.

oC_Dhcp_OptionLength_MTU 

Length in bytes for option oC_Dhcp_Option_MTU.

oC_Dhcp_OptionLength_Broadcast 

Length in bytes for option oC_Dhcp_Option_Broadcast.

oC_Dhcp_OptionLength_TcpTTL 

Length in bytes for option oC_Dhcp_Option_TcpTTL.

oC_Dhcp_OptionLength_NtpMin 

Minimum length in bytes for option #oC_Dhcp_Option_NtpMin.

oC_Dhcp_OptionLength_RequestedIp 

Length in bytes for option oC_Dhcp_Option_RequestedIp.

oC_Dhcp_OptionLength_LeaseTime 

Length in bytes for option oC_Dhcp_Option_LeaseTime.

oC_Dhcp_OptionLength_Overload 

Length in bytes for option oC_Dhcp_Option_Overload.

oC_Dhcp_OptionLength_ServerId 

Length in bytes for option oC_Dhcp_Option_ServerId.

oC_Dhcp_OptionLength_RequestedListMin 

Minimum length in bytes for option oC_Dhcp_Option_RequestedList.

oC_Dhcp_OptionLength_MessageType 

Length in bytes for option oC_Dhcp_Option_MessageType.

oC_Dhcp_OptionLength_T1RenevalTime 

Length in bytes for option #oC_Dhcp_Option_T1RenevalTime.

oC_Dhcp_OptionLength_T2RebindingTime 

Length in bytes for option #oC_Dhcp_Option_T2RebindingTime.

oC_Dhcp_OptionLength_ClientIdMin 

Minimum length in bytes for option #oC_Dhcp_Option_ClientIdMin.

oC_Dhcp_OptionLength_TftpServerNameMin 

Minimum length in bytes for option #oC_Dhcp_Option_TftpServerNameMin.

oC_Dhcp_OptionLength_BootfileMin 

Minimum length in bytes for option oC_Dhcp_Option_Bootfile.

Definition at line 175 of file oc_dhcp.h.