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.

CC2652R: Periodic advertising functions keep returning bleInvalidRange

Part Number: CC2652R

Using: simplelink_cc13xx_cc26xx_sdk_6_10_00_29 BTool from a slightly modified Host_test app. (added the -DUSE_PERIODIC_ADV to host_test.opt)

I initialize a device as Peripheral and want to start Periodic advertizing.

Steps I do:

1. I reset the device using: HCIExt_ResetSystemCmd

2. I initialize the device as peripheral using GAP_DeviceInit

3. I Create advertising using GapAdv_create

4. I try to call any periodic advertizing function like: GapAdv_SetPeriodicAdvParams, GapAdv_setPeriodicAdvData, GapAdv_SetPeriodicAdvEnable

5. I get bleInvalidRange as a response.

Documentation I found was not very helpful on how to use this feature. I am not sure I am using the right order or right parameters.

Here a complete log:

[1] : <Tx> - 04:04:04.465
-Type           : 0x01 (Command)
-OpCode         : 0xFC1D (HCIExt_ResetSystemCmd)
-Data Length    : 0x01 (1) byte(s)
 Type           : 0x00 (0) (Chip Reset)
Dump(Tx):
0000:01 1D FC 01 00                                  .....
--------------------------------------------------------------------
[2] : <Rx> - 04:04:04.478
-Type           : 0x04 (Event)
-EventCode      : 0x00FF (HCI_LE_ExtEvent)
-Data Length    : 0x05 (5) bytes(s)
 Event          : 0x041D (1053) (HCIExt_ResetSystemCmdDone)
 Status         : 0x00 (0) (SUCCESS)
 CmdOpCode      : 0xFC1D (HCIExt_ResetSystemCmd)
Dump(Rx):
0000:04 FF 05 1D 04 00 1D FC                         ........
--------------------------------------------------------------------
[3] : <Tx> - 04:04:11.194
-Type           : 0x01 (Command)
-OpCode         : 0xFE00 (GAP_DeviceInit)
-Data Length    : 0x08 (8) byte(s)
 ProfileRole    : 0x04 (4) (
                  Peripheral)
 AddrMode       : 0x00 (0) (ADDRMODE_PUBLIC)
 RandomAddr     : 00:00:00:00:00:00
Dump(Tx):
0000:01 00 FE 08 04 00 00 00 00 00 00 00             ............
--------------------------------------------------------------------
[4] : <Rx> - 04:04:11.213
-Type           : 0x04 (Event)
-EventCode      : 0x00FF (HCI_LE_ExtEvent)
-Data Length    : 0x06 (6) bytes(s)
 Event          : 0x067F (1663) (GAP_HCI_ExtentionCommandStatus)
 Status         : 0x00 (0) (SUCCESS)
 OpCode         : 0xFE00 (GAP_DeviceInit)
 DataLength     : 0x00 (0)
Dump(Rx):
0000:04 FF 06 7F 06 00 00 FE 00                      .........
--------------------------------------------------------------------
[5] : <Rx> - 04:04:11.228
-Type           : 0x04 (Event)
-EventCode      : 0x00FF (HCI_LE_ExtEvent)
-Data Length    : 0x2C (44) bytes(s)
 Event          : 0x0600 (1536) (GAP_DeviceInitDone)
 Status         : 0x00 (0) (SUCCESS)
 DevAddr        : F8:8A:5E:2D:70:B4
 DataPktLen     : 0x00FF (255)
 NumDataPkts    : 0x05 (5)
 IRK            : 00:00:00:00:00:00:00:00:00:00:00:00:00:00:00:00
 CSRK           : 52:0D:25:A2:9F:BD:C7:B9:6E:D2:09:3A:D9:2C:40:7F
