Does anyone know or have some accelerometer or gyroscope examples?
Hi, and welcome, @Night_Lee!
Sure! Check this page out.
There isn’t a gyro in the sensor expansion board, but that page has example readings from the accelerometer, as well as example code for detecting shaking.
v2 of the sensor board needs a gyroscope