Renesas RA Family EK-RA6M4 – Quick Start Guide
R20QS0016EG0101 Rev.1.01 Page 27 of 32
Nov.17.20
5.4 DHCP and Static IP settings
To modify the Ethernet based sample to enable/disable DHCP use the FreeRTOS+TCP setting in the stack.
The FSP Configuration view must be active to access the stack items properties.
Figure 31. DHCP Setting in FreeRTOS + TCP Stack
If DHCP is disabled, set the static IP address, net-mask and gateway address, to suit your local network.
In File: src\net_thread_entry.c
/* Static IP configuration, when DHCP mode is not used for the Example Project.
* This needs to be populated by the user according to the Network Settings of
your LAN.
* This sample address taken from the LAN where it is tested. This is different
for different LAN.
* get the Address using the PC IPconfig details.
*/
uint8_t ucMACAddress[ 6 ] = {0x00, 0x11, 0x22, 0x33, 0x44, 0x55};
uint8_t ucIPAddress[ 4 ] = {192, 168, 0, 52};
uint8_t ucNetMask[ 4 ] = {255, 255, 255, 0};
uint8_t ucGatewayAddress[ 4 ] = {192, 168, 0, 3};
uint8_t ucDNSServerAddress[ 4 ] = {10, 60, 1, 2};