How Do Motion Sensors Work?