works well but pid is near useless