You mention a scan_lights() function. I'm really interested in learning from this example. Could you give me any hints as to how this works?