0

I am trying to develop an application, which will check for firmware updates and will install updated firmware manually. Is it possible to get which modules of the firmware are added to update and the progress for updation?

Cœur
  • 37,241
  • 25
  • 195
  • 267
snehal_penurkar
  • 273
  • 1
  • 3
  • 15

1 Answers1

1

It should be possible. I am trying to do the same thing. I posted a question about this as another user. It almost works for me, but my device can't apply the new image on boot time.

Basically you use the RecoverySystem.installPackage(context, packageFile) method to do this. You will also need the following permissions:

<uses-permission android:name="android.permission.REBOOT" />
<uses-permission android:name="android.permission.ACCESS_CACHE_FILESYSTEM" />
<uses-permission android:name="android.permission.DELETE_CACHE_FILES" />

Also, your app must run as a system app. I don't know if you're using the whole Android SDK with Eclipse and the SDK tools, but what I did for that was basically connect my device to my machine and used it for debuggin, then ran the app through the IDE so it gets uploaded and run on the device. And finally use the adb shell command to open up a shell on my device and moved the apk package file from /data/app to /system/app and rebooted.

Check out my post here. It might help you out.

Android development RecoverySystem.installPackage() cannot write to /cache/recovery/command permission denied

Community
  • 1
  • 1
Santhi Bharath
  • 2,818
  • 3
  • 28
  • 42