I am trying to launch the emulator after building the Android source.
Right now, the setup is like, I am running a windows machine connecting through putty to my linux machine. I have downloaded my source in the linux machine and I have successfully built it.
When I am running the emulator using the command in
https://stackoverflow.com/a/9023141/539472
the emulator is launching but only the android image is coming. From there on the emulator is not completely booting. Its not going to launcher.
The logs are
emulator: WARNING: Could not initialize OpenglES emulation, using software renderer.
Failed to create Context 0x3005
There are many posts with this error, they say that check if the graphics driver is installed. I have checked it and its installed.
What might be the problem ?
Putty is just terminal console, it has no graphics/windows it cant possibly display emulator. Emulator is application like Browser or GEdit. If you login to you linux machine directly using Ubuntu then it can show emulator application.
Related
I am running the Opencv 4.4.0 in a Ubuntu 20.04 AWS-Ec2 instance connected with VSCODE trough the Remote Explorer module.
I am trying to open an image that I have uploaded to the project.
import cv2
img = cv2.imread("imgs/cat1.jpg")
cv2.imshow("Output", img)
But when I run the file (pressing the green arrow) I get the follow error:
(env) ubuntu#ip-xxx-xx-xx-xxx:~/vhosts/opencv-ml-images$ /bin/python3 /home/ubuntu/vhosts/opencv-ml-images/chapter1.py
qt.qpa.xcb: could not connect to display
qt.qpa.plugin: Could not load the Qt platform plugin "xcb" in "/home/ubuntu/.local/lib/python3.8/site-packages/cv2/qt/plugins" even though it was found.
This application failed to start because no Qt platform plugin could be initialized. Reinstalling the application may fix this problem.
Available platform plugins are: xcb.
Aborted (core dumped)
Does someone knows what is happening? maybe something related to the fact I am running the opencv in a remote computer? How to sove it?
I think what you are trying to do is run it on Remote Desktop Connection. I was having the same problem but I am running WSL 2 (Both are quite similar). And I solved it by setting up environment for GUI applications on WSL 2 from https://wiki.ubuntu.com/WSL . Just start your X server and run the code again. It should work. If not, do reply so that we can sort it out together.
After doing a Google search for running a Gnome desktop or just desktop (found Xfce4 info...) on a cloud instance, I found some guides at Digital Ocean, for example:
Install and Configure VNC on Ubuntu 20.04LTS
The problem is, that doesn't help me set up a desktop that can run Visual Studio Code or other apps. vscode fails to run, and so does the Atom text editor. They seem to need something like the Gnome Desktop to run, which I can't start using the information in that link. I can't just replace xfce4 with gnome-session and get it to work.
Am I missing something? I have installed gnome desktop and vnc server.
I hadn't installed all the packages I needed. Some were missing in the various guides I read.
So I went here:
Installing and configuring Ubuntu Desktop for Google Cloud Platform
... and it worked perfectly.
I have a Samsung Galaxy S8 and whenever I try to debug an app in Android Studio the app crashes and disconnects the phone from the PC.
I don't know if it's the drivers for the phone that I need to re-install or if there is a bug in the operating system or maybe something else.
I'm running Android Studio 3.1 under Linux Mint 18.3 Sylvia edition, and I'm running KDE.
Yes, there is a driver for Linux. You can get it from here:
https://dl.google.com/android/repository/platform-tools-latest-linux.zip
try following these steps to set it up correctly (I have it from https://www.xda-developers.com/install-adb-windows-macos-linux/)
Extract the ZIP to an easily-accessible location (like the Desktop for example).
Open a Terminal window.
Enter the following command: cd /path/to/extracted/folder/
This will change the directory to where you extracted the ADB files.
So for example:cd /Users/Doug/Desktop/platform-tools/
Connect your device to your Linux machine with your USB cable. Change the connection mode to “file transfer (MTP)” mode. This is not always necessary for every device, but it’s recommended so you don’t run into any issues.
Once the Terminal is in the same folder your ADB tools are in, you can execute the following command to launch the ADB daemon: adb devices
Back on your smartphone or tablet device, you’ll see a prompt asking you to allow USB debugging. Go ahead and grant it.install adb
Finally, re-enter the command from step #7. If everything was successful, you should now see your device’s serial number in the Terminal window output.
i have install all prerequisite for cordova project in my system.
installed software like below.
1)node.js
2)cordova
3)phonegap
4)npm
5)jdk
6)jre
7)android - sdk
error image here error like in image.
when i have run 'cordova run android' in my project directory using CLI
then error/output like in attached image.
i have already set path in environment variables.
please suggest some solution.
This command is for running the app on an actual device. Have you set up the device and enabled USB debugging?
From the docs:
Alternately, you can plug the handset into your computer and test the
app directly:
$ cordova run android
Before running this command, you need to set up the device for testing, following procedures that vary for each
platform. In Android and Amazon Fire OS devices, you would have to
enable a USB debugging option on the device, and perhaps add a USB
driver depending on your development environmnent. See Platform Guides
for details on each platform's requirements.
If you want to run the app in an emulator instead you should use:
$ cordova emulate android
Read all about it at: https://cordova.apache.org/docs/en/5.1.1/guide/cli/index.html
When I start the emulator, the "phone" shows only a black screen. Nothing more happens. No loading, no pixels, no application nothing. Just a black screen.
Based on other forums i tried:
restart several times
install mesagl
install more c++ libs
start emulator without android studio
enable or disable "Use host gpu" option
limit emulator ram to 768mbyte
delete and recreate virtual device with several other api and abi
reinstall nvidia closed driver
Non of these helped.
Any other suggestions?