console: separate driver for USART
This commit is contained in:
parent
b6d216255f
commit
81632df5e9
5 changed files with 4 additions and 4 deletions
1
Makefile
1
Makefile
|
@ -19,7 +19,6 @@ CFLAGS += -fno-common --function-sections -fdata-sections
|
|||
|
||||
obj-y += source/main.o
|
||||
obj-y += source/shell.o
|
||||
obj-y += source/usart.o
|
||||
|
||||
obj-y += source/core/flash.o
|
||||
|
||||
|
|
|
@ -19,6 +19,7 @@ STLINK_PORT ?= :4242
|
|||
obj-y += source/core/spi.o
|
||||
obj-y += source/drivers/spi_flash.o
|
||||
obj-y += source/drivers/stm32f0_spi.o
|
||||
obj-y += source/drivers/usart_console.o
|
||||
|
||||
$(OPENCM3_DIR)/lib/lib$(OPENCM3_LIBNAME).a:
|
||||
@if [ ! -e libopencm3/.git ]; then \
|
||||
|
|
|
@ -12,7 +12,7 @@
|
|||
#include <limits.h>
|
||||
#include <sys/types.h>
|
||||
|
||||
#include "usart.h"
|
||||
#include <console.h>
|
||||
|
||||
static ssize_t usart_read(void *cookie, char *buf, size_t n)
|
||||
{
|
|
@ -1,7 +1,7 @@
|
|||
#include <stdio.h>
|
||||
|
||||
#include "shell.h"
|
||||
#include "usart.h"
|
||||
#include <console.h>
|
||||
#include <shell.h>
|
||||
|
||||
int main(void)
|
||||
{
|
||||
|
|
Loading…
Add table
Reference in a new issue