<?xml version="1.0" encoding="UTF-8" ?>
<?xml-stylesheet type="text/xsl" href="https://devzone.nordicsemi.com/cfs-file/__key/system/syndication/rss.xsl" media="screen"?><rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:slash="http://purl.org/rss/1.0/modules/slash/" xmlns:wfw="http://wellformedweb.org/CommentAPI/" xmlns:atom="http://www.w3.org/2005/Atom"><channel><title>Printf() in NRF51</title><link>https://devzone.nordicsemi.com/f/nordic-q-a/17835/printf-in-nrf51</link><description>Hi!, 
 UART works fine with nrf-ble-tutorial-characteristic-CompletedCode in my nRF51-DK but I&amp;#39;m trying to implement in my application but not works. 
 These are my includes: 
 #include &amp;lt;app_error.h&amp;gt;
#include &amp;lt;app_timer.h&amp;gt;
#include &amp;lt;app_uart.h&amp;gt;</description><dc:language>en-US</dc:language><generator>Telligent Community 13</generator><lastBuildDate>Wed, 23 Nov 2016 10:47:29 GMT</lastBuildDate><atom:link rel="self" type="application/rss+xml" href="https://devzone.nordicsemi.com/f/nordic-q-a/17835/printf-in-nrf51" /><item><title>RE: Printf() in NRF51</title><link>https://devzone.nordicsemi.com/thread/68724?ContentTypeID=1</link><pubDate>Wed, 23 Nov 2016 10:47:29 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:9de86d62-c81b-495a-b7af-a05f12d8a563</guid><dc:creator>Javier</dc:creator><description>&lt;p&gt;Hi!,&lt;/p&gt;
&lt;p&gt;I enabled the NRF_LOG in sdk_config.h and works fine with minicom&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;//==========================================================
// &amp;lt;e&amp;gt; NRF_LOG_ENABLED - nrf_log - Logging
//==========================================================
#ifndef NRF_LOG_ENABLED
#define NRF_LOG_ENABLED 1
#endif

// &amp;lt;e&amp;gt; NRF_LOG_BACKEND_SERIAL_USES_UART - If enabled data is printed over UART
//==========================================================
#ifndef NRF_LOG_BACKEND_SERIAL_USES_UART
#define NRF_LOG_BACKEND_SERIAL_USES_UART 1
#endif
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;minicom output&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;SDH:INFO:sd_ble_enable: RAM START at 0x20002128
APP:INFO:Heart Rate Sensor Start!
APP:INFO:Fast Adverstising
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;Best regards&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Printf() in NRF51</title><link>https://devzone.nordicsemi.com/thread/68723?ContentTypeID=1</link><pubDate>Mon, 21 Nov 2016 19:30:09 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:39e06ef7-5e51-4715-8582-f97d6ee852c8</guid><dc:creator>Javier</dc:creator><description>&lt;p&gt;Thanks Jørgen,&lt;/p&gt;
&lt;p&gt;I had seen those macros in some examples but I was confused, now I have it clear.&lt;/p&gt;
&lt;p&gt;Best regards&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Printf() in NRF51</title><link>https://devzone.nordicsemi.com/thread/68722?ContentTypeID=1</link><pubDate>Mon, 21 Nov 2016 15:30:40 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:a2e68b79-e944-420b-ba2f-05cf3ca24b4a</guid><dc:creator>J&amp;#248;rgen Holmefjord</dc:creator><description>&lt;p&gt;You can find information about the logger module &lt;a href="http://infocenter.nordicsemi.com/topic/com.nordic.infocenter.sdk5.v12.0.0/nrf_log.html?cp=4_0_0_3_15"&gt;here&lt;/a&gt;. It is used in many of the examples in the SDK, for instance &lt;a href="http://infocenter.nordicsemi.com/topic/com.nordic.infocenter.sdk5.v12.0.0/ble_sdk_app_hrs.html?cp=4_0_0_4_2_2_8"&gt;heart rate application&lt;/a&gt;.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Printf() in NRF51</title><link>https://devzone.nordicsemi.com/thread/68721?ContentTypeID=1</link><pubDate>Mon, 21 Nov 2016 15:26:33 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:314d7037-eefd-4f20-b128-07dc3f101488</guid><dc:creator>Javier</dc:creator><description>&lt;p&gt;In SDK12 Release Notes say:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;** Overall **
- Added a new log system across all SDK sources. Replaced printf and 
  the old log system.
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;Which is the new log system?&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Printf() in NRF51</title><link>https://devzone.nordicsemi.com/thread/68720?ContentTypeID=1</link><pubDate>Mon, 21 Nov 2016 15:17:28 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:a8857968-7ce7-46a2-8f36-6494aa5eea18</guid><dc:creator>Javier</dc:creator><description>&lt;p&gt;Thanks!&lt;/p&gt;
&lt;p&gt;I have it done but not works to me:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;PROJECT_NAME := ble_app_template_s132_pca10040

