direction_finding_connectionless Tx&Rx((nrf5340dk)):Unable to achieve synchronization, unable to receive CTE package

I have uploaded my project

1832.direction_finding_connectionless.zip

This problem has been bothering me for a long time!And if possible, I really hope someone could download it to see where the problem is. Thank you in advance!I have listed some modifications I made to the SDK examples(D:\NCS\ncs2.5.0\v2.5.0\nrf\samples\bluetooth\direction_finding_connectionless_rx&tx) and the experimental results later.


hardware: nrf5340-dk

ncs:2.5.0

sample: direction_finding_connectionless_rx  &  direction_finding_connectionless_tx (AoD mode)

issue:
Creating Periodic Advertising Sync...ASSERTION FAIL [err == 0] @ WEST_TOPDIR/zephyr/subsys/bluetooth/host/hci_core.c:338
*** Booting nRF Connect SDK v2.5.0 ***with err -11
after debug, I find the code stall at hci_core.c 388:
err = k_sem_take(&sync_sem, HCI_CMD_TIMEOUT);
BT_ASSERT_MSG(err == 0, "command opcode 0x%04x timeout with err %d", opcode, err);
I cannot run into create_sync() after the scan_enable() is runed even if I run the Rx sample along with the TX sample.
I can not find CTE advertising package. 
[DEVICE]: 76:E6:BA:B0:C6:17 (random), AD evt type 3, Tx Pwr: 127, RSSI -64  C:0 S:0 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
but the interval always is 0. and SID always is 255.
I cannot find : success. Periodic sync established.So, never run to receive CTE.
I connected an external antenna matrix with 4 antennas at the TX end using an RF connector, I tried the connection example (Direction finding central/peripheral)  and used the same configuration as direction_finding_connectionless_rx/tx,and according to Direction finding central/peripheral testing, the antenna signal was indeed successfully connected to the external antenna.It did connect successfully and received CTE data.But in direction_finding_connectionless_rx/tx example, using the same configuration failed.
direction_finding_connectionless_tx(AOD mode):
Configuration:
Control panel output:
*** Booting nRF Connect SDK v2.5.0 ***
Starting Connectionless Beacon Demo
Bluetooth initialization...success
Advertising set create...success
Update CTE params...success
Periodic advertising params set...success
Enable CTE...success
Periodic advertising enable...success
Extended advertising enable...success
Started extended advertising as DF:51:35:BB:2D:FC (random)
direction_finding_connectionless_rx:
Configuration:
Control panel output:
First time programming code:
*** Booting nRF Connect SDK v2.5.0 ***
Starting Connectionless Locator Demo
Bluetooth initialization...success
Scan callbacks register...success.
Periodic Advertising callbacks register...success.
Start scanning...success
Waiting for periodic advertising...
[DEVICE]: 36:24:D7:AC:34:13 (random), AD evt type 3, Tx Pwr: 127, RSSI -96  C:0 S:0 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
[DEVICE]: 70:BD:2C:AA:B9:D6 (random), AD evt type 0, Tx Pwr: 127, RSSI -90  C:1 S:1 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
[DEVICE]: 70:BD:2C:AA:B9:D6 (random), AD evt type 4, Tx Pwr: 127, RSSI -89  C:1 S:1 D:0 SR:1 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
[DEVICE]: 12:86:E6:5C:F9:40 (random), AD evt type 3, Tx Pwr: 127, RSSI -61  C:0 S:0 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
[DEVICE]: 69:1B:97:62:73:42 (random), AD evt type 0, Tx Pwr: 127, RSSI -89  C:1 S:1 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
[DEVICE]: 7F:13:80:1F:B5:29 (random), AD evt type 0, Tx Pwr: 127, RSSI -96  C:1 S:1 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
[DEVICE]: 29:5A:96:94:BD:E3 (random), AD evt type 3, Tx Pwr: 127, RSSI -93  C:0 S:0 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
[DEVICE]: 5F:97:DC:DC:01:BE (random), AD evt type 3, Tx Pwr: 127, RSSI -94  C:0 S:0 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
[DEVICE]: 38:E9:2C:46:09:43 (random), AD evt type 3, Tx Pwr: 127, RSSI -86  C:0 S:0 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
[DEVICE]: 7D:85:8C:FE:F6:99 (random), AD evt type 2, Tx Pwr: 127, RSSI -76  C:0 S:1 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
[DEVICE]: 7A:73:92:C1:D1:1C (random), AD evt type 2, Tx Pwr: 127, RSSI -80  C:0 S:1 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
[DEVICE]: 33:A5:ED:97:96:BF (random), AD evt type 3, Tx Pwr: 127, RSSI -78  C:0 S:0 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
Continuous second time programming code:
[DEVICE]: 7B:34:B4:83:65:85 (random), AD evt type 3, Tx Pwr: 127, RSSI -68  C:0 S:0 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
[DEVICE]: 76:E6:BA:B0:C6:17 (random), AD evt type 3, Tx Pwr: 127, RSSI -64  C:0 S:0 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
success. Found periodic advertising.
Creating Periodic Advertising Sync...ASSERTION FAIL [err == 0] @ WEST_TOPDIR/zephyr/subsys/bluetooth/host/hci_core.c:338
*** Booting nRF Connect SDK v2.5.0 ***with err -11
Starting Connectionless Locator Demo
Bluetooth initialization...failed (err -11)
success
Scan callbacks register...success.
Periodic Advertising callbacks register...success.
Start scanning...failed (err -11)
Waiting for periodic advertising...
*** Booting nRF Connect SDK v2.5.0 ***
Starting Connectionless Locator Demo
Bluetooth initialization...success
Scan callbacks register...success.
Periodic Advertising callbacks register...success.
Start scanning...success
Waiting for periodic advertising...
[DEVICE]: FC:02:F2:8B:8A:8E (public), AD evt type 0, Tx Pwr: 127, RSSI -89 FR8010_MI C:1 S:1 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
[DEVICE]: 75:26:60:D1:5E:74 (random), AD evt type 3, Tx Pwr: 127, RSSI -92  C:0 S:0 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
[DEVICE]: 38:FC:98:8C:0F:B3 (public), AD evt type 0, Tx Pwr: 127, RSSI -93  C:1 S:1 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
[DEVICE]: 38:FC:98:8C:0F:B3 (public), AD evt type 4, Tx Pwr: 127, RSSI -92  C:1 S:1 D:0 SR:1 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
[DEVICE]: 72:E9:B7:AD:B2:40 (random), AD evt type 0, Tx Pwr: 127, RSSI -75  C:1 S:1 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
[DEVICE]: 72:E9:B7:AD:B2:40 (random), AD evt type 4, Tx Pwr: 127, RSSI -75  C:1 S:1 D:0 SR:1 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
When I modify the code(hci_core.c 388) ,err -11 disappeared, but synchronization was still not achieved and CTE data was not received:
 (Change HCI_CMD_TIMEOUT to K_FOREVER;I did not modify this code in the project I uploaded;
hci_core.c 66: #define HCI_CMD_TIMEOUT      K_SECONDS(10))
err = k_sem_take(&sync_sem, K_FOREVER);        
BT_ASSERT_MSG(err == 0, "command opcode 0x%04x timeout with err %d", opcode, err);
First time programming code:
*** Booting nRF Connect SDK v2.5.0 ***
Starting Connectionless Locator Demo
Bluetooth initialization...success
Scan callbacks register...success.
Periodic Advertising callbacks register...success.
Start scanning...success
Waiting for periodic advertising...
[DEVICE]: 0B:77:C4:66:D4:59 (random), AD evt type 3, Tx Pwr: 127, RSSI -88  C:0 S:0 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
[DEVICE]: 18:96:1D:03:92:A7 (random), AD evt type 3, Tx Pwr: 127, RSSI -92  C:0 S:0 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
[DEVICE]: 6A:6A:79:86:AA:30 (random), AD evt type 0, Tx Pwr: 127, RSSI -78  C:1 S:1 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
[DEVICE]: 32:73:62:FF:00:78 (random), AD evt type 3, Tx Pwr: 127, RSSI -97  C:0 S:0 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
[DEVICE]: 30:0A:60:4B:94:22 (random), AD evt type 3, Tx Pwr: 127, RSSI -98  C:0 S:0 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
Continuous second time programming code:
[DEVICE]: 7A:29:E0:CF:BD:C0 (random), AD evt type 0, Tx Pwr: 127, RSSI -73  C:1 S:1 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
[DEVICE]: 7A:29:E0:CF:BD:C0 (random), AD evt type 4, Tx Pwr: 127, RSSI -71  C:1 S:1 D:0 SR:1 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
success. Found periodic advertising.
Creating Periodic Advertising Sync...*** Booting nRF Connect SDK v2.5.0 ***
Starting Connectionless Locator Demo
Bluetooth initialization...success
Scan callbacks register...success.
Periodic Advertising callbacks register...success.
Start scanning...success
Waiting for periodic advertising...
[DEVICE]: 59:A5:67:B4:31:29 (random), AD evt type 2, Tx Pwr: 127, RSSI -82  C:0 S:1 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
[DEVICE]: 7A:29:E0:CF:BD:C0 (random), AD evt type 0, Tx Pwr: 127, RSSI -70  C:1 S:1 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
[DEVICE]: 7A:29:E0:CF:BD:C0 (random), AD evt type 4, Tx Pwr: 127, RSSI -70  C:1 S:1 D:0 SR:1 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
Antenna matrix connection(TX  AOD):
Four GPIOs used to control antenna switching are connected to the external antenna matrix via DuPont cables.The antenna array is connected through RF connectors.
  antenna 
  RF connector
I don't know if it's a problem with my hardware configuration or software configuration.
Parents
  • Hi,

    Could you provide more information on what is shown in "first time programming code" and "continuous second time programming code"?

    When exactly did the ASSERTION FAIL error occur? Is assertion error reproducible on your end?

    Best regards,
    Dejan

  •  Hi,Dejan

    Thank you very much for your comfort. I have tried to adjust my mindset and I believe that the problem will eventually be solved.

    After the sender's code was flashed to nrf5340dk, I flash the receiver's code on another board. On the receiving end, after the first time flash the code, I clicked on flash key again, and the results of these two burns were different.The console has been printing text like this:"[DEVICE]: CF:62:C2:8A:64:34 (random), AD evt type 3, Tx Pwr: 127, RSSI -72  C:0 S:0 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255", but there is no synchronization.

    1.First time programming code:

    *** Booting nRF Connect SDK v2.5.0 ***
    Starting Connectionless Locator Demo
    Bluetooth initialization...success
    Scan callbacks register...success.
    Periodic Advertising callbacks register...success.
    Start scanning...success
    Waiting for periodic advertising...
    [DEVICE]: 38:A6:4D:3B:8E:4C (random), AD evt type 3, Tx Pwr: 127, RSSI -56  C:0 S:0 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    [DEVICE]: 00:BC:E9:16:2F:D9 (random), AD evt type 3, Tx Pwr: 127, RSSI -72  C:0 S:0 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    [DEVICE]: 61:FD:9A:F2:5B:EF (random), AD evt type 0, Tx Pwr: 127, RSSI -76  C:1 S:1 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    [DEVICE]: 61:FD:9A:F2:5B:EF (random), AD evt type 4, Tx Pwr: 127, RSSI -75  C:1 S:1 D:0 SR:1 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    [DEVICE]: 17:EE:ED:DD:BE:7E (random), AD evt type 3, Tx Pwr: 127, RSSI -72  C:0 S:0 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    [DEVICE]: 17:95:25:48:98:46 (random), AD evt type 3, Tx Pwr: 127, RSSI -85  C:0 S:0 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    [DEVICE]: D2:51:A1:08:D3:93 (public), AD evt type 0, Tx Pwr: 127, RSSI -93  C:1 S:1 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    [DEVICE]: 11:D6:AB:B0:8B:32 (random), AD evt type 3, Tx Pwr: 127, RSSI -88  C:0 S:0 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    [DEVICE]: 68:73:1F:4A:64:7C (random), AD evt type 0, Tx Pwr: 127, RSSI -81  C:1 S:1 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    [DEVICE]: 68:73:1F:4A:64:7C (random), AD evt type 4, Tx Pwr: 127, RSSI -80  C:1 S:1 D:0 SR:1 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    [DEVICE]: 35:55:77:56:D5:0E (random), AD evt type 3, Tx Pwr: 127, RSSI -86  C:0 S:0 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    [DEVICE]: 34:65:8B:3E:C4:55 (random), AD evt type 3, Tx Pwr: 127, RSSI -80  C:0 S:0 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    [DEVICE]: 5C:C1:F0:C7:67:88 (random), AD evt type 3, Tx Pwr: 127, RSSI -74  C:0 S:0 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    [DEVICE]: 2D:83:D6:E9:FA:B2 (random), AD evt type 3, Tx Pwr: 127, RSSI -97  C:0 S:0 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    [DEVICE]: 69:A8:D3:ED:9D:02 (random), AD evt type 0, Tx Pwr: 127, RSSI -67  C:1 S:1 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    [DEVICE]: 69:A8:D3:ED:9D:02 (random), AD evt type 4, Tx Pwr: 127, RSSI -66 LE-晨曦 C:1 S:1 D:0 SR:1 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    [DEVICE]: 31:0B:98:FB:F6:28 (random), AD evt type 3, Tx Pwr: 127, RSSI -90  C:0 S:0 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    [DEVICE]: 5D:12:A0:42:67:CA (random), AD evt type 0, Tx Pwr: 127, RSSI -89  C:1 S:1 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    [DEVICE]: 17:96:C5:EB:02:CE (random), AD evt type 3, Tx Pwr: 127, RSSI -83  C:0 S:0 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    [DEVICE]: 5F:F7:5B:88:F2:BF (random), AD evt type 0, Tx Pwr: 127, RSSI -79  C:1 S:1 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    [DEVICE]: 5F:F7:5B:88:F2:BF (random), AD evt type 4, Tx Pwr: 127, RSSI -79  C:1 S:1 D:0 SR:1 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    [DEVICE]: 7F:04:80:25:B2:FD (random), AD evt type 0, Tx Pwr: 127, RSSI -90  C:1 S:1 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    [DEVICE]: 38:A6:4D:3B:8E:4C (random), AD evt type 3, Tx Pwr: 127, RSSI -56  C:0 S:0 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    [DEVICE]: 1C:46:A4:7B:F0:4C (random), AD evt type 3, Tx Pwr: 127, RSSI -67  C:0 S:0 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    [DEVICE]: 00:BC:E9:16:2F:D9 (random), AD evt type 3, Tx Pwr: 127, RSSI -80  C:0 S:0 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    [DEVICE]: 3D:B6:BC:D3:8F:23 (random), AD evt type 5, Tx Pwr: 127, RSSI -36 DF Connectionless Beacon App C:0 S:0 D:0 SR:0 E:1 Prim: LE 1M, Secn: LE 2M, Interval: 0x0780 (2400 ms), SID: 0
    success. Found periodic advertising.
    Creating Periodic Advertising Sync...success.
    Waiting for periodic sync...
    [DEVICE]: 75:3F:EA:42:F9:0D (random), AD evt type 0, Tx Pwr: 127, RSSI -70  C:1 S:1 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    [DEVICE]: 75:3F:EA:42:F9:0D (random), AD evt type 4, Tx Pwr: 127, RSSI -70  C:1 S:1 D:0 SR:1 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    [DEVICE]: 07:7A:C5:61:5F:8B (random), AD evt type 3, Tx Pwr: 127, RSSI -51  C:0 S:0 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    [DEVICE]: 3D:A2:53:A0:B7:85 (random), AD evt type 3, Tx Pwr: 127, RSSI -87  C:0 S:0 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    [DEVICE]: 11:D6:AB:B0:8B:32 (random), AD evt type 3, Tx Pwr: 127, RSSI -86  C:0 S:0 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    [DEVICE]: 17:95:25:48:98:46 (random), AD evt type 3, Tx Pwr: 127, RSSI -80  C:0 S:0 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    [DEVICE]: 17:EE:ED:DD:BE:7E (random), AD evt type 3, Tx Pwr: 127, RSSI -57  C:0 S:0 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    [DEVICE]: 08:03:CD:B1:5F:83 (random), AD evt type 3, Tx Pwr: 127, RSSI -69  C:0 S:0 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    [DEVICE]: 3A:FC:5C:0C:54:96 (random), AD evt type 3, Tx Pwr: 127, RSSI -84  C:0 S:0 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    [DEVICE]: 45:DF:6C:8A:91:CC (random), AD evt type 3, Tx Pwr: 127, RSSI -59  C:0 S:0 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    [DEVICE]: 71:90:71:12:09:F0 (random), AD evt type 3, Tx Pwr: 127, RSSI -63  C:0 S:0 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    [DEVICE]: 31:0B:98:FB:F6:28 (random), AD evt type 3, Tx Pwr: 127, RSSI -89  C:0 S:0 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    [DEVICE]: 56:F5:DA:3A:5B:D3 (random), AD evt type 3, Tx Pwr: 127, RSSI -65  C:0 S:0 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    [DEVICE]: 5C:C1:F0:C7:67:88 (random), AD evt type 3, Tx Pwr: 127, RSSI -76  C:0 S:0 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    [DEVICE]: 17:96:C5:EB:02:CE (random), AD evt type 3, Tx Pwr: 127, RSSI -74  C:0 S:0 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    [DEVICE]: 3A:6E:F3:AA:F5:88 (random), AD evt type 3, Tx Pwr: 127, RSSI -67  C:0 S:0 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    [DEVICE]: 0B:CF:A8:09:1D:8B (random), AD evt type 3, Tx Pwr: 127, RSSI -94  C:0 S:0 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    [DEVICE]: 7F:04:80:25:B2:FD (random), AD evt type 0, Tx Pwr: 127, RSSI -87  C:1 S:1 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    [DEVICE]: 7F:04:80:25:B2:FD (random), AD evt type 4, Tx Pwr: 127, RSSI -88  C:1 S:1 D:0 SR:1 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    [DEVICE]: 02:E8:71:9F:4A:DF (random), AD evt type 3, Tx Pwr: 127, RSSI -75  C:0 S:0 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    [DEVICE]: 3D:B6:BC:D3:8F:23 (random), AD evt type 5, Tx Pwr: 127, RSSI -35 DF Connectionless Beacon App C:0 S:0 D:0 SR:0 E:1 Prim: LE 1M, Secn: LE 2M, Interval: 0x0780 (2400 ms), SID: 0
    [DEVICE]: 41:17:8B:EA:B4:EF (random), AD evt type 0, Tx Pwr: 127, RSSI -91  C:1 S:1 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    [DEVICE]: 75:3F:EA:42:F9:0D (random), AD evt type 0, Tx Pwr: 127, RSSI -70  C:1 S:1 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    [DEVICE]: 75:3F:EA:42:F9:0D (random), AD evt type 4, Tx Pwr: 127, RSSI -70  C:1 S:1 D:0 SR:1 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    [DEVICE]: 4B:57:B9:4B:A1:CB (random), AD evt type 2, Tx Pwr: 127, RSSI -65  C:0 S:1 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    [DEVICE]: 47:AB:48:64:6F:02 (public), AD evt type 0, Tx Pwr: 127, RSSI -87  C:1 S:1 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    [DEVICE]: 5D:12:A0:42:67:CA (random), AD evt type 0, Tx Pwr: 127, RSSI -74  C:1 S:1 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    [DEVICE]: 5D:12:A0:42:67:CA (random), AD evt type 4, Tx Pwr: 127, RSSI -74  C:1 S:1 D:0 SR:1 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    [DEVICE]: 38:A6:4D:3B:8E:4C (random), AD evt type 3, Tx Pwr: 127, RSSI -50  C:0 S:0 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    [DEVICE]: 11:D6:AB:B0:8B:32 (random), AD evt type 3, Tx Pwr: 127, RSSI -84  C:0 S:0 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    [DEVICE]: 6B:E6:35:5B:86:E5 (random), AD evt type 0, Tx Pwr: 127, RSSI -70  C:1 S:1 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0

    2.continuous second time programming code:

    Most of the time it's like this:

    [DEVICE]: 26:30:76:21:1B:4E (random), AD evt type 3, Tx Pwr: 127, RSSI -87  C:0 S:0 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    success. Found periodic advertising.
    Creating Periodic Advertising Sync...ASSERTION FAIL [err == 0] @ WEST_TOPDIR/zephyr/subsys/bluetooth/host/hci_core.c:338
    *** Booting nRF Connect SDK v2.5.0 ***with err -11
    Starting Connectionless Locator Demo
    Bluetooth initialization...failed (err -11)
    success
    Scan callbacks register...success.
    Periodic Advertising callbacks register...success.
    Start scannin*** Booting nRF Connect SDK v2.5.0 ***
    Starting Connectionless Locator Demo
    Bluetooth initialization...success
    Scan callbacks register...success.
    Periodic Advertising callbacks register...success.
    Start scanning...success
    Waiting for periodic advertising...
    [DEVICE]: 0F:8C:38:71:57:52 (random), AD evt type 3, Tx Pwr: 127, RSSI -61  C:0 S:0 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    [DEVICE]: 4F:FD:EB:D7:69:D6 (random), AD evt type 3, Tx Pwr: 127, RSSI -61  C:0 S:0 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    [DEVICE]: 0B:80:29:1E:C4:95 (random), AD evt type 3, Tx Pwr: 127, RSSI -69  C:0 S:0 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    [DEVICE]: 55:20:C3:85:85:52 (random), AD evt type 0, Tx Pwr: 127, RSSI -67  C:1 S:1 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    [DEVICE]: 55:20:C3:85:85:52 (random), AD evt type 4, Tx Pwr: 127, RSSI -67  C:1 S:1 D:0 SR:1 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    [DEVICE]: 38:48:5B:8F:8A:2E (random), AD evt type 3, Tx Pwr: 127, RSSI -71  C:0 S:0 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    [DEVICE]: 28:3E:3A:93:D2:A5 (random), AD evt type 3, Tx Pwr: 127, RSSI -67  C:0 S:0 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    [DEVICE]: 26:30:76:21:1B:4E (random), AD evt type 3, Tx Pwr: 127, RSSI -86  C:0 S:0 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    [DEVICE]: 2B:1C:F0:03:5F:61 (random), AD evt type 3, Tx Pwr: 127, RSSI -62  C:0 S:0 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    [DEVICE]: 0B:16:B6:9F:98:10 (random), AD evt type 3, Tx Pwr: 127, RSSI -78  C:0 S:0 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    [DEVICE]: 30:66:D0:50:F8:45 (public), AD evt type 0, Tx Pwr: 127, RSSI -80  C:1 S:1 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    [DEVICE]: 30:66:D0:50:F8:45 (public), AD evt type 4, Tx Pwr: 127, RSSI -79 M-Pencil C:1 S:1 D:0 SR:1 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    [DEVICE]: 06:D9:32:56:79:FC (random), AD evt type 3, Tx Pwr: 127, RSSI -88  C:0 S:0 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    [DEVICE]: 75:7E:21:65:97:CD (random), AD evt type 0, Tx Pwr: 127, RSSI -94  C:1 S:1 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    [DEVICE]: 5C:E5:A6:C4:F1:12 (random), AD evt type 3, Tx Pwr: 127, RSSI -73  C:0 S:0 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    [DEVICE]: 16:E5:3F:ED:54:96 (random), AD evt type 3, Tx Pwr: 127, RSSI -95  C:0 S:0 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    [DEVICE]: 39:9E:87:42:68:38 (random), AD evt type 3, Tx Pwr: 127, RSSI -83  C:0 S:0 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    [DEVICE]: 3D:B6:BC:D3:8F:23 (random), AD evt type 5, Tx Pwr: 127, RSSI -47 DF Connectionless Beacon App C:0 S:0 D:0 SR:0 E:1 Prim: LE 1M, Secn: LE 2M, Interval: 0x0780 (2400 ms), SID: 0
    [DEVICE]: 7F:04:80:25:B2:FD (random), AD evt type 0, Tx Pwr: 127, RSSI -93  C:1 S:1 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    [DEVICE]: 7F:04:80:25:B2:FD (random), AD evt type 4, Tx Pwr: 127, RSSI -91  C:1 S:1 D:0 SR:1 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    [DEVICE]: 10:76:14:C2:E1:3A (random), AD evt type 3, Tx Pwr: 127, RSSI -57  C:0 S:0 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    [DEVICE]: 2F:F8:4B:94:0B:52 (random), AD evt type 3, Tx Pwr: 127, RSSI -81  C:0 S:0 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    [DEVICE]: 7B:7C:AB:6B:48:81 (random), AD evt type 0, Tx Pwr: 127, RSSI -93  C:1 S:1 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    [DEVICE]: 4C:B3:E8:56:D8:52 (random), AD evt type 0, Tx Pwr: 127, RSSI -64  C:1 S:1 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    [DEVICE]: 4C:B3:E8:56:D8:52 (random), AD evt type 4, Tx Pwr: 127, RSSI -64  C:1 S:1 D:0 SR:1 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    [DEVICE]: 0B:80:29:1E:C4:95 (random), AD evt type 3, Tx Pwr: 127, RSSI -68  C:0 S:0 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    [DEVICE]: 76:E3:27:25:EE:00 (random), AD evt type 0, Tx Pwr: 127, RSSI -69  C:1 S:1 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    [DEVICE]: 76:E3:27:25:EE:00 (random), AD evt type 4, Tx Pwr: 127, RSSI -69  C:1 S:1 D:0 SR:1 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    [DEVICE]: 0F:8C:38:71:57:52 (random), AD evt type 3, Tx Pwr: 127, RSSI -52  C:0 S:0 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    [DEVICE]: 7C:1E:16:3E:76:F9 (random), AD evt type 3, Tx Pwr: 127, RSSI -92  C:0 S:0 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    [DEVICE]: 7B:C9:66:B6:57:57 (random), AD evt type 3, Tx Pwr: 127, RSSI -69  C:0 S:0 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    [DEVICE]: 4F:32:44:C6:F7:B4 (random), AD evt type 0, Tx Pwr: 127, RSSI -68  C:1 S:1 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    [DEVICE]: 4F:32:44:C6:F7:B4 (random), AD evt type 4, Tx Pwr: 127, RSSI -68 LE-���曦 C:1 S:1 D:0 SR:1 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    [DEVICE]: 2B:1C:F0:03:5F:61 (random), AD evt type 3, Tx Pwr: 127, RSSI -59  C:0 S:0 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    [DEVICE]: 39:D1:3F:C9:DF:70 (random), AD evt type 3, Tx Pwr: 127, RSSI -81  C:0 S:0 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    [DEVICE]: E6:B0:BE:EF:B7:5A (random), AD evt type 0, Tx Pwr: 127, RSSI -81  C:1 S:1 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    [DEVICE]: CF:62:C2:8A:64:34 (random), AD evt type 3, Tx Pwr: 127, RSSI -72  C:0 S:0 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    [DEVICE]: 30:66:D0:50:F8:45 (public), AD evt type 0, Tx Pwr: 127, RSSI -72  C:1 S:1 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    [DEVICE]: 30:66:D0:50:F8:45 (public), AD evt type 4, Tx Pwr: 127, RSSI -72 M-Pencil C:1 S:1 D:0 SR:1 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    [DEVICE]: 4F:FD:EB:D7:69:D6 (random), AD evt type 3, Tx Pwr: 127, RSSI -59  C:0 S:0 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    [DEVICE]: 26:30:76:21:1B:4E (random), AD evt type 3, Tx Pwr: 127, RSSI -83  C:0 S:0 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    [DEVICE]: 2F:13:1E:81:59:A5 (random), AD evt type 3, Tx Pwr: 127, RSSI -90  C:0 S:0 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    Sometimes it's like this:

    success. Periodic sync established.
    Enable receiving of CTE...
    *** Booting nRF Connect SDK v2.5.0 ***
    Starting Connectionless Locator Demo
    Bluetooth initialization...success
    Scan callbacks register...success.
    Periodic Advertising callbacks register...success.
    Start scanning...success
    Waiting for periodic advertising...
    [DEVICE]: 34:8C:70:3B:C3:21 (random), AD evt type 3, Tx Pwr: 127, RSSI -87  C:0 S:0 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    [DEVICE]: 38:A6:4D:3B:8E:4C (random), AD evt type 3, Tx Pwr: 127, RSSI -59  C:0 S:0 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    [DEVICE]: 17:96:C5:EB:02:CE (random), AD evt type 3, Tx Pwr: 127, RSSI -87  C:0 S:0 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    [DEVICE]: 0B:CF:A8:09:1D:8B (random), AD evt type 3, Tx Pwr: 127, RSSI -95  C:0 S:0 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    [DEVICE]: 55:59:9E:F3:0D:D6 (random), AD evt type 3, Tx Pwr: 127, RSSI -64  C:0 S:0 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    [DEVICE]: 5C:C1:F0:C7:67:88 (random), AD evt type 3, Tx Pwr: 127, RSSI -66  C:0 S:0 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    [DEVICE]: 34:65:8B:3E:C4:55 (random), AD evt type 3, Tx Pwr: 127, RSSI -75  C:0 S:0 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    [DEVICE]: 07:7A:C5:61:5F:8B (random), AD evt type 3, Tx Pwr: 127, RSSI -63  C:0 S:0 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    [DEVICE]: 11:D6:AB:B0:8B:32 (random), AD evt type 3, Tx Pwr: 127, RSSI -91  C:0 S:0 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    [DEVICE]: 75:3F:EA:42:F9:0D (random), AD evt type 0, Tx Pwr: 127, RSSI -81  C:1 S:1 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    [DEVICE]: 75:3F:EA:42:F9:0D (random), AD evt type 4, Tx Pwr: 127, RSSI -81  C:1 S:1 D:0 SR:1 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    [DEVICE]: 47:AB:48:64:6F:02 (public), AD evt type 0, Tx Pwr: 127, RSSI -93  C:1 S:1 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    [DEVICE]: 5F:F7:5B:88:F2:BF (random), AD evt type 0, Tx Pwr: 127, RSSI -67  C:1 S:1 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    [DEVICE]: 5F:F7:5B:88:F2:BF (random), AD evt type 4, Tx Pwr: 127, RSSI -66  C:1 S:1 D:0 SR:1 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    [DEVICE]: 02:E8:71:9F:4A:DF (random), AD evt type 3, Tx Pwr: 127, RSSI -72  C:0 S:0 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    [DEVICE]: 3A:8B:7E:1B:BA:36 (random), AD evt type 3, Tx Pwr: 127, RSSI -80  C:0 S:0 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    [DEVICE]: 00:BC:E9:16:2F:D9 (random), AD evt type 3, Tx Pwr: 127, RSSI -71  C:0 S:0 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    [DEVICE]: 60:76:33:3A:08:05 (random), AD evt type 2, Tx Pwr: 127, RSSI -72  C:0 S:1 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    [DEVICE]: 46:D4:86:30:08:C7 (random), AD evt type 3, Tx Pwr: 127, RSSI -89  C:0 S:0 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    [DEVICE]: 50:BD:5B:A0:94:5D (random), AD evt type 3, Tx Pwr: 127, RSSI -95  C:0 S:0 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    [DEVICE]: 71:90:71:12:09:F0 (random), AD evt type 3, Tx Pwr: 127, RSSI -60  C:0 S:0 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    [DEVICE]: 1C:46:A4:7B:F0:4C (random), AD evt type 3, Tx Pwr: 127, RSSI -74  C:0 S:0 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    [DEVICE]: 19:85:47:E1:4E:41 (random), AD evt type 3, Tx Pwr: 127, RSSI -93  C:0 S:0 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    [DEVICE]: 62:BB:9B:16:ED:B7 (random), AD evt type 3, Tx Pwr: 127, RSSI -95  C:0 S:0 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    [DEVICE]: 61:FD:9A:F2:5B:EF (random), AD evt type 0, Tx Pwr: 127, RSSI -62  C:1 S:1 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    [DEVICE]: 61:FD:9A:F2:5B:EF (random), AD evt type 4, Tx Pwr: 127, RSSI -63  C:1 S:1 D:0 SR:1 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    [DEVICE]: 69:A8:D3:ED:9D:02 (random), AD evt type 0, Tx Pwr: 127, RSSI -71  C:1 S:1 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    [DEVICE]: 69:A8:D3:ED:9D:02 (random), AD evt type 4, Tx Pwr: 127, RSSI -71 LE-晨曦 C:1 S:1 D:0 SR:1 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    [DEVICE]: 17:EE:ED:DD:BE:7E (random), AD evt type 3, Tx Pwr: 127, RSSI -58  C:0 S:0 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    [DEVICE]: 35:55:77:56:D5:0E (random), AD evt type 3, Tx Pwr: 127, RSSI -80  C:0 S:0 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    [DEVICE]: 3D:A2:53:A0:B7:85 (random), AD evt type 3, Tx Pwr: 127, RSSI -90  C:0 S:0 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    [DEVICE]: 4B:57:B9:4B:A1:CB (random), AD evt type 2, Tx Pwr: 127, RSSI -71  C:0 S:1 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    [DEVICE]: 17:95:25:48:98:46 (random), AD evt type 3, Tx Pwr: 127, RSSI -91  C:0 S:0 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    [DEVICE]: 5D:42:1C:09:26:F4 (random), AD evt type 0, Tx Pwr: 127, RSSI -94  C:1 S:1 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    [DEVICE]: 5C:C1:F0:C7:67:88 (random), AD evt type 3, Tx Pwr: 127, RSSI -67  C:0 S:0 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    [DEVICE]: 34:65:8B:3E:C4:55 (random), AD evt type 3, Tx Pwr: 127, RSSI -68  C:0 S:0 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    [DEVICE]: 07:7A:C5:61:5F:8B (random), AD evt type 3, Tx Pwr: 127, RSSI -58  C:0 S:0 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    [DEVICE]: 38:A6:4D:3B:8E:4C (random), AD evt type 3, Tx Pwr: 127, RSSI -61  C:0 S:0 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    [DEVICE]: 6E:9D:56:1E:56:3B (random), AD evt type 0, Tx Pwr: 127, RSSI -91  C:1 S:1 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    [DEVICE]: 34:8C:70:3B:C3:21 (random), AD evt type 3, Tx Pwr: 127, RSSI -87  C:0 S:0 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    [DEVICE]: 02:E8:71:9F:4A:DF (random), AD evt type 3, Tx Pwr: 127, RSSI -74  C:0 S:0 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    [DEVICE]: 55:59:9E:F3:0D:D6 (random), AD evt type 3, Tx Pwr: 127, RSSI -73  C:0 S:0 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    [DEVICE]: 5D:12:A0:42:67:CA (random), AD evt type 0, Tx Pwr: 127, RSSI -86  C:1 S:1 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    [DEVICE]: 5F:F7:5B:88:F2:BF (random), AD evt type 0, Tx Pwr: 127, RSSI -66  C:1 S:1 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    [DEVICE]: 5F:F7:5B:88:F2:BF (random), AD evt type 4, Tx Pwr: 127, RSSI -66  C:1 S:1 D:0 SR:1 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    [DEVICE]: 69:2F:17:E6:C8:FE (random), AD evt type 3, Tx Pwr: 127, RSSI -67  C:0 S:0 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    [DEVICE]: 3D:B6:BC:D3:8F:23 (random), AD evt type 5, Tx Pwr: 127, RSSI -33 DF Connectionless Beacon App C:0 S:0 D:0 SR:0 E:1 Prim: LE 1M, Secn: LE 2M, Interval: 0x0780 (2400 ms), SID: 0
    [DEVICE]: 3A:8B:7E:1B:BA:36 (random), AD evt type 3, Tx Pwr: 127, RSSI -65  C:0 S:0 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    [DEVICE]: 22:72:2A:A2:A9:9F (random), AD evt type 3, Tx Pwr: 127, RSSI -70  C:0 S:0 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    [DEVICE]: 36:83:2F:F9:82:86 (random), AD evt type 3, Tx Pwr: 127, RSSI -87  C:0 S:0 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    [DEVICE]: 60:76:33:3A:08:05 (random), AD evt type 2, Tx Pwr: 127, RSSI -69  C:0 S:1 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    [DEVICE]: 00:BC:E9:16:2F:D9 (random), AD evt type 3, Tx Pwr: 127, RSSI -68  C:0 S:0 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    [DEVICE]: 1C:46:A4:7B:F0:4C (random), AD evt type 3, Tx Pwr: 127, RSSI -63  C:0 S:0 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255

    Even in rare cases, CTE can be received, but the device's address is not the address of my another board, which means CTE has not been received yet:

    PER_ADV_SYNC[0]: [DEVICE]: 3D:B6:BC:D3:8F:23 (random) synced, Interval 0x0780 (2400 ms), PHY LE 2M
    success. Periodic sync established.
    Enable receiving of CTE...
    success. CTE receive enabled.
    Scan disable...Success.
    Waiting for periodic sync lost...
    CTE[0]: samples count 45, cte type AOD 2 [us], slot durations: 2 [us], packet status CRC OK, RSSI -450
    CTE[0]: samples count 45, cte type AOD 2 [us], slot durations: 2 [us], packet status CRC OK, RSSI -410
    CTE[0]: samples count 45, cte type AOD 2 [us], slot durations: 2 [us], packet status CRC OK, RSSI -410
    CTE[0]: samples count 45, cte type AOD 2 [us], slot durations: 2 [us], packet status CRC OK, RSSI -410
    CTE[0]: samples count 45, cte type AOD 2 [us], slot durations: 2 [us], packet status CRC OK, RSSI -410
    

    Is assertion error reproducible on your end?

    YES,It is reproducible.

    According to the output log of the console, an assertion error occurred at line 338 of hci_core. c. That's the 23rd line of the code I added.The code for this section is as follows:

    int bt_hci_cmd_send_sync(uint16_t opcode, struct net_buf *buf,
    			 struct net_buf **rsp)
    {
    	struct k_sem sync_sem;
    	uint8_t status;
    	int err;
    
    	if (!buf) {
    		buf = bt_hci_cmd_create(opcode, 0);
    		if (!buf) {
    			return -ENOBUFS;
    		}
    	}
    
    	LOG_DBG("buf %p opcode 0x%04x len %u", buf, opcode, buf->len);
    
    	k_sem_init(&sync_sem, 0, 1);
    	cmd(buf)->sync = &sync_sem;
    
    	net_buf_put(&bt_dev.cmd_tx_queue, net_buf_ref(buf));
    
    	err = k_sem_take(&sync_sem, HCI_CMD_TIMEOUT);
    	BT_ASSERT_MSG(err == 0, "command opcode 0x%04x timeout with err %d", opcode, err);
    
    	status = cmd(buf)->status;
    	if (status) {
    		LOG_WRN("opcode 0x%04x status 0x%02x", opcode, status);
    		net_buf_unref(buf);
    
    		switch (status) {
    		case BT_HCI_ERR_CONN_LIMIT_EXCEEDED:
    			return -ECONNREFUSED;
    		case BT_HCI_ERR_INSUFFICIENT_RESOURCES:
    			return -ENOMEM;
    		default:
    			return -EIO;
    		}
    	}
    
    	LOG_DBG("rsp %p opcode 0x%04x len %u", buf, opcode, buf->len);
    
    	if (rsp) {
    		*rsp = buf;
    	} else {
    		net_buf_unref(buf);
    	}
    
    	return 0;
    }

    Best regards,
    xu shengxian

  • Hi,

    Thank you for providing additional information.

    Could you please provide UART log from the network core?

    Best regards,
    Dejan

Reply Children
Related