@doop4
I'm not familiar with the M5Unified driver; but I've worked with the bmi270 and written a micropython driver for it..

Despite your pillow; you will still get a bit of bounce.. (I've spent time testing this chip, it's very hard to not get any bounce when you do this sort of test.)

But, I think you are seeing the device going out of range; at which point you get weird/invalid readings.

I dont see anywhere in your code setting the acceleration range; the max is +/- 16G, but it defaults to +/- 8g, which is where your readings appear to fail. I guess M5Unified has a method for setting this? Try the biggest range.

Also; you can set filtering based on an average mode; the default is to average 4 readings (the sensor runs at 20MHz) but this can be set all the way up to 128.

The M5Unified driver is using 'direct readings' (just like my driver), do not confuse this with 'FIFO' mode; which is an automated, IRQ triggered high-speed burst capture method. You read the dataset out from the chip buffer after the event has ended. AFIK the M5 drivers do not support this.