This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

LPSTK-CC1352R: Uniflash & jlink issues

Part Number: LPSTK-CC1352R
Other Parts Discussed in Thread: UNIFLASH, SEGGER, CC1352R

Setup:

SDK:                 simplelink_cc13x2_26x2_sdk_5_10_00_48
Compiler:          CCS Compiler
Uniflash:           6.3.0.3193
Programmer:    TI CC1352R LAUNCHXL and Segger
Devices:           Two CC1352R LPSTK revision E
Bootlaoder:       bim_offchip_CC1352R1_LAUNCHXL_nortos_ccs
Application:       simple_peripheral_oad_offchip_CC13X2R1_LAUNCHXL_tirtos_ccs

Hi Experts,

I am facing some issues while flashing binary with both Uniflash and Jlink.

Without any modification, I built bim_offchip bootloader and simple_peripheral_oad_offchip examples.

Test 1:
With Uniflash, if I sequentially flash the bootloader (*.hex) and then the simple_peripheral_oad_offchip (*.out).
[Works as intended] After the program load, the device reboots by itself, and launches the simple_peripheral_oad_offchip firmware without any manual action.

6/10/2021, 11:01:19 AM] [INFO] Cortex_M3_0: GEL Output: Memory Map Initialization Complete.
[6/10/2021, 11:01:24 AM] [INFO] Cortex_M4_0: GEL Output: Memory Map Initialization Complete.
[6/10/2021, 11:01:24 AM] [INFO] Cortex_M4_0: Flashloader: Verbose output enabled.
[6/10/2021, 11:01:26 AM] [INFO] Cortex_M4_0: GEL Output: Memory Map Initialization Complete.
[6/10/2021, 11:01:26 AM] [INFO] Cortex_M4_0: GEL Output: Board Reset Complete.
[6/10/2021, 11:01:26 AM] [INFO] Cortex_M4_0: Writing Flash @ Address 0x00056000 of Length 0x00001138
[6/10/2021, 11:01:26 AM] [INFO] Cortex_M4_0: Performing bank erase
[6/10/2021, 11:01:26 AM] [INFO] Cortex_M4_0: Loading flashloader to target: FlashLoaderCC26x2.out
[6/10/2021, 11:01:27 AM] [INFO] Cortex_M4_0: Chunk 1: addr=0x00056000, length=4408, crc=0x738EB07D (using block 1)
[6/10/2021, 11:01:27 AM] [INFO] Cortex_M4_0: Writing Flash @ Address 0x00057fa8 of Length 0x00000058
[6/10/2021, 11:01:27 AM] [INFO] Cortex_M4_0: Chunk 1: addr=0x00057FA8, length=88, crc=0xB0D43234 (using block 0)
[6/10/2021, 11:01:28 AM] [SUCCESS] Program Load completed successfully.
[6/10/2021, 11:01:48 AM] [INFO] Cortex_M3_0: GEL Output: Memory Map Initialization Complete.
[6/10/2021, 11:01:53 AM] [INFO] Cortex_M4_0: GEL Output: Memory Map Initialization Complete.
[6/10/2021, 11:01:53 AM] [INFO] Cortex_M4_0: Flashloader: Verbose output enabled.
[6/10/2021, 11:01:55 AM] [INFO] Cortex_M4_0: GEL Output: Memory Map Initialization Complete.
[6/10/2021, 11:01:55 AM] [INFO] Cortex_M4_0: GEL Output: Board Reset Complete.
[6/10/2021, 11:01:55 AM] [INFO] Cortex_M4_0: Writing Flash @ Address 0x00000000 of Length 0x00007ff0
[6/10/2021, 11:01:55 AM] [INFO] Cortex_M4_0: Loading flashloader to target: FlashLoaderCC26x2.out
[6/10/2021, 11:01:55 AM] [INFO] Cortex_M4_0: Chunk 1: addr=0x00000000, length=8192, crc=0x0BC95FEA (using block 0)
[6/10/2021, 11:01:56 AM] [INFO] Cortex_M4_0: Chunk 2: addr=0x00002000, length=8192, crc=0x02DA14AB (using block 1)
[6/10/2021, 11:01:56 AM] [INFO] Cortex_M4_0: Chunk 3: addr=0x00004000, length=8192, crc=0x242B801E (using block 0)
[6/10/2021, 11:01:56 AM] [INFO] Cortex_M4_0: Chunk 4: addr=0x00006000, length=8176, crc=0x11143C29 (using block 1)
[6/10/2021, 11:01:56 AM] [INFO] Cortex_M4_0: Writing Flash @ Address 0x00007ff0 of Length 0x00007ff0
[6/10/2021, 11:01:56 AM] [INFO] Cortex_M4_0: Chunk 1: addr=0x00007FF0, length=8192, crc=0x69B4779B (using block 0)
[6/10/2021, 11:01:57 AM] [INFO] Cortex_M4_0: Chunk 2: addr=0x00009FF0, length=8192, crc=0x03D704E9 (using block 1)
[6/10/2021, 11:01:57 AM] [INFO] Cortex_M4_0: Chunk 3: addr=0x0000BFF0, length=8192, crc=0xF1889C83 (using block 0)
[6/10/2021, 11:01:57 AM] [INFO] Cortex_M4_0: Chunk 4: addr=0x0000DFF0, length=8176, crc=0x5F427E11 (using block 1)
[6/10/2021, 11:01:57 AM] [INFO] Cortex_M4_0: Writing Flash @ Address 0x0000ffe0 of Length 0x00007ff0
[6/10/2021, 11:01:57 AM] [INFO] Cortex_M4_0: Chunk 1: addr=0x0000FFE0, length=8192, crc=0xB4CAB77D (using block 0)
[6/10/2021, 11:01:58 AM] [INFO] Cortex_M4_0: Chunk 2: addr=0x00011FE0, length=8192, crc=0xB4E60C97 (using block 1)
[6/10/2021, 11:01:58 AM] [INFO] Cortex_M4_0: Chunk 3: addr=0x00013FE0, length=8192, crc=0xAE6347E2 (using block 0)
[6/10/2021, 11:01:58 AM] [INFO] Cortex_M4_0: Chunk 4: addr=0x00015FE0, length=8176, crc=0x05A6EA1F (using block 1)
[6/10/2021, 11:01:58 AM] [INFO] Cortex_M4_0: Writing Flash @ Address 0x00017fd0 of Length 0x00006630
[6/10/2021, 11:01:58 AM] [INFO] Cortex_M4_0: Chunk 1: addr=0x00017FD0, length=8192, crc=0x7EB8797F (using block 0)
[6/10/2021, 11:01:58 AM] [INFO] Cortex_M4_0: Chunk 2: addr=0x00019FD0, length=8192, crc=0x731E740C (using block 1)
[6/10/2021, 11:01:59 AM] [INFO] Cortex_M4_0: Chunk 3: addr=0x0001BFD0, length=8192, crc=0xFB155709 (using block 0)
[6/10/2021, 11:01:59 AM] [INFO] Cortex_M4_0: Chunk 4: addr=0x0001DFD0, length=1584, crc=0xB8CDB500 (using block 1)
[6/10/2021, 11:02:00 AM] [SUCCESS] Program Load completed successfully.

