use pid to stop