Communicating with serial USB device over Android

Josef picture Josef · Feb 15, 2014 · Viewed 65.8k times · Source

I have one custom made device for measuring current. This device can be connected to PC and communication is done over USB. It is based on FTDI chip. I have application written in Java and that application is using rxtxSerial.dll library and gnu.io.rxtx_2.1.7.4.jar. Now I want to port this application on my android device and I'm litte bit confused what to do that? All I have is android tablet (os version 4.1.1), OTG cable and this measuring device.

Should my device be rooted? Is there any kind of library that I can simply add to my Java Android application and read data over USB? Where to start?

I have tried to port existing application for PC using same library, but rxtxSerial.dll is missing and I can't transfer it to my android device.

Answer

Frank D. picture Frank D. · Jun 2, 2015

I can really recommend the USB-Serial-For-Android library, it supports multiple popular usb-to-serial chips (also FTDI) and there is no rooting required. Check out the GitHub project here.