Extending Android interface lazarus / 43-Android ---------------------------------------------------------------------- djdjdjole · 2012-10-19 15:27 As much as I understand, accessing Android via Lazarus is solved for graphic interface, but what is also interested, regards communication for example. No much use of graphic interface if there are no communication capabilities, file manipulation capabilities, work with threads, timers  ...(or maybe some of that already exist). I suppose that there should be done some Java programming (which I hardly know), but  wonder how Java classes that do serial or ethernet or ..., could be incorporated in Lazarus? Has someone already done part of that job ? I also don't understand how example application is compiled and what is (and why) exported from project, etc... which I think is essential for achieving the aim I mentioned. Regards ---------------------------------------------------------------------- djdjdjole · 2012-10-20 05:44 To be more specific - here is the link that interests me: http://android.serverbox.ch/?p=549 It describes new USB hosta API, that I need in my project (and serial communication and TCP, also). My question is how can I incorporate that example java source in Lazarus ? Probably JNI calls (a little bit I know of), or what else ? At least I need basic steps, some kind of hint, just to know where to start learning from. Regards ---------------------------------------------------------------------- BigChimp · 2012-10-20 06:11 Hard to know what you know if you don't tell what you read already. I know nothing about the subject but have you read this: http://wiki.lazarus.freepascal.org/Android_Programming http://wiki.lazarus.freepascal.org/Custom_Drawn_Interface/Android http://wiki.lazarus.freepascal.org/LazDeviceAPIs If you follow links in those articles and/or search on Java in the wiki I'm sure there will be more relevant articles. Apart from that, have you searched this forum? Did you find anything? I remember some posts about programming for android hardware... ---------------------------------------------------------------------- djdjdjole · 2012-10-20 08:32 Thank you BigChimp for links you provideded - second one I've already red, it is more tutorial article, but the rest I am going to read. I consider myself famliar with Delphi/Windows programing and moderate with Lazarus on Windows CE and Linux (x86 and ARM), but in Java don't feel so familiar. My opinion is that if I had to learn Java, because of Android, then I will rather incline to Eclipse and "forget" of Lazarus, but I would rather stick to it simply because of less efort I have to have. I would rather stick to Linux or WindowsCE, but already mentioned USB Host API in Android, makes it spetial, because AFAIK in Windows(CE)/Linux, you have to write drivers, and  in Android it is user level programming. I will search forum once more, although I tried briefly. Thanks ---------------------------------------------------------------------- djdjdjole · 2012-10-21 12:29 First link was the most usefull to me. However, I don't know where in big picture fits LCLActivity.java file - what is it's job ? Also, it seems to me, that if I want to use JNI calls, then it is probably anavoidable to "know" java and for making tests (and programing) then Eclipse, too. Except for incorporating java sources without any changes. Or am I wrong ? Regards ---------------------------------------------------------------------- djdjdjole · 2012-10-22 16:11 At this link http://forum.lazarus.freepascal.org/index.php/topic,16803 .msg92135.html#msg92135 I noticed that accessing files in android can be done by Pascal functions. How it happens that for file functions "conversions"  to java stream classes (ie JNI calls to them) is not needed and for graphics (eg) it is ? What about threads, sockets, ... in that sense ?