Test 2:
With Uniflash, if I sequentially flash the bootloader (*.hex) and then the simple_peripheral_oad_offchip (*.hex):
[Does not work as intended] After the program load, the device does not reboot automatically.

  • After the 1st power cycle: nothing happen.
  • After the 2nd power cycle: the recovery image Multi-Sensor is launching instead of the application.

6/10/2021, 11:07:52 AM] [INFO] Cortex_M3_0: GEL Output: Memory Map Initialization Complete.
[6/10/2021, 11:07:57 AM] [INFO] Cortex_M4_0: GEL Output: Memory Map Initialization Complete.
[6/10/2021, 11:07:57 AM] [INFO] Cortex_M4_0: Flashloader: Verbose output enabled.
[6/10/2021, 11:07:59 AM] [INFO] Cortex_M4_0: GEL Output: Memory Map Initialization Complete.
[6/10/2021, 11:07:59 AM] [INFO] Cortex_M4_0: GEL Output: Board Reset Complete.
[6/10/2021, 11:07:59 AM] [INFO] Cortex_M4_0: Writing Flash @ Address 0x00056000 of Length 0x00001138
[6/10/2021, 11:07:59 AM] [INFO] Cortex_M4_0: Performing bank erase
[6/10/2021, 11:07:59 AM] [INFO] Cortex_M4_0: Loading flashloader to target: FlashLoaderCC26x2.out
[6/10/2021, 11:07:59 AM] [INFO] Cortex_M4_0: Chunk 1: addr=0x00056000, length=4408, crc=0x738EB07D (using block 1)
[6/10/2021, 11:07:59 AM] [INFO] Cortex_M4_0: Writing Flash @ Address 0x00057fa8 of Length 0x00000058
[6/10/2021, 11:07:59 AM] [INFO] Cortex_M4_0: Chunk 1: addr=0x00057FA8, length=88, crc=0xB0D43234 (using block 0)
[6/10/2021, 11:08:00 AM] [SUCCESS] Program Load completed successfully.
[6/10/2021, 11:08:13 AM] [INFO] Cortex_M3_0: GEL Output: Memory Map Initialization Complete.
[6/10/2021, 11:08:18 AM] [INFO] Cortex_M4_0: GEL Output: Memory Map Initialization Complete.
[6/10/2021, 11:08:18 AM] [INFO] Cortex_M4_0: Flashloader: Verbose output enabled.
[6/10/2021, 11:08:20 AM] [INFO] Cortex_M4_0: GEL Output: Memory Map Initialization Complete.
[6/10/2021, 11:08:20 AM] [INFO] Cortex_M4_0: GEL Output: Board Reset Complete.
[6/10/2021, 11:08:22 AM] [INFO] Cortex_M4_0: Writing Flash @ Address 0x00000000 of Length 0x0000008d
[6/10/2021, 11:08:22 AM] [INFO] Cortex_M4_0: Loading flashloader to target: FlashLoaderCC26x2.out
[6/10/2021, 11:08:22 AM] [INFO] Cortex_M4_0: Chunk 1: addr=0x00000000, length=141, crc=0xD3F58142 (using block 0)
[6/10/2021, 11:08:22 AM] [INFO] Cortex_M4_0: Writing Flash @ Address 0x00000090 of Length 0x0000003c
[6/10/2021, 11:08:22 AM] [INFO] Cortex_M4_0: Chunk 1: addr=0x00000090, length=60, crc=0xCA5AED48 (using block 1)
[6/10/2021, 11:08:22 AM] [INFO] Cortex_M4_0: Writing Flash @ Address 0x000000d0 of Length 0x00007ff0
[6/10/2021, 11:08:22 AM] [INFO] Cortex_M4_0: Chunk 1: addr=0x000000D0, length=8192, crc=0x9CF69E46 (using block 0)
[6/10/2021, 11:08:23 AM] [INFO] Cortex_M4_0: Chunk 2: addr=0x000020D0, length=8192, crc=0xBCFE35F8 (using block 1)
[6/10/2021, 11:08:23 AM] [INFO] Cortex_M4_0: Chunk 3: addr=0x000040D0, length=8192, crc=0x6E83A2F6 (using block 0)
[6/10/2021, 11:08:23 AM] [INFO] Cortex_M4_0: Chunk 4: addr=0x000060D0, length=8176, crc=0x2BA9892E (using block 1)
[6/10/2021, 11:08:23 AM] [INFO] Cortex_M4_0: Writing Flash @ Address 0x000080c0 of Length 0x00007ff0
[6/10/2021, 11:08:24 AM] [INFO] Cortex_M4_0: Chunk 1: addr=0x000080C0, length=8192, crc=0x76FFD0FF (using block 0)
[6/10/2021, 11:08:24 AM] [INFO] Cortex_M4_0: Chunk 2: addr=0x0000A0C0, length=8192, crc=0x90FE2B0D (using block 1)
[6/10/2021, 11:08:24 AM] [INFO] Cortex_M4_0: Chunk 3: addr=0x0000C0C0, length=8192, crc=0xC26933C7 (using block 0)
[6/10/2021, 11:08:24 AM] [INFO] Cortex_M4_0: Chunk 4: addr=0x0000E0C0, length=8176, crc=0x0833A055 (using block 1)
[6/10/2021, 11:08:24 AM] [INFO] Cortex_M4_0: Writing Flash @ Address 0x000100b0 of Length 0x00007ff0
[6/10/2021, 11:08:25 AM] [INFO] Cortex_M4_0: Chunk 1: addr=0x000100B0, length=8192, crc=0x948018DC (using block 0)
[6/10/2021, 11:08:25 AM] [INFO] Cortex_M4_0: Chunk 2: addr=0x000120B0, length=8192, crc=0x6E149376 (using block 1)
[6/10/2021, 11:08:25 AM] [INFO] Cortex_M4_0: Chunk 3: addr=0x000140B0, length=8192, crc=0x14517B08 (using block 0)
[6/10/2021, 11:08:25 AM] [INFO] Cortex_M4_0: Chunk 4: addr=0x000160B0, length=8176, crc=0xCA3A7616 (using block 1)
[6/10/2021, 11:08:25 AM] [INFO] Cortex_M4_0: Writing Flash @ Address 0x000180a0 of Length 0x00007ff0
[6/10/2021, 11:08:26 AM] [INFO] Cortex_M4_0: Chunk 1: addr=0x000180A0, length=8192, crc=0xF4637A47 (using block 0)
[6/10/2021, 11:08:26 AM] [INFO] Cortex_M4_0: Chunk 2: addr=0x0001A0A0, length=8192, crc=0xB21C5EDB (using block 1)
[6/10/2021, 11:08:26 AM] [INFO] Cortex_M4_0: Chunk 3: addr=0x0001C0A0, length=8192, crc=0xA6AEB2EC (using block 0)
[6/10/2021, 11:08:26 AM] [INFO] Cortex_M4_0: Chunk 4: addr=0x0001E0A0, length=8176, crc=0x70DBF215 (using block 1)
[6/10/2021, 11:08:26 AM] [INFO] Cortex_M4_0: Writing Flash @ Address 0x00020090 of Length 0x00001420
[6/10/2021, 11:08:27 AM] [INFO] Cortex_M4_0: Chunk 1: addr=0x00020090, length=5152, crc=0x56A28BCB (using block 0)
[6/10/2021, 11:08:27 AM] [INFO] Cortex_M4_0: Writing Flash @ Address 0x000214b0 of Length 0x00000aa0
[6/10/2021, 11:08:27 AM] [INFO] Cortex_M4_0: Chunk 1: addr=0x000214B0, length=2720, crc=0xF68FCB1E (using block 1)
[6/10/2021, 11:08:28 AM] [SUCCESS] Program Load completed successfully.

