B4A Library IOIO board library

pinoy_ako

Member
Licensed User
Longtime User
If it doesn't just work I can do nothing more. Does it work via USB? I assume you paired the IOIO board with the device. Did it seem to connect?
:sign0148: that is sad.

thr IOIOlibBT works with usb but with error. 1 error is when i issue led.write command, the app force close. but before issuing led.write command, there is no error.

i paired the bt ioio with the device and it connect, and was able to control led on the board using sample apps provided by ytai.

hope you could do something about it sir agraham. :sign0085:
 

agraham

Expert
Licensed User
Longtime User
IOIOBT 1.4 now posed includes IOIOBT.jar as well as IOIOlibBT.jar. Use either the original IOIO and IOIOlib together for USB connections and IOIOBT and IOIOlibBT together for a IOIO that supports Bluetooth connections. The object in the IOIOBT library is called IOIOBT.

If this IOIOBT doesn't work with IOIOlibBT then there is nothing more that I can do as I have compiled the original IOIO library source, that works, against the Bluetooth capable sources provided by ytai.
 

pinoy_ako

Member
Licensed User
Longtime User
thanks for the quick update sir agraham. 'appreciate that.

but for my first try with ioiobt and ioiolibbt, still, the application hungs.
 

pinoy_ako

Member
Licensed User
Longtime User
i dont know how to check that logs sir agraham. :sign0089:
can you give me tip how to do that? if it is just a short instruction to do. but if too many things to do for that, i'll find away to get those logs. and get back to you as soon as i get it.

thank you sir agraham.
 

pinoy_ako

Member
Licensed User
Longtime User
thanks agraham.

this is the from the unfiltered logs after i run the app.:

"** Activity (main) Create, isFirst = true **"
"** Activity (main) Resume **"

then when i issue connect to ioio:

"Waiting for IOIO connection"
"Waiting for underlying connection"
"Creating server socket"
"Waiting for TCP connection"

after that no more related to ioio app. and the app hungs.

for filtered logs, no exceptions.
 

agraham

Expert
Licensed User
Longtime User
Try this. Select Project -> Do Not Overwrite Manifest File and add the Bluetooth permission to the manifest after the INTERNET one. If it works I'll change IOIOBT to add the permission automatically.
B4X:
 <uses-permission android:name="android.permission.BLUETOOTH" />
 

pinoy_ako

Member
Licensed User
Longtime User
thanks sir agraham.

yes sir, i remember ytai mention to add the bluetooth permission in the manifest in his bluetooth wiki. i'll try to do your instruction now.
 

pinoy_ako

Member
Licensed User
Longtime User
thanks erel.

sir agraham, i included bluetooth permission in the manifest, checked do not overwrite manifest, but still the same. app hungs up.
i also tried IOIO + IOIObtLib combination with bluetooth permission, same hung up.

after it hung up, i close the app and run the sample app provided by ytai, it connected quickly.

i also tried erel's advice, and added serial lib, but still the same.

hope you can help me with this. :sign0013:

i even thinking of sending my ioio with bluetooth module to you now just to help you make this works.

thanks thanks.
 

pinoy_ako

Member
Licensed User
Longtime User
another thing i noticed. when i changed the firmware to display the bluetooth name as "b4a" instead of "ioio", the sample app provided by ytai doesnt work anymore. it may mean the app is looking for the "ioio" bluetooth name paired to the device.

is it also true with the b4a sample provided sir agraham, that it is looking for the name "ioio" in the list of paired devices in the phone?

thanks
 
Last edited:

ytai

New Member
:sign0087:
glad to see you're keeping up with the latest and greatest.
great work Andrew!
you're all welcome to post IOIO related questions on the ioio-users list. I'll try to help as much as I can and can probably save you some pain and struggling (and time) sometimes...
keep it up!
Btw, would be happy to hear your ideas and wishes for the next features. OpenAccessory? Wifi dongle? More I/O features? Other?
 

pinoy_ako

Member
Licensed User
Longtime User
WoW! The master musketeer is here. Good to you know you are now here Ytai. Great!

People are doing great here with your IOIO, especially sir andrew. Hope you could support us here, with the updates on IOIO.

Thanks Ytai!
 

agraham

Expert
Licensed User
Longtime User
IOIOBT version 1.5 now posted. This now sets the Bluetooth permission correctly. Initialize has a "Bluetooth" parameter, set it False for USB and True for Bluetooth.

B4X:
i changed the firmware to display the bluetooth name as "b4a" instead of "ioio",
The IOIOlibBT library is hardcoded to look for the name "IOIO".
 
Cookies are required to use this site. You must accept them to continue using the site. Learn more…