fix buffer size bug (#1747)

* fix buffer size bug

* faster file over usbcdc - wip

* minimal faster display tx
This commit is contained in:
Totoo
2024-01-09 18:30:43 +01:00
committed by GitHub
parent ad94ae05c1
commit 0e6f303eec
3 changed files with 24 additions and 19 deletions
+8 -4
View File
@@ -24,6 +24,10 @@
#include "ch.h"
#include "hal.h"
#ifndef USBSERIAL_BUFFERS_SIZE
#define USBSERIAL_BUFFERS_SIZE 400
#endif
struct SerialUSBDriverVMT {
_base_asynchronous_channel_methods
};
@@ -31,10 +35,10 @@ struct SerialUSBDriverVMT {
struct SerialUSBDriver {
/** @brief Virtual Methods Table.*/
const struct SerialUSBDriverVMT* vmt;
InputQueue iqueue; /* Output queue.*/
OutputQueue oqueue; /* Input circular buffer.*/
uint8_t ib[SERIAL_BUFFERS_SIZE]; /* Output circular buffer.*/
uint8_t ob[SERIAL_BUFFERS_SIZE];
InputQueue iqueue; /* Output queue.*/
OutputQueue oqueue; /* Input circular buffer.*/
uint8_t ib[USBSERIAL_BUFFERS_SIZE]; /* Output circular buffer.*/
uint8_t ob[USBSERIAL_BUFFERS_SIZE];
};
typedef struct SerialUSBDriver SerialUSBDriver;