export OUTPUT_FILENAME
#MAKEFILE_NAME := $(CURDIR)/$(word $(words $(MAKEFILE_LIST)),$(MAKEFILE_LIST))
MAKEFILE_NAME := $(MAKEFILE_LIST)
MAKEFILE_DIR := $(dir $(MAKEFILE_NAME) )

TEMPLATE_PATH = ../../../../../../components/toolchain/gcc
ifeq ($(OS),Windows_NT)
include $(TEMPLATE_PATH)/Makefile.windows
else
include $(TEMPLATE_PATH)/Makefile.posix
endif

MK := mkdir
RM := rm -rf

#echo suspend
ifeq (&amp;quot;$(VERBOSE)&amp;quot;,&amp;quot;1&amp;quot;)
NO_ECHO :=
else
NO_ECHO := @
endif

# Toolchain commands
CC              := &amp;#39;$(GNU_INSTALL_ROOT)/bin/$(GNU_PREFIX)-gcc&amp;#39;
AS              := &amp;#39;$(GNU_INSTALL_ROOT)/bin/$(GNU_PREFIX)-as&amp;#39;
AR              := &amp;#39;$(GNU_INSTALL_ROOT)/bin/$(GNU_PREFIX)-ar&amp;#39; -r
LD              := &amp;#39;$(GNU_INSTALL_ROOT)/bin/$(GNU_PREFIX)-ld&amp;#39;
NM              := &amp;#39;$(GNU_INSTALL_ROOT)/bin/$(GNU_PREFIX)-nm&amp;#39;
OBJDUMP         := &amp;#39;$(GNU_INSTALL_ROOT)/bin/$(GNU_PREFIX)-objdump&amp;#39;
OBJCOPY         := &amp;#39;$(GNU_INSTALL_ROOT)/bin/$(GNU_PREFIX)-objcopy&amp;#39;
SIZE            := &amp;#39;$(GNU_INSTALL_ROOT)/bin/$(GNU_PREFIX)-size&amp;#39;

#function for removing duplicates in a list
remduplicates = $(strip $(if $1,$(firstword $1) $(call remduplicates,$(filter-out $(firstword $1),$1))))

