def get_arduino(): serial_port = detect._find_arduino_dev(platform.system()) if not serial_port: raise LookupError('Serial port not found') return ArduinoFirmata(serial_port)