I am in charge of testing a mobile-compliant website that also needs access to the device camera and microphone. I needed to expand the ability to test different Android devices, so I downloaded the Android SDK and created virtual devices. However, if I set the camera of any virtual device to "Webcam0" (to use my computer's webcam) and go to the url via the built in web browser, the entire emulator crashes immediately. macOS then generates the following report:
Process: qemu-system-x86_64 [1487]
Path: /Users/USER/Library/Android/*/qemu-system-x86_64
Identifier: qemu-system-x86_64
Version: 0
Code Type: X86-64 (Native)
Parent Process: studio [1288]
Responsible: studio [1288]
User ID: 673642719
Date/Time: 2020-04-29 11:50:56.314 -0400
OS Version: Mac OS X 10.15.4 (19E287)
Report Version: 12
Bridge OS Version: 4.4 (17P4281)
Anonymous UUID: B56B5142-EE7D-3D95-B70C-861201C1208B
Time Awake Since Boot: 2200 seconds
System Integrity Protection: enabled
Crashed Thread: 63 Dispatch queue: com.apple.root.default-qos
Exception Type: EXC_CRASH (SIGABRT)
Exception Codes: 0x0000000000000000, 0x0000000000000000
Exception Note: EXC_CORPSE_NOTIFY
Termination Reason: Namespace TCC, Code 0x0
The "Namespace TCC" points to a privacy issue. The new Catalina makes it v hard to access the camera (https://carlashley.com/2018/09/28/tcc-round-up/). I have googled how to work around the issue for Android development and the responses are something like the following:
If your app uses device cameras, include the NSCameraUsageDescription key in your app’s Info.plist file.
If your app uses device microphones, include the NSMicrophoneUsageDescription key in your app’s Info.plist file.
That's great for someone who is actually building a native Android App, but I just want to launch the Android emulator and use its default web browser to test a website.
Is it overkill to use Android Emulator for this purpose? In other words, can I simply go to Dev Tools in Chrome desktop and resize the browser to the target dimensions of whatever Android device I want to test?
And
If it were not overkill / I had to do it via the Emulator, how would I do it? My hunch is to build a custom Chromium apk with the NSCameraUsageDescription settings in Info.plist and put it into the emulator via instructions here: https://developers.google.com/web/t...er-browsers#chromium_content_shell_on_android but that would require pulling down Chromium and making a custom build.
Has anyone else gotten their android emulator web browser to access the webcam of on macOS Catalina? What were the steps?
I was running into a similar issue trying to access the Camera from the Android Emulator. What I ended up having to do was following the steps listed here to run the emulator manually through the command line:
https://developer.android.com/studio/run/emulator-commandline
Only addition is you'll have to run the command with the sudo permissions.
Related
I run "ionic cordova run android" using visual studio code.. but the apps shows white screen in the emulator.. it display properly if using USB debugging.. the device also display properly if install using the apk.. the reason why I want to use emulator because I want to debug "http://10.0.2.2".. this is my emulator setting..
Emulator setting
Things that I have done is as per below
Choose ANGLE (D3D11) for OpenGL ES Renderer at the emulator advance setting
Choose Software - GLES 2.0 graphic for the Emulated Performance during create emulator
Try both R and Q for the system image during create the virtual device
Update the SDK based on the system image set at the emulator
System image selection
Issue
I compile the source code at different laptop (Laptop A) and it manage to display error at the web console using google inspect
it display "newtrustedfunctionforjit fn.bind is not a function"..
Founding
the issue is related to the chrome version 83 and the browser need an upgrade to solve the issue
The emulator is not using a browser (it using web view) hence I cannot update the google version
Solution
download new skin for newer android model into laptop A
download same skin on the laptop B (the laptop that I initially come with this post)
Below is the explanation from GitHub for angular
Explanation about the chrome issue
Below is my new System Image
Release Name S
API Level 31
ABI x86_64
Target Android 12 (Google APIs)
New System Image
I have recently developed a Flutter application which works totally fine on all iPhone models and tested on Samsung and different android devices. However it gives either one of the following issue on some phones such as OnePlus, Xiomi Redmi etc.
Application won't install with error message "There was a problem in parsing the package"
If by chance the app gets installed on some Xiomi, OnePlus models, my user session which I have maintained through shared preferences does not persist. User is logged out when the app has been closed.
I am using following packages in my application:
list of packages
This error occurs mostly due to Android 12 and incorrect AndroidManifest.xml configuration if the phone i running SDK 31+ insure your app is configured for Android 12 if not try to set android:exported to any , ,, or components that have s declared in the app’s AndroidManifest.xml
Here is a blog on how to fix it
When trying to run my test app on a HVD emulator, I get the following error message:
App Launch: The Huawei Lite Simulator supports only Lite projects.
Meanwhile I've realized, that currently one can only use hardware or a remote emulator for such a project. But when trying to set this up, the Harmony OS Virtual Device Manager responds with 404:
Is there anything to do about it?
I haven't tried with DevEco Studio on Windows so far, but with Android Studio on Linux, which appears to be functioning now.
With HMS Toolkit version 1.0.5, it will ask for Huawei ID and then also lists devices in Düsseldorf or Ireland (where the one is a city and the other a country). However, there are currently only EMUI ROM available. It integrates better than before, but without an HarmonyOS 2.0 ROM, it still doesn't provide the expected environment.
I have just spent an hour reading through similar questions on Stack Overflow, and they are all for Android Studio, not Visual Studio Code. Also, I am doing Flutter development, so don't have access to adb commands, such as adb kill-server.
Everything was fine, unlike I clicked the power button on my emulated Android. Now, when I run/start debug and select active device, I get Failed to launch Nexus 5X API 29 x86: Error: Emulator didn't connect within 60 seconds.
How can I restart the emulated device? When it appears, clicking the power button does not seem to do anything. Is there a flutter terminal command?
Or can I somehow use a different emulator (if so, how)?
I faced the same issue with Android Virtual Device and Memu emulator so I switched to Genymotion.
I am using Genymotion personal edition which works amazingly and it's very light on resources too as compared to AVD and Memu.
You can download Genymotion Personal edition from Genymotion Personal Edition
Apart from Installing emulator Image you should also consider installing the GAPPS bundle in the emulator as it does not comes with it preinstalled. GAPPS will be needed in many apps requiring Google Play Services.
Here are the docs on how to install GAPPS in Genymotion emulator: GAAPS Docs
GAAPS Website
My Genymotion Emulator is Google Pixel 3a, 9.0 API 28.
Getting the following message when installing xamarin forms ios app in physical ios device.
NSLocalizedRecoverySuggestion=Please try rebooting and reconnecting the device. (0xE8000022)., NSLocalizedFailureReason=Please try rebooting and reconnecting the device. (0xE8000022).}
warning MT1043: Failed to launch the application using the instruments service. Will try launching the app using gdb service.
Launching 'appname' on the device 'iPhone'
warning HE0030: Could not mount developer tools on 'iPhone': Could not locate device support files.
warning HE0031: Failed to mount developer tools on 'iPhone'.
warning HE0030: Could not mount developer tools on 'iPhone': Could not locate device support files.
warning HE0031: Failed to mount developer tools on 'iPhone'.
error MT1007: Failed to launch the application 'appname' on the device 'My iPhone': Failed to launch the application 'apname 'My iPhone': Invalid Service Error (error: 0xe8000022). You can still launch the application manually by tapping on it.
I am using visual studio for mac version 7.7.3(build 43), iPhone 7(12.3.1) and xcode(Version 10.1 (10B61))
I have installed Xcode on mac, not iPhone, is Xcode need to install on iPhone for debugging the app?
I already found the same issue on here. Restarted iPhone, Mac and visual studio as per the solution on that thread, but that didn't help me.
Update to the latest Visual Studio for Mac version (2019) as well as XCode version.