<!--
{
  "availability" : [
    "macOS: -"
  ],
  "documentType" : "symbol",
  "framework" : "IOBluetooth",
  "identifier" : "/documentation/IOBluetooth/IOBluetoothOBEXSession/init(incomingRFCOMMChannel:eventSelector:selectorTarget:refCon:)",
  "metadataVersion" : "0.1.0",
  "role" : "Initializer",
  "symbol" : {
    "kind" : "Initializer",
    "modules" : [
      "IOBluetooth"
    ],
    "preciseIdentifier" : "c:objc(cs)IOBluetoothOBEXSession(im)initWithIncomingRFCOMMChannel:eventSelector:selectorTarget:refCon:"
  },
  "title" : "init(incomingRFCOMMChannel:eventSelector:selectorTarget:refCon:)"
}
-->

# init(incomingRFCOMMChannel:eventSelector:selectorTarget:refCon:)

Initializes a Bluetooth-based OBEX Session using an incoming RFCOMM channel.

```
init!(incomingRFCOMMChannel inChannel: IOBluetoothRFCOMMChannel!, eventSelector inEventSelector: Selector!, selectorTarget inEventSelectorTarget: Any!, refCon inUserRefCon: UnsafeMutableRawPointer!)
```

## Parameters

`inChannel`

RFCOMM channel ID of the desired channel to be used.

`inEventSelector`

The selector to be called when an event is received.

`inEventSelectorTarget`

The target object that get the selector message.

`inUserRefCon`

caller reference constant, pass whatever you want, it will be returned to you in the selector.

## Discussion

---

Copyright &copy; 2026 Apple Inc. All rights reserved. | [Terms of Use](https://www.apple.com/legal/internet-services/terms/site.html) | [Privacy Policy](https://www.apple.com/privacy/privacy-policy)