Test 3:
With Uniflash, if I select both images for flashing the bootloader (*.hex) and simple_peripheral_oad_offchip (*.out):
[Does not work as intended] After the program load, the device does not reboot automatically.

  • After the 1st power cycle (by removing the programmer): nothing happens.
  • After the 2nd power cycle (by removing the programmer): the recovery image is launching instead of the application.

Combo

[6/10/2021, 10:34:53 AM] [INFO] Cortex_M3_0: GEL Output: Memory Map Initialization Complete.
[6/10/2021, 10:34:58 AM] [INFO] Cortex_M4_0: GEL Output: Memory Map Initialization Complete.
[6/10/2021, 10:34:58 AM] [INFO] Cortex_M4_0: Flashloader: Verbose output enabled.
[6/10/2021, 10:35:00 AM] [INFO] Cortex_M4_0: GEL Output: Memory Map Initialization Complete.
[6/10/2021, 10:35:00 AM] [INFO] Cortex_M4_0: GEL Output: Board Reset Complete.
[6/10/2021, 10:35:00 AM] [INFO] Cortex_M4_0: Writing Flash @ Address 0x00000000 of Length 0x00007ff0
[6/10/2021, 10:35:00 AM] [INFO] Cortex_M4_0: Performing bank erase
[6/10/2021, 10:35:00 AM] [INFO] Cortex_M4_0: Loading flashloader to target: FlashLoaderCC26x2.out
[6/10/2021, 10:35:01 AM] [INFO] Cortex_M4_0: Chunk 1: addr=0x00000000, length=8192, crc=0x0BC95FEA (using block 1)
[6/10/2021, 10:35:01 AM] [INFO] Cortex_M4_0: Chunk 2: addr=0x00002000, length=8192, crc=0x02DA14AB (using block 0)
[6/10/2021, 10:35:01 AM] [INFO] Cortex_M4_0: Chunk 3: addr=0x00004000, length=8192, crc=0x242B801E (using block 1)
[6/10/2021, 10:35:02 AM] [INFO] Cortex_M4_0: Chunk 4: addr=0x00006000, length=8176, crc=0x11143C29 (using block 0)
[6/10/2021, 10:35:02 AM] [INFO] Cortex_M4_0: Writing Flash @ Address 0x00007ff0 of Length 0x00007ff0
[6/10/2021, 10:35:02 AM] [INFO] Cortex_M4_0: Chunk 1: addr=0x00007FF0, length=8192, crc=0x69B4779B (using block 1)
[6/10/2021, 10:35:02 AM] [INFO] Cortex_M4_0: Chunk 2: addr=0x00009FF0, length=8192, crc=0x03D704E9 (using block 0)
[6/10/2021, 10:35:03 AM] [INFO] Cortex_M4_0: Chunk 3: addr=0x0000BFF0, length=8192, crc=0xF1889C83 (using block 1)
[6/10/2021, 10:35:03 AM] [INFO] Cortex_M4_0: Chunk 4: addr=0x0000DFF0, length=8176, crc=0x5F427E11 (using block 0)
[6/10/2021, 10:35:03 AM] [INFO] Cortex_M4_0: Writing Flash @ Address 0x0000ffe0 of Length 0x00007ff0
[6/10/2021, 10:35:03 AM] [INFO] Cortex_M4_0: Chunk 1: addr=0x0000FFE0, length=8192, crc=0xB4CAB77D (using block 1)
[6/10/2021, 10:35:03 AM] [INFO] Cortex_M4_0: Chunk 2: addr=0x00011FE0, length=8192, crc=0xB4E60C97 (using block 0)
[6/10/2021, 10:35:03 AM] [INFO] Cortex_M4_0: Chunk 3: addr=0x00013FE0, length=8192, crc=0xAE6347E2 (using block 1)
[6/10/2021, 10:35:04 AM] [INFO] Cortex_M4_0: Chunk 4: addr=0x00015FE0, length=8176, crc=0x05A6EA1F (using block 0)
[6/10/2021, 10:35:04 AM] [INFO] Cortex_M4_0: Writing Flash @ Address 0x00017fd0 of Length 0x00006630
[6/10/2021, 10:35:04 AM] [INFO] Cortex_M4_0: Chunk 1: addr=0x00017FD0, length=8192, crc=0x7EB8797F (using block 1)
[6/10/2021, 10:35:04 AM] [INFO] Cortex_M4_0: Chunk 2: addr=0x00019FD0, length=8192, crc=0x731E740C (using block 0)
[6/10/2021, 10:35:05 AM] [INFO] Cortex_M4_0: Chunk 3: addr=0x0001BFD0, length=8192, crc=0xFB155709 (using block 1)
[6/10/2021, 10:35:05 AM] [INFO] Cortex_M4_0: Chunk 4: addr=0x0001DFD0, length=1584, crc=0xB8CDB500 (using block 0)
[6/10/2021, 10:35:05 AM] [INFO] Cortex_M4_0: Writing Flash @ Address 0x00056000 of Length 0x00001138
[6/10/2021, 10:35:05 AM] [INFO] Cortex_M4_0: Chunk 1: addr=0x00056000, length=4408, crc=0x738EB07D (using block 1)
[6/10/2021, 10:35:05 AM] [INFO] Cortex_M4_0: Writing Flash @ Address 0x00057fa8 of Length 0x00000058
[6/10/2021, 10:35:05 AM] [INFO] Cortex_M4_0: Chunk 1: addr=0x00057FA8, length=88, crc=0xB0D43234 (using block 0)
[6/10/2021, 10:35:06 AM] [SUCCESS] Program Load completed successfully.

