Arduino Mega + Ethernet shield <—-> Tutorial using CoAP between Coopers
Tools and materials required
Download file MicroCoAP library on the link below.
https://github.com/1248/microcoap
Open the code file Arduino IDE, click Sketch -> Include Library -> Add, ZIP Library
Then select the library file has been downloaded previously.
Install Copper (Firefox Plugin)
Open Firefox then add Copper as shown below.
Copy the link that appears on Copper then paste.
Then the page will appear as in the picture
Select Serial Monitor to view the Arduino IP address you use if you connect Arduino Mega with Arduino Ethernet Shield in the Arduino program.
For your reference, you should check it on the Serial Monitor if you use DHCP. However, you can check it on the Source Code if you use any IP address.
COAP://vs0.inf.ethz.ch/ replace with COAP://192.168.2.109:5683/
Click Ping then, Arduino will disyplay the “Pong:Remote responds to CoAP” if it is connected with the IP Address.
You will see that the displayed value of Ping is increasing whenever clicking the Ping button at the Arduino Serial Monitor.
The original post can be found in the below link
https://geeknesia.freshdesk.com/support/solutions/articles/6000103001-arduino-coap-protocol
Thanks for sharing this !!!