#source common to all targets
C_SOURCE_FILES += \
$(abspath ../../../../../../components/libraries/button/app_button.c) \
$(abspath ../../../../../../components/libraries/util/app_error.c) \
$(abspath ../../../../../../components/libraries/util/app_error_weak.c) \
$(abspath ../../../../../../components/libraries/timer/app_timer.c) \
$(abspath ../../../../../../components/libraries/trace/app_trace.c) \
$(abspath ../../../../../../components/libraries/util/app_util_platform.c) \
$(abspath ../../../../../../components/libraries/fstorage/fstorage.c) \
$(abspath ../../../../../../components/libraries/util/nrf_assert.c) \
$(abspath ../../../../../../components/libraries/util/nrf_log.c) \
$(abspath ../../../../../../components/libraries/uart/retarget.c) \
$(abspath ../../../../../../components/libraries/uart/app_uart.c) \
$(abspath ../../../../../../components/libraries/fifo/app_fifo.c) \
$(abspath ../../../../../../components/libraries/sensorsim/sensorsim.c) \
$(abspath ../../../../../../external/segger_rtt/RTT_Syscalls_GCC.c) \
$(abspath ../../../../../../external/segger_rtt/SEGGER_RTT.c) \
$(abspath ../../../../../../external/segger_rtt/SEGGER_RTT_printf.c) \
$(abspath ../../../../../../components/drivers_nrf/delay/nrf_delay.c) \
$(abspath ../../../../../../components/drivers_nrf/common/nrf_drv_common.c) \
$(abspath ../../../../../../components/drivers_nrf/gpiote/nrf_drv_gpiote.c) \
$(abspath ../../../../../../components/drivers_nrf/uart/nrf_drv_uart.c) \
$(abspath ../../../../../../components/drivers_nrf/pstorage/pstorage.c) \
$(abspath ../../../../../bsp/bsp.c) \
$(abspath ../../../../../bsp/bsp_btn_ble.c) \
$(abspath ../../../main.c) \
$(abspath ../../../my_custom_service.c) \
$(abspath ../../../../../../components/ble/common/ble_advdata.c) \
$(abspath ../../../../../../components/ble/ble_advertising/ble_advertising.c) \
$(abspath ../../../../../../components/ble/common/ble_conn_params.c) \
$(abspath ../../../../../../components/ble/common/ble_srv_common.c) \
$(abspath ../../../../../../components/ble/device_manager/device_manager_peripheral.c) \
$(abspath ../../../../../../components/toolchain/system_nrf52.c) \
$(abspath ../../../../../../components/softdevice/common/softdevice_handler/softdevice_handler.c) \

#assembly files common to all targets
ASM_SOURCE_FILES  = $(abspath ../../../../../../components/toolchain/gcc/gcc_startup_nrf52.s)

#includes common to all targets
INC_PATHS  = -I$(abspath ../../../config/ble_app_template_s132_pca10040)
INC_PATHS += -I$(abspath ../../../config)
INC_PATHS += -I$(abspath ../../../../../../components/drivers_nrf/config)
INC_PATHS += -I$(abspath ../../../../../../components/drivers_nrf/delay)
INC_PATHS += -I$(abspath ../../../../../../components/drivers_nrf/uart)
INC_PATHS += -I$(abspath ../../../../../../components/drivers_nrf/pstorage)
INC_PATHS += -I$(abspath ../../../../../../components/drivers_nrf/gpiote)
INC_PATHS += -I$(abspath ../../../../../../components/drivers_nrf/hal)
INC_PATHS += -I$(abspath ../../../../../../components/drivers_nrf/common)
INC_PATHS += -I$(abspath ../../../../../../components/libraries/timer)
INC_PATHS += -I$(abspath ../../../../../../components/libraries/fstorage/config)
INC_PATHS += -I$(abspath ../../../../../../components/libraries/sensorsim)
INC_PATHS += -I$(abspath ../../../../../../components/libraries/uart)
INC_PATHS += -I$(abspath ../../../../../../components/libraries/fifo)
INC_PATHS += -I$(abspath ../../../../../../components/libraries/util)
INC_PATHS += -I$(abspath ../../../../../../components/libraries/button)
INC_PATHS += -I$(abspath ../../../../../../components/libraries/fstorage)
INC_PATHS += -I$(abspath ../../../../../../components/libraries/experimental_section_vars)
INC_PATHS += -I$(abspath ../../../../../../components/libraries/trace)
INC_PATHS += -I$(abspath ../../../../../../components/softdevice/s132/headers/nrf52)
INC_PATHS += -I$(abspath ../../../../../../components/softdevice/s132/headers)
INC_PATHS += -I$(abspath ../../../../../../components/softdevice/common/softdevice_handler)
INC_PATHS += -I$(abspath ../../../../../../components/ble/ble_advertising)
INC_PATHS += -I$(abspath ../../../../../../components/ble/device_manager)
INC_PATHS += -I$(abspath ../../../../../../components/ble/common)
INC_PATHS += -I$(abspath ../../../../../../components/device)
INC_PATHS += -I$(abspath ../../../../../../external/segger_rtt)
INC_PATHS += -I$(abspath ../../../../../bsp)
INC_PATHS += -I$(abspath ../../../../../../components/toolchain/CMSIS/Include)
INC_PATHS += -I$(abspath ../../../../../../components/toolchain/gcc)
INC_PATHS += -I$(abspath ../../../../../../components/toolchain)


