How to Increase the Arduino I2C Buffer Size?

Hi
I have read some information and know to use build_flags, here is my platformio.ini

BUFFER_LENGTH was in
c:\Users\001.platformio\packages\framework-arduino-avr\libraries\Wire\src\Wire.h

SERIAL_RX_BUFFER_SIZE was in
c:\Users\001.platformio\packages\framework-arduino-avr\cores\arduino\HardwareSerial.h

But only the buffer size of the serial port is changed, and the I2C buffer size is not changed.
Am I missing any steps?

It’s a hardcoded define with no room for changes.

Also since the variables at line 38 and 39 are of type uint8_t, the maximum buffer length is 255… or maybe 254 if there’s some problems with overflow and “+1” checks.

You’d have to do a patch to the Arduino framework to get what you want.

But have you already verified your applicaiton still works with the buffer length changed directly in the source file?

thank you i understand.
I may consider reducing my data to 32byte or use the method of split transmission.