App crash when "createUsbSerialDevice"
Hi All,
I am having an issue when integrate with library. My application was crashed when "createUsbSerialDevice",
i have 2 case as below:
- Plug USB to android device: ==> OK
- App is open because i have device filter USB attached.
- Can create a connection and open it.
- USB is already plugged.
- Reboot android device.
- Permission is granted.
- openDevice success
- createUsbSerialDevice ===> FAILED.
Could somebody help me on this?
i have simmilar issue...
@PawelSzymanski89 Some info from Logcat would be great
I have the same issue in my app ( cratch on createUsbSerialDevice I think because openDevice always returns null ). Your example works fine and my code is a copy past of your example ... obviously something is missing in my code but I can not figure what.. A queston : How to get logcat and debug ? if the USB is attached to the FDTI I can not connect to Android Studio. Maybe a silly question but a suggestion would be appreciated. Thanks
Hi @ToninoTarsi What Android version do you have? Also It would be great to take a look of the exception stacktrace
Thanks Felipe Android 6 ( LG G3 ) . For the stacktrace I will be happy to be able to provide you one but I have no idea on how to connect simultaneously the FDTI and the PC to my phone. How do you do that ? Regards
@ToninoTarsi Android 6 should work fine. What kind of UsbSerial device are you connecting? if createUsbSerialDevice is returning null that means the usb device "is not supported" because VID-PID are not recognized. For debugging through wifi try this
Thanks for the information about ADB ove WiFi .. I will try. The device is an FTDI ( device.getVendorId() return 1027 ) and your example sync works fine so it is supported and your library works fine. The ADB over wifi will help to understand what I'm missing .. I hope. Thanks
@ToninoTarsi And the product id? Vendor id is standard FTDI but maybe that product id is not supported.
PID = 24597 (dec ) 0x6015
@ToninoTarsi It should be supported
Yes .. it works. It was my fault. Thanks for indicating me how to use ADB over Wifi .. I did not known that :-) Regards