Closed BrotherV closed 5 years ago
meet with the same problem
I finally finished the project and I did it with two library(mik3y and felhr85 usb serial for android). If you would like, I can share what I did.
Send an email an I'll reply it for you. find my email in my profile.
haven't see your email in your profile
Send an email an I'll reply it for you. find my email in my profile.
haven't see your email in your profile.
haven't see your email in your profile
Send an email an I'll reply it for you. find my email in my profile.
haven't see your email in your profile.
I've sent you my codes. if you had any problem, you know how to find me.
so i have a same problem,i can get the device ,but when i use the "connection = manger.openDevice(device);" this connection is always null error: java.lang.SecurityException: User has not given permission to device UsbDevice
i'd want a broadcastReceiver to deal with the action of the USB, if use the activity like example it's well,
ps: meta-data in the AndroidManifest.xml must in Activity statement
looks like you have to ask permission to the user to use the USB device. This can be done in the manifest. Here is a deeper explanation: http://blog.blecentral.com/2015/10/01/handling-usb-connections-in-android/
@BrotherV could you share your work with me? Thanks
You can refer https://github.com/mik3y/usb-serial-for-android/issues/220 for usage idea and a useful example app from kai-morich fork.
Thanks @eclectice I have found another solution
@acaliaro Sure, give me your email and I can send it all for you.
Thanks @BrotherV , I have found another good solution to this project. I will contact you if I will need your help in the future. Thanks again
@acaliaro Your welcome. feel free and contact me with this email: mohsen_hatami@ymail.com Good luck
please look into examples at end of https://github.com/mik3y/usb-serial-for-android#quick-start for permission handling
I finally finished the project and I did it with two library(mik3y and felhr85 usb serial for android). If you would like, I can share what I did.
I need them for my project, Can you send me your code use mik3y or felhr85. Thanks. My email. thang.phamduc@gmail.com. Sorry I can't find your email address.
Hi, I appreciate your work. Unfortunately I couldn't find a right way to connect to serial port, There are two different ways that you mentioned. first of them relate to jar library and second one relate to the last commit. In the first sample Jar file doesn't support any of control values such as stop bit and so on. Can you guide me to fix it? Even I can't connect to an Arduino.
Sample code: UsbSerialProber prober = UsbSerialProber.getDefaultProber(); UsbSerialDriver driver = prober.probeDevice(device); if(driver != null){ List ports = driver.getPorts();
}
I have a device with vendor id 0x2341 but driver always return null.
Thanks in advance.