This post is older than 2 years and might not be relevant anymore
More Info: Consider searching for newer posts

ble_app_uart not building on GCC

Hi, I have downloaded the SDK 6.0 which contains the ble_app_uart and tried to compile it using GCC, but getting the following error which doesn't make any sense because it is having braces:

../ble_nus.c:197:2: error: (near initialization for 'nus_base_uuid.uuid128') [-Werror=missing-braces]

Since the hrs example compiles fine, I used the same makefile from the hrs example and just changed the source files within the makefile.

Parents
  • Yes thanks, that solves the missing braces error. Now, I get a ton of undefined reference errors. Any suggestions? Sorry, I'm new to eclipse + GCC:

    D:\Nordic Semiconductor\nrf51_sdk_v6_0_0_43681\nrf51822\Board\pca10001\s110\experimental\ble_app_uart\gcc/../main.c:147: undefined reference to app_timer_init' _build/main.o: In functionadvertising_init': D:\Nordic Semiconductor\nrf51_sdk_v6_0_0_43681\nrf51822\Board\pca10001\s110\experimental\ble_app_uart\gcc/../main.c:205: undefined reference to ble_advdata_set' _build/main.o: In functionnus_data_handler': D:\Nordic Semiconductor\nrf51_sdk_v6_0_0_43681\nrf51822\Board\pca10001\s110\experimental\ble_app_uart\gcc/../main.c:220: undefined reference to simple_uart_put' D:\Nordic Semiconductor\nrf51_sdk_v6_0_0_43681\nrf51822\Board\pca10001\s110\experimental\ble_app_uart\gcc/../main.c:222: undefined reference tosimple_uart_put' _build/main.o: In function conn_params_init': D:\Nordic Semiconductor\nrf51_sdk_v6_0_0_43681\nrf51822\Board\pca10001\s110\experimental\ble_app_uart\gcc/../main.c:308: undefined reference toble_conn_params_init' _build/main.o: In function ble_evt_dispatch': D:\Nordic Semiconductor\nrf51_sdk_v6_0_0_43681\nrf51822\Board\pca10001\s110\experimental\ble_app_uart\gcc/../main.c:427: undefined reference toble_conn_params_on_ble_evt' _build/main.o: In function ble_stack_init': D:\Nordic Semiconductor\nrf51_sdk_v6_0_0_43681\nrf51822\Board\pca10001\s110\experimental\ble_app_uart\gcc/../main.c:442: undefined reference tosoftdevice_handler_init' D:\Nordic Semiconductor\nrf51_sdk_v6_0_0_43681\nrf51822\Board\pca10001\s110\experimental\ble_app_uart\gcc/../main.c:452: undefined reference to softdevice_ble_evt_handler_set' _build/main.o: In functionuart_init': D:\Nordic Semiconductor\nrf51_sdk_v6_0_0_43681\nrf51822\Board\pca10001\s110\experimental\ble_app_uart\gcc/../main.c:480: undefined reference to simple_uart_config' _build/main.o: In functionUART0_IRQHandler': D:\Nordic Semiconductor\nrf51_sdk_v6_0_0_43681\nrf51822\Board\pca10001\s110\experimental\ble_app_uart\gcc/../main.c:504: undefined reference to simple_uart_get' _build/main.o: In functionmain': D:\Nordic Semiconductor\nrf51_sdk_v6_0_0_43681\nrf51822\Board\pca10001\s110\experimental\ble_app_uart\gcc/../main.c:538: undefined reference to `simple_uart_putstring' collect2.exe: error: ld returned 1 exit status make: *** [_build/ble_app_uart_s110_xxaa.out] Error 1

  • You should have a look at the makefile in the project I linked to in my answer. There are probably some missing files or incorrect paths in your makefile.

Reply Children
No Data
Related