I am connecting my Arduino to my Cubieboard that is running Android.

I tested this originally with my android tablet and USB cable. This worked successfully for the most part using the firmata kit but I don't want to use firmata.

I want a basic function library written in Java for use with Unity (eg Library Tutorial Video) to connect to the Arduino via the USB serial port connection much like a connection with my Windows computer.

I'd like basic command functions like:

  • Connect / Open
  • Write
  • Read
  • Flush
  • Close

I was thinking maybe of using this library here but I am unsure how to go about this. I know similar discussion have already taken place on the forum claiming it may not be possible, but it is very clear that it is. It has been done many times. All I need to do is send strings with serial after finding the Arduino's COM port and reading from the serial.

  • is your Cubieboard using adroid? what does "java eclipse" means? java is a language, eclipse is an ide, i think you have a bit of confusion. Many times they say it not possible as many phone does NOT have an USB HOST, but only USB SLAVE. Cubie should have a master. Java's library used by arduino ide are RXTX(old) and JSSC(use that)
    – Lesto
    Apr 1, 2014 at 15:57
  • Of course yes. I did get it a little confused. I need to access the serial port connected to arduino. Could you give a bit of information on the JSSC? Apr 1, 2014 at 16:00
  • Ive been looking at the documentation at code.google.com/p/java-simple-serial-connector/wiki/… and im not seeing any android support, am i being a little naive? Apr 1, 2014 at 16:47
  • JSSC does not support Andorid. i was thinking you was running Linux on the cubie.. Then the library you linked is the way to go
    – Lesto
    Apr 1, 2014 at 17:05

2 Answers 2


Using the library you linked should be a simple case of downloading the library's jar file from https://github.com/mik3y/usb-serial-for-android/releases and adding it as a reference/library/dependency (I forget what eclipse calls them) in your eclipse project.

Then of course providing you connect with the right baud rates and so on it should work.


Totally insane thought here but.....

Have you tried writing a chrome App to talk to your Arduino?

I did it on the Mac - had chrome monitoring things happening on the network and sending Serial Commands to the Arduino over USB.

You can find samples in the Chrome samples / docs


  • Do you know if this will run on the poster's embedded board, under their current operating system, and have access to the serial devices? May 12, 2015 at 1:52

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.