-
Notifications
You must be signed in to change notification settings - Fork 225
Network utilities
Jaume Olivé Petrus edited this page Sep 25, 2017
·
11 revisions
Lua RTOS has support for the following network services:
The net.ping utility is used to test the reachability of a host on an Internet Protocol (IP) network. The host argument is a string with the host name o the host ip address.
/ > net.ping("whitecatboard.org")
PING whitecatboard.org (5.196.211.36): 32 data bytes
60 bytes from 0.0.0.0: icmp_seq=1 time=37.567 ms
60 bytes from 0.0.0.0: icmp_seq=2 time=36.479 ms
60 bytes from 0.0.0.0: icmp_seq=3 time=36.865 ms
60 bytes from 0.0.0.0: icmp_seq=4 time=36.871 ms
60 bytes from 0.0.0.0: icmp_seq=5 time=36.861 ms
60 bytes from 0.0.0.0: icmp_seq=6 time=36.861 ms
60 bytes from 0.0.0.0: icmp_seq=7 time=36.880 ms
60 bytes from 0.0.0.0: icmp_seq=8 time=36.859 ms
60 bytes from 0.0.0.0: icmp_seq=9 time=36.873 ms
60 bytes from 0.0.0.0: icmp_seq=10 time=36.858 ms
10 packets transmitted, 10 packets received, 0.0% packet loss
round-trip min/avg/max/stddev = 36.479/36.897/37.567/0.251 ms
/ > net.ping("8.8.8.8")
PING 8.8.8.8 (8.8.8.8): 32 data bytes
60 bytes from 8.0.0.0: icmp_seq=1 time=27.440 ms
60 bytes from 8.0.0.0: icmp_seq=2 time=27.531 ms
60 bytes from 8.0.0.0: icmp_seq=3 time=27.811 ms
60 bytes from 8.0.0.0: icmp_seq=4 time=27.830 ms
60 bytes from 8.0.0.0: icmp_seq=5 time=27.819 ms
60 bytes from 8.0.0.0: icmp_seq=6 time=27.853 ms
60 bytes from 8.0.0.0: icmp_seq=7 time=27.826 ms
60 bytes from 8.0.0.0: icmp_seq=8 time=27.838 ms
60 bytes from 8.0.0.0: icmp_seq=9 time=27.827 ms
60 bytes from 8.0.0.0: icmp_seq=10 time=27.847 ms
10 packets transmitted, 10 packets received, 0.0% packet loss
round-trip min/avg/max/stddev = 27.440/27.762/27.853/0.140 ms
Pinging can be interrupted pressing the Ctrl-c key.