code: def get_all_connected_interfaces():
          
  
          devices = hid.enumerate()
  
          if not devices:
              log.debug("No Mbed device connected")
              return []
  
          boards = []
  
          for deviceInfo in devices:
              product_name = to_str_safe(deviceInfo['product_string'])
              if (product_name.find("CMSIS-DAP") < 0):
                  # Skip non cmsis-dap devices
                  continue
              
              vid = deviceInfo['vendor_id']
              pid = deviceInfo['product_id']
              
              # Perform device-specific filtering.
              if filter_device_by_usage_page(vid, pid, deviceInfo['usage_page']):
                  continue
  
              try:
                  dev = hid.device(vendor_id=vid, product_id=pid, path=deviceInfo['path'])
              except IOError as exc:
                  log.debug("Failed to open USB device: %s", exc)
                  continue
  
              # Create the USB interface object for this device.
              new_board = HidApiUSB()
              new_board.vendor_name = deviceInfo['manufacturer_string']
              new_board.product_name = deviceInfo['product_string']
              new_board.serial_number = deviceInfo['serial_number']
              new_board.vid = vid
              new_board.pid = pid
              new_board.device_info = deviceInfo
              new_board.device = dev
              boards.append(new_board)
  
          return boards
docs: returns all the connected devices which matches HidApiUSB.vid/HidApiUSB.pid.
          returns an array of HidApiUSB (Interface) objects