xseignard / cordovarduino

Cordova/Phonegap plugin for USB host serial communication from an Android device.
MIT License
166 stars 110 forks source link

Is my board supported? #77

Closed LiftLink closed 6 years ago

LiftLink commented 7 years ago

Using an Adafruit Feather (adalogger 32u4). Android-Cordova-Arduino-JS.TXT Adafruit-Feather-32u4-sketch.txt

Attached is the code that I’m using to read and write to the USB from the Android app and the Arduino sketch that receives a signal from the app which then causes the sketch to send a line of data back to the app.

We are opening the port at 9600 baud, Vendor ID of ‘0239a’, Product ID of ‘8011’ and the ‘CdcAcmSerialDriver’ This is what happens when we run our test…

The write from our Android app works, our test sketch receives the written data, sends a line of data back to the app (via serial.printf), flashes the LED 10 times. The back on the Android app side, the registered read handler gets called, but the Cordova-Arduino plugin always sends byte array with a length of zero (0) bytes. We cannot read from the USB port from the Android device, only writes to the USB port work.

Thanks for your help!

xseignard commented 7 years ago

Did you solved it? Please try the following https://github.com/xseignard/cordovarduino#a-complete-example to check if everything is working.

xseignard commented 6 years ago

Closing it due to inactivity. Feel free to reopen it.