Beware that this post is related to an SDK in maintenance mode
More Info: Consider nRF Connect SDK for new designs

when i use DF with connectionless with ti 6 antenna array,there is no err in procedure,but i can't get a full output in Rx.where is the problem?

I use NCS version 1.9.1.i use the command line tool to build project and flash the executable file to my board.Both in Rx or Tx are nrf52833dk.

As you see that there are only six(6) antennae i can use.i use RTT to get debug or log.

the next photo is my antenna board.

on the basis of silab 16 antenna array,i modify some configurations about this.

Firsly,i change the antenna _num which is refered to antennae numbers.At the same time,i change the dfu_antenna,the next is my configuration.

/*
 * Copyright (c) 2021 Nordic Semiconductor ASA
 *
 * SPDX-License-Identifier: LicenseRef-Nordic-5-Clause
 */

&radio {
	status = "okay";
	/* This is a number of antennas that are available on antenna matrix
	 * designed by Nordic. For more information see README.rst.
	 */
	dfe-antenna-num = <3>;
	/*dfe-antenna-num = <16>;*/
	/* This is a setting that enables antenna 12 (in antenna matrix designed
	 * by Nordic) for Rx PDU. For more information see README.rst.
	 */
	dfe-pdu-antenna = <0x4>;
	/*dfe-pdu-antenna = <0x0>;*/
	/* These are GPIO pin numbers that are provided to
	 * Radio peripheral. The pins will be acquired by Radio to
	 * drive antenna switching when AoA is enabled.
	 * Pin numbers are selected to drive switches on antenna matrix
	 * desinged by Nordic. For more information see README.rst.
	 */
	dfegpio0-gpios = <&gpio0 3 0>;
	dfegpio1-gpios = <&gpio0 4 0>;
	dfegpio2-gpios = <&gpio0 28 0>;
	dfegpio3-gpios = <&gpio0 29 0>;
};

Them i chnage the antenna partterns as follow in main.c file.i wnat to use  three antennae.

#if defined(CONFIG_BT_DF_CTE_RX_AOA)
/* Example sequence of antenna switch patterns for antenna matrix designed by
 * Nordic. For more information about antenna switch patterns see README.rst.
 */
/*切换顺序,11,12,1,2,10,3,9,4,8,7,6,5  12根天线*/
/*static const uint8_t ant_patterns[] = { 0x2, 0x0, 0x5, 0x6, 0x4, 0x9,
*					0xA, 0x8, 0xD, 0xE, 0xC, 0x1 };*/
/*切换顺序,11,12,1,2,3,4,5,6,7,8,9,10 12根天线*/
/*static const uint8_t ant_patterns[] = { 0x2, 0x0, 0x5, 0x6, 0x1, 0x4,
*					0xC, 0x9, 0xE, 0xD, 0x8, 0xA };*/
/*切换顺序,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16  16根天线*/
/*static const uint8_t ant_patterns[] = { 0x0, 0x8, 0x4, 0xC, 0x2, 0xA, 0x6, 0xE,
*					0x1, 0x9, 0x5, 0xD, 0x3, 0xB, 0x7, 0xF };*/
/*切换顺序,12,9  2根天线*/
/*static const uint8_t ant_patterns[] = { 0x0, 0xC };*/
/*切换顺序,A1.1,A1.2,A1.3  ,3根天线*/
static const uint8_t ant_patterns[] = { 0x4, 0x2, 0x1 };

#endif /* CONFIG_BT_DF_CTE_RX_AOA */

You can see it in last sce second line.The parttern are 0x4, 0x2, 0x1 .

Finally i add the RTT log for my project.i add some configurations about it in prg.conf

#RTT log
CONFIG_USE_SEGGER_RTT=y
CONFIG_RTT_CONSOLE=y
CONFIG_UART_CONSOLE=n

I can get the full output as rst file said in Tx.

The Tx is here.

