Handles detached events from USBDevice.start_detection().

def handle_detached(sender, device):
    """
    Handles detached events from USBDevice.start_detection().
    """
    vendor, product, sernum, ifcount, description = device

    # Close and remove the device from our list.
    if sernum in list(__devices.keys()):
        __devices[sernum].close()

        del __devices[sernum]

    print('detached', sernum)