OBJECT_DIRECTORY = _build
LISTING_DIRECTORY = $(OBJECT_DIRECTORY)
OUTPUT_BINARY_DIRECTORY = $(OBJECT_DIRECTORY)

# Sorting removes duplicates
BUILD_DIRECTORIES := $(sort $(OBJECT_DIRECTORY) $(OUTPUT_BINARY_DIRECTORY) $(LISTING_DIRECTORY) )

#flags common to all targets
CFLAGS  = -DNRF52
CFLAGS += -DSOFTDEVICE_PRESENT
CFLAGS += -DBOARD_PCA10040
CFLAGS += -DNRF52_PAN_12
CFLAGS += -DNRF52_PAN_15
CFLAGS += -DNRF52_PAN_58
CFLAGS += -DNRF52_PAN_55
CFLAGS += -DNRF52_PAN_54
CFLAGS += -DNRF52_PAN_31
CFLAGS += -DNRF52_PAN_30
CFLAGS += -DNRF52_PAN_51
CFLAGS += -DNRF52_PAN_36
CFLAGS += -DNRF52_PAN_53
CFLAGS += -DNRF_LOG_USES_UART=1
CFLAGS += -DS132
CFLAGS += -DCONFIG_GPIO_AS_PINRESET
CFLAGS += -DBLE_STACK_SUPPORT_REQD
CFLAGS += -DSWI_DISABLE0
CFLAGS += -DNRF52_PAN_20
CFLAGS += -DNRF52_PAN_64
CFLAGS += -DNRF52_PAN_62
CFLAGS += -DNRF52_PAN_63
CFLAGS += -mcpu=cortex-m4
CFLAGS += -mthumb -mabi=aapcs --std=gnu99
CFLAGS += -Wall -O3 -g3
CFLAGS += -mfloat-abi=hard -mfpu=fpv4-sp-d16
# keep every function in separate section. This will allow linker to dump unused functions
CFLAGS += -ffunction-sections -fdata-sections -fno-strict-aliasing
CFLAGS += -fno-builtin --short-enums
# keep every function in separate section. This will allow linker to dump unused functions
LDFLAGS += -Xlinker -Map=$(LISTING_DIRECTORY)/$(OUTPUT_FILENAME).map
LDFLAGS += -mthumb -mabi=aapcs -L $(TEMPLATE_PATH) -T$(LINKER_SCRIPT)
LDFLAGS += -mcpu=cortex-m4
LDFLAGS += -mfloat-abi=hard -mfpu=fpv4-sp-d16
# let linker to dump unused sections
LDFLAGS += -Wl,--gc-sections
# use newlib in nano version
LDFLAGS += --specs=nano.specs -lc -lnosys

# Assembler flags
ASMFLAGS += -x assembler-with-cpp
ASMFLAGS += -DNRF52
ASMFLAGS += -DSOFTDEVICE_PRESENT
ASMFLAGS += -DBOARD_PCA10040
ASMFLAGS += -DNRF52_PAN_12
ASMFLAGS += -DNRF52_PAN_15
ASMFLAGS += -DNRF52_PAN_58
ASMFLAGS += -DNRF52_PAN_55
ASMFLAGS += -DNRF52_PAN_54
ASMFLAGS += -DNRF52_PAN_31
ASMFLAGS += -DNRF52_PAN_30
ASMFLAGS += -DNRF52_PAN_51
ASMFLAGS += -DNRF52_PAN_36
ASMFLAGS += -DNRF52_PAN_53
ASMFLAGS += -DNRF_LOG_USES_UART=1
ASMFLAGS += -DS132
ASMFLAGS += -DCONFIG_GPIO_AS_PINRESET
ASMFLAGS += -DBLE_STACK_SUPPORT_REQD
ASMFLAGS += -DSWI_DISABLE0
ASMFLAGS += -DNRF52_PAN_20
ASMFLAGS += -DNRF52_PAN_64
ASMFLAGS += -DNRF52_PAN_62
ASMFLAGS += -DNRF52_PAN_63

