Arduino IDE coding ( Computing )

Introduction
In this assignment you will write software for your Arduino that will analyse the transmission of messages sent and received through software serial ports connected to a “virtual network” of hosts (networked computer devices) running on the connected Nano. The overall aim of the work is to determine which hosts are present on which ports and to analyse the performance of the virtual network. This assignment is divided into several tasks and you should complete each task before moving on to the next:

Task 1 will send messages to a port to determine if a host can be reached.
Task 2 will analyse how long it takes to get a response from a connected host whose port is known.
Task 3 will determine which port each host is connected to.
Task 4 will analyse the response times of hosts on each port.

Note that this assignment assumes that you have completed the practical work carried out during the module.
The program you write for this assignment should consist of a number of functions and test functions. Each test function should be called at the end of setup() while you are working on the relevant task.