Test 4:
Since Jlink does not support the *.out format, I flash the device with both the bootloader (*.hex) and then the simple_peripheral_oad_offchip (*.hex).
[Does not work as intended] The device boots the recovery image "Multi-Sensor".

'C:\Program Files (x86)\SEGGER\JLink\JLink.exe' -device cc1352R1F3 -if jtag -speed 4000 -jtagconf -1,-1 -autoconnect 1 -CommandFile .\cmd.jlink
SEGGER J-Link Commander V6.98c (Compiled Mar 16 2021 12:20:44)
DLL version V6.98c, compiled Mar 16 2021 12:19:26


J-Link Command File read successfully.
Processing script file...

J-Link connection not established yet but required for command.
Connecting to J-Link via USB...O.K.
Firmware: J-Link V10 compiled Feb  4 2021 12:58:41
Hardware version: V10.10
S/N: 50114253
License(s): GDB
VTref=3.216V
Target connection not established yet but required for command.
Device "CC1352R1F3" selected.


Connecting to target via JTAG
InitTarget: Found ICE-Pick with ID: 0x3BB4102F
InitTarget: Found CPU TAP 0x4BA00477
DPv0 detected
Scanning AP map to find all available APs
AP[1]: Stopped AP scan as end of AP map has been reached
AP[0]: AHB-AP (IDR: 0x24770011)
Iterating through AP map to find AHB-AP to use
AP[0]: Core found
AP[0]: AHB-AP ROM base: 0xE00FF000
CPUID register: 0x410FC241. Implementer code: 0x41 (ARM)
Found Cortex-M4 r0p1, Little endian.
FPUnit: 6 code (BP) slots and 2 literal slots
CoreSight components:
ROMTbl[0] @ E00FF000
ROMTbl[0][0]: E000E000, CID: B105E00D, PID: 000BB00C SCS-M7
ROMTbl[0][1]: E0001000, CID: B105E00D, PID: 003BB002 DWT
ROMTbl[0][2]: E0002000, CID: B105E00D, PID: 002BB003 FPB
ROMTbl[0][3]: E0000000, CID: B105E00D, PID: 003BB001 ITM
ROMTbl[0][4]: E0040000, CID: B105900D, PID: 000BB9A1 TPIU
Cortex-M4 identified.
PC = 1000060A, CycleCnt = 00240DBC
R0 = 00000004, R1 = 40082000, R2 = 00000000, R3 = 00000000
R4 = E000ED10, R5 = 00000004, R6 = FFFFFFFF, R7 = FFFFFFFF
R8 = 10000000, R9 = FFFFFFFF, R10= FFFFFFFF, R11= FFFFFFFF
R12= 00000000
SP(R13)= 20005B18, MSP= 20013FF8, PSP= 20005B18, R14(LR) = 100036C5
XPSR = 81000000: APSR = Nzcvq, EPSR = 01000000, IPSR = 000 (NoException)
CFBP = 02000001, CONTROL = 02, FAULTMASK = 00, BASEPRI = 00, PRIMASK = 01

