IOIO on Android not working
Joe7M opened this issue · 4 comments
Hi Chris,
IOIO doesn't work on Android:
- Tested on a tablet and a mobile phone
- SmallBASIC 12.27.
- IOIO is powered externally with 5V over the 5V pin
- IOIO charges Android device -> seems to be in host mode
- using the led.bas example in the ioio folder
- Error message: `LIB: IOIO ->sblib_init() failed"
- When USB-debugging is on, Android detects, when ioio board is connected
- When USB-debugging is off, Android wants to use OpenAccessory but displays error message:
No app installed for this accessory
Do you have any suggestions? Is it possible to get a better error message indicating what went wrong?
Here's some steps - hope this helps:
- Launch SmallBASIC and then click Setup.
- On the second screen, click to Load extension modules.
- Restart SmallBASIC and then click About
- You should see: Extension modules: enabled.
- If you have enabled Android developer options, make sure USB debugging is disabled.
- On your ioio-otg board, connect a power source to the VIN + GND (9v battery worked for me).
- Connect a USB cable between your mobile and the board (I used the included red adaptor plus another cable).
- You should see "IOIO Standard application - no installed apps".
- Launch led.bas
- You should see a prompt requesting permission for SmallBASIC to access the board. Click okay.
- You should then see a toast message: IOIO board access permitted.
- For this initial setup led.bas has now timed out
- I couldn't find a way to smooth over this part of the process.
- You should be able to re-launch led.bas for successful operation.
If this all fails, you could use adb to retrieve the android log - there should be something that hints at what went wrong. You may also find some extra detail in SB's console screen.
I do step 1 (About shows me, that the extension modules are enabled). After restarting SmallBASIC (step 2) the extension modules are disabled. This happens on my mobile phone and tablet (Android 9).
I think there's a bug where if you return to the setup screen, it shows as disabled. If you look in the about screen it should say enabled. I've mostly been using the same device, i'll try some others.
Good news. IOIO is working now on both Android devices. I'm not 100% sure, what the solution was. I had the problem, that I could not activate the extension modules. After running setup and restarting SmallBASIC, the modules were always listed as disabled in the About screen. It might be, that the fix was, to type in the Setup screen also for the web service port a new number (the tries before I just hit the enter key).