Rotation fix for HP Chromebook 14 x360 (Blooguard),possibly more!

didn’t really know where to post this, but i have had an issue with inverted screen rotation on Linux with my HP Chromebook 14 (ca-0090wm) for over a year and i have finally solved it.

instructions (mostly terminal commands):
open terminal
cd /lib/udev/hwdb.d
sudo nano 60-sensor-local.hwdb (not necessary to create a separate file but makes it easier to work with)
input this exactly how it is formatted here (without quotes, also don’t try doing this by hand lol)
ACCEL_MOUNT_MATRIX=-1, 0, 0; 0, -1, 0; 0, 0, -1”

save the file with ctrl+x, run sudo udevadm hwdb --update, reboot, and enjoy the fixed screen rotation.

if your chromebook has the same exact issue you can try replacing Blooguard with your model to see if it works or try a different value from the existing set of Chromebook models included here, after all i just copied that from the Inspiron 2-in-1 and changed the model name.

cheers, hope this helps someone!

edit: i guess this has been fixed in newer kernels, but i’m running 22.04.

Btw the bug that causes the screen to be upside down is already fixed. Newer Linux distros like Fedora don’t need that file to be added manually anymore.

And also, the upstream udev rule covers every chromebook, not just a specific model.

Yet another reason why the use of LTS distros is discouraged.