#default target - first one defined
default: clean nrf52832_xxaa_s132

#building all targets
all: clean
	$(NO_ECHO)$(MAKE) -f $(MAKEFILE_NAME) -C $(MAKEFILE_DIR) -e cleanobj
	$(NO_ECHO)$(MAKE) -f $(MAKEFILE_NAME) -C $(MAKEFILE_DIR) -e nrf52832_xxaa_s132

#target for printing all targets
help:
	@echo following targets are available:
	@echo 	nrf52832_xxaa_s132
	@echo 	flash_softdevice

C_SOURCE_FILE_NAMES = $(notdir $(C_SOURCE_FILES))
C_PATHS = $(call remduplicates, $(dir $(C_SOURCE_FILES) ) )
C_OBJECTS = $(addprefix $(OBJECT_DIRECTORY)/, $(C_SOURCE_FILE_NAMES:.c=.o) )

ASM_SOURCE_FILE_NAMES = $(notdir $(ASM_SOURCE_FILES))
ASM_PATHS = $(call remduplicates, $(dir $(ASM_SOURCE_FILES) ))
ASM_OBJECTS = $(addprefix $(OBJECT_DIRECTORY)/, $(ASM_SOURCE_FILE_NAMES:.s=.o) )

vpath %.c $(C_PATHS)
vpath %.s $(ASM_PATHS)

OBJECTS = $(C_OBJECTS) $(ASM_OBJECTS)

nrf52832_xxaa_s132: OUTPUT_FILENAME := nrf52832_xxaa_s132
nrf52832_xxaa_s132: LINKER_SCRIPT=ble_app_template_gcc_nrf52.ld

nrf52832_xxaa_s132: $(BUILD_DIRECTORIES) $(OBJECTS)
	@echo Linking target: $(OUTPUT_FILENAME).out
	$(NO_ECHO)$(CC) $(LDFLAGS) $(OBJECTS) $(LIBS) -lm -o $(OUTPUT_BINARY_DIRECTORY)/$(OUTPUT_FILENAME).out
	$(NO_ECHO)$(MAKE) -f $(MAKEFILE_NAME) -C $(MAKEFILE_DIR) -e finalize

## Create build directories
$(BUILD_DIRECTORIES):
	echo $(MAKEFILE_NAME)
	$(MK) $@

# Create objects from C SRC files
$(OBJECT_DIRECTORY)/%.o: %.c
	@echo Compiling file: $(notdir $&amp;lt;)
	$(NO_ECHO)$(CC) $(CFLAGS) $(INC_PATHS) -c -o $@ $&amp;lt;

# Assemble files
$(OBJECT_DIRECTORY)/%.o: %.s
	@echo Assembly file: $(notdir $&amp;lt;)
	$(NO_ECHO)$(CC) $(ASMFLAGS) $(INC_PATHS) -c -o $@ $&amp;lt;
# Link
$(OUTPUT_BINARY_DIRECTORY)/$(OUTPUT_FILENAME).out: $(BUILD_DIRECTORIES) $(OBJECTS)
	@echo Linking target: $(OUTPUT_FILENAME).out
	$(NO_ECHO)$(CC) $(LDFLAGS) $(OBJECTS) $(LIBS) -lm -o $(OUTPUT_BINARY_DIRECTORY)/$(OUTPUT_FILENAME).out
