Arduino IDE 1.8.19 Serial RX Buffer Modified Problem?

Hello. How can I change the RX buffer in the 1.8.19 IDE for Arduino Uno? Previously, I could easily do this via hardwareserial.h, but after the update, the 1.8.19 IDE ignores the changes made on hardwareserial.h.

not really, but you have modified the file, but now the original is being used again,

But just a few days ago someone ran into some issues, and by chance i had a good look, and within hardwareserial.h.

#if !defined(SERIAL_RX_BUFFER_SIZE)
#if ((RAMEND - RAMSTART) < 1023)
#define SERIAL_RX_BUFFER_SIZE 16
#else
#define SERIAL_RX_BUFFER_SIZE 64
#endif

it only sets the SERIAL_RX_BUFFER_SIZE only if it hasn't been defined yet, so the easiest solution is to let one of the first lines in you sketch be

#define SERIAL_RX_BUFFER_SIZE 64

with the size that you want it to be.
The method you've used previously obviously is not the best.

1 Like

This topic was automatically closed 180 days after the last reply. New replies are no longer allowed.