1

first of all, I have no problems running all the examples in APP-IOIO0504.zip.

Because my App has timing concern (in terms of mini sec), I would like to create an IOIO connection myself instead of using BaseIOIOLooper (i.e. another thread) or IOIOActivity


When I run the code "IOIOFactory.create()", it shows up this error:

10-14 22:02:59.473: E/IOIOFactory(29160): No connection is available. This shouldn't happen.


My environment:

Android: 4.4.2,

IOIO hardware: spark0020

Firmware: App-IOIO0500

Bootloader: IOIO0400

ps, I post on Google group IOIO-users, but got no response. Please show me a direction,

Thank you.

MrYo
  • 1,797
  • 3
  • 19
  • 33

1 Answers1

0

Adding this code (copied from one of the Android-specific classes) solved this problem for me:

IOIOConnectionRegistry.addBootstraps(new String[] {
    "ioio.lib.impl.SocketIOIOConnectionBootstrap",
    "ioio.lib.android.bluetooth.BluetoothIOIOConnectionBootstrap",
    "ioio.lib.android.accessory.AccessoryConnectionBootstrap",
    "ioio.lib.android.device.DeviceConnectionBootstrap"});

It should be more straight-forward to use the basic IOIO classes. The Android-specific helpers are much too "frameworky" for my taste / use case.

Stefan Haustein
  • 18,427
  • 3
  • 36
  • 51