loop ping implementation