I can't connect without any method(WIFI, USB, Emulator)

523 views
Skip to first unread message

Rafael Carvalho

unread,
Apr 17, 2015, 3:42:27 PM4/17/15
to mitappinv...@googlegroups.com
I'm trying to connect my creator to the wifi, usb, emulator, but anything works, always it give me the same Error: Companion Connextion Error: See Connection Help I tryed tots of things, but nothing worked, please help me. Sorry by any english errors, I'm brazilian.

SteveJG

unread,
Apr 17, 2015, 4:22:53 PM4/17/15
to mitappinv...@googlegroups.com
First some questions.

Did you follow the installation instructions for App Inventor 2  here  

Did you install Companion version 2.26 to your phone, downloading from Google Play?  

You can not connect with WIFI .. that is usually easy .. do you see the Companion screen in your Android ?   if so, did you follow these instructions  http://appinventor.mit.edu/explore/ai2/setup-device-wifi.html  ?

Are you using a dsl connection or a dongle WIFI connected to a network?   If you are using the latter system, that is probably your problem.

Have you installed the emulator?   http://appinventor.mit.edu/explore/ai2/setup-emulator.html  

When you try the USB connection  did you download and install the USB Drivers mentioned in the article here  http://appinventor.mit.edu/explore/ai2/setup-device-usb.html ?  Did you also change the setting in the Developer options of your Android settings  to Enable USB Debugging?

Regards,
Steve


May Mei

unread,
Apr 18, 2015, 5:11:46 AM4/18/15
to mitappinv...@googlegroups.com

Hi Steve,

I have the same problem as Rafael Carvalho. But let me focus on the WIFI connection first and see if anything can be done.

 

Did you follow the installation instructions for App Inventor 2  here  

- Yes, all done. I have changed the security setting of my android phone to allow the installation of an anonymous programme.

 

Did you install Companion version 2.26 to your phone, downloading from Google Play?  

- Yes!! The problem is it still keeps saying mine is not update even it is version 2.26.

 

You can not connect with WIFI .. that is usually easy .. do you see the Companion screen in your Android ?   if so, did you follow these instructions  

http://appinventor.mit.edu/explore/ai2/setup-device-wifi.html  ?

- I can connect with the same WIFI source of same SSID but I notice that the IP addresses are slightly different on my notebook and android phone respectively. Is that the problem?

 

 

Are you using a dsl connection or a dongle WIFI connected to a network?   If you are using the latter system, that is probably your problem.

- I am using DSL connection. 

 

Have you installed the emulator?   http://appinventor.mit.edu/explore/ai2/setup-emulator.html  

- Yes, installed in the default folder commands-for-appinventor.... but in the aiStarter window, I read the message saying it cannot find the emulator.exe. I even tried to double click to start the emulator.exe myself but stilll nothing came out.

- I am using window 8.1 (traditional chinese) , chrome (traditional chinese) version 42.0.2311.90 m, SONY Z ultra C6833(traditional chinese), Android version 4.4.4

- attached below is what I read in the aiStarter window.

 

If you need more information, please let me know. Thanks for the help

 

May

 

Platform = Windows

AppInventor tools located here: "C:\Program Files (x86)"

Bottle server starting up (using WSGIRefServer())...

Listening on http://127.0.0.1:8004/

Hit Ctrl-C to quit.

 

Killed adb

 

錯誤找不到處理程序 "emulator.exe"

Problem stopping emulator : status 128

 

127.0.0.1 - - [18/Apr/2015 16:56:48] "GET /reset/ HTTP/1.1" 200 40

Killed adb

 

錯誤找不到處理程序 "emulator.exe"

Problem stopping emulator : status 128

 

127.0.0.1 - - [18/Apr/2015 17:04:16] "GET /reset/ HTTP/1.1" 200 40

Killed adb

May Mei

unread,
Apr 18, 2015, 5:27:34 AM4/18/15
to mitappinv...@googlegroups.com
My new update:

Really strange enough, I at last successfully installed the app and it worked too just immediately after I finished my last posting!

Still have no idea why it all happened???? .... anyway, just to share what I see in the aiStarter Window now. Maybe it's useful for solving other similar problems.

Platform = Windows

AppInventor tools located here: "C:\Program Files (x86)"

Bottle server starting up (using WSGIRefServer())...

Listening on http://127.0.0.1:8004/

Hit Ctrl-C to quit.

 

Killed adb

 

錯誤找不到處理程序 "emulator.exe"

Problem stopping emulator : status 128

 

127.0.0.1 - - [18/Apr/2015 16:56:48] "GET /reset/ HTTP/1.1" 200 40

Killed adb

 

錯誤找不到處理程序 "emulator.exe"

Problem stopping emulator : status 128

 

127.0.0.1 - - [18/Apr/2015 17:04:16] "GET /reset/ HTTP/1.1" 200 40

Killed adb

 

錯誤找不到處理程序 "emulator.exe"

Problem stopping emulator : status 128

 

127.0.0.1 - - [18/Apr/2015 17:04:39] "GET /reset/ HTTP/1.1" 200 40

127.0.0.1 - - [18/Apr/2015 17:13:21] "GET / HTTP/1.1" 404 720

127.0.0.1 - - [18/Apr/2015 17:13:21] "GET /favicon.ico HTTP/1.1" 404 742

SteveJG

unread,
Apr 18, 2015, 8:50:01 AM4/18/15
to mitappinv...@googlegroups.com
@ May Mei     Thank you for your notes.   We are glad AI2 is working for you now.   Did you re-install the installer software?  Sometimes uninstalling and re-installing fixes issues like what you described and doing that may be why AI2 now works properly.

Regarding "Yes, all done. I have changed the security setting of my android phone to allow the installation of an anonymous programme."

 