Dump(Rx):
0000:04 FF 2C 00 06 00 B4 70 2D 5E 8A F8 FF 00 05 00 ..,....p-^......
0010:00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 52 ...............R
0020:0D 25 A2 9F BD C7 B9 6E D2 09 3A D9 2C 40 7F    .%.....n..:.,@.
--------------------------------------------------------------------
[6] : <Tx> - 04:04:16.002
-Type           : 0x01 (Command)
-OpCode         : 0xFE3E (GapAdv_create)
-Data Length    : 0x15 (21) byte(s)
 Properties     : 0x0013 (19) (
                  GAP_ADV_PROP_CONNECTABLE
                  GAP_ADV_PROP_SCANNABLE
                  GAP_ADV_PROP_LEGACY)
 IntervalMin    : 0x0000A0 (160)
 IntervalMax    : 0x0000A0 (160)
 PrimaryChMap   : 0x07 (7) (
                  GAP_ADV_CHAN_37
                  GAP_ADV_CHAN_38
                  GAP_ADV_CHAN_39)
 PeerAddrType   : 0x00 (0) (PEER_ADDRTYPE_PUBLIC_OR_PUBLIC_ID)
 PeerAddress    : 00:00:00:00:00:00
 FilterPolicy   : 0x00 (0) (
                  AdvFilterPolicy Bit Mask Is Not Set)
 TxPower        : 0x7F (127)
 PrimaryPHY     : 0x01 (1) (GAP_ADV_PRIM_PHY_1_MBPS)
 SecondaryPHY   : 0x01 (1) (GAP_ADV_SEC_PHY_1_MBPS)
 SID            : 0x00 (0)
Dump(Tx):
0000:01 3E FE 15 13 00 A0 00 00 A0 00 00 07 00 00 00 .>..............
0010:00 00 00 00 00 7F 01 01 00                      .........
--------------------------------------------------------------------
[7] : <Rx> - 04:04:16.032
-Type           : 0x04 (Event)
-EventCode      : 0x00FF (HCI_LE_ExtEvent)
-Data Length    : 0x07 (7) bytes(s)
 Event          : 0x067F (1663) (GAP_HCI_ExtentionCommandStatus)
 Status         : 0x00 (0) (SUCCESS)
 OpCode         : 0xFE3E (GapAdv_create)
 DataLength     : 0x01 (1)
 Handle         : 0x00 (0)
Dump(Rx):
0000:04 FF 07 7F 06 00 3E FE 01 00                   ......>...
--------------------------------------------------------------------
[8] : <Tx> - 04:04:25.418
-Type           : 0x01 (Command)
-OpCode         : 0xFE14 (GapAdv_SetPeriodicAdvParams)
-Data Length    : 0x07 (7) byte(s)
 Handle         : 0x00 (0)
 Interval Min   : 0x0006 (6)
 Interval Max   : 0x0006 (6)
 Properties     : 0x0000 (0)
Dump(Tx):
0000:01 14 FE 07 00 06 00 06 00 00 00                ...........
--------------------------------------------------------------------
[9] : <Rx> - 04:04:25.433
-Type           : 0x04 (Event)
-EventCode      : 0x00FF (HCI_LE_ExtEvent)
-Data Length    : 0x06 (6) bytes(s)
 Event          : 0x067F (1663) (GAP_HCI_ExtentionCommandStatus)
 Status         : 0x18 (24) (bleInvalidRange)
 OpCode         : 0xFE14 (GapAdv_SetPeriodicAdvParams)
 DataLength     : 0x00 (0)
Dump(Rx):
0000:04 FF 06 7F 06 18 14 FE 00                      .........
--------------------------------------------------------------------
[10] : <Tx> - 04:04:26.440
-Type           : 0x01 (Command)
-OpCode         : 0xFE16 (GapAdv_SetPeriodicAdvEnable)
-Data Length    : 0x02 (2) byte(s)
 Enable         : 0x00 (0)
 Handle         : 0x00 (0)
Dump(Tx):
0000:01 16 FE 02 00 00                               ......
--------------------------------------------------------------------
[11] : <Rx> - 04:04:26.480
-Type           : 0x04 (Event)
-EventCode      : 0x00FF (HCI_LE_ExtEvent)
-Data Length    : 0x06 (6) bytes(s)
 Event          : 0x067F (1663) (GAP_HCI_ExtentionCommandStatus)
 Status         : 0x18 (24) (bleInvalidRange)
 OpCode         : 0xFE16 (GapAdv_SetPeriodicAdvEnable)
 DataLength     : 0x00 (0)
Dump(Rx):
0000:04 FF 06 7F 06 18 16 FE 00                      .........
--------------------------------------------------------------------