Skip to content
Tarek edited this page Jun 21, 2015 · 10 revisions

Prerequisites

Inception automates all the manual work that you'd do on a device to set it up, however, you still need to do some homework first. Inception needs to know some information about the target device in order to achieve the best results (and correct ones). You can find most of this information online, or even easier:


The automated way

If you have a rooted device or if your device runs a custom recovery, use incept learn or incept bootstrap to retrieve almost all the required information

incept learn -v inception.device.mydevice
incept bootstrap --base inception.device --variant mydevice --learn-settings --learn-props --learn-imgs --learn-partitions

if not, then continue reading...


For generating an update package

update.settings

If you are generating key-val settings databases, for each database you must find:

  • Database schema
  • Database version

from the target device. For example the following database, which is the main device settings database:

{
    "update": {
        "settings": {
            "com.android.providers.settings": {
                "path": "/data/data/com.android.providers.settings/databases/settings.db",
                "schema": null,
                "version": "98"
            }
        }
    }
}

You must fill the schema and version with the correct data. To do so, connect your (rooted/ in custom recovery mode) device and:

adb shell mount /data
adb pull /data/data/com.android.providers.settings/databases/settings.db
sqlite3 settings.db .schema
sqlite3 settings.db "pragma user_version"

An even easier method is through using incept learn

For generating Cache IMG

Inception can generate a cache partition img which will contain the following:

  • The generated update.zip
  • Instructions for android to install this update once it boots into recovery mode.

You can then flash this IMG to your device. To able to generate this Cache img, inceptions needs the following info:

{
    "cache": {
        "__make__": true, 
        "sparsed": true/false
    }
}

At the moment of writing this, I'm unaware of any bootloader that supports a sparsed img except Samsung. Therefore it's enabled by default in samsung.common.

To get the size:

@@TODO

For installing the update package

An OTA update package is installed in recovery mode. However, stock recovery will not accept an update package that was not signed by the platform keys. Therefore, a custom recovery, or the recovery that inception generates, must be used

The update package inception generates can be installed in several ways.

Through recovery

Boot your device into recovery mode and activate installation through ADB sideload from the recovery menu. Then

adb sideload update.zip

Alternatively, place the update.zip on your sdcard and choose "Install update from SD Card"

Through bootloader

Samsung Devices

Use Heimdall or Odin

Fastboot Devices

@@TODO

Rockchip Devices

@@TODO

To have inception generate odin packages, set update.odin.make to true:

{
    "update": {
        "odin": {
            "__make__": true
        }
    }
}

For fully automated update package installation

You can achieve fully automated installation, that is, you unbox a new device, power it on, connect it via usb and run one command on your computer and you're good to go.

For this to work you need to generate:

@@TODO