Can I emulate a compass on Android

杀马特。学长 韩版系。学妹 提交于 2019-12-30 05:05:47

问题


I want to test a compass app on the emulator. Is this possible or do I have to use a real device. Also I do not want to use gps.


回答1:


It's possible to install sensorsimulator from openintents but you can only use this as an app on the emulator and send commands from the pc. The weird thing is once you quit the app on the emulator then it stops receiving sensor simulation data. So it's useless for testing your own app! Is it possible to simulate sensor commands on the emulator to actually send sensor data? like DDMS does for GPS?




回答2:


It seems that at the moment testing hardware sensor input is not possible with the emulator. At least this is what I read from the emulator docs. Maybe there is some badly documented console program that you can use via telnet.



来源:https://stackoverflow.com/questions/2376512/can-i-emulate-a-compass-on-android

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