Nick rehm

https://diydrones.com/profiles/blogs/inverted-pendulum-on-a-drone

https://github.com/nickrehm/dRehmFlight   dRehmFlight VTOL is a new flight controller and stabilization package intended to be used for small to medium sized hobby or research projects. dRehmFlight is the code, and the physical flight controller is a Teensy 4.0 microcontroller with an MPU6050 IMU. This lightweight flight controller can be used for anything from basic multirotors, to advanced VTOL configurations, to simple fixed wing platforms. Uses https://github.com/arduino-libraries/MadgwickAHRS a less computationally intensive algorith compared to KalmanFilter for gyro IMU readings.

teensy flight controller and stabilization for small-scale VTOL vehicles. dRehmFlight is a simple, bare-bones flight controller intended for all types of vertical takeoff and landing (VTOL) vehicles from simple multirotors to more complex transitioning vehicles. This flight controller software and hardware package was developed with people in mind who may not be particularly fluent in object-oriented programming. The goal is to have an easy to understand flow of discrete operations that allows anyone with basic knowledge of coding in C/Arduino to peer into the code, make the changes they need for their specific application, and quickly have something flying

links
Depth perception

PID control