User's Manual

EWB160031M User manual
Proprietary & Confidential Information Egis Technology Inc.
Doc. NO:
firmware documents that support OTA download, with the document generated by using download tool
named as “opl1000_ota.bin”. In order to understand the structure of OTA Image document, we need to
first understand the working process of OPL1000 OTA upgrade firmware. When OPL1000 firmware
supports OTA download for upgrade, there are two firmware maintained in Flash, as shown in Table 1,as
the first OTA Bin file and the second OTA Bin file are placed in 0x00005000 and 0x0003E000 locations
respectively, with the maximum size of 228K Bytes. At the locations of 0x00003000 and 0x00004000
there are Header message of the first and the second OTA bin. Header messages include the chip type,
version message, firmware calibration and firmware size and Header Calibration, etc., of OTA Bin
Firmware. The first OTA bin file and the second OTA bin use ping-pong switch method to execute
upgrade. For example, when the currently executing firmware corresponding to the first OTA Bin
document, then the firmware (and its Header message) downloaded through OTA download would be
placed in the second OTA Bin document location (firmware in 0x0003E000, and header in 0x00004000).
If the currently executing firmware corresponding to the second OTA Bin document, then the newly
downloaded upgrade firmware would be placed in the first OTA Bin document location (firmware in
0x00005000, and header in 0x00003000) .
Please note that there are two premises for OPL1000 firmware supporting OTA download that firstly,
being structured on opl1000_ota.bin, and the other being OTA Bin document supporting the function of
obtaining firmware through BLE or WIFI. Regarding user APP coding that supports OTA function,
download process is shown in Figure 3, as it includes two-time Pack combination functions. One is to
combine user APP bin document and M0 bin document as opl1000.bin. The second is to combine
opl1000.bin, OTA loader and the Header message of opl1000.bin, in forming opl1000_ota.bin document.
Figure 3: Coding of User APP & Patch, Loading Process (Supporting OTA Function)
9-2 SDK Environment Setup
When users develop APP, it is recommended to develop with the Keil uVision 5 IDE tool. This
chapter introduces the Keil uVision-based user APP project configuration method, and combines