## Create binary .bin file from the .out file
$(OUTPUT_BINARY_DIRECTORY)/$(OUTPUT_FILENAME).bin: $(OUTPUT_BINARY_DIRECTORY)/$(OUTPUT_FILENAME).out
	@echo Preparing: $(OUTPUT_FILENAME).bin
	$(NO_ECHO)$(OBJCOPY) -O binary $(OUTPUT_BINARY_DIRECTORY)/$(OUTPUT_FILENAME).out $(OUTPUT_BINARY_DIRECTORY)/$(OUTPUT_FILENAME).bin

## Create binary .hex file from the .out file
$(OUTPUT_BINARY_DIRECTORY)/$(OUTPUT_FILENAME).hex: $(OUTPUT_BINARY_DIRECTORY)/$(OUTPUT_FILENAME).out
	@echo Preparing: $(OUTPUT_FILENAME).hex
	$(NO_ECHO)$(OBJCOPY) -O ihex $(OUTPUT_BINARY_DIRECTORY)/$(OUTPUT_FILENAME).out $(OUTPUT_BINARY_DIRECTORY)/$(OUTPUT_FILENAME).hex

finalize: genbin genhex echosize

genbin:
	@echo Preparing: $(OUTPUT_FILENAME).bin
	$(NO_ECHO)$(OBJCOPY) -O binary $(OUTPUT_BINARY_DIRECTORY)/$(OUTPUT_FILENAME).out $(OUTPUT_BINARY_DIRECTORY)/$(OUTPUT_FILENAME).bin

## Create binary .hex file from the .out file
genhex:
	@echo Preparing: $(OUTPUT_FILENAME).hex
	$(NO_ECHO)$(OBJCOPY) -O ihex $(OUTPUT_BINARY_DIRECTORY)/$(OUTPUT_FILENAME).out $(OUTPUT_BINARY_DIRECTORY)/$(OUTPUT_FILENAME).hex
echosize:
	-@echo &amp;#39;&amp;#39;
	$(NO_ECHO)$(SIZE) $(OUTPUT_BINARY_DIRECTORY)/$(OUTPUT_FILENAME).out
	-@echo &amp;#39;&amp;#39;

clean:
	$(RM) $(BUILD_DIRECTORIES)

