Skip to content

Instantly share code, notes, and snippets.

Created May 17, 2021
What would you like to do?
sonar-like icmp ping

Sonic Ping

Emit a sound on each icmp reply.


sudo apt install tcpdump sox


In one terminal:

while true; do sudo tcpdump -v -nn -i eno1 -c 1 'icmp and icmp[icmptype] == icmp-echoreply' && play -q -n -c 2 synth 2 sin 880 synth 2 sin fmod 1200 fade l 0 2 1.8 trim 0 1; done

Replace interface eno1 if needed.


In another terminal:

ping -i 2 targethost

Replace targethost with the host you want to ping.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment