samd: bug fix on uart newlines
This commit is contained in:
parent
94238fd95b
commit
c1b3d0c629
@ -11,6 +11,10 @@ ifeq ($(CUSTOM_SER), 1)
|
|||||||
CFLAGS += -DCUSTOM_SER
|
CFLAGS += -DCUSTOM_SER
|
||||||
endif
|
endif
|
||||||
|
|
||||||
|
ifeq ($(CONSOLE_NO_AUTO_CRLF), 1)
|
||||||
|
CFLAGS += -DCONSOLE_NO_AUTO_CRLF
|
||||||
|
endif
|
||||||
|
|
||||||
CFLAGS += -mthumb -mcpu=cortex-m0plus \
|
CFLAGS += -mthumb -mcpu=cortex-m0plus \
|
||||||
-DSAMD -DSAMD21E17 -DBLACKMAGIC -I../libopencm3/include \
|
-DSAMD -DSAMD21E17 -DBLACKMAGIC -I../libopencm3/include \
|
||||||
-Iplatforms/samd -msoft-float -ffunction-sections -fdata-sections -MD
|
-Iplatforms/samd -msoft-float -ffunction-sections -fdata-sections -MD
|
||||||
|
@ -58,7 +58,7 @@ struct {
|
|||||||
/* non blocking putc function */
|
/* non blocking putc function */
|
||||||
static void usart_putc(char c)
|
static void usart_putc(char c)
|
||||||
{
|
{
|
||||||
#ifndef CONSOLE_NO_AUTO_CRLF
|
#ifdef CONSOLE_NO_AUTO_CRLF
|
||||||
if (c == '\n')
|
if (c == '\n')
|
||||||
usart_putc('\r');
|
usart_putc('\r');
|
||||||
#endif
|
#endif
|
||||||
|
Loading…
x
Reference in New Issue
Block a user