Here are the adjusted MotionDetector files