cleanobj:
	$(RM) $(BUILD_DIRECTORIES)/*.o
flash: nrf52832_xxaa_s132
	@echo Flashing: $(OUTPUT_BINARY_DIRECTORY)/$&amp;lt;.hex
	nrfjprog --program $(OUTPUT_BINARY_DIRECTORY)/$&amp;lt;.hex -f nrf52  --sectorerase
	nrfjprog --reset -f nrf52

## Flash softdevice
flash_softdevice:
	@echo Flashing: s132_nrf52_2.0.0_softdevice.hex
	nrfjprog --program ../../../../../../components/softdevice/s132/hex/s132_nrf52_2.0.0_softdevice.hex -f nrf52 --chiperase
	nrfjprog --reset -f nrf52
&lt;/code&gt;&lt;/pre&gt;
&lt;hr /&gt;
&lt;pre&gt;&lt;code&gt;#include &amp;lt;app_error.h&amp;gt;
#include &amp;lt;app_timer.h&amp;gt;
#include &amp;lt;app_uart.h&amp;gt;
#include &amp;lt;app_util.h&amp;gt;
#include &amp;lt;app_util_platform.h&amp;gt;
#include &amp;lt;ble.h&amp;gt;
#include &amp;lt;ble_advdata.h&amp;gt;
#include &amp;lt;ble_advertising.h&amp;gt;
#include &amp;lt;ble_conn_params.h&amp;gt;
#include &amp;lt;ble_gap.h&amp;gt;
#include &amp;lt;ble_gatt.h&amp;gt;
#include &amp;lt;ble_hci.h&amp;gt;
#include &amp;lt;ble_stack_handler_types.h&amp;gt;
#include &amp;lt;ble_types.h&amp;gt;
#include &amp;lt;boards.h&amp;gt;
#include &amp;lt;bsp.h&amp;gt;
#include &amp;lt;bsp_btn_ble.h&amp;gt;
#include &amp;lt;device_manager.h&amp;gt;
#include &amp;lt;nrf_error.h&amp;gt;
#include &amp;lt;nrf_sdm.h&amp;gt;
#include &amp;lt;nrf_soc.h&amp;gt;
#include &amp;lt;nrf52_bitfields.h&amp;gt;
#include &amp;lt;pca10040.h&amp;gt;
#include &amp;lt;pstorage.h&amp;gt;
#include &amp;lt;pstorage_platform.h&amp;gt;
#include &amp;lt;sdk_errors.h&amp;gt;
#include &amp;lt;softdevice_handler.h&amp;gt;
#include &amp;lt;stdbool.h&amp;gt;
#include &amp;lt;string.h&amp;gt;
#include &amp;lt;sys/_stdint.h&amp;gt;
#include &amp;quot;my_custom_service.h&amp;quot;
&lt;/code&gt;&lt;/pre&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Printf() in NRF51</title><link>https://devzone.nordicsemi.com/thread/68719?ContentTypeID=1</link><pubDate>Mon, 21 Nov 2016 13:18:35 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:6dfb08bc-817a-48e3-a2ab-cde1c21af1fe</guid><dc:creator>J&amp;#248;rgen Holmefjord</dc:creator><description>&lt;p&gt;You also need to include the path to &lt;em&gt;app_fifo.h&lt;/em&gt; in your include paths:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;INC_PATHS += -I$(abspath ../../../../../../components/libraries/fifo)
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;And add &lt;em&gt;app_fifo.c&lt;/em&gt; to your source files:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;C_SOURCE_FILES += $(abspath ../../../../../../components/libraries/fifo/app_fifo.c)
&lt;/code&gt;&lt;/pre&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Printf() in NRF51</title><link>https://devzone.nordicsemi.com/thread/68718?ContentTypeID=1</link><pubDate>Mon, 21 Nov 2016 11:23:23 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:36e319b6-7df1-4c63-b66c-181837353cea</guid><dc:creator>Javier</dc:creator><description>&lt;p&gt;Of course,&lt;/p&gt;
&lt;p&gt;Makefile in my_app_sdk11:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;#source common to all targets
$(abspath ../../../../../../components/libraries/uart/app_uart_fifo.c) \

#includes common to all targets
INC_PATHS += -I$(abspath ../../../../../../components/libraries/uart)
&lt;/code&gt;&lt;/pre&gt;
&lt;hr /&gt;
&lt;pre&gt;&lt;code&gt;javi@PC:~/Development/Nordic/NRF-SDK/nRF5_SDK_11.0.0_89a8197/components/libraries/uart$ tree .
    .
    ├── app_uart.c
    ├── app_uart_fifo.c
    ├── app_uart.h
    └── retarget.c
    
    0 directories, 4 files
&lt;/code&gt;&lt;/pre&gt;
&lt;hr /&gt;
&lt;pre&gt;&lt;code&gt;Compiling file: app_uart_fifo.c
/home/javi/Development/Nordic/NRF-SDK/nRF5_SDK_11.0.0_89a8197/components/libraries/uart/app_uart_fifo.c:14:22: fatal error: app_fifo.h: No such file or directory
Makefile:222: fallo en las instrucciones para el objetivo &amp;#39;_build/app_uart_fifo.o&amp;#39;
 #include &amp;quot;app_fifo.h&amp;quot;
                      ^
compilation terminated.
make: *** [_build/app_uart_fifo.o] Error 1
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;However, yesterday, I started to migrate from SDK11 to SDK12 and I used ble_app_uart as template.&lt;/p&gt;
&lt;p&gt;I put it &lt;a href="https://devzone.nordicsemi.com/question/103857/migrating-custom-service-from-sdk11-to-the-sdk12/"&gt;in another post.&lt;/a&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Printf() in NRF51</title><link>https://devzone.nordicsemi.com/thread/68716?ContentTypeID=1</link><pubDate>Mon, 21 Nov 2016 10:33:15 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:0abdcbae-8864-4809-a052-deb6e169a8c6</guid><dc:creator>J&amp;#248;rgen Holmefjord</dc:creator><description>&lt;p&gt;I see that you are using the macro &lt;code&gt;APP_UART_FIFO_INIT&lt;/code&gt; to init your UART. Can you change your source file include from &lt;em&gt;app_uart.c&lt;/em&gt; to &lt;em&gt;app_uart_fifo.c&lt;/em&gt;?&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Printf() in NRF51</title><link>https://devzone.nordicsemi.com/thread/68715?ContentTypeID=1</link><pubDate>Fri, 18 Nov 2016 13:50:11 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:6d6f5b02-da62-4749-bde1-c0e3542df0a6</guid><dc:creator>Javier</dc:creator><description>&lt;p&gt;Thanks Jørgen but I already have that line in my Makefile.&lt;/p&gt;
&lt;p&gt;Source common to all targets&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;C_SOURCE_FILES += \

$(abspath ../../../../../../components/libraries/uart/app_uart.c) \
$(abspath ../../../../../../components/libraries/uart/retarget.c) \
$(abspath ../../../../../../components/drivers_nrf/uart/nrf_drv_uart.c) \
$(abspath ../../../../../../components/ble/ble_services/ble_nus/ble_nus.c) \
&lt;/code&gt;&lt;/pre&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Printf() in NRF51</title><link>https://devzone.nordicsemi.com/thread/68714?ContentTypeID=1</link><pubDate>Fri, 18 Nov 2016 13:09:15 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:888485c9-97d0-458b-990d-f18cb5be0e27</guid><dc:creator>J&amp;#248;rgen Holmefjord</dc:creator><description>&lt;p&gt;Then you need to add the source file to your Makefile:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;C_SOURCE_FILES += \
$(abspath ../../../../../../components/libraries/uart/retarget.c) \
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;For an example, see the ble_app_uart Makefile.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Printf() in NRF51</title><link>https://devzone.nordicsemi.com/thread/68713?ContentTypeID=1</link><pubDate>Fri, 18 Nov 2016 13:04:16 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:06da2011-3ae1-4cd2-8733-dbc88b8017fb</guid><dc:creator>Javier</dc:creator><description>&lt;p&gt;Nope, I use Eclipse Neon.1 on Ubuntu 16.10&lt;/p&gt;
&lt;p&gt;How I add it to my project?&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Printf() in NRF51</title><link>https://devzone.nordicsemi.com/thread/68712?ContentTypeID=1</link><pubDate>Fri, 18 Nov 2016 13:01:16 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:3bd1af29-6b7b-4cc3-a08a-3be5ecaf7c50</guid><dc:creator>J&amp;#248;rgen Holmefjord</dc:creator><description>&lt;p&gt;You should not include it in the main-file. Just add it to your project. Are you using Keil?&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Printf() in NRF51</title><link>https://devzone.nordicsemi.com/thread/68711?ContentTypeID=1</link><pubDate>Fri, 18 Nov 2016 12:42:06 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:b4b32728-8890-4566-8227-dd7f08756664</guid><dc:creator>Javier</dc:creator><description>&lt;p&gt;I use SDK11. I haven&amp;#39;t error but neither print in console.&lt;/p&gt;
&lt;p&gt;In the &lt;a href="https://github.com/NordicSemiconductor/nrf5-ble-tutorial-characteristic/blob/CompletedCode/main.c"&gt;tutorial&lt;/a&gt; not is include retarget.c&lt;/p&gt;
&lt;p&gt;I don&amp;#39;t understand&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Printf() in NRF51</title><link>https://devzone.nordicsemi.com/thread/68717?ContentTypeID=1</link><pubDate>Fri, 18 Nov 2016 12:27:46 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:8013f3dd-75a6-41cd-a443-ef9eea9bf6be</guid><dc:creator>J&amp;#248;rgen Holmefjord</dc:creator><description>&lt;p&gt;Did you include &lt;em&gt;retarget.c&lt;/em&gt; found in &lt;code&gt;components\libraries\uart&lt;/code&gt; folder? Which SDK version are you using? What are your errors?&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>