MIT App Inventor 2: emulator doesn't launch companion

早过忘川 提交于 2019-12-13 14:44:13

问题


When I run aiStarter.exe as administrator, and the click on connect to the emulator in http://ai2.appinventor.mit.edu, then the emulator starts, the black screen with android is displayed and after a couple of seconds I get the android home screen.

Then every couple of seconds, a line "127.0.0.1 - date/hour/ "GET/echeck/..." is added in aiStarter.exe, and on http://ai2.appinventor.mit.edu the message asking me to wait a minute or two while it's starting emulator remains. I have waited for something to happen at this point for 30 minutes, but nothing changes.

If I understood it well, the companion should be automatically launched and then I should be asked if I when to update it. But this never happens, it is as if emulator get stuck just before companion get launched, or App Inventor never recognizes that emulator has started.


回答1:


There is a simple fix to that bug:

once your emulator is loaded (just wait until you see that: pct1), don't close anything, just open Windows Task Manager (Ctrl+Shift+Esc or Ctrl+Shift+Del -> Task Manager) in the process kill the adb.exe (while the emulator is working) cf. pct2. Don't do anything else, wait for few second and you will see a new popup to this site saying that it has detected the emulator. Repeat that each time the emulator stuck.

pct1:

pct2:

This seems to force adb to listen on the port 8001

EDIT1 an other way to kill and restart adb.exe:

List item:

  1. put your UAC (in start menu) at the lower level
  2. launch your emulator, when it's ready (SD card prepared) do the following
  3. go in C:\Program Files (x86)\AppInventor\commands-for-appinventor right click new and "text" and rename this file run.bat (to change .txt in .bat)
  4. right click to edit the file with notepad
  5. write just: CMD
  6. save and close
  7. now double click that run.bat file
  8. write: adb kill-server
    (press enter and wait)
  9. write: start-server
    (your emulator should now connect)

Edit2: Genymotion works much faster with app inventor 2.



来源:https://stackoverflow.com/questions/29207717/mit-app-inventor-2-emulator-doesnt-launch-companion

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