This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

'CONFIG_BT_PER_ADV_SYNC_MAX' undeclared here (not in a function)

Hi,

I met some problems when I tried the sample 'direction_finding_connectionless_rx' in ncs v1.7.1 on nRF5340dk. I copied files to hci_rpmsg/boards as https://developer.nordicsemi.com/nRF_Connect_SDK/doc/latest/zephyr/samples/bluetooth/direction_finding_connectionless_rx/README.html said, here is my nrf5340dk_nrf5340_cpunet.conf:

CONFIG_BT_CTLR=y
CONFIG_BT_LL_SW_SPLIT=y

CONFIG_BT_EXT_ADV=y

CONFIG_BT_CTLR_ADV_EXT=y
CONFIG_BT_CTLR_SYNC_PERIODIC=y

# Enable Direction Finding Feature including AoA and AoD
CONFIG_BT_CTLR_DF=y

# Disable Direction Fiding TX mode
CONFIG_BT_CTLR_DF_ANT_SWITCH_TX=n
CONFIG_BT_CTLR_DF_ADV_CTE_TX=n

direction_finding_connectionless_rx/prj.conf:

CONFIG_BT=y
CONFIG_BT_DEVICE_NAME="DF Connectionless Locator App"

CONFIG_BT_EXT_ADV=y
CONFIG_BT_PER_ADV_SYNC=y
CONFIG_BT_OBSERVER=y

# Enable Direction Finding Feature including AoA and AoD
CONFIG_BT_DF=y
CONFIG_BT_DF_CONNECTIONLESS_CTE_RX=y
 

I built by SES and failed: 

Using git-cmd:west build -b nrf5340dk_nrf5340_cpuapp -- -DOVERLAY_CONFIG=overlay-aod.conf:

I'm not sure how to solve it, I got the same error when I built hci_rpmsg to network core. Please help me.

Thanks in advance!

Parents
  • Hi

    I notice you link to, and build the Zephyr version of the project. Is there a reason for not using the nRF version of the DF locator sample instead? This version is possible to build and run on the DKs. Please note that you'll need to use the master branch for support on the nRF53 DK.

    Are you intending to use Angle-of-Departure? If you're planning on using Angle-of-Arrival (AOA), the overlay-aod.conf file is not necessary to add, but you need to build with the hci_rpmsg as a child image for the network core, where the hci_rpmsg.conf file needs the following defines to enable BT_PER_ADV_SYNC_MAX

    #
    # Copyright (c) 2021 Nordic Semiconductor ASA
    #
    # SPDX-License-Identifier: LicenseRef-Nordic-5-Clause
    #
    
    # Required to enable BT_BUF_CMD_TX_SIZE for LE Set Extended Advertising Data command
    CONFIG_BT_EXT_ADV=y
    
    # Required to enable BT_PER_ADV_SYNC_MAX
    CONFIG_BT_PER_ADV_SYNC=y
    CONFIG_BT_OBSERVER=y
    
    CONFIG_BT_CTLR=y
    CONFIG_BT_LL_SW_SPLIT=y
    
    CONFIG_BT_CTLR_ADV_EXT=y
    CONFIG_BT_CTLR_SYNC_PERIODIC=y
    
    # Enable Direction Finding Feature including AoA and AoD
    CONFIG_BT_CTLR_DF=y
    CONFIG_BT_CTLR_DF_ANT_SWITCH_TX=n
    
    # Disable Direction Finding TX mode
    CONFIG_BT_CTLR_DF_ADV_CTE_TX=n
    

    Best regards,

    Simon

  • Hi Simonr!

    Actually I am a beginner of nrf5340, and I just got used to working with zephyr version. Indeed I sovled this problem by adding CONFIG_BT_PER_ADV_SYNC=y in hci_rpmsg/boards/nrf5340dk_nrf5340_cpunet.conf, it's really great.

    Now I met another problem, I'm working with AoA example without antenna matrix, here's my output:

    PER_ADV_SYNC[0]: [DEVICE]: 06:A2:07:3E:26:C0 (random), tx_power 127, RSSI -28, CTE AOA, data length 0, data: 
    CTE[59]: samples count 168, cte type Unknown, slot durations: 0 [us], packet status CRC OK, RSSI 0

    This seems something wrong, and I'd like to know if additional antenna matrix is necessary, if I need an antenna matrix(I know there is Nordic 12 patch antenna matrix), what's it concrete name? I got nothing by searching on Chinese internet, Thanks for your reply!

    Best Regards.

Reply
  • Hi Simonr!

    Actually I am a beginner of nrf5340, and I just got used to working with zephyr version. Indeed I sovled this problem by adding CONFIG_BT_PER_ADV_SYNC=y in hci_rpmsg/boards/nrf5340dk_nrf5340_cpunet.conf, it's really great.

    Now I met another problem, I'm working with AoA example without antenna matrix, here's my output:

    PER_ADV_SYNC[0]: [DEVICE]: 06:A2:07:3E:26:C0 (random), tx_power 127, RSSI -28, CTE AOA, data length 0, data: 
    CTE[59]: samples count 168, cte type Unknown, slot durations: 0 [us], packet status CRC OK, RSSI 0

    This seems something wrong, and I'd like to know if additional antenna matrix is necessary, if I need an antenna matrix(I know there is Nordic 12 patch antenna matrix), what's it concrete name? I got nothing by searching on Chinese internet, Thanks for your reply!

    Best Regards.

Children
No Data
Related