Skip to content

Commit 812b9be

Browse files
author
Marcus Chang
committed
NRF5: Customize STDIO pins from config system
1 parent f0bda6c commit 812b9be

File tree

2 files changed

+12
-0
lines changed

2 files changed

+12
-0
lines changed

targets/TARGET_NORDIC/TARGET_NRF5/TARGET_MCU_NRF52832/PeripheralNames.h

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -45,8 +45,14 @@
4545
extern "C" {
4646
#endif
4747

48+
#ifndef STDIO_UART_TX
4849
#define STDIO_UART_TX TX_PIN_NUMBER
50+
#endif
51+
52+
#ifndef STDIO_UART_RX
4953
#define STDIO_UART_RX RX_PIN_NUMBER
54+
#endif
55+
5056
#define STDIO_UART UART_0
5157

5258
typedef enum {

targets/TARGET_NORDIC/TARGET_NRF5/TARGET_MCU_NRF52840/PeripheralNames.h

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -45,8 +45,14 @@
4545
extern "C" {
4646
#endif
4747

48+
#ifndef STDIO_UART_TX
4849
#define STDIO_UART_TX TX_PIN_NUMBER
50+
#endif
51+
52+
#ifndef STDIO_UART_RX
4953
#define STDIO_UART_RX RX_PIN_NUMBER
54+
#endif
55+
5056
#define STDIO_UART UART_0
5157

5258
typedef enum

0 commit comments

Comments
 (0)