check conection state