Nano 33 BLE code to calculate pitch roll and yaw angles

I have an arduino nano 33 ble and I want to code it to calculate the pitch roll and yaw angles with respect to time from the accelerometer and the gyroscope. Need help with the code

Have you made any progress? I am planning to do the same!

The Madgwick/Mahony fusion filter should work fine, but it is essential to get the sensor axes properly sorted out, calibrated and scaled correctly. Otherwise the results will be completely useless.

There are some hints for how to do that in this thread.