FPS0 = 00000000, FPS1 = 00000000, FPS2 = 00000000, FPS3 = 00000000
FPS4 = 00000000, FPS5 = 00000000, FPS6 = 00000000, FPS7 = 00000000
FPS8 = 00000000, FPS9 = 00000000, FPS10= 00000000, FPS11= 00000000
FPS12= 00000000, FPS13= 00000000, FPS14= 00000000, FPS15= 00000000
FPS16= FFFFFFFF, FPS17= FFFFFFFF, FPS18= FFFFFFFF, FPS19= FFFFFFFF
FPS20= FFFFFFFF, FPS21= FFFFFFFF, FPS22= FFFFFFFF, FPS23= FFFFFFFF
FPS24= FFFFFFFF, FPS25= FFFFFFFF, FPS26= FFFFFFFF, FPS27= FFFFFFFF
FPS28= FFFFFFFF, FPS29= FFFFFFFF, FPS30= FFFFFFFF, FPS31= FFFFFFFF
FPSCR= 00000000

Without any give address range, Erase Chip will be executed
Erasing device...
J-Link: Flash download: Total time needed: 1.186s (Prepare: 0.484s, Compare: 0.000s, Erase: 0.697s, Program: 0.000s, Verify: 0.000s, Restore: 0.004s)
Erasing done.

