B4A Library IOIO board library

agraham

Expert
Licensed User
The request in this thread here introduced me to a product called IOIO that seems to have been designed by some Google engineers in the 20% of time that Google gives them to pursue their own interests,

The blog of the main mover of the project is at Microcontrollers, Electronics & Robotics: Meet IOIO - I/O for Android

The board will be available soon from here IOIO for Android - SparkFun Electronics

As the software has just been released I took a look at it and wrapped it in a couple of libraries for use with Basic4android. I obviously cannot test it as I have no board but the Basic4android library is a very thin veneer on top of the normal Android library so, typos and idiot errors aside, it should work with no problems and the software documentation should be pretty much applicable. I have copied a lot of the library help from the software documention so a B4A help viewer should give you a good grounding in how to use it.

I don't yet know if the board will be available this side of the pond - if anyone wants to ship me one for testing .... :)

EDIT :- Version 1.1 posted with INTERNET permission. See post #11 for details.

EDIT :- Version 1.2 posted with PulseInput. See post #37 for details.

EDIT :- Version 1.2 reposted with XML error fixed. See post #39 for details.

EDIT :- Version 1.3 posted with SPI and I2C support. See post #40 for details.

EDIT :- Version 1.3a posted with IOIOlib 3.2 included. See post #42 for details.

EDIT :- Version 1.4 posted. See post #47 for details.

EDIT :- IOIOlibBT 3.10 posted. See post#58 for details.

EDIT:- IOIOBT1.4 posted See post #63 for details

EDIT:- IOIOBT1.5 posted See post #77 for details.

THESE ATTACHMENTS ARE NOW OBSOLETE. SEE POST #105 FOR THE LATEST VERSIONS BY KOLBE: http://www.basic4ppc.com/android/forum/threads/ioio-board-library.8942/page-6#post-90731
 

Attachments

Last edited by a moderator:

colin9876

Active Member
Licensed User
This could be very useful in the future.
Small Arduino Boards have been popular for making interactive devices, e.g. Segway type self balancing wheels etc, GPS controlled model planes etc etc and I can imagine that these boards could be used in the same kind of way.
The possibilities will be endless
 

jscoulter

Member
Licensed User
nearly wet my pants in excitement....I was thinking the other day if something like this device existed. I didnt get around to looking, but now....wow...just THINK of the posibilities ! data loggers (expensive ones if you need a phone:)) that phone home, home automation...I hope I will get to sleep tonight :).....I was dissapointed to see the site out of stock at the moment :(
 

agraham

Expert
Licensed User
The XML file included in the zip is (almost) empty. The one you sent me is fine.
There are two xmls in the archive. IOIOlib.xml, the empty one, is like the AdMob one - used to make the IDE include the actual IOIO library, IOIOlib.jar, in the apk. The actual Basic4android wrapper library is IOIO.jar with its own xml.
 

wes58

Active Member
Licensed User
Thanks for that. Although I prefer using wireless (or 3G) connection (I use PicMicroWeb from OLIMEX) for controlling lights, garage door etc. I wish there was some library for SNMP protocol which would make easier and probably faster communication than just using http.
 

bluedude

Well-Known Member
Licensed User
Wow, that is awesome! I was planning to purchase one and hoped someone would create a library for it!
 

geoffcwicks

New Member
Licensed User
B4A Demo for IOIO

I have just received my IOIO and put together a B4A version of the IOIOHello demo. It toggles the yellow stat LED on the IOIO.

The B4A library works fine for this demo.

The only issue I had was that the application requires the android.permission.INTERNET permission. I found this on the IOIO wiki. There is a comment in the project source code with details.

Demo project is attached.
 

Attachments

agraham

Expert
Licensed User
Sorry. I overlooked adding the INTERNET permission to the library. Version 1.1 now posted should correctly request that permission.
 

gobblegob

Member
Licensed User
Hi,
I have a problem with the IOIO. I bought the IOIO with the recommended JST Connector and recommended power supply. I installed your Demo app and it worked one time and now there the board will not turn on at all, and the power LED will not turn on anymore.
the app never seems to initilize the board is my IOIO dead? :(
 

agraham

Expert
Licensed User
If the power Led doesn't come on then either the PSU is dead or the voltage regulator on the board has failed.
 

gobblegob

Member
Licensed User
Thanks mate i think the regulator has died :(
I will have to buy another IOIO and wait another 3 weeks /cry
 

atlasautocom

New Member
Licensed User
IOIO can not download

I downloaded the trial version to test with more precise tests uart communication in the library more IOIO can not download.
to read an entry ttyUSB0

Natal.

:sign0098:
 

meirmark

New Member
IOIO in Israel

Hi.
You can buy IOIO in Israel - h??p://www.dash.co.il/index.php?route=product/product&product_id=496

Meir.
 

cmartins

Member
Licensed User
Agraham,

Thanks for your lib, but I am try to compile the demo from geoffcwicks and I am got this error:



Compiling code. 0.03
Generating R file. 0.00
Compiling generated Java code. Error
B4A line: 42
led = YOYO.OpenDigitalOutput( 0,led.OP_NORMAL ,True) ' Enable LED_PIN for output
javac 1.6.0_21
src\b4a\gw\ioiodemo\main.java:203: package ioio.lib.api does not exist
_led.setObject((ioio.lib.api.DigitalOutput)(_yoyo_OpenDigitalOutput((int)(0),_led.OP_NORMAL,anywheresoftware.b4a.keywords.Common.True)));
^
1 error

Do I need download something?


thanks a lot
 
Top