You may not want to leave the security setting continuously checked to allow anonymous program installation.   You should only have to check the security selection when you install an apk compiled app to your Android.  Some Androids provide an option to use the setting only once and then after you install, the setting reverts to the safe mode.    I recommend you return the setting to the safe mode.    What you must check is to allow USB debugging if you are going to use a USB connection.


Regards,

Steve

May Mei

unread,
Apr 18, 2015, 10:34:36 AM4/18/15
to mitappinv...@googlegroups.com
@Steve
Thanks for your advice and information.

"Did you re-install the installer software?"

- No. Sorry I actually meant I have successfully installed the demo app 'HelloPurr' and it worked as it supposed to.
I just tried to restart everything again and again and suddenly it worked. Or is it because I have to wait the aiStarter to load for a while until it's ready to connect (which I really didn't do)?...

- In fact, I tried to install the app by opening the apk file before too. but whenever I reached the final stage where I could choose to click install or cancel, I found that there's always no response even I clicked to install, leaving me the only choice to cancel...

May

May Mei

unread,
Apr 18, 2015, 12:18:53 PM4/18/15
to mitappinv...@googlegroups.com
Oh no, it's not working again. :(

May Mei

unread,
Apr 18, 2015, 12:37:51 PM4/18/15
to mitappinv...@googlegroups.com
Hi Steve,
I kinda found out why now... I by chance closed the aiStarter window and unconsciously tried the connection by WIFI again and surprisingly it WORKED again!!

So, there must be something related to the aiStarter causing the failure in connection then? 
Well, I just hope you can give me some clues so that I don't need to try my luck anymore...

Thanks again! 




SteveJG

unread,
Apr 18, 2015, 3:08:12 PM4/18/15
to mitappinv...@googlegroups.com
I understand accidentally closing aiStarter.   Once aiStarter is closed, aiStarter has to be reopened.

Aa simple way is to reboot the computer, another is to go to the directory where aiStarter is located and right click on the aiStarter exe file (to ensure you run the program as Admin).
In a win7 64 bit PC., aiStarter is here:





 Does yuor Windows task bar show the Android icon when you start your computer?  The icon shows when aiStarter is set for automatic starting, which is what happens on most PCs.


I  know if you use USBconnection for a project and then attempt to use your device with WIFI in the same programming session that the WIFI connection will not work.  To allow the connection to work again,  close your browser and/or reboot your PC and start fresh.

Regards,
Steve


May Mei

unread,
Apr 19, 2015, 4:22:30 AM4/19/15
to mitappinv...@googlegroups.com
@Steve

What surprisingly happened to me last time is that I could connect with WIFI even while the aiStarter was closed (not running), which I really don't understand.

The aiStarter icon never automatically shows on my Windows task bar (I don't know how to make it automatic though) - I need to start it manually every time. By the way, I'm using Windows 8.1, 64 bit.

Still, I can connect with WIFI only by chance now and I haven't figured out the reason for this unstable performance.

Thanks again.

Mira

SteveJG

unread,
Apr 19, 2015, 8:13:13 AM4/19/15
to mitappinv...@googlegroups.com
@ May  If someone runs AI2 using WIFI, no additional software is required on the pc.  Companion is required on the device. " If you are using an Android device and you have a wireless internet connection, you can start building apps without downloading any software to your computer. You will need to install the App Inventor Companion App for your device."

"If you do not have an Android device, you'll need to install software on your computer so that you can use the on-screen Android emulator." 

"you do not have a wireless internet connection, you'll need to install software on your computer so that you can connect to your Android device over USB. 
To connect with USB, you need to first install the App Inventor setup software on your computer. (This is not required for the wifi method.)"

The downloaded software is required to use the emulator or USB.   aiStarter is not needed with WIFI.

If your app does not appear on your device, the most likely problems are:

  • You may have an outdated version of the App Inventor Companion App. Download the latest Companion App for App Inventor 2 from above.
  • Your device may not be connected to wifi. Make sure you see an IP address at the bottom of the AICompanion App screen on your phone or tablet. (your Android might have a weak WIFI connection), the connection might not be strong all the time, check the WIFI signal strength with the display on your phone/tablet perhaps?
  • Your device may not be connected to the same wifi network as your computer. Make sure both devices are connected to the same wifi network name.
  • Your school or organization may have network protocols in place such that the wifi connection is not allowed. If this is the case, you can still use App Inventor with the emulator or you can use a USB cable to connect your device. 

The following information might help:  The setup procedures using the old installer installs an Android icon to the task bar.  I have an 8.1 laptop, I have an icon on both my Win7 desktop and the laptop task bars installed using the installer.  This was done with the old installer.


 I just installed aiStarter on the 8.1 PC which now has Win10 preview on it.   I do not have the task bar icon there too. using the latest installer and have to revert to the desktop icon.  When you used the installer, did you check the box that asks if you want a Desktop icon?   I did not.  thinking the icon would be installed on the Task bar.   The Android icon did not, so it appears that the icon no longer installs automatically to the Task bar using the latest installer.  That surprised me .  

So, when you use WIFI, you should not start aiStarter, just   Connect > AI Companion.   When you use USB or the emulator, I believe you have to use the desktop icon to start aiStarter (perhaps with a right click?) then  Connect > Emulator    or  Connect > USB.

:)
--Steve


May Mei

unread,
Apr 20, 2015, 2:33:07 AM4/20/15
to mitappinv...@googlegroups.com
@Steve
Oh yes, that's the reason! - I used aiStarter whenever I connected over WIFI, which I shouldn't. I guess its just because I installed aiStarter at the very first place and then I kept running it without knowing that it's not needed at all...

Haha, I understand now. Thanks a lot, Steve. :)
Reply all
Reply to author
Forward
0 new messages