Skip to content
Permalink
Browse files

boards: arm: nrf52840_pca10090: update log settings

Add a board-specific log level setting and change log levels.

Signed-off-by: Emanuele Di Santo <emdi@nordicsemi.no>
  • Loading branch information...
lemrey authored and carlescufi committed Apr 17, 2019
1 parent d422d56 commit 0604e21de653049402a7088e6ac1a9bf0fc5af84
Showing with 19 additions and 14 deletions.
  1. +5 −0 boards/arm/nrf52840_pca10090/Kconfig
  2. +14 −14 boards/arm/nrf52840_pca10090/board.c
@@ -192,4 +192,9 @@ config BOARD_PCA10090_INTERFACE2_MCU

endchoice


module = BOARD_PCA10090
module-str = Board Control
source "subsys/logging/Kconfig.template.log_config"

endif # BOARD_NRF52840_PCA10090
@@ -9,7 +9,7 @@
#include <gpio.h>
#include <logging/log.h>

LOG_MODULE_REGISTER(board_control_pca10090);
LOG_MODULE_REGISTER(board_control, CONFIG_BOARD_PCA10090_LOG_LEVEL);

/* The following pins on the nRF52840 control the routing of certain
* components/lines on the nRF9160 DK. They are specified as follows:
@@ -81,82 +81,82 @@ static const u8_t pins_on_p1[][2] = {
static void config_print(void)
{
/* Interface pins 0-2 */
LOG_DBG("Routing interface pins 0-2 to %s (pin -> %d)",
LOG_INF("Routing interface pins 0-2 to %s (pin -> %d)",
IS_ENABLED(CONFIG_BOARD_PCA10090_INTERFACE0_MCU) ?
"nRF52840" :
"Arduino headers",
IS_ENABLED(CONFIG_BOARD_PCA10090_INTERFACE0_MCU));

/* Interface pins 3-5 */
LOG_DBG("Routing interface pins 3-5 to %s (pin -> %d)",
LOG_INF("Routing interface pins 3-5 to %s (pin -> %d)",
IS_ENABLED(CONFIG_BOARD_PCA10090_INTERFACE1_MCU) ?
"nRF52840" :
"TRACE header",
IS_ENABLED(CONFIG_BOARD_PCA10090_INTERFACE1_MCU));

/* Interface pins 6-8 */
LOG_DBG("Routing interface pins 6-8 to %s (pin -> %d)",
LOG_INF("Routing interface pins 6-8 to %s (pin -> %d)",
IS_ENABLED(CONFIG_BOARD_PCA10090_INTERFACE2_MCU) ?
"nRF52840" :
"COEX header",
IS_ENABLED(CONFIG_BOARD_PCA10090_INTERFACE2_MCU));

LOG_DBG("Routing nRF9160 UART0 to %s (pin -> %d)",
LOG_INF("Routing nRF9160 UART0 to %s (pin -> %d)",
IS_ENABLED(CONFIG_BOARD_PCA10090_UART0_ARDUINO) ?
"Arduino pin headers" :
"VCOM0",
IS_ENABLED(CONFIG_BOARD_PCA10090_UART0_ARDUINO));

LOG_DBG("Routing nRF9160 UART1 to %s (pin -> %d)",
LOG_INF("Routing nRF9160 UART1 to %s (pin -> %d)",
IS_ENABLED(CONFIG_BOARD_PCA10090_UART1_ARDUINO) ?
"Arduino pin headers" :
"VCOM2",
/* defaults to arduino pins */
IS_ENABLED(CONFIG_BOARD_PCA10090_UART1_VCOM));

LOG_DBG("Routing nRF9160 LED 1 to %s (pin -> %d)",
LOG_INF("Routing nRF9160 LED 1 to %s (pin -> %d)",
IS_ENABLED(CONFIG_BOARD_PCA10090_LED0_ARDUINO) ?
"Arduino pin headers" :
"physical LED",
IS_ENABLED(CONFIG_BOARD_PCA10090_LED0_ARDUINO));

LOG_DBG("Routing nRF9160 LED 2 to %s (pin -> %d)",
LOG_INF("Routing nRF9160 LED 2 to %s (pin -> %d)",
IS_ENABLED(CONFIG_BOARD_PCA10090_LED1_ARDUINO) ?
"Arduino pin headers" :
"physical LED",
IS_ENABLED(CONFIG_BOARD_PCA10090_LED1_ARDUINO));

LOG_DBG("Routing nRF9160 LED 3 to %s (pin -> %d)",
LOG_INF("Routing nRF9160 LED 3 to %s (pin -> %d)",
IS_ENABLED(CONFIG_BOARD_PCA10090_LED2_ARDUINO) ?
"Arduino pin headers" :
"physical LED",
IS_ENABLED(CONFIG_BOARD_PCA10090_LED2_ARDUINO));

LOG_DBG("Routing nRF9160 LED 4 to %s (pin -> %d)",
LOG_INF("Routing nRF9160 LED 4 to %s (pin -> %d)",
IS_ENABLED(CONFIG_BOARD_PCA10090_LED3_ARDUINO) ?
"Arduino pin headers" :
"physical LED",
IS_ENABLED(CONFIG_BOARD_PCA10090_LED3_ARDUINO));

LOG_DBG("Routing nRF9160 button 1 to %s (pin -> %d)",
LOG_INF("Routing nRF9160 button 1 to %s (pin -> %d)",
IS_ENABLED(CONFIG_BOARD_PCA10090_BUTTON0_ARDUINO) ?
"Arduino pin headers" :
"physical button",
IS_ENABLED(CONFIG_BOARD_PCA10090_BUTTON0_ARDUINO));

LOG_DBG("Routing nRF9160 button 2 to %s (pin -> %d)",
LOG_INF("Routing nRF9160 button 2 to %s (pin -> %d)",
IS_ENABLED(CONFIG_BOARD_PCA10090_BUTTON1_ARDUINO) ?
"Arduino pin headers" :
"physical button",
IS_ENABLED(CONFIG_BOARD_PCA10090_BUTTON1_ARDUINO));

LOG_DBG("Routing nRF9160 switch 1 to %s (pin -> %d)",
LOG_INF("Routing nRF9160 switch 1 to %s (pin -> %d)",
IS_ENABLED(CONFIG_BOARD_PCA10090_SWITCH0_ARDUINO) ?
"Arduino pin headers" :
"physical switch",
IS_ENABLED(CONFIG_BOARD_PCA10090_SWITCH0_ARDUINO));

LOG_DBG("Routing nRF9160 switch 2 to %s (pin -> %d)",
LOG_INF("Routing nRF9160 switch 2 to %s (pin -> %d)",
IS_ENABLED(CONFIG_BOARD_PCA10090_SWITCH1_ARDUINO) ?
"Arduino pin headers" :
"physical switch",

0 comments on commit 0604e21

Please sign in to comment.
You can’t perform that action at this time.