I have an app installed on Android Things, in a Raspberry Pi. I want to replace with a newer version, but it's overwritten with previous version after a reboot. That's weird!
This is what I've tried: Let's say the installed app package name is "com.myapp", I've run "adb uninstall com.myapp", and I get "Success". If I run uninstall command again, I get "Failure [DELETE_FAILED_INTERNAL_ERROR]", so the app is completely uninstalled.
Then, I've modified package name in build.gradle to "com.mynewapp", and I install and run it using Run button from Android Studio. Now "com.mynewapp" appears when I run "adb shell pm list packages".
Now I restart the Pi using "adb shell reboot". And after reboot, the old app is running. Executing "adb shell pm list packages" shows my old package: "com.myapp", and "com.mynewapp" does not appear in the list.
How can I completely remove the old app, and replace with a new one?
Uninstall the app using:
adb uninstall <pkg name>
I tried deleting all SD contents, and flash latest Android Things image, and I realized SD card is corrupt. I replaced SD card, and it's working fine.
You can not uninstall the app which you packed in the OS image and flashed in the SD card using adb (returns the error which you encountered Failure [DELETE_FAILED_INTERNAL_ERROR]). Only you can uninstall the app which you installed using adb or android studio.That is why first time you are seeing success,which is uninstalling the overwritten version but next time as you are actually trying to uninstall the OEM version of your app so,you are seeing this error.
Just format and reflash the SD card with only Android things OS (without your app) then install your app using adb/android studio,now you will have only the uninstallable copy of your app in the sd card. So you can replace or do whatever you like with that app as like normal app downloaded from playstore.
Related
I'm not too familiar with mac and iOS but I need to downgrade xcode on a mac host for CI stuff (current app build is failing on xcode 12). I have access to the host via jumphost and I'm not sure if I can connect via VNC (I also don't like this since it's terribly slow) and most of the guides need a UI to download xcode. Any ideas on how to do this completely via terminal?
First of all download older version of Xcode, you will be need sign in to open the Downloads page.
Here is the Xcode releases page with downloads and release notes.
And install it.
After installing you can switch to the version you currently desire (for example 11.2 below) via terminal using a command like this:
sudo xcode-select -switch /Applications/Xcodex.11.2.app
I am trying to set up a react-native development environment. I would like to set up an iOS emulator (preferably an iPhone 10) to run my app on. I am using a Macbook Pro 2016 running on MacOS 10.14.3. I have installed my react-native app through the command create-react-native-app (running version 2.0.2). I also have installed XCode running version 10.2(10E125). When I scan the QR code that Expo generates and run it on my iPad or my Android device it works just fine, but when I try to load the iOS emulator by pressing i after expo start it returns the error
Trying to open the project in iOS simulator...
Simulator is installed but is identified as 'com.apple.CoreSimulator.SimulatorTrampoline'; don't know what that is.
Simulator not installed. Please visit https://developer.apple.com/xcode/download/ to download Xcode and the iOS simulator. If you already have the latest version of Xcode installed, you may have to run the command `sudo xcode-select -s /Applications/Xcode.app`
I have already tried running the command sudo xcode-select -s /Applications/Xcode.app
I have also tried running the command xcode-select -r
I have also confirmed that in my XCode->Preferences->Locations Command Line Tools is selected as "Xcode 10.2(10E125)"
None of these have worked.
I am expecting that after pressing i after expo start an iOS emulator loads up. Thank you.
-----EDIT-------
After some more research, I found out that running open -a Simulator and then running expo start loads the app on an emulator and works for my purposes. But still if I just run expo start without running open -a Simulator it still gives the same error. I want to ask if this is the best I am going to get?
You might be running an outdated version of Expo. I had this problem when I was download someone's old repo using Expo 27 when Expo 36 came out. After updating to the latest version, it works.
To update packages in your project, npm-check-updates comes in handy.
npm i -g npm-check-updates # installs ncu globally
ncu -u # updates all dependency versions in your local package.json
npm install # updates the packages in node_modules to match
Note: This will update all your dependencies to the latest version. If you don't want to do this, you can find the latest version of expo and change the version in package.json manually.
I ran into the exact same problem all of a sudden. Clicking "Run on iOS Simulator" within the Expo Developer Browser worked 2 days ago but did not work today. Your clue of using open -a Simulator helped me though. I went into Xcode and clicked the Xcode menu > Open Developer Tool > Simulator. This started the Simulator and then I was able to click "Run on iOS Simulator" within the Expo Developer Browser and it worked as expected. If you haven't had the fortune of "Run on iOS Simulator" working, I'm guessing you could just start a simulator, download Expo from the App Store and just use it from there. None of this answers the question as to why the error happens but at least gives a few workarounds for anyone else that might need. All that matters is you get the app running on the Simulator in the end!
I'm tryin' to debug my app on iOS simulator in my Mac.
I've followed all the instructions installing on my Mac:
sudo npm install -g vs-mda-remote
sudo npm install -g ios-sim
When I prompted
vs-mda-remote --buildDir Projects
(Projects is the folder where debug files will be droped), I see results in my PC by
http://<MAc_IP>:3000
With the following text
Remote build Express server open for business on port 3000
Ok, now I prompted
vs-mda-remote test
And I see an error with the following message
Failed to build app: CordovaError: Platform ios already added
I don't know what happen.
Ok, I found the problem. Maybe, I'm too eagier.
Instead of using one session in terminal app on mac, I used too many, so, when I prompted too many timesvs-mda-remote, obviously ios was already installed.
So, opening terminal at first time, and prompting
vs-mda-remote --buildDir Projects --allowsEmulate=true
Now, I can debug on iOS simulator from my PC to Mac.
While running the build agent, the correct command is:
vs-mda-remote --buildDir <server-build-directory> --allowsEmulate=true
Note the last "--allowsEmulate=true" part of the command.
*Taken from "Setting up the Remote Agent to Support Starting the iOS Simulator" section in the documentation.
Platform ios already installed
Received this error for running in device too, while running multiple instance in mac.
Quit Terminal and run single instance for vs-mda-remote to resolve this problem if you receive this error for running in Device.
My iOS emulator is no longer opening when I run "phonegap run ios" in the terminal on Mac OS X. I receive no error messages and:
[phonegap] Platform "ios" deployed to emulator.
[phonegap] successfully installed onto emulator
While this is currently a known bug, you can run the emulate command more directly (note you need to build separately):
phonegap local build ios
/platforms/ios/cordova/emulate
You can also run the application using the same technique:
phonegap local build ios
/platforms/ios/cordova/run
NOTE: When using this method to run the app on your phone, the task might get stuck on the splash screen. To fix this, launch the Activity Monitor on your Mac and quit any processes with the name "ios-deploy". From there you can launch the application on your phone by clicking the application icon.
Or, you can even look inside the generated /platforms/ios folder and launch XCode project directly to test in an emulator or on your device. Open project and click the RUN button.
IMPORTANT: with all of the above methods, you MUST run the build command before running:
phonegap local build ios
Not really an answer, but I can say this is a known bug. Here is the bug so you can track it:
https://issues.apache.org/jira/browse/CB-5103
I only had this problem after upgrading to 3.1. I downgraded to 3.0 and it works more reliably:
npm uninstall -g phonegap
npm install -g phonegap#3.0
Also had to delete the platform/ios dir and plugins/ios.json and then run 'phonegap build ios' and 'phonegap run ios'
I run the drvupdate-64 installer which runs until it closes and I get a notification in the tray icon that '"not supported bluetooth function"' was successfully installed as a driver.
I found that a bit weird and after that NOTHING happens with the installer, it just dissapers and doesn't come back.
In task manager I can see it running as 'driver_setup.exe' with the description 'windows mobile device center setup' but that's it, nothing else seems to be happening.
Any ideas what's going wrong and how I can fix this? I need it to get the windows mobile sdk to install.
I had to navigate to the install directory of WMDC Driver Update and find the installer to continue the process, the installer was bugging out on me and not proceeding to the next step for some reason...
I had a similar issue when installing on Dell laptops models 7480, 7280. I had tried updating removing device drivers as per Microsoft Answers with no success.
Having come across the above I did continue the installer process as per tweetypi comment but still had issues. I was able to install and get this working as per following steps:
After running the WMDC installer I could see that in task manager the install process "driver_setup.exe" was still running.
As per tweetypi answers I then navigated to the install directory for WMDC Driver Update to find the installer and continue the process:
C:\Windows\WindowsMobile
I opened each Drivers folder (Bluetooth, RNDIS, Serial) in turn and run the “wmupdate” installer.
Windows Mobile Device Centre was then listed on my programs list but would not launch.
I then opened Device Manager from Control Panel. Changed view to show hidden devices. This revealed 'Bluetooth Virtual Devices' > 'Not Supported Bluetooth function'.
I then uninstalled this driver and checked delete the driver software for this device
After this, I ended the “driver_setup.exe” process within task manager. Then run the “driver_setup.exe” install file once more. The install process was then able to complete and the Windows Mobile Device Centre was now launching.
The device I needed to connect was for USB, I'm not sure about functionality for Bluetooth after removing the virtual device.