Downloading file [.\bim_offchip_CC1352R1_LAUNCHXL_nortos_ccs\Debug_unsecure\bim_offchip_CC1352R1_LAUNCHXL_nortos_ccs.hex]...
J-Link: Flash download: Bank 0 @ 0x00000000: 1 range affected (8192 bytes)
J-Link: Flash download: Total: 0.285s (Prepare: 0.030s, Compare: 0.079s, Erase: 0.025s, Program & Verify: 0.132s, Restore: 0.017s)
J-Link: Flash download: Program & Verify speed: 61 KB/s
O.K.

Downloading file [.\simple_peripheral_oad_offchip_CC13X2R1_LAUNCHXL_tirtos_ccs\Release\simple_peripheral_oad_offchip_CC13X2R1_LAUNCHXL_tirtos_ccs.hex]...
J-Link: Flash download: Bank 0 @ 0x00000000: 1 range affected (131072 bytes)
J-Link: Flash download: Total: 1.089s (Prepare: 0.038s, Compare: 0.076s, Erase: 0.000s, Program & Verify: 0.949s, Restore: 0.025s)
J-Link: Flash download: Program & Verify speed: 135 KB/s
O.K.

Reset delay: 0 ms
Reset type NORMAL: Resets core & peripherals via SYSRESETREQ & VECTRESET bit.


Script processing completed.


Questions:

  • Is there any reason explaining why downloading both binaries (bootloader.hex + firmware.out cf Test 3) does not work?
  • What needs to be changed for successfully flashing the *.hex using Uniflash and Jlink?

Thanks,

  • Hello,

    For Test #2, do you get the same result when flashing with CCS instead of UniFlash?

    Thanks

    ki

  • Hi Ki,

    Same issue with CCS:

    Test #5: From CCS

    1. I flash bim_offchip_CC1352R1_LAUNCHXL_nortos_ccs.hex
    2. I flash simple_peripheral_oad_offchip_CC13X2R1_LAUNCHXL_tirtos_ccs.hex

    Nothing happens, after 2 power cycles, the device boots on the recovery image MultiSensor.

    Test #6: From CCS

    1. I flash bim_offchip_CC1352R1_LAUNCHXL_nortos_ccs.hex
    2. I flash simple_peripheral_oad_offchip_CC13X2R1_LAUNCHXL_tirtos_ccs.out

    The device runs the simple_peripheral application as expected.

    Note1) I did not modify anything from the CCS example.

    Note 2) The exact same issue occurs if I disconnect the LPSTK for flashing the CC1352 LAUNCHXL instead. Everything works fine with the *.out without any power cycle. However while flashing simple_peripheral_oad_offchip_CC13X2R1_LAUNCHXL_tirtos_ccs.hex, after a power cycle, the device advertises 'ProjectZero'

    Note 3) For debugging purposes, I tried to dump to memory after successfully loading the *.out. With Uniflash, I click on the Memory menu, then "Read memory"...Suddenly the device runs the recovery image...

    Conclusion:

    • There is apparently an issue with the *.hex regardless of the programming tool (Uniflash, CCS, Jlink).
    • Also with Uniflash, we can sequentially flash the bim_offchip_CC1352R1_LAUNCHXL_nortos_ccs.hex and then the simple_peripheral_oad_offchip_CC13X2R1_LAUNCHXL_tirtos_ccs.out but not by using the 'combo' mode (selecting both firmware at once).

    Questions:

    1. Could you please quickly reproduce this issue?
    2. If everything works for you, could you please send me back your simple_peripheral_oad_offchip_CC13X2R1_LAUNCHXL_tirtos_ccs.hex?

    Sincerely,

     

  • I can reproduce this issue. I feel you are correct - it is not an issue with the programming tools or debug probe but with the generated hex file. I will need to bring this thread to the attention of the device experts so that they can analyze further. Thank you for the excellent details you have provided regarding this issue. 

  • Hi Jo,

    Can you go through the steps in the OAD Target Setup exactly and test? (E.g. use bim.hex and application .bin file.)

    dev.ti.com/.../setting-up-environment.html

  • Hi Marie,

    Thanks for your help and missing information!

    Here my observation:

    Binary Result
    simple_peripheral_oad_offchip_CC13X2R1_LAUNCHXL_tirtos_ccs.out [OK]
    simple_peripheral_oad_offchip_CC13X2R1_LAUNCHXL_tirtos_ccs_oad.bin [OK]
    simple_peripheral_oad_offchip_CC13X2R1_LAUNCHXL_tirtos_ccs.hex [ERROR]

    Is there any reason explaining why the *.out works and not the *.hex?

    Thanks

  • Hi Jo,

    For the hex file, the oad image header is missing. When you power the device, it starts by running the BIM image. BIM then checks the oad image header of all present images, and boots into the newest one with valid crc etc. So, for the hex file, since the header is missing, BIM will never boot into this image.

    You can read a more detailed description here:

    https://dev.ti.com/tirex/explore/content/simplelink_cc13x2_26x2_sdk_5_10_00_48/docs/ble5stack/ble_user_guide/html/oad-secure/bim.html 

  • Hi Marie H,

    My question is more why the *.out contains the OAD image header but not the *.hex:

    /* simple_peripheral_oad_offchip.out sections */
    
    Section Headers:
      [Nr] Name              Type            Address  Off    Size   ES Flg Lk Inf Al
      [ 0]                   NULL            00000000 000000 000000 00      0   0  0
    ...
      [ 9] .image_header     PROGBITS        00000000 000038 00008d 00   A  0   0  1
      [10] .resetVecs        NOBITS          00000090 01e770 000000 00   A  0   0  1

    Anyway, thanks a lot for your information. 

  • Hi Jo,

    The hex file contains only the application.

    The OAD image header is added by OAD image tool. I would recommend you to use the .bin file which only contains the actual code, no meta information.