Error compiling lpn example from BLE Mesh v5.0.0

Hello,

I am working on BLE MESH using nRF52840. I am trying to put nRF52840 into deep sleep mode. For this I am referring to lpn example in BLE Mesh which makes use of Friend Node. As per documentation, using Friend Node it is possible to put node in Deep Sleep.

My setup:
nRF SDK ver : nRF5_SDK_17.0.2_d674dde
BLE MESH ver : nrf5_SDK_for_Mesh_v5.0.0
Hardware : BT840 based custom board

I am tryting to compile lpn example from examples - nrf5_SDK_for_Mesh_v5.0.0\examples\lpn. It looks like the example needs some modification in order to compile. The example shows this error while compiling.


..\nrf5_sdk_17.0.2_d674dde\modules\nrfx\drivers\include\nrfx_power_clock.h:67:6: error: #error "This code is not supposed to be compiled when neither POWER nor CLOCK is enabled."
67 | #error "This code is not supposed to be compiled when neither POWER nor CLOCK is enabled."

POWER_ENABLED and NRFX_POWER_ENABLED is already 1 in the example code. So upon enabling macros NRF_CLOCK_ENABLED and NRFX_CLOCK_ENABLED or it shows further compilation errors. I was wondering if this is a right way to go about it.


nRF5_SDK_17.0.2_d674dde/external/segger_rtt/SEGGER_RTT_Conf.h:86:46: error: 'SEGGER_RTT_CONFIG_MAX_NUM_DOWN_BUFFERS' undeclared here (not in a function); did you mean 'SEGGER_RTT_MAX_NUM_DOWN_BUFFERS'?
86 | #define SEGGER_RTT_MAX_NUM_DOWN_BUFFERS (SEGGER_RTT_CONFIG_MAX_NUM_DOWN_BUFFERS) // Max. number of down-buffers (H->T) available on this target (Default: 3)
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
../nRF5_SDK_17.0.2_d674dde/external/segger_rtt/SEGGER_RTT_Conf.h:86:46: note: in definition of macro 'SEGGER_RTT_MAX_NUM_DOWN_BUFFERS'
86 | #define SEGGER_RTT_MAX_NUM_DOWN_BUFFERS (SEGGER_RTT_CONFIG_MAX_NUM_DOWN_BUFFERS) // Max. number of down-buffers (H->T) available on this target (Default: 3)
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Kindly let me know the changes/modification required to compile lpn example.

Best Regards,

Rajendra

Parents
  • Hi,

    The LPN example project for the nRF52840 DK builds fine in my end, using the Segger Embedded Studio project lpn_nrf52840_xxAA_s140_7_2_0.emProject.

    Your second error message mentioning nRF5_SDK_17.0.2_d674dde/external/segger_rtt/SEGGER_RTT_Conf.h is a bit suspicious, as in my project the path to that file is nrf5_SDK_for_Mesh_v5.0.0_src/external/rtt/include/SEGGER_RTT_Conf.h. What (if anything) have you done to the example, and what toolchain are you using?

    Regards,
    Terje

  • Hi,

    I am using eclise as an IDE, gcc-arm-none-eabi-10-2020-q4-major compiler and build tools 2.12-20190422-1053.
    Using these tools I am able to build and run light_switch\client and light_switch\server.

    I have copied lpn example from examples folder to local folder and trying to compile it. I have followed same mechanism for light_switch\client and light_switch\server, which are running fine.
    I am also confused about SEGGER_RTT_Conf related error.

    Regards,
    Rajendra

Reply
  • Hi,

    I am using eclise as an IDE, gcc-arm-none-eabi-10-2020-q4-major compiler and build tools 2.12-20190422-1053.
    Using these tools I am able to build and run light_switch\client and light_switch\server.

    I have copied lpn example from examples folder to local folder and trying to compile it. I have followed same mechanism for light_switch\client and light_switch\server, which are running fine.
    I am also confused about SEGGER_RTT_Conf related error.

    Regards,
    Rajendra

Children
No Data
Related