Added auto-sweep functinality