Hi all,
there are weeks i am becoming mad in finding some way to simply ping a server.
I have checked w5500 library, Ethernet2 library, but i cannot end with it.
Or receiving error message lwip\icmp.h not found, or error during compiling....
Please, can you help me telling a library to download or a way that let me simply ping some server ?
Really thanks
Ethernet ping
Moderators: adafruit_support_bill, adafruit
Please be positive and constructive with your questions and comments.
- adafruit_support_mike
- Posts: 67454
- Joined: Thu Feb 11, 2010 2:51 pm
Re: Ethernet ping
The Ethernet library doesn't support ICMP (the connection protocol of ping packets), for arguably good reasons:
Pings are notoriously easy to abuse, for everything from address harvesting (find machines in an unknown network by pinging the broadcast address and seeing which ones respond) to denial of service attacks (ping flooding). Many ISPs and firewalls block ICMP by default.
Considering how easy it would be to turn a microcontroller into a ping flood generator:
I can see the point of making it harder to do.
If you aren't interested in rolling your own ICMP layer, I'd suggest polling servers by trying to open a TCP connection to some well-known port. It's more complicated, but will tell you whether the server is answering calls.
Pings are notoriously easy to abuse, for everything from address harvesting (find machines in an unknown network by pinging the broadcast address and seeing which ones respond) to denial of service attacks (ping flooding). Many ISPs and firewalls block ICMP by default.
Considering how easy it would be to turn a microcontroller into a ping flood generator:
Code: Select all
void loop () {
ping( address );
}
If you aren't interested in rolling your own ICMP layer, I'd suggest polling servers by trying to open a TCP connection to some well-known port. It's more complicated, but will tell you whether the server is answering calls.
Please be positive and constructive with your questions and comments.