Difference between revisions of "IoTGateway/BSP/Android/Gettingstarted/Auto install APK"
From ESS-WIKI
Jerry.liao (talk | contribs) (Created page with "<span style="font-size:small;">The current platform can install Android application, apk file, automatically through the mass storage device.</span> <span style="font-si...") |
Jerry.liao (talk | contribs) |
||
Line 18: | Line 18: | ||
<span style="font-size:small;">If the apk named stability_test.apk that put into the root directory of mass storage device wanted to be installed.</span> | <span style="font-size:small;">If the apk named stability_test.apk that put into the root directory of mass storage device wanted to be installed.</span> | ||
− | <span style="font-size:small;">The content of the start_up.sh should be | + | <span style="font-size:small;">The content of the start_up.sh should be edited as follow</span> |
<pre>#!/system/bin/sh | <pre>#!/system/bin/sh | ||
UUID=`getprop sys.update.storage` | UUID=`getprop sys.update.storage` | ||
pm install /mnt/media_rw/$UUID/stability_test.apk</pre> | pm install /mnt/media_rw/$UUID/stability_test.apk</pre> |
Latest revision as of 08:25, 6 February 2017
The current platform can install Android application, apk file, automatically through the mass storage device.
1. System requirement
- A USB mass storage device with FAT32 filesystem
- The apk files that whated to be installed
2. How to trigger the apk auto installation
- put the apk files into the mass storage device
- create folder named startup containing a shell script file, start_up.sh.
- edit the shell script file, start_up.sh, with the apk installation commands
- instert the mass storage device
- wait few minutes and check the applcation list to confirm if the applications are completley installed
3. Example
If the apk named stability_test.apk that put into the root directory of mass storage device wanted to be installed.
The content of the start_up.sh should be edited as follow
#!/system/bin/sh UUID=`getprop sys.update.storage` pm install /mnt/media_rw/$UUID/stability_test.apk