UDP Server has to be configured and started. In this example we will use UDP port 8082, like showed in UDP Server Setup topic.


Required hardware is Arduino UNO, configured like in Led Blink Example topic (without TIMER component) and Wiz5100 Ethernet shield.


Notice: You cannot use now D13 pin with built-in led diode. Wiz5100 use D13 pin for shield connection. Use another free pin for connection led diode and assign this pin as TIMER component, or simply delete TIMER component and Upload Output Configuration with only D4 pin as DIGITAL OUTPUT, like in Led blink example but without TIMER. At least one component should be assigned(hardware does not have to be connected on pins), otherwise data statuses are not transmitted either over serial or network connection.


Arduino UNO communicates with W5100 using the SPI bus. This is on digital pins 10, 11, 12, and 13. Don't use these pins for any other purpose.



First, since we will used Ethernet shield, updating firmware is required.

Unplug Arduino UNO from USB cable, attach Ethernet shield, reconnect USB, connect LAN cable to shield and router or switch.


Select Arduino board Test UNO in list view, then go to Main menu -> Tools-> Update Firmware 


Upload firmware




IMPORTANT: Arduino UNO with Ethernet shield in Arduino Control Center cannot be configured to obtain IP address automatically via DHCP server(usually your home router).

IP address has to be assigned manually. 

Right click on Test UNO device in list view -> Device & Network Setup. Arduino UNO has to be connected and port must be opened, device will be restarted and data stored in Arduino UNO EEPROM will be showed.

My IP address :192.168.1.101 

Net mask:255.255.255.0

Gateway: 192.168.1.1

DNS:not relevant in our case, can stay with zeros


IP address has to be in range, so I will added next configuration:

Arduino UNO IP address :192.168.1.50 

Net mask:255.255.255.0

Gateway: 192.168.1.1

DNS:not relevant in our case, can stay with zeros


Everything match to PC configuration, new address 192.168.1.50 is in range. I will added this data in the fields for network setup. Of course, your configuration will be different.

Generate MAC address for your Arduino UNO board.


IMPORTANT: Your setup is different, for sure. You can click on IP Config button and check your PC configuration, add these data in the fields for network setup.

 

If configuration is correct and uploaded to Arduino UNO board, IP address from Arduino UNO will show up in list view for Test Uno device.

Disconnect COM port, uncheck Test UNO device.


Possible issues:

1. Data not receiving - check if UDP Server is started and Arduino UNO server port(8082 in our case) is matching with UDP Sever port configuration.

2. Data not receiving - check firewall settings, arduinocontrolcenterdemo.exe should be allowed for Incoming and Outgoing traffic.

3. Data receiving, but cannot send to Arduino UNO(cannot trigger D4 output in order to start stop TIMER) - check Gateway setup


 

Free Kindle producer