00> *** Booting Zephyr OS build v2.7.99-ncs1-1  ***
00> Starting Connectionless Beacon Demo
00> Bluetooth initialization...success
00> Advertising set create...success
00> Update CTE params...success
00> Periodic advertising params set...success
00> Enable CTE...success
00> Periodic advertising enable...success
00> Extended advertising enable...success
00> Started extended advertising as DE:86:9B:6D:43:F0 (random)

The Rx have not full output.

Booting Zephyr OS build v2.7.99-ncs1-1  ***
00> Starting Connectionless Locator Demo
00> Bluetooth initialization...success
00> Scan callbacks register...success.
00> Periodic Advertising callbacks register...success.
00> Start scanning...success
00> Waiting for periodic advertising...
00> [DEVICE]: 20:B8:52:EB:41:3A (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
00> [DEVICE]: 70:61:EE:22:88:0C (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
00> [DEVICE]: DD:49:C2:60:5A:F8 (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
00> [DEVICE]: 70:74:BB:30:FF:2F (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
00> [DEVICE]: 2F:E8:97:E4:48:99 (random), AD evt type 3, Tx Pwr: 127, RSSI -79  C:0 S:0 D:0 SR:0 E:0 Prim: LE 1M

As rst file descrbled,the problen exist in  success. Found periodic advertising.

I find it in main.c file,i can't solve this problem. it is controled by void main() in main.c file.

Code is here.

while (true) {
		per_adv_found = false;
		scan_enable();

		printk("Waiting for periodic advertising...\n");
		err = k_sem_take(&sem_per_adv, K_FOREVER);
		if (err) {
			printk("failed (err %d)\n", err);
			return;
		}
		printk("success. Found periodic advertising.\n");

		create_sync();

what do you think this problem?

  • Hello Shu, and sorry about the delay

    Are you able to find the periodic advertising without using the antenna? Have you edited anything in the Direction Finding samples from the SDK besides the switching pattern?

    By the way: The TI Boostxl Antenna should work with our Direction Finding samples, but you may need to trim the switch point to compensate for different delays in the switches. This is described in the nWP036 - Direction Finding.

    on the basis of silab 16 antenna array,i modify some configurations about this.

    Could you expand a bit on what you mean by this?

    Regards,

    Elfving

  • I mean that i can control the 16 antenna array,but think the 6 antenna array are less than 16 antenna array,so i only change the configuration about antenna partterms.i only keep a some of 6 antenna array configuration.but it does't work well.i can't get the full output of Rx .you can see that in my problem.

    Booting Zephyr OS build v2.7.99-ncs1-1  ***
    00> Starting Connectionless Locator Demo
    00> Bluetooth initialization...success
    00> Scan callbacks register...success.
    00> Periodic Advertising callbacks register...success.
    00> Start scanning...success
    00> Waiting for periodic advertising...
    00> [DEVICE]: 20:B8:52:EB:41:3A (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
    00> [DEVICE]: 70:61:EE:22:88:0C (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
    00> [DEVICE]: DD:49:C2:60:5A:F8 (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
    00> [DEVICE]: 70:74:BB:30:FF:2F (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
    00> [DEVICE]: 2F:E8:97:E4:48:99 (random), AD evt type 3, Tx Pwr: 127, RSSI -79  C:0 S:0 D:0 SR:0 E:0 Prim: LE 1M

    yes,i use the DF of connectionnless_rx and tx.as you can see,there is some devices information about advertising.but it can't get the CTE.so what is this problem?

  • I see.

    Could you try the antenna pattern: ant_patterns[] = {0xC,0xA,0x9}; ?

    Regards,

    Elfving

  • yes,i try yir method.but it have a error.i change the configuration,it have no output.

    /*切换顺序,A1.1,A1.2,A1.3  3根天线*/
    /*static const uint8_t ant_patterns[] = { 0x4, 0x2, 0x1 };*/

    i can't get the iq samples.

  • swz_nordic said:
    yes,i try yir method

    I assume you've not only commented out  {0x4, 0x2, 0x1}, but also added the pattern {0xC,0xA,0x9}. Note that you need a minimum of 3 antennas in the pattern.

    I also assume the log you provided from RX simply continues like that indefinitely? It might not always be as quick to find the periodic advertising and get the CTE. Below is the log I've got from trying it just now. 

    [00]*** Booting Zephyr OS build v2.7.99-ncs1  ***
    Starting Connectionless Locator Demo
    Bluetooth initialization...success
    Scan callbacks register...success.
    Periodic Advertising callbacks register...success.
    Start scanning...success
    Waiting for periodic advertising...
    [DEVICE]: 54:88:2C:42:F3:24 (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]: D3:FE:A5:6C:97:17 (random), AD evt type 0, Tx Pwr: 127, RSSI -85 Nordic_UART_Service C:1 S:1 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    [DEVICE]: 60:A2:75:F8:47:B1 (random), AD evt type 2, Tx Pwr: 127, RSSI -81  C:0 S:1 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    [DEVICE]: 11:FF:87:AF:63:E3 (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]: 66:17:F1:1F:D0:8E (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]: D3:01:A5:99:87:48 (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]: 1C:C2:5D:E5:30:4C (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]: 6D:92:10:7E:E0:C4 (random), AD evt type 0, Tx Pwr: 127, RSSI -77  C:1 S:1 D:0 SR:0 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    [DEVICE]: 6D:92:10:7E:E0:C4 (random), AD evt type 4, Tx Pwr: 127, RSSI -76  C:1 S:1 D:0 SR:1 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    [DEVICE]: 2B:6C:E7:4D:C1:F8 (random), AD evt type 5, Tx Pwr: 127, RSSI -43 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]: 66:17:F1:1F:D0:8E (random), AD evt type 4, Tx Pwr: 127, RSSI -77  C:1 S:1 D:0 SR:1 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    [DEVICE]: 70:9D:01:CB:D6:6D (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]: 70:9D:01:CB:D6:6D (random), AD evt type 4, Tx Pwr: 127, RSSI -78  C:1 S:1 D:0 SR:1 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    [DEVICE]: FA:16:C8:B8:42:0B (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]: D3:01:A5:99:87:48 (random), AD evt type 4, Tx Pwr: 127, RSSI -72 Mesh Light Switch C:1 S:1 D:0 SR:1 E:0 Prim: LE 1M, Secn: No packets, Interval: 0x0000 (0 ms), SID: 255
    PER_ADV_SYNC[0]: [DEVICE]: 2B:6C:E7:4D:C1:F8 (random) synced, Interval 0x0780 (2400 ms), PHY LE 2M
    PER_ADV_SYNC[0]: [DEVICE]: 2B:6C:E7:4D:C1:F8 (random), tx_power 127, RSSI -44, CTE AOA, data length 0, data: 
    success. Periodic sync established.
    Enable receiving of CTE...
    success. CTE receive enabled.
    Scan disable...Success.
    Waiting for periodic sync lost...
    PER_ADV_SYNC[0]: [DEVICE]: 2B:6C:E7:4D:C1:F8 (random), tx_power 127, RSSI -45, CTE AOA, data length 0, data: 
    CTE[0]: samples count 45, cte type AOA, slot durations: 2 [us], packet status CRC OK, RSSI -450
    PER_ADV_SYNC[0]: [DEVICE]: 2B:6C:E7:4D:C1:F8 (random), tx_power 127, RSSI -46, CTE AOA, data length 0, data: 
    CTE[0]: samples count 45, cte type AOA, slot durations: 2 [us], packet status CRC OK, RSSI -460
    

    swz_nordic said:
    .but it have a error.i change the configuration,it have no output.

    So you are not only not getting the CTE now, now it additionally doesn't have an output? An by that, do you mean the log from the RX (locator)? Are you getting an output if you switch to the Silab16 antenna array?

    Regards,

    Elfving

Related