We are running a survey to help us improve the experience for all of our members. If you see the survey appear, please take the time to tell us about your experience if you can.
Hello
I am using Seggar Embedded Studio for ARM V3.4 and nRF_SDK 12.3.0.
I am using nRF51 DK
I am trying to understand interrupts and interrupt handlers.
The interrupt request for Watchdog timer (i.e. void WDT_IRQHandler(void)) is not getting executed. The control is not going to WDT_IRQHandler.
I did the following attempts to verify if the control was going to WDT_IRQHandler()
1>I tried to switch on the LED
2>I tried to switch off the LED
3>Only a printf() statement inside WDT_IRQHandler() (in debug mode)
The above attempts did not work.
I have defined the following Preprocessor Definitions:-
NO_VTOR_CONFIG
BLE_STACK_SUPPORT_REQD
NRF51422
BOARD_PCA10028
SWI_DISABLE0
NRF51
I have attached main.c file and sdk_config.h files. Please let me know how can I achieve it.
.
/* Copyright (c) 2014 Nordic Semiconductor. All Rights Reserved. * * The information contained herein is property of Nordic Semiconductor ASA. * Terms and conditions of usage are described in detail in NORDIC * SEMICONDUCTOR STANDARD SOFTWARE LICENSE AGREEMENT. * * Licensees are granted free, non-transferable use of the information. NO * WARRANTY of ANY KIND is provided. This heading must NOT be removed from * the file. * */ /* This example shows functionality of the Watchdog. The watchdog will reset the IC every 3 seconds if * it is not reloaded by pressing Button 1. LED 2 will blink during startup, which indicates that the * watchdog has restarted the IC. */ #include <stdbool.h> #include "nrf.h" #include "nrf_drv_gpiote.h" #include "app_error.h" #include "boards.h" #include "nrf_delay.h" #define DELAY 100000 #define NR_OF_STARTUP_BLINKS 10 #define PIN_IN BSP_BUTTON_0 #define PIN_OUT BSP_LED_0 #define PIN_WDT BSP_LED_1 #define PIN_WDT_IRQ_HANDLER BSP_LED_2 void in_pin_handler(nrf_drv_gpiote_pin_t pin, nrf_gpiote_polarity_t action) { nrf_drv_gpiote_out_toggle(PIN_OUT); NRF_WDT->RR[0] = WDT_RR_RR_Reload; //Reload watchdog register 0 } void WDT_IRQHandler(void) { nrf_drv_gpiote_out_toggle(PIN_WDT_IRQ_HANDLER); //The WDT interrupt handler will have around 2 32kHz clock cycles to execute before reset, so you can not actully see this LED blink with your eye. printf("I M in IRQ\n"); } /** * @brief Function for configuring: PIN_IN pin for input, PIN_OUT and PIN_WDT pin for output, * and configures GPIOTE to give an interrupt on pin change. */ static void gpio_init(void) { ret_code_t err_code; err_code = nrf_drv_gpiote_init(); APP_ERROR_CHECK(err_code); nrf_drv_gpiote_out_config_t out_config = GPIOTE_CONFIG_OUT_SIMPLE(false); err_code = nrf_drv_gpiote_out_init(PIN_OUT, &out_config); APP_ERROR_CHECK(err_code); err_code = nrf_drv_gpiote_out_init(PIN_WDT, &out_config); APP_ERROR_CHECK(err_code); err_code = nrf_drv_gpiote_out_init(PIN_WDT_IRQ_HANDLER, &out_config); APP_ERROR_CHECK(err_code); nrf_drv_gpiote_in_config_t in_config = GPIOTE_CONFIG_IN_SENSE_TOGGLE(true); in_config.pull = NRF_GPIO_PIN_PULLUP; err_code = nrf_drv_gpiote_in_init(PIN_IN, &in_config, in_pin_handler); APP_ERROR_CHECK(err_code); nrf_drv_gpiote_in_event_enable(PIN_IN, true); } void wdt_init(void) { NRF_WDT->CONFIG = (WDT_CONFIG_HALT_Pause << WDT_CONFIG_HALT_Pos) | ( WDT_CONFIG_SLEEP_Run << WDT_CONFIG_SLEEP_Pos); //Configure Watchdog. a) Pause watchdog while the CPU is halted by the debugger. b) Keep the watchdog running while the CPU is sleeping. NRF_WDT->CRV = 3*32768; //ca 3 sek. timout NRF_WDT->RREN |= WDT_RREN_RR0_Msk; //Enable reload register 0 // Enable WDT interrupt: NVIC_EnableIRQ(WDT_IRQn); NRF_WDT->INTENSET = WDT_INTENSET_TIMEOUT_Msk; NRF_WDT->TASKS_START = 1; //Start the Watchdog timer } /** * @brief Function for application main entry. */ int main(void) { gpio_init(); //BLINK LED 2 during startup for(int i=0;i<NR_OF_STARTUP_BLINKS;i++) { nrf_drv_gpiote_out_toggle(PIN_WDT); nrf_delay_us(DELAY); } wdt_init(); //Initialize watchdog while (true) { __WFE(); __SEV(); __WFE(); } }
#ifndef SDK_CONFIG_H #define SDK_CONFIG_H // <<< Use Configuration Wizard in Context Menu >>>\n #ifdef USE_APP_CONFIG #include "app_config.h" #endif // <h> nRF_Drivers //========================================================== // <e> CLOCK_ENABLED - nrf_drv_clock - CLOCK peripheral driver //========================================================== #ifndef CLOCK_ENABLED #define CLOCK_ENABLED 1 #endif #if CLOCK_ENABLED // <o> CLOCK_CONFIG_XTAL_FREQ - HF XTAL Frequency // <0=> Default (64 MHz) // <255=> Default (16 MHz) // <0=> 32 MHz #ifndef CLOCK_CONFIG_XTAL_FREQ #define CLOCK_CONFIG_XTAL_FREQ 255 #endif // <o> CLOCK_CONFIG_LF_SRC - LF Clock Source // <0=> RC // <1=> XTAL // <2=> Synth #ifndef CLOCK_CONFIG_LF_SRC #define CLOCK_CONFIG_LF_SRC 1 #endif // <o> CLOCK_CONFIG_IRQ_PRIORITY - Interrupt priority // <i> Priorities 0,2 (nRF51) and 0,1,4,5 (nRF52) are reserved for SoftDevice // <0=> 0 (highest) // <1=> 1 // <2=> 2 // <3=> 3 #ifndef CLOCK_CONFIG_IRQ_PRIORITY #define CLOCK_CONFIG_IRQ_PRIORITY 3 #endif // <e> CLOCK_CONFIG_LOG_ENABLED - Enables logging in the module. //========================================================== #ifndef CLOCK_CONFIG_LOG_ENABLED #define CLOCK_CONFIG_LOG_ENABLED 0 #endif #if CLOCK_CONFIG_LOG_ENABLED // <o> CLOCK_CONFIG_LOG_LEVEL - Default Severity level // <0=> Off // <1=> Error // <2=> Warning // <3=> Info // <4=> Debug #ifndef CLOCK_CONFIG_LOG_LEVEL #define CLOCK_CONFIG_LOG_LEVEL 3 #endif // <o> CLOCK_CONFIG_INFO_COLOR - ANSI escape code prefix. // <0=> Default // <1=> Black // <2=> Red // <3=> Green // <4=> Yellow // <5=> Blue // <6=> Magenta // <7=> Cyan // <8=> White #ifndef CLOCK_CONFIG_INFO_COLOR #define CLOCK_CONFIG_INFO_COLOR 0 #endif // <o> CLOCK_CONFIG_DEBUG_COLOR - ANSI escape code prefix. // <0=> Default // <1=> Black // <2=> Red // <3=> Green // <4=> Yellow // <5=> Blue // <6=> Magenta // <7=> Cyan // <8=> White #ifndef CLOCK_CONFIG_DEBUG_COLOR #define CLOCK_CONFIG_DEBUG_COLOR 0 #endif #endif //CLOCK_CONFIG_LOG_ENABLED // </e> #endif //CLOCK_ENABLED // </e> // <e> WDT_ENABLED - nrf_drv_wdt - WDT peripheral driver //========================================================== #ifndef WDT_ENABLED #define WDT_ENABLED 1 #endif #if WDT_ENABLED // <o> WDT_CONFIG_BEHAVIOUR - WDT behavior in CPU SLEEP or HALT mode // <1=> Run in SLEEP, Pause in HALT // <8=> Pause in SLEEP, Run in HALT // <9=> Run in SLEEP and HALT // <0=> Pause in SLEEP and HALT #ifndef WDT_CONFIG_BEHAVIOUR #define WDT_CONFIG_BEHAVIOUR 1 #endif // <o> WDT_CONFIG_RELOAD_VALUE - Reload value <15-4294967295> #ifndef WDT_CONFIG_RELOAD_VALUE #define WDT_CONFIG_RELOAD_VALUE 2000 #endif // <o> WDT_CONFIG_IRQ_PRIORITY - Interrupt priority // <i> Priorities 0,2 (nRF51) and 0,1,4,5 (nRF52) are reserved for SoftDevice // <0=> 0 (highest) // <1=> 1 // <2=> 2 // <3=> 3 #ifndef WDT_CONFIG_IRQ_PRIORITY #define WDT_CONFIG_IRQ_PRIORITY 3 #endif // <e> WDT_CONFIG_LOG_ENABLED - Enables logging in the module. //========================================================== #ifndef WDT_CONFIG_LOG_ENABLED #define WDT_CONFIG_LOG_ENABLED 0 #endif #if WDT_CONFIG_LOG_ENABLED // <o> WDT_CONFIG_LOG_LEVEL - Default Severity level // <0=> Off // <1=> Error // <2=> Warning // <3=> Info // <4=> Debug #ifndef WDT_CONFIG_LOG_LEVEL #define WDT_CONFIG_LOG_LEVEL 3 #endif // <o> WDT_CONFIG_INFO_COLOR - ANSI escape code prefix. // <0=> Default // <1=> Black // <2=> Red // <3=> Green // <4=> Yellow // <5=> Blue // <6=> Magenta // <7=> Cyan // <8=> White #ifndef WDT_CONFIG_INFO_COLOR #define WDT_CONFIG_INFO_COLOR 0 #endif // <o> WDT_CONFIG_DEBUG_COLOR - ANSI escape code prefix. // <0=> Default // <1=> Black // <2=> Red // <3=> Green // <4=> Yellow // <5=> Blue // <6=> Magenta // <7=> Cyan // <8=> White #ifndef WDT_CONFIG_DEBUG_COLOR #define WDT_CONFIG_DEBUG_COLOR 0 #endif #endif //WDT_CONFIG_LOG_ENABLED // </e> #endif //WDT_ENABLED // </e> // <e> APP_TIMER_ENABLED - app_timer - Application timer functionality //========================================================== #ifndef APP_TIMER_ENABLED #define APP_TIMER_ENABLED 1 #endif #if APP_TIMER_ENABLED // <q> APP_TIMER_WITH_PROFILER - Enable app_timer profiling #ifndef APP_TIMER_WITH_PROFILER #define APP_TIMER_WITH_PROFILER 0 #endif // <q> APP_TIMER_KEEPS_RTC_ACTIVE - Enable RTC always on // <i> If option is enabled RTC is kept running even if there is no active timers. // <i> This option can be used when app_timer is used for timestamping. #ifndef APP_TIMER_KEEPS_RTC_ACTIVE #define APP_TIMER_KEEPS_RTC_ACTIVE 0 #endif #endif //APP_TIMER_ENABLED // </e> //========================================================== // <e> GPIOTE_ENABLED - nrf_drv_gpiote - GPIOTE peripheral driver //========================================================== #ifndef GPIOTE_ENABLED #define GPIOTE_ENABLED 1 #endif #if GPIOTE_ENABLED // <o> GPIOTE_CONFIG_NUM_OF_LOW_POWER_EVENTS - Number of lower power input pins #ifndef GPIOTE_CONFIG_NUM_OF_LOW_POWER_EVENTS #define GPIOTE_CONFIG_NUM_OF_LOW_POWER_EVENTS 1 #endif // <o> GPIOTE_CONFIG_IRQ_PRIORITY - Interrupt priority // <i> Priorities 0,2 (nRF51) and 0,1,4,5 (nRF52) are reserved for SoftDevice // <0=> 0 (highest) // <1=> 1 // <2=> 2 // <3=> 3 #ifndef GPIOTE_CONFIG_IRQ_PRIORITY #define GPIOTE_CONFIG_IRQ_PRIORITY 3 #endif // <e> GPIOTE_CONFIG_LOG_ENABLED - Enables logging in the module. //========================================================== #ifndef GPIOTE_CONFIG_LOG_ENABLED #define GPIOTE_CONFIG_LOG_ENABLED 0 #endif #if GPIOTE_CONFIG_LOG_ENABLED // <o> GPIOTE_CONFIG_LOG_LEVEL - Default Severity level // <0=> Off // <1=> Error // <2=> Warning // <3=> Info // <4=> Debug #ifndef GPIOTE_CONFIG_LOG_LEVEL #define GPIOTE_CONFIG_LOG_LEVEL 3 #endif // <o> GPIOTE_CONFIG_INFO_COLOR - ANSI escape code prefix. // <0=> Default // <1=> Black // <2=> Red // <3=> Green // <4=> Yellow // <5=> Blue // <6=> Magenta // <7=> Cyan // <8=> White #ifndef GPIOTE_CONFIG_INFO_COLOR #define GPIOTE_CONFIG_INFO_COLOR 0 #endif // <o> GPIOTE_CONFIG_DEBUG_COLOR - ANSI escape code prefix. // <0=> Default // <1=> Black // <2=> Red // <3=> Green // <4=> Yellow // <5=> Blue // <6=> Magenta // <7=> Cyan // <8=> White #ifndef GPIOTE_CONFIG_DEBUG_COLOR #define GPIOTE_CONFIG_DEBUG_COLOR 0 #endif #endif //GPIOTE_CONFIG_LOG_ENABLED // </e> #endif //GPIOTE_ENABLED // </e> // <e> PERIPHERAL_RESOURCE_SHARING_ENABLED - nrf_drv_common - Peripheral drivers common module //========================================================== #ifndef PERIPHERAL_RESOURCE_SHARING_ENABLED #define PERIPHERAL_RESOURCE_SHARING_ENABLED 0 #endif #if PERIPHERAL_RESOURCE_SHARING_ENABLED // <e> COMMON_CONFIG_LOG_ENABLED - Enables logging in the module. //========================================================== #ifndef COMMON_CONFIG_LOG_ENABLED #define COMMON_CONFIG_LOG_ENABLED 0 #endif #if COMMON_CONFIG_LOG_ENABLED // <o> COMMON_CONFIG_LOG_LEVEL - Default Severity level // <0=> Off // <1=> Error // <2=> Warning // <3=> Info // <4=> Debug #ifndef COMMON_CONFIG_LOG_LEVEL #define COMMON_CONFIG_LOG_LEVEL 3 #endif // <o> COMMON_CONFIG_INFO_COLOR - ANSI escape code prefix. // <0=> Default // <1=> Black // <2=> Red // <3=> Green // <4=> Yellow // <5=> Blue // <6=> Magenta // <7=> Cyan // <8=> White #ifndef COMMON_CONFIG_INFO_COLOR #define COMMON_CONFIG_INFO_COLOR 0 #endif // <o> COMMON_CONFIG_DEBUG_COLOR - ANSI escape code prefix. // <0=> Default // <1=> Black // <2=> Red // <3=> Green // <4=> Yellow // <5=> Blue // <6=> Magenta // <7=> Cyan // <8=> White #ifndef COMMON_CONFIG_DEBUG_COLOR #define COMMON_CONFIG_DEBUG_COLOR 0 #endif #endif //COMMON_CONFIG_LOG_ENABLED // </e> #endif //PERIPHERAL_RESOURCE_SHARING_ENABLED // </e> // <e> UART_ENABLED - nrf_drv_uart - UART/UARTE peripheral driver //========================================================== #ifndef UART_ENABLED #define UART_ENABLED 1 #endif #if UART_ENABLED // <o> UART_DEFAULT_CONFIG_HWFC - Hardware Flow Control // <0=> Disabled // <1=> Enabled #ifndef UART_DEFAULT_CONFIG_HWFC #define UART_DEFAULT_CONFIG_HWFC 0 #endif // <o> UART_DEFAULT_CONFIG_PARITY - Parity // <0=> Excluded // <14=> Included #ifndef UART_DEFAULT_CONFIG_PARITY #define UART_DEFAULT_CONFIG_PARITY 0 #endif // <o> UART_DEFAULT_CONFIG_BAUDRATE - Default Baudrate // <323584=> 1200 baud // <643072=> 2400 baud // <1290240=> 4800 baud // <2576384=> 9600 baud // <3862528=> 14400 baud // <5152768=> 19200 baud // <7716864=> 28800 baud // <10289152=> 38400 baud // <15400960=> 57600 baud // <20615168=> 76800 baud // <30924800=> 115200 baud // <61865984=> 230400 baud // <67108864=> 250000 baud // <121634816=> 460800 baud // <251658240=> 921600 baud // <268435456=> 57600 baud #ifndef UART_DEFAULT_CONFIG_BAUDRATE #define UART_DEFAULT_CONFIG_BAUDRATE 30924800 #endif // <o> UART_DEFAULT_CONFIG_IRQ_PRIORITY - Interrupt priority // <i> Priorities 0,2 (nRF51) and 0,1,4,5 (nRF52) are reserved for SoftDevice // <0=> 0 (highest) // <1=> 1 // <2=> 2 // <3=> 3 #ifndef UART_DEFAULT_CONFIG_IRQ_PRIORITY #define UART_DEFAULT_CONFIG_IRQ_PRIORITY 3 #endif // <q> UART_EASY_DMA_SUPPORT - Driver supporting EasyDMA #ifndef UART_EASY_DMA_SUPPORT #define UART_EASY_DMA_SUPPORT 1 #endif // <q> UART_LEGACY_SUPPORT - Driver supporting Legacy mode #ifndef UART_LEGACY_SUPPORT #define UART_LEGACY_SUPPORT 1 #endif // <e> UART0_ENABLED - Enable UART0 instance //========================================================== #ifndef UART0_ENABLED #define UART0_ENABLED 1 #endif #if UART0_ENABLED // <q> UART0_CONFIG_USE_EASY_DMA - Default setting for using EasyDMA #ifndef UART0_CONFIG_USE_EASY_DMA #define UART0_CONFIG_USE_EASY_DMA 1 #endif #endif //UART0_ENABLED // </e> // <e> UART_CONFIG_LOG_ENABLED - Enables logging in the module. //========================================================== #ifndef UART_CONFIG_LOG_ENABLED #define UART_CONFIG_LOG_ENABLED 0 #endif #if UART_CONFIG_LOG_ENABLED // <o> UART_CONFIG_LOG_LEVEL - Default Severity level // <0=> Off // <1=> Error // <2=> Warning // <3=> Info // <4=> Debug #ifndef UART_CONFIG_LOG_LEVEL #define UART_CONFIG_LOG_LEVEL 3 #endif // <o> UART_CONFIG_INFO_COLOR - ANSI escape code prefix. // <0=> Default // <1=> Black // <2=> Red // <3=> Green // <4=> Yellow // <5=> Blue // <6=> Magenta // <7=> Cyan // <8=> White #ifndef UART_CONFIG_INFO_COLOR #define UART_CONFIG_INFO_COLOR 0 #endif // <o> UART_CONFIG_DEBUG_COLOR - ANSI escape code prefix. // <0=> Default // <1=> Black // <2=> Red // <3=> Green // <4=> Yellow // <5=> Blue // <6=> Magenta // <7=> Cyan // <8=> White #ifndef UART_CONFIG_DEBUG_COLOR #define UART_CONFIG_DEBUG_COLOR 0 #endif #endif //UART_CONFIG_LOG_ENABLED // </e> #endif //UART_ENABLED // </e> // </h> //========================================================== // <h> nRF_Log //========================================================== // <e> NRF_LOG_ENABLED - nrf_log - Logging //========================================================== #ifndef NRF_LOG_ENABLED #define NRF_LOG_ENABLED 0 #endif #if NRF_LOG_ENABLED // <e> NRF_LOG_USES_COLORS - If enabled then ANSI escape code for colors is prefixed to every string //========================================================== #ifndef NRF_LOG_USES_COLORS #define NRF_LOG_USES_COLORS 0 #endif #if NRF_LOG_USES_COLORS // <o> NRF_LOG_COLOR_DEFAULT - ANSI escape code prefix. // <0=> Default // <1=> Black // <2=> Red // <3=> Green // <4=> Yellow // <5=> Blue // <6=> Magenta // <7=> Cyan // <8=> White #ifndef NRF_LOG_COLOR_DEFAULT #define NRF_LOG_COLOR_DEFAULT 0 #endif // <o> NRF_LOG_ERROR_COLOR - ANSI escape code prefix. // <0=> Default // <1=> Black // <2=> Red // <3=> Green // <4=> Yellow // <5=> Blue // <6=> Magenta // <7=> Cyan // <8=> White #ifndef NRF_LOG_ERROR_COLOR #define NRF_LOG_ERROR_COLOR 0 #endif // <o> NRF_LOG_WARNING_COLOR - ANSI escape code prefix. // <0=> Default // <1=> Black // <2=> Red // <3=> Green // <4=> Yellow // <5=> Blue // <6=> Magenta // <7=> Cyan // <8=> White #ifndef NRF_LOG_WARNING_COLOR #define NRF_LOG_WARNING_COLOR 0 #endif #endif //NRF_LOG_USES_COLORS // </e> // <o> NRF_LOG_DEFAULT_LEVEL - Default Severity level // <0=> Off // <1=> Error // <2=> Warning // <3=> Info // <4=> Debug #ifndef NRF_LOG_DEFAULT_LEVEL #define NRF_LOG_DEFAULT_LEVEL 3 #endif // <e> NRF_LOG_DEFERRED - Enable deffered logger. // <i> Log data is buffered and can be processed in idle. //========================================================== #ifndef NRF_LOG_DEFERRED #define NRF_LOG_DEFERRED 1 #endif #if NRF_LOG_DEFERRED // <o> NRF_LOG_DEFERRED_BUFSIZE - Size of the buffer for logs in words. // <i> Must be power of 2 #ifndef NRF_LOG_DEFERRED_BUFSIZE #define NRF_LOG_DEFERRED_BUFSIZE 256 #endif #endif //NRF_LOG_DEFERRED // </e> // <q> NRF_LOG_USES_TIMESTAMP - Enable timestamping // <i> Function for getting the timestamp is provided by the user #ifndef NRF_LOG_USES_TIMESTAMP #define NRF_LOG_USES_TIMESTAMP 0 #endif #endif //NRF_LOG_ENABLED // </e> // <h> nrf_log_backend - Logging sink //========================================================== // <o> NRF_LOG_BACKEND_MAX_STRING_LENGTH - Buffer for storing single output string // <i> Logger backend RAM usage is determined by this value. #ifndef NRF_LOG_BACKEND_MAX_STRING_LENGTH #define NRF_LOG_BACKEND_MAX_STRING_LENGTH 256 #endif // <o> NRF_LOG_TIMESTAMP_DIGITS - Number of digits for timestamp // <i> If higher resolution timestamp source is used it might be needed to increase that #ifndef NRF_LOG_TIMESTAMP_DIGITS #define NRF_LOG_TIMESTAMP_DIGITS 8 #endif // <e> 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 #if NRF_LOG_BACKEND_SERIAL_USES_UART // <o> NRF_LOG_BACKEND_SERIAL_UART_BAUDRATE - Default Baudrate // <323584=> 1200 baud // <643072=> 2400 baud // <1290240=> 4800 baud // <2576384=> 9600 baud // <3862528=> 14400 baud // <5152768=> 19200 baud // <7716864=> 28800 baud // <10289152=> 38400 baud // <15400960=> 57600 baud // <20615168=> 76800 baud // <30924800=> 115200 baud // <61865984=> 230400 baud // <67108864=> 250000 baud // <121634816=> 460800 baud // <251658240=> 921600 baud // <268435456=> 57600 baud #ifndef NRF_LOG_BACKEND_SERIAL_UART_BAUDRATE #define NRF_LOG_BACKEND_SERIAL_UART_BAUDRATE 30924800 #endif // <o> NRF_LOG_BACKEND_SERIAL_UART_TX_PIN - UART TX pin #ifndef NRF_LOG_BACKEND_SERIAL_UART_TX_PIN #define NRF_LOG_BACKEND_SERIAL_UART_TX_PIN 9 #endif // <o> NRF_LOG_BACKEND_SERIAL_UART_RX_PIN - UART RX pin #ifndef NRF_LOG_BACKEND_SERIAL_UART_RX_PIN #define NRF_LOG_BACKEND_SERIAL_UART_RX_PIN 11 #endif // <o> NRF_LOG_BACKEND_SERIAL_UART_RTS_PIN - UART RTS pin #ifndef NRF_LOG_BACKEND_SERIAL_UART_RTS_PIN #define NRF_LOG_BACKEND_SERIAL_UART_RTS_PIN 8 #endif // <o> NRF_LOG_BACKEND_SERIAL_UART_CTS_PIN - UART CTS pin #ifndef NRF_LOG_BACKEND_SERIAL_UART_CTS_PIN #define NRF_LOG_BACKEND_SERIAL_UART_CTS_PIN 10 #endif // <o> NRF_LOG_BACKEND_SERIAL_UART_FLOW_CONTROL - Hardware Flow Control // <0=> Disabled // <1=> Enabled #ifndef NRF_LOG_BACKEND_SERIAL_UART_FLOW_CONTROL #define NRF_LOG_BACKEND_SERIAL_UART_FLOW_CONTROL 0 #endif // <o> NRF_LOG_BACKEND_UART_INSTANCE - UART instance used // <0=> 0 #ifndef NRF_LOG_BACKEND_UART_INSTANCE #define NRF_LOG_BACKEND_UART_INSTANCE 0 #endif #endif //NRF_LOG_BACKEND_SERIAL_USES_UART // </e> // <e> NRF_LOG_BACKEND_SERIAL_USES_RTT - If enabled data is printed using RTT //========================================================== #ifndef NRF_LOG_BACKEND_SERIAL_USES_RTT #define NRF_LOG_BACKEND_SERIAL_USES_RTT 0 #endif #if NRF_LOG_BACKEND_SERIAL_USES_RTT // <o> NRF_LOG_BACKEND_RTT_OUTPUT_BUFFER_SIZE - RTT output buffer size. // <i> Should be equal or bigger than \ref NRF_LOG_BACKEND_MAX_STRING_LENGTH. // <i> This value is used in Segger RTT configuration to set the buffer size // <i> if it is bigger than default RTT buffer size. #ifndef NRF_LOG_BACKEND_RTT_OUTPUT_BUFFER_SIZE #define NRF_LOG_BACKEND_RTT_OUTPUT_BUFFER_SIZE 512 #endif #endif //NRF_LOG_BACKEND_SERIAL_USES_RTT // </e> // </h> //========================================================== // </h> //========================================================== // <h> nRF_Segger_RTT //========================================================== // <h> segger_rtt - SEGGER RTT //========================================================== // <o> SEGGER_RTT_CONFIG_BUFFER_SIZE_UP - Size of upstream buffer. #ifndef SEGGER_RTT_CONFIG_BUFFER_SIZE_UP #define SEGGER_RTT_CONFIG_BUFFER_SIZE_UP 64 #endif // <o> SEGGER_RTT_CONFIG_MAX_NUM_UP_BUFFERS - Size of upstream buffer. #ifndef SEGGER_RTT_CONFIG_MAX_NUM_UP_BUFFERS #define SEGGER_RTT_CONFIG_MAX_NUM_UP_BUFFERS 2 #endif // <o> SEGGER_RTT_CONFIG_BUFFER_SIZE_DOWN - Size of upstream buffer. #ifndef SEGGER_RTT_CONFIG_BUFFER_SIZE_DOWN #define SEGGER_RTT_CONFIG_BUFFER_SIZE_DOWN 16 #endif // <o> SEGGER_RTT_CONFIG_MAX_NUM_DOWN_BUFFERS - Size of upstream buffer. #ifndef SEGGER_RTT_CONFIG_MAX_NUM_DOWN_BUFFERS #define SEGGER_RTT_CONFIG_MAX_NUM_DOWN_BUFFERS 2 #endif // </h> //========================================================== // </h> //========================================================== // <<< end of configuration section >>> #endif //SDK_CONFIG_H
For specific details about the Nordic chip, and/or the Nordic SDK - you need to ask Nordic!
https://devzone.nordicsemi.com/
For understanding the Cortex-M0+ core - including its interrupt handling - get Joseph Yiu's excellent book:
https://www.elsevier.com/books/the-definitive-guide-to-arm-cortex-m0-and-cortex-m0-processors/yiu/978-0-12-803277-0
There is also the ARM documentation:
http://infocenter.arm.com/help/topic/com.arm.doc.subset.cortexm.m0plus/index.html
https://developer.arm.com/docs
And plenty of other books:
http://www.keil.com/books/armbooks.asp