Other Parts Discussed in Thread: CC2650, , Z-STACK
I try to get some CPU information from IAR when cc2650 hang-up.
If need more information to debug this issue , please let me know what debug information I can provide.
Question :
ZStack Version : Z-Stack_Home_1.2.2a.44539 (CC2650,CC2538)
ZigBee Hardware :
|
Role |
IC Part Number |
Number of devices |
|
Coordinator |
CC2538 |
1 |
|
Router |
CC2538 |
1 |
|
End Device |
CC2650 |
400 |
Situation :
- Router , Coordinator power on.
- After Router join to Coordinator network, then the coordinator can’t be joined any other device.
- MCU ( Linux Base )use Uart communication with CC2538 ( USB Uart – TI ZNP Protocol ).
- 400 set of End devices power on at the same time, and start join to Router.
- If end Device Join network already, then send information to Router and Router report information thought USB Uart to MCU.
Issue 1 :
400 end devices can’t join to network totally ( test for 5 times, every time, approx 40 sets of device can’t join to the network )
Issue 1 status :
- During the joining period, some end devices will be crashed.
- After Joining to network, end device’s MCU keep alive but Device State got abnormal status.
(The global variable devState declarated in ZDApp.c)
(A) Device State is not zstack_DevState_DEV_END_DEVICE , end device don’t send data request or other data packet.
(B) Device State is equal zstack_DevState_NWK_DISC, end device send data request or other data packet regularly.
CC2650 Debug Information :
|
Role |
IC Part Number |
MAC Address |
|
Coordinator |
CC2538 |
00124B0002F3EDC3 |
|
Router |
CC2538 |
00124B0002F4ABBE |
|
End Device |
CC2650 |
00124B000D6A9E80 |
In Normal Case :
I record all device state change value (ICall_fetchServiceMsg() => zstackmsg_CmdIDs_DEV_STATE_CHANGE_IND) :
devState = 2 (zstack_DevState_NWK_DISC)
devState = 13 (zstack_DevState_NWK_REJOIN_SEC_ALL_CHANNEL)
devState = 6 (zstack_DevState_DEV_END_DEVICE)
The device state start at devState=2 , then change to devState=13.
It change to devState=6 after joined network successfully.
Crash Case Debug Information :
I use “Attach to running target” without download image in IAR IDE. Dump below information after CC2650 hang on.
IAR Debug Log Window :
Sun Jun 10, 2018 23:49:43: Loaded macro file: C:\Program Files (x86)\IAR Systems\Embedded Workbench 7.4\arm\config\debugger\TexasInstruments\CC26xx.dmac
Sun Jun 10, 2018 23:49:47: Connecting to TI XDS100v3 ( Probe no: 06EB1210078A ) COM[--/--]
Sun Jun 10, 2018 23:49:48: TI XDS ARM, device revision: 0x00000001, big endian: false, cache: false, board revision: 0x00000000, driver revision: 0x0B020200
Sun Jun 10, 2018 23:49:53: 0 bytes with download suppressed
Sun Jun 10, 2018 23:49:53: Loaded debugee: D:\Work\Project\GSmartek\SVN\RD\Software\ZigBee\Z-Stack_Home_1.2.2a.44539_RTOS\trunk-debug\Projects\Customer\Advantech\ESL-Tag\CC26xx\LEO-D33-OTA\Exe\ESL-Tag-LEO-D33-OTA.out
IAR Disassembly Window :
0x16b48: 0xf89d 0x0000 LDRB.W R0, [SP]
0x16b4c: 0x2800 CMP R0, #0
0x16b4e: 0xd1fb BNE.N 0x16b48
0x16b50: 0xbd01 POP {R0, PC}
0x16b52: 0x0000 MOVS R0, R0
0x16b54: 0x48f4 LDR.N R0, [PC, #0x3d0] ; 0x10011985 (268507525)
0x16b56: 0x2000 MOVS R0, #0
0x16b58: 0xf8df 0x037c LDR.W R0, [PC, #0x37c] ; 0x20004994 (536889748)
0x16b5c: 0xf20f 0x11a5 ADR.W R1, . + 0x1a9 ; 0x16d05
0x16b60: 0x6001 STR R1, [R0]
0x16b62: 0xf20f 0x1141 ADR.W R1, . + 0x145 ; 0x16ca5
0x16b66: 0x6041 STR R1, [R0, #0x4]
0x16b68: 0x4770 BX LR
0x16b6a: 0xb510 PUSH {R4, LR}
0x16b6c: 0x4604 MOV R4, R0
0x16b6e: 0x4623 MOV R3, R4
0x16b70: 0xf000 0xf86b BL 0x16c4a
0x16b74: 0xb918 CBNZ R0, 0x16b7e
0x16b76: 0xf8df 0x0364 LDR.W R0, [PC, #0x364] ; 0x2000498c (536889740)
0x16b7a: 0x6840 LDR R0, [R0, #0x4]
0x16b7c: 0x6160 STR R0, [R4, #0x14]
0x16b7e: 0xbd10 POP {R4, PC}
0x16b80: 0xb500 PUSH {LR}
0x16b82: 0xb085 SUB SP, SP, #0x14
0x16b84: 0x2210 MOVS R2, #16 ; 0x10
0x16b86: 0xf88d 0x1000 STRB.W R1, [SP]
0x16b8a: 0x4601 MOV R1, R0
0x16b8c: 0xf10d 0x0001 ADD.W R0, SP, #1
0x16b90: 0xf7fe 0xfc0f BL 0x153b2
0x16b94: 0x466b MOV R3, SP
0x16b96: 0x2211 MOVS R2, #17 ; 0x11
0x16b98: 0x2100 MOVS R1, #0
IAR Current CPU Register Window:
|
Register Name |
Value |
|
R0 |
0x0000 0001 |
|
R1 |
0x0100 0008 |
|
R2 |
0x0000 0001 |
|
R3 |
0x0000 0008 |
|
R4 |
0x4004 1000 |
|
R5 |
0x2000 4810 |
|
R6 |
0x0020 0001 |
|
R7 |
0x1001 353C |
|
R8 |
0x1001 34C0 |
|
R9 |
0x0000 001F |
|
R10 |
0x0000 0000 |
|
R11 |
0x2000 4C4C |
|
R12 |
0x0000 0000 |
|
SP |
0x2000 2170 |
|
LR |
0x0000 B215 |
|
APSR |
0 |
|
IPSR |
0x0000 0000 |
|
EPSR |
0x0100 0000 |
|
PC |
0x0001 6B4E |
|
PRIMASK |
0x0000 0000 |
|
BASEPRI |
0x0000 0020 |
|
BASEPRI_MAX |
0x0000 0020 |
|
FAULTMASK |
0x0000 0000 |
|
CONTROL |
0x0000 0002 |
|
CYCLECOUNTER |
0 |
IAR CPU Register Window :
|
Register Name |
Value |
|
R0 |
0x0000 0001 |
|
R1 |
0x0100 0008 |
|
R2 |
0x0000 0001 |
|
R3 |
0x0000 0008 |
|
R4 |
0x4004 1000 |
|
R5 |
0x2000 4810 |
|
R6 |
0x0020 0001 |
|
R7 |
0x1001 353C |
|
R8 |
0x1001 34C0 |
|
R9 |
0x0000 001F |
|
R10 |
0x0000 0000 |
|
R11 |
0x2000 4C4C |
|
R12 |
0x0000 0000 |
|
SP |
0x2000 2170 |
|
LR |
0x0000 B215 |
|
xPSR |
0x2100 0000 |
|
APSR |
0x2000 0000 |
|
IPSR |
0x0000 0000 |
|
EPSR |
0x0100 0000 |
|
PC |
0x0001 6B4E |
|
SP_main |
0x2000 4160 |
|
SP_process |
0x2000 2170 |
|
PRIMASK |
0x0000 0000 |
|
BASEPRI |
0x0000 0020 |
|
BASEPRI_MAX |
0x0000 0020 |
|
FAULTMASK |
0x0000 0000 |
|
CONTROL |
0x0000 0002 |
|
IAPSR |
0x2000 0000 |
|
EAPSR |
0x2100 0000 |
|
IEPSR |
0x0100 0000 |
|
CYCLECOUNTER |
0 |
|
CCTIMER1 |
0 |
|
CCTIMER2 |
0 |
|
CCSTEP |
0 |