usbuart: Moved the AUX serial receive buffer definition into aux_serial.c

This commit is contained in:
dragonmux 2022-08-21 14:57:08 +01:00 committed by Piotr Esden-Tempski
parent 62b1a33188
commit 60b91e1da9
4 changed files with 3 additions and 14 deletions

View File

@ -37,6 +37,7 @@
#include "usb.h"
#include "aux_serial.h"
static char aux_serial_receive_buffer[AUX_UART_BUFFER_SIZE];
/* Fifo in pointer, writes assumed to be atomic, should be only incremented within RX ISR */
static uint8_t aux_serial_receive_write_index;
/* Fifo out pointer, writes assumed to be atomic, should be only incremented outside RX ISR */

View File

@ -40,12 +40,9 @@ void debug_uart_run(void);
#define USART_DMA_BUF_SIZE (1U << USART_DMA_BUF_SHIFT)
#define AUX_UART_BUFFER_SIZE (USART_DMA_BUF_SIZE)
/* RX Fifo buffer with space for copy fn overrun */
extern char aux_serial_receive_buffer[AUX_UART_BUFFER_SIZE + sizeof(uint64_t)];
#ifdef ENABLE_DEBUG
/* Debug Fifo buffer with space for copy fn overrun */
extern char usb_dbg_buf[AUX_UART_BUFFER_SIZE + sizeof(uint64_t)];
extern char usb_dbg_buf[AUX_UART_BUFFER_SIZE];
/* Debug Fifo in pointer */
extern uint8_t usb_dbg_in;
/* Debug Fifo out pointer */
@ -53,9 +50,6 @@ extern uint8_t usb_dbg_out;
#endif
#elif defined(LM4F)
#define AUX_UART_BUFFER_SIZE 128
/* RX Fifo buffer */
extern char aux_serial_receive_buffer[AUX_UART_BUFFER_SIZE];
#endif
#endif

View File

@ -38,12 +38,9 @@
#define DMA_CGIF DMA_IFCR_CGIF_BIT
#endif
/* RX Fifo buffer with space for copy fn overrun */
char aux_serial_receive_buffer[AUX_UART_BUFFER_SIZE + sizeof(uint64_t)];
#ifdef ENABLE_DEBUG
/* Debug Fifo buffer with space for copy fn overrun */
char usb_dbg_buf[AUX_UART_BUFFER_SIZE + sizeof(uint64_t)];
char usb_dbg_buf[AUX_UART_BUFFER_SIZE];
/* Debug Fifo in pointer */
uint8_t usb_dbg_in;
/* Debug Fifo out pointer */

View File

@ -28,6 +28,3 @@
#include "general.h"
#include "usb.h"
/* RX Fifo buffer */
char aux_serial_receive_buffer[AUX_UART_BUFFER_SIZE];