Complete the icmp part and it interact with MainWindow well