Skip to content

Commit 6240e2c

Browse files
committed
Force UART to stay powered once serial port is enabled.
1 parent 846b97e commit 6240e2c

File tree

2 files changed

+3
-2
lines changed

2 files changed

+3
-2
lines changed

firmware/nRF51/core/openbeacon/src/uart.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -76,7 +76,7 @@ void uart_init(void)
7676

7777
/* start UART */
7878

79-
#if CONFIG_UART_FORCE_POWERED | CONFIG_UART_RXD_PIN
79+
#if CONFIG_UART_FORCE_POWERED || defined(CONFIG_UART_RXD_PIN)
8080
NRF_UART0->ENABLE = (UART_ENABLE_ENABLE_Enabled << UART_ENABLE_ENABLE_Pos);
8181
#else
8282
NRF_UART0->ENABLE = 0;

firmware/nRF51/tag-proximity/inc/config.h

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -60,11 +60,12 @@
6060
#if CONFIG_UART_FAST
6161
#define CONFIG_UART_BAUDRATE UART_BAUDRATE_BAUDRATE_Baud1M
6262
#define CONFIG_UART_BUFFER 1024
63-
#define CONFIG_UART_FORCE_POWERED 1
6463
#else
6564
#define CONFIG_UART_BAUDRATE UART_BAUDRATE_BAUDRATE_Baud115200
6665
#endif
6766

67+
#define CONFIG_UART_FORCE_POWERED 1
68+
6869
#define CONFIG_UART_TXD_PIN 9
6970
#ifdef CONFIG_UART_RX
7071
#define CONFIG_UART_RXD_PIN 8

0 commit comments

Comments
 (0)