title: Android Studio can't run AVD... times out
body: <p>Just got a new M1 Mac Mini and I have been having trouble running my Android projects.</p>
  <p>I'm using Android Studio (Bumblebee), JDK 11 (tried 17 as well), and Gradle 7.3.</p>
  <p>When I try to run the project from AS, it builds fine and then gets stuck on &quot;Waiting for target device to come online&quot; and eventually times out.</p>
  <p><a href="https://i.stack.imgur.com/bL0bP.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/bL0bP.png" alt="Android Studio" /></a></p>
  <p>If I try to run the emulator again I get a message that the device is already running, including a path to a lock file.</p>
  <p><a href="https://i.stack.imgur.com/xcKzR.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/xcKzR.png" alt="AS Error Message" /></a></p>
  <p>However, I've found that if I run the emulator manually from the CLI, the emulator <em>does</em> open, at which point I <em>can</em> get AS to run the app on said emulator. So the problem is apparently just that AS can't <em>open</em> the AVD.</p>
  <p>Command line output when running emulator via <code>adelphia$ emulator -avd Pixel_3a_API_32_arm64-v8a</code>:</p>
  <pre><code>adelphia$ emulator -avd Pixel_3a_API_32_arm64-v8a
  INFO    | Android emulator version 31.2.6.0 (build_id 8100890) (CL:N/A)
  WARNING | unexpected system image feature string, emulator might not function correctly, please try updating the emulator.
  INFO    | Warning: QMetaObject::connectSlotsByName: No matching signal for on_new_posture_requested(int) ((null):0, (null))
  INFO    | Warning: QMetaObject::connectSlotsByName: No matching signal for on_dismiss_posture_selection_dialog() ((null):0, (null))
  INFO    | Warning: QMetaObject::connectSlotsByName: No matching signal for on_new_resizable_requested(PresetEmulatorSizeType) ((null):0, (null))
  INFO    | Warning: QMetaObject::connectSlotsByName: No matching signal for on_dismiss_resizable_dialog() ((null):0, (null))
  WARNING | cannot add library /Users/adelphia/Library/Android/sdk/emulator/qemu/darwin-aarch64/lib64/vulkan/libvulkan.dylib: failed
  INFO    | added library /Users/adelphia/Library/Android/sdk/emulator/lib64/vulkan/libvulkan.dylib
  INFO    | configAndStartRenderer: setting vsync to 60 hz
  INFO    | Sending adb public key [QAAAAG8XVkhVwEAAQA....= adelphia@unknown]
  INFO    | Rootcanal has  been activated.
  Could not initialize record - Unknown Audiodevice
  Could not initialize record - Unknown Audiodevice
  Failed to create voice `goldfish_audio_in'
  qemu-system-aarch64: warning: opening audio input failed
  INFO    | Started GRPC server at 127.0.0.1:8556, security: Local
  INFO    | Advertising in: /Users/adelphia/Library/Caches/TemporaryItems/avd/running/pid_1469.ini
  Could not initialize record - Unknown Audiodevice
  Could not initialize record - Unknown Audiodevice
  Failed to create voice `adc'
  Could not initialize record - Unknown Audiodevice
  Could not initialize record - Unknown Audiodevice
  Failed to create voice `adc'
  </code></pre>
  <p>If it's relevant, here's my <code>.bash_profile</code> (changed back to bash)</p>
  <pre><code>export PATH=&quot;/opt/homebrew/bin:$PATH&quot;
  export PATH=&quot;/opt/homebrew/sbin:$PATH&quot;
  export PATH=&quot;/Users/adelphia/Scripts:$PATH&quot;
  
  export NVM_DIR=~/.nvm
  source $(brew --prefix nvm)/nvm.sh
  
  export ANDROID_HOME=~/Library/Android/sdk
  export ANDROID_SDK_ROOT=~/Library/Android/sdk
  export PATH=${PATH}:${ANDROID_HOME}/emulator
  export PATH=${PATH}:${ANDROID_HOME}/tools
  export PATH=${PATH}:${ANDROID_HOME}/platform-tools
  export JAVA_HOME=/Library/Java/JavaVirtualMachines/jdk-11.0.14.jdk/Contents/Home
  </code></pre>
  <p>So, how do I get AS to be able to open the emulator from the GUI?</p>