mik3y / usb-serial-for-android

Android USB host serial driver library for CDC, FTDI, Arduino and other devices.
MIT License
4.81k stars 1.58k forks source link

How to read data from two different usb devices at a time ? #487

Open dd-technologies opened 1 year ago

dd-technologies commented 1 year ago

The problem is we are sending and receiving data from two different usb devices. How to differentiate between the data from two devices ?

kai-morich commented 1 year ago

Use 2 different objects that implement SerialInputOutputManager.Listener, see https://github.com/mik3y/usb-serial-for-android/blob/9bd1f257739f57a9079c15cd25ea4331fb587091/usbSerialForAndroid/src/androidTest/java/com/hoho/android/usbserial/CrossoverTest.java#LL48C19-L48C19

dd-technologies commented 1 year ago

can you give me a chance to be a collaborator in your github repo, i do need to work for your repo too... as i am having core experience in these serial i2c communications with android .

On Sat, 8 Apr 2023 at 20:11, kai-morich @.***> wrote:

Use 2 different objects that implement SerialInputOutputManager.Listener, see https://github.com/mik3y/usb-serial-for-android/blob/9bd1f257739f57a9079c15cd25ea4331fb587091/usbSerialForAndroid/src/androidTest/java/com/hoho/android/usbserial/CrossoverTest.java#LL48C19-L48C19

— Reply to this email directly, view it on GitHub https://github.com/mik3y/usb-serial-for-android/issues/487#issuecomment-1500904997, or unsubscribe https://github.com/notifications/unsubscribe-auth/AYY2JA65CU3XC6CIKDOBOITXAF2KLANCNFSM6AAAAAAWXJU72E . You are receiving this because you authored the thread.Message ID: @.***>