OTA upgrade explain (a)


A short step, a thousand miles;

Not small streams, into jianghai.

From Zi "Encouraging Learning"

 

 

 1. Explain the concept

OTA is the thing English interpreted as Over The Air, both OTA mean, specifically refers to the way wireless remote, OTA technology can be understood as a long-range wireless technology upgrade?;

FOTA: Firmware OverThe Air / air firmware upgrade for devices with networking capabilities through the cloud: such as mobile phones, tablet computers, mobile internet devices provide firmware upgrades, phone firmware upgrade can be called FOTA;

In 3G, 4G network popular today, often still have to consider traffic restrictions, if entered 5G era, although traffic is no longer a bottleneck, but because of the small but important feature of version upgrades compared to the overall firmware upgrade is still pretty good select.

2. Basics

Done for some time OTA upgrade, mainly based on the differential and total amount of upgrading Android, the plan of the current knowledge in doing sort of a summary of the system, before making a formal process to explain I'll start some of the original of the OTA packet structure, the structure of the target package in detail in this section are regarded as a foundation chapter, for understanding, behind the main digestion process to pave the way.

Packet structure

Production upgrade package having a certain format, it needs to generate the original package, the original package has a fixed format, the system works basically compiled by the following structure:

 

 

 Directory Description

 

 

 Upgrade package structure

 

 

 Directory Description

 

 Generation tool upgrade package

OTA used to generate the required difference subcontracted to use a python script, C source code compiled executable files, which are open source, as follows

 

 

 File functions

ota_from_target_files: a python script, do the package entrance from here to generate a package of major work is done here.

bsddiff: This executable file of the main users of calculating the difference uncompressed, for example, we calculate the difference rootfs file, you use this script.

imgdiff: This executable file of the main users of calculating the difference compression formats are supported * .gz, * zip, * apk, * jar, * img.....

fs_config: This executable file to calculate the primary user of the original file gid, uid, mode, but this way there is a downside, fs_config are hard-coded in fact, if we add a file, making it possible to add after, can not be its authority to add.

common.py: mainly defines some common functions, such as: an acquisition partition type, calculate the difference file, to generate patch files.

edify_generator.py: mainly generated content updater-script file, further comprising adding files to the upgrade package.

 These are the OTA upgrade to learn the basics, the next chapter I will explain in detail how to use two different basic package script generates a differential upgrade package, so stay tuned oh. . .

 

 

 Focus on micro-channel public number of embedded C [tribe] for more essence of the article, massive programming information, so that we progress together, grow together. 

 

Guess you like

Origin www.cnblogs.com/nuoyan/p/11777424.html