Multiple emulators

How can I deploy more than 1 emulator to test my app from MIT app inventor? Actually, my app is required two devices to show a proper response, it is a texting-based app and I want to test its feature.

Simple answer, you cannot.

You should compile your app and test on two different devices, or compile the app for one device and use the emulator for the other

1 Like

@TIMAI2 I was surfing on YouTube and I have seen a video in which a user was has initialized 2 emulators but the video was of 2013 and I guess it was possible in MIT app inventor 1.0 and not possible now. What do you say?

There is always a way. If you have two separate accounts with AI2 and two computers (just to help avoid confusion), you can probably do this.

But he was using the same PC, I am trying to find the video again but not getting what I am searching fro. Anyways, I can build the .apk file and run it on two emulators on same PC but how will I send message from 1 to another? any ideas? My problem is that I do not have any android cell phone, I am iOS user.

The video should be in your youtube History....

If this is your solution, then try it.

Hello Muhammad

What I would do is compile my APK, upload it to Google Drive (or send it via a free service such as WeTransfer) and get my friends to test it for me. Perhaps with everyone on a Zoom or Skype meeting.

Actually, you can do this if you have Android Studio installed. I use it for testing the Texting component. It requires a bit of a dance but here is what you can do:

  1. Create two Android Virtual Devices (AVDs) in Android Studio. Use the x86_64 image if you're on an x86_64 architecture or arm64 if on an ARM device.
  2. Launch the two emulators and drag the App Inventor companion app APK onto the emulator window to install the app.
  3. Note that the two emulators run on different ports. The first one will be port 5554 and the second will be 5556. You will want to stop the one that is 5554.
  4. Use the Connect > Emulator option in App Inventor to establish a connection to the second emulator.
  5. Once the app shows in the emulator, reload the App Inventor window to get a fresh session.
  6. Start the first emulator (5554) again.
  7. Use the Connect > Emulator option in App Inventor to establish a connection to the first emulator.
  8. Send messages between the two emulators using their port numbers as the phone numbers (5554 and 5556 for emulator 1 and 2, respectively).
4 Likes

...you forgot one thing Evan - very large cup of coffee required. :slightly_smiling_face:

2 Likes

That's usually a given for me. But also when we're doing development builds we have a bunch of extra patches that skip all the waiting since we know how fast our machines are.

(added to new Usage section of FAQ)

If you are using MemuPlay or Nox, there are options to run multiple emulators at the same time, and there are setup options to simulate a phone service. (I did not have a need to follow up those leads any further, since I was concentrating on figuring out why my emulators all stopped loading at 99%. (It turned out to be Avast trying to monitor my virtual environments.))

2 Likes

Thanks for a very detailed answer, I think it will solve my problem. :smiley: :+1:

Yes I am using Memu emulator