changed pinging class, works but considerably slower