Forum > Android

Bluetooth + Android + lazarus ?= 1

(1/2) > >>

mas steindorff:
how much work should I expect to do to port a data logging program (already created for windows) to work on an android tablet?  mainly my program and measurement hardware uses Bluetooth's serial protocol to send data as a virtual comm port that a window's driver handles for me now. I just use synaser.

Can the android OS do the same? 

I know my acer tablet has limited blue tooth protocol support but I don't know what's involved in adding something or if it even provies hooks to do so.

thank you for your time.

felipemdc:
I did some searching and found a lot of info on the subject. The downside is that the Bluetooth API in Android seams to be quite big:

http://developer.android.com/guide/topics/wireless/bluetooth.html

http://groups.google.com/group/android-ndk/browse_thread/thread/f21586a49be83d16?pli=1

http://stackoverflow.com/questions/5619850/code-samples-for-android-bluetooth-programming

http://developer.android.com/resources/samples/BluetoothChat/index.html

http://luugiathuy.com/2011/02/android-java-bluetooth/

The API is Java-only, so the traditional way which we are using to access Java API which are complex like this Bluetooth stuff is by wrapping it into the LazDeviceAPIs, which means doing:
1->adding routines in lazarus/examples/androidlcl/android/src/... .java
2->adding a generic API in lazarus/lcl/lazdeviceapis.pas
3->adding a WS implementation which calls the Java routines via JNI in lazarus/lcl/interfaces/customdrawn/customdrawnwslazdeviceapis.pas (or similar name)

The process is not hard, we already have Accelerometer, SMS sending and GPS support like that, but it is indeed a good amount of work because you have to test it with multiple devices at the same time which is much more time consuming then testing stuff which works in an isolated device like accelerometer or GPS and because the API is quite big.

mas steindorff:
thank you for your input. 
If I were to put a bounty out for this option, how much do you (and others reading this) think would be a ball park amount.  As this project doesn't have the goahead yet, time is not yet a factor.

felipemdc:
I think we could be talking for around us$200, although I would not be able to start any time soon, probably only in July because I already have so many pending tasks that taking anything new would be impossible...

BigSid56:
I need to get Bluetooth as well. I am also porting a datalogger. I'd be happy to contribute to the bounty.

Navigation

[0] Message Index

[#] Next page

Go to full version