BLE Simulation Over Android Debug Bridge

I'm having problems to work with BLE Simulation Over Android Debug Bridge. The compiler doesn't recognize IQCommProtocol. Am I missing something very obvious? Some class I should import or so? Could someone provide me with a working example?

According to the documentation:

"To enable the companion to communicate over ADB you must:

1. Connect the phone to the PC running the simulator via USB.
2. Have USB debugging enabled on the Android handset.
3. Obtain an instance of ConnectIQ using getInstance(IQCommProtocol.ADB_SIMULATOR)
4. Optionally call setAdbPort(int port) to set a specific port to use for communication. The default port is 7381.
5. Call initialize().

To allow the simulator to communicate over ADB, in a terminal or console forward the tcp port you are using to the Android device.

adb forward tcp:7381 tcp:7381"

PS: I'm working with Android Studio on a Mac.
  • Former Member
    Former Member
    Apologies for that, it is a mistake in the documentation. The getInstance() call that expects arguments requires an application context and a value of the type ConnectIQ.IQConnectType.

    ConnectIQ mCiq = ConnectIQ.getInstance(this, IQConnectType.TETHERED);

    We are working on improving the mobile SDK documentation, and I have created an explicit note to address this issue. In the meantime, the sample included in the Android Mobile SDK should be functional and should demonstrate most aspects of the SDK.