TI Android DevKit Factory Reset Alternative Approach
- 1 What is Factory Reset in Android ? What is does ?
- 2 Why Factory Reset?
- 3 Feature Integration to TI Android DevKit
- 4 Feature Validation
- 5 What to do before Factory Reset?
- 6 Assumption and Further Scope
- 7 References
- 8 Technical Support and Product Updates
What is Factory Reset in Android ? What is does ?
- The feature "factory reset" - will erase all the data on android powered device. It will wipe all the data from the internal storage of the device and return it to the default factory settings. The data could be
- google account
- system and application data
- custom settings
- downloaded applications.
In addition, one can also choose to erase external storage (SD card). After the factory reset is complete; device will operate in the same way it did the first time one turned it on. One has to re-install all of data and applications back onto the device.
- On any android powered device factory reset feature is located in settings application. Traditionally it will be at "settings->backup & reset->factory data reset", but it may very device to device
Why Factory Reset?
Feature is useful in following conditions
- Malfunctioning device (resetting the device to original settings may fix numerous issues)
- Wipe personal data off before selling
- Returning it to manufacturer or retailer and want all personal data removed
Feature Integration to TI Android DevKit
- This wiki describes an alternative approach for implementing factory reset feature. Mentioned approach is quick to integrate, however it does stand for comparison for default or other available approaches that are exits. Every approach has its unique way of achieving desired actions.
- Also, this wiki does not hold any claim on comparison or complexity improvement of described approach over exiting solutions.
- To download source of factory reset service click here
/* go to <android-src>/external directory */ $cd <android-src>/external /* copy downloaded source to current directory */ $cp <download-location>/TI_Android_DevKit_Factory-Reset.tar.gz . /* untar downloaded source here */ $tar -xzvf TI_Android_DevKit_Factory-Reset.tar.gz
modify init.rc file
- To download required patch file click here
- Apply patch
/* go to user directory */ $cd <MY_DIR> /* extract downloader patch files */ $tar -xzvf Patch_init_rc_factoryreset.tar.gz /* go to device directory */ $cd <android-src>/device/ti/<platform> /* apply below patch to kernel */ $patch -pl < <MY_DIR>/init_rc-factory-reset-changes.patch
- Note : patch has been generated with respect to "<android-src>/device/ti/am335xevm/init.rc". If one has changed this file then patch will not gets applied out of box. It needs to be integrated manually
Build Android and Prepare Images
- After applying above patches, kindly do full build of android
- For the build procedure and preparing images refer to - DevKit developer guide
- Go to home->app launcher->settings
- Changes the settings like sound, display, language etc..
- Go to settings->backup & reset->factory data reset
- It will prompt the message & after clicking erase everything, it will restart the device
- On restart, factory-service what we have added, will erase required things to achieve factory-reset functionality.
What to do before Factory Reset?
Followings are the recommendation actions from user perspective before using this feature
- Backup any important files to PC or external storage
- Make sure contacts ( if exists) are synced with Gmail/Any other social account
- Make a log of apps one may want to reinstall after reset
Assumption and Further Scope
- Feature implementation assumed - /data & /cache – are the directories on emmc/mmc not the partitions.
- If vendor is using separate partitions for these locations, then one need to modified following :
factory-reset/factory-reset.c: function# erase_data For more details, kindly read comments mentioned for this function.
Technical Support and Product Updates
For further information or to report any problems, contact http://e2e.ti.com/android or http://support.ti.com.
For community support join http://groups.google.com/group/rowboat
For IRC #rowboat on irc.freenode.net
To raise any defect for this release please use http://code.google.com/p/rowboat/issues/list