What do I need to know to add mesh functionality into a normal BLE application ?
What do I need to know to add mesh functionality into a normal BLE application ?
No user71706
Any changes / updates for use with 2.2.0 SDK?
Hi Hung Bui
I tried building the attached example using SES, it fails while linking
Building ‘ble_app_uart_pca10040_s132’ from solution ‘ble_app_uart_pca10040_s132’ in configuration ‘Release’ 1> Assembling ‘thumb_crt0.s’ 2> Compiling ‘nrf_log_backend_rtt.c’ 3> Compiling ‘nrf_log_backend_serial.c’ 4> Compiling ‘nrf_log_default_backends.c’ 1> Compiling ‘nrf_log_frontend.c’ 3> Compiling ‘nrf_log_str_formatter.c’ 4> Compiling ‘app_button.c’ 2> Compiling ‘app_error.c’ 2> Compiling ‘app_error_handler_gcc.c’ 3> Compiling ‘app_error_weak.c’ 1> Compiling ‘app_fifo.c’ 4> Compiling ‘app_scheduler.c’ 2> Compiling ‘app_timer.c’ 3> Compiling ‘app_uart_fifo.c’ 1> Compiling ‘app_util_platform.c’ 4> Compiling ‘hardfault_implementation.c’ 1> Compiling ‘nrf_assert.c’ 3> Compiling ‘nrf_atfifo.c’ 2> Compiling ‘nrf_atflags.c’ 4> Compiling ‘nrf_atomic.c’ 1> Compiling ‘nrf_balloc.c’ 3> Compiling ‘nrf_fprintf.c’ 4> Compiling ‘nrf_fprintf_format.c’ 2> Compiling ‘nrf_fstorage.c’ 1> Compiling ‘nrf_fstorage_sd.c’ 3> Compiling ‘nrf_memobj.c’ 4> Compiling ‘nrf_pwr_mgmt.c’ 2> Compiling ‘nrf_section_iter.c’ 1> Compiling ‘nrf_strerror.c’ 2> Compiling ‘retarget.c’ 3> Assembling ‘ses_nRF_Startup.s’ 4> Assembling ‘ses_nrf52_Vectors.s’ 3> Compiling ‘system_nrf52.c’ 4> Compiling ‘boards.c’ 1> Compiling ‘nrf_drv_clock.c’ 2> Compiling ‘nrf_drv_uart.c’ 3> Compiling ‘nrfx_clock.c’ 2> Compiling ‘nrfx_gpiote.c’ 4> Compiling ‘nrfx_power_clock.c’ 1> Compiling ‘nrfx_prs.c’ 3> Compiling ‘nrfx_uart.c’ 4> Compiling ‘nrfx_uarte.c’ 1> Compiling ‘bsp.c’ 2> Compiling ‘bsp_btn_ble.c’ 1> Compiling ‘main.c’ 3> Compiling ‘SEGGER_RTT.c’ 4> Compiling ‘SEGGER_RTT_Syscalls_SES.c’ 2> Compiling ‘SEGGER_RTT_printf.c’ 4> Compiling ‘ble_advdata.c’ 3> Compiling ‘ble_advertising.c’ 2> Compiling ‘ble_conn_params.c’ 4> Compiling ‘ble_conn_state.c’ 1> Compiling ‘ble_link_ctx_manager.c’ 3> Compiling ‘ble_srv_common.c’ 2> Compiling ‘nrf_ble_gatt.c’ 4> Compiling ‘nrf_ble_qwr.c’ 1> Compiling ‘ble_nus.c’ 3> Compiling ‘nrf_sdh.c’ 4> Compiling ‘nrf_sdh_ble.c’ 2> Compiling ‘nrf_sdh_soc.c’ 1> Compiling ‘mesh_provisionee.c’ 2> Compiling ‘rtt_input.c’ 4> Compiling ‘simple_hal.c’ 3> Compiling ‘mesh_app_utils.c’ 3> Compiling ‘nrf_mesh_weak.c’ 2> Compiling ‘assertion_handler_weak.c’ 4> Compiling ‘internal_event.c’ 1> Compiling ‘nrf_mesh_configure.c’ 2> Compiling ‘aes.c’ 1> Compiling ‘msg_cache.c’ 3> Compiling ‘transport.c’ 4> Compiling ‘event.c’ 2> Compiling ‘packet_buffer.c’ 1> Compiling ‘flash_manager_defrag.c’ 4> Compiling ‘fifo.c’ 2> Compiling ‘nrf_flash.c’ 4> Compiling ‘packet_mgr.c’ 3> Compiling ‘net_state.c’ 1> Compiling ‘mesh_flash.c’ 2> Compiling ‘nrf_mesh_utils.c’ 4> Compiling ‘nrf_mesh.c’ 1> Compiling ‘queue.c’ 3> Compiling ‘hal.c’ 2> Compiling ‘aes_cmac.c’ 4> Compiling ‘timer_scheduler.c’ 3> Compiling ‘timer.c’ 1> Compiling ‘ticker.c’ 1> Compiling ‘rand.c’ 2> Compiling ‘nrf_mesh_opt.c’ 4> Compiling ‘timeslot.c’ 3> Compiling ‘bearer_event.c’ 1> Compiling ‘enc.c’ 2> Compiling ‘network.c’ 3> Compiling ‘net_packet.c’ 4> Compiling ‘msqueue.c’ 1> Compiling ‘nrf_mesh_keygen.c’ 2> Compiling ‘cache.c’ 4> Compiling ‘uri.c’ 3> Compiling ‘list.c’ 2> Compiling ‘log.c’ 1> Compiling ‘flash_manager.c’ 4> Compiling ‘ccm_soft.c’ 3> Compiling ‘toolchain.c’ 2> Compiling ‘replay_cache.c’ 3> Compiling ‘beacon.c’ 2> Compiling ‘flash_manager_internal.c’ 4> Compiling ‘core_tx.c’ 1> Compiling ‘heartbeat.c’ 2> Compiling ‘net_beacon.c’ 3> Compiling ‘fsm.c’ 4> Compiling ‘core_tx_adv.c’ 1> Compiling ‘mesh_stack.c’ 3> Compiling ‘access_publish.c’ 4> Compiling ‘access.c’ 2> Compiling ‘access_reliable.c’ 1> Compiling ‘device_state_manager.c’ 3> Compiling ‘ad_listener.c’ 2> Compiling ‘ad_type_filter.c’ 2> Compiling ‘adv_packet_filter.c’ 4> Compiling ‘advertiser.c’ 3> Compiling ‘bearer_handler.c’ 1> Compiling ‘broadcast.c’ 2> Compiling ‘filter_engine.c’ 3> Compiling ‘gap_address_filter.c’ 4> Compiling ‘radio_config.c’ 4> Compiling ‘rssi_filter.c’ 1> Compiling ‘scanner.c’ 2> Compiling ‘uECC.c’ 3> Compiling ‘prov_provisionee.c’ 4> Compiling ‘nrf_mesh_prov.c’ 1> Compiling ‘provisioning.c’ 2> Compiling ‘prov_beacon.c’ 3> Compiling ‘prov_utils.c’ 4> Compiling ‘prov_bearer_adv.c’ 1> Compiling ‘composition_data.c’ 2> Compiling ‘config_server.c’ 3> Compiling ‘packed_index_list.c’ 1> Compiling ‘health_server.c’ 3> Compiling ‘simple_on_off_server.c’ 1> Generating linker script ‘ble_app_uart_pca10040_s132.ld’ 1> Linking ble_app_uart_pca10040_s132.elf 1> Output/ble_app_uart_pca10040_s132 Release/Obj/bearer_handler.o: In function `TIMER2_IRQHandler': 1> E:\git_repo\Tools\nRF5_SDK_15.0.0_a53641a\components\mesh\mesh\bearer\src/bearer_handler.c:236: multiple definition of `TIMER2_IRQHandler' 1> Output/ble_app_uart_pca10040_s132 Release/Obj/rtt_input.o:E:\git_repo\Tools\nRF5_SDK_15.0.0_a53641a\examples\ble_peripheral\ble_app_uart_mesh\common\src/rtt_input.c:55: first defined here 1> Output/ble_app_uart_pca10040_s132 Release/Obj/access.o: In function `packet_tx': 1> E:\git_repo\Tools\nRF5_SDK_15.0.0_a53641a\components\mesh\mesh\access\src/access.c:378: undefined reference to `access_loopback_handle' 1> E:\git_repo\Tools\nRF5_SDK_15.0.0_a53641a\components\mesh\mesh\access\src/access.c:362: undefined reference to `is_access_loopback' 1> Output/ble_app_uart_pca10040_s132 Release/Obj/access.o: In function `access_init': 1> E:\git_repo\Tools\nRF5_SDK_15.0.0_a53641a\components\mesh\mesh\access\src/access.c:980: undefined reference to `access_loopback_init' 1> Output/ble_app_uart_pca10040_s132 Release/Obj/broadcast.o: In function `broadcast_start': 1> E:\git_repo\Tools\nRF5_SDK_15.0.0_a53641a\components\mesh\mesh\bearer\src/broadcast.c:136: undefined reference to `mesh_pa_setup_start' 1> Output/ble_app_uart_pca10040_s132 Release/Obj/broadcast.o: In function `prepare_last_tx': 1> E:\git_repo\Tools\nRF5_SDK_15.0.0_a53641a\components\mesh\mesh\bearer\src/broadcast.c:107: undefined reference to `mesh_pa_lna_setup_stop' 1> Output/ble_app_uart_pca10040_s132 Release/Obj/broadcast.o: In function `radio_irq_handler': 1> E:\git_repo\Tools\nRF5_SDK_15.0.0_a53641a\components\mesh\mesh\bearer\src/broadcast.c:188: undefined reference to `mesh_pa_lna_disable_start' 1> Output/ble_app_uart_pca10040_s132 Release/Obj/broadcast.o: In function `end_action': 1> E:\git_repo\Tools\nRF5_SDK_15.0.0_a53641a\components\mesh\mesh\bearer\src/broadcast.c:172: undefined reference to `mesh_pa_lna_cleanup' 1> Output/ble_app_uart_pca10040_s132 Release/Obj/broadcast.o: In function `prepare_last_tx': 1> E:\git_repo\Tools\nRF5_SDK_15.0.0_a53641a\components\mesh\mesh\bearer\src/broadcast.c:107: undefined reference to `mesh_pa_lna_setup_stop' 1> Output/ble_app_uart_pca10040_s132 Release/Obj/scanner.o: In function `radio_start': 1> E:\git_repo\Tools\nRF5_SDK_15.0.0_a53641a\components\mesh\mesh\bearer\src/scanner.c:227: undefined reference to `mesh_lna_setup_start' 1> E:\git_repo\Tools\nRF5_SDK_15.0.0_a53641a\components\mesh\mesh\bearer\src/scanner.c:229: undefined reference to `mesh_pa_lna_setup_stop' 1> Output/ble_app_uart_pca10040_s132 Release/Obj/scanner.o: In function `radio_stop': 1> E:\git_repo\Tools\nRF5_SDK_15.0.0_a53641a\components\mesh\mesh\bearer\src/scanner.c:209: undefined reference to `mesh_pa_lna_cleanup' Build failed
Am I missing something?
I also have the same question.
Hi Hung Bui,
ble_app_uart_mesh_SDK2_0_1.zip is working on DK board PCA10040 under SEGGER Embedded studio.
But when flashing the *exe files to a custom board using nrfjprog or nRFgo studio, the board do not advertise. I checked whether flashing is done normally or not by blinking LED.
I questioned this problem on the below url.
I have modifed the ble_app_uart_mesh for my applications, flashing with nrfjprog is fine but no advertising !
Is there some setup issue on segger ?
Any tips or guide? Anyone have same issue?
I also have encountered the same issue. Have you found any solution?
Hi Hung Bui!
Segger embedded studio version:4.12.
nRF5 SDK version:15.2.
nRF5 SDK for mesh version:3.0.
I am trying to compile ble_app_uart_mesh_SDK2_0_1.zip but i got a error.
when i add the source files in the ble_app_uart_mesh project, i can't find the ses_nRF_Startup.s and the ses_nfr52_Vectors.s in nRF5 SDK.
I refer to anther one mesh example, it adds ses_startup_nrf_common.s and ses_startup_nrf52.s. So i add this two files in ble_app_uart_mesh project instead of that two files i can't find.
after that when I compile the ble_app_uart_mesh example, it appears a error like this:
Building ‘ble_app_uart_pca10040_s132’ from solution ‘ble_app_uart_pca10040_s132’ in configuration ‘ Release’ 1> Compiling ‘app_util_platform.c’ 2> Compiling ‘hardfault_implementation.c’ 1> rm failed: can't delete F:/ARM-Linux/jeffrey/BLE_mesh/nRF5_SDK_15.2.0_9412b96/nRF5_SDK_15.2.0_9412b96/examples/ble_peripheral/ble_app_uart_mesh/pca10040/s132/ses/Output/ble_app_uart_pca10040_s132 Release/Obj/system_nrf52.asm 2> rm failed: can't delete F:/ARM-Linux/jeffrey/BLE_mesh/nRF5_SDK_15.2.0_9412b96/nRF5_SDK_15.2.0_9412b96/examples/ble_peripheral/ble_app_uart_mesh/pca10040/s132/ses/Output/ble_app_uart_pca10040_s132 Release/Obj/system_nrf52.asmrm failed: can't delete F:/ARM-Linux/jeffrey/BLE_mesh/nRF5_SDK_15.2.0_9412b96/nRF5_SDK_15.2.0_9412b96/examples/ble_peripheral/ble_app_uart_mesh/pca10040/s132/ses/Output/ble_app_uart_pca10040_s132 Release/Obj/system_nrf52.asm 1> rm failed: can't delete F:/ARM-Linux/jeffrey/BLE_mesh/nRF5_SDK_15.2.0_9412b96/nRF5_SDK_15.2.0_9412b96/examples/ble_peripheral/ble_app_uart_mesh/pca10040/s132/ses/Output/ble_app_uart_pca10040_s132 Release/Obj/system_nrf52.asm 2> rm failed: can't delete F:/ARM-Linux/jeffrey/BLE_mesh/nRF5_SDK_15.2.0_9412b96/nRF5_SDK_15.2.0_9412b96/examples/ble_peripheral/ble_app_uart_mesh/pca10040/s132/ses/Output/ble_app_uart_pca10040_s132 Release/Obj/system_nrf52.asmrm failed: can't delete F:/ARM-Linux/jeffrey/BLE_mesh/nRF5_SDK_15.2.0_9412b96/nRF5_SDK_15.2.0_9412b96/examples/ble_peripheral/ble_app_uart_mesh/pca10040/s132/ses/Output/ble_app_uart_pca10040_s132 Release/Obj/system_nrf52.asm 1> rm failed: can't delete F:/ARM-Linux/jeffrey/BLE_mesh/nRF5_SDK_15.2.0_9412b96/nRF5_SDK_15.2.0_9412b96/examples/ble_peripheral/ble_app_uart_mesh/pca10040/s132/ses/Output/ble_app_uart_pca10040_s132 Release/Obj/system_nrf52.asm 2> rm failed: can't delete F:/ARM-Linux/jeffrey/BLE_mesh/nRF5_SDK_15.2.0_9412b96/nRF5_SDK_15.2.0_9412b96/examples/ble_peripheral/ble_app_uart_mesh/pca10040/s132/ses/Output/ble_app_uart_pca10040_s132 Release/Obj/system_nrf52.asmrm failed: can't delete F:/ARM-Linux/jeffrey/BLE_mesh/nRF5_SDK_15.2.0_9412b96/nRF5_SDK_15.2.0_9412b96/examples/ble_peripheral/ble_app_uart_mesh/pca10040/s132/ses/Output/ble_app_uart_pca10040_s132 Release/Obj/system_nrf52.asm 1> The object file Output/ble_app_uart_pca10040_s132 Release/Obj/system_nrf52.o has been supplied more than once Build failed
Do you know why? And would you tell me how to solve this error specifically? Thank you!!!
Hi,
Have you already fixed the "Permanent storage of provisioning and configuration is not stored on flash" issue?