sleep 1 in this loop so cpu doesn't go crazy