-module(echo_client). -export([send_ping/1]). send_ping(Echo_Node) -> io:format("Sending echo to ~s, self=~p~n", [Echo_Node, self()]), {echo, Echo_Node} ! {ping, self()}, receive {pong, Server} -> io:format("got pong from ~w~n", [Server]); X -> io:format("Unexpected reply: ~w~n", [X]) after 1000 -> io:format("timeout~n") end.