Android Emulator - PC Serial Port

社会主义新天地 提交于 2019-12-23 09:35:08

问题


I need to prototype an Android application which communicates to external hardware using serial I/O. Can the emulator send and receive serial data over a PC's com port?


回答1:


The Android emulator itself supports this feature, I see people use "emulator -qemu -serial COM1" on Windows PC

or

"emulatro -qemu -serial /dev/ttyS0" on Linux PC

I have not tried it by myself yet, but that is the way in the big picture.




回答2:


I came across this: http://code.google.com/p/android-serialport-api/

this library will let you use Java to access the serial port on your Android device



来源:https://stackoverflow.com/questions/5246094/android-emulator-pc-serial-port

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!