Processing on Android device

My basic goal is to get a USB connection between an Android device (in my case a Samsung galaxy S4 mini) running a Processing sketch and an Arduino with USB Host shield (in my case a Leonardo board and the Sparkfun USB Host shield).

What I achieved so far:
-Writing Processing sketches that run on the Android device. (using Android-Mode).
-Getting the Leonardo board to work propperly with the USB Host shield.

What I have looked at:

What I hope to get:
-A detailed walktrogh on how to set things up and a simple example like switching the pin 13 Led via touch screen (verry optimistic)
-some more recent resources in the style of those I looked at.
-information on what I might have done wrong when I was trying to follow trough.

I am trying to do something similar. All I want to do is receive serial data from the arduino and display it in a terminal type window on the tablet. After some preliminary searching I have come to the conclusion that writing even simple aps for android tablets is going to be a chore.

Anyway, you may want to search around at xda developers for more info. At this point that forum looks to have some very sharp android programmers / hackers on it.

If you come across any good examples of how to get android tablets and arduinos talking let me know.

Good Luck, JP.

P.S.: I was just googling around some more, if you search "android arduino communication" lots of good stuff comes up.

JP.

jogl8: All I want to do is receive serial data from the arduino and display it in a terminal type window on the tablet.

So why don't you use a serial connection via bluetooth?

After some preliminary searching I have come to the conclusion that writing even simple aps for android tablets is going to be a chore.

This is probably correct, and you can test whether it is a good idea to try such an ostensibly basic task is a good idea by counting the number of times it has already been done.

I am hoping to avoid using bluetooth. I already have the arduino's installed and programmed (in tractors, combines and a few other, mostly temperature monitoring devices) and do not want to have to add bluetooth shields. These are all set up to send data from the serial port. I receive the data with computers (my laptop in the tractors and combine) running simple Python aps that I have written. Some of the arduinos also hang on my LAN and send data to a Linux database server via the LAN.

The reason I'm interested in tablets is because they would be very easy to mount in a tractor (lappy's are a chore).

I'm still researching (use that term very loosely) writing (or borrowing) a tablet ap to mimic what my computers do. Hopefully I'll find an example of it having already been done in a fashion that I can easily adapt. I am definitely not an ace programmer / hacker so if you could direct me to some of those examples I would much appreciate it.

To Fridolin, the OP, sorry for the hijack.

Thanks, JP.

jogl8: I have come to the conclusion that writing even simple aps for android tablets is going to be a chore.

Right. That is why I only want to work with Processing. Anything else is a little to far out for me at this point.

jogl8: P.S.: I was just googling around some more, if you search "android arduino communication" lots of good stuff comes up.

The problem with that is that the biggest part of those results just gives you a premade app and the necessary arduino code many of them also use USB host mode in the Android device which is impossible with my device.

Sounds like you are a ways ahead of me. Next I need learn what is this "processing."

OK, let me get this straight, Processing is basically a programming language (sounds like another C derivative) an IDE, an emulator and maybe other stuff all in one. You develop your ap, and download it to the android device.

So you need a library of serial port functions for Processing?

Processing builds on the Java language. The Arduino IDE derives from the Processing IDE making working with it pretty familiar.

Usually Processing sketches run on normal computers, but there are also several other options like Android-mode which allows the creation of android apps.

The optimum for me would be to have 2 libraries. One for the Arduino side and one for the Processing(Android-mode) side. Allowing data transfer between the devices.