Hi, sorry for the delayed response. I’m working on a from-scratch flight controller for my university, so all custom hardware and software.
The board is similar to the pixhawk 1 - an STM32F4 main processor and an STM32F0 I/O or failsafe processor. Mostly the same sensors too - an MPU9250 IMU, and MS5611 barometer for example.
On the software side, we use ChibiosOS, our own device drivers, and (up to now) our own flight control code with our own GCS. We’re still continuing with our flight control system, but we’re replacing the old AHRS with the EKF from PX4 to get the full-state estimation that’s necessary to fly multicopters well.
The integration with the EKF has been challenging, but successful. Despite being posted as a stand-alone project, it’s evident that the EKF is really only being used with the PX4 right now. For example, the “getting started” instructions in readme.md for building the stand-alone library don’t work. Some of the functionality it has, like emitting error messages, only work when built with the PX4. The stand-alone version is hard-coded to emit error messages through printf(), which isn’t great on systems that don’t have a stdout. That being said, it can be made to work, and it gives good results (as you see in PX4 copters and airplanes) when set up correctly.
To get started from a programming standpoint, you need to include ekf.h and then create an instance of an Ekf(). The use the methods in estimator_interface.h to push all of your sensor data to the system. Then call Ekf->update(), then use more estimator_interface.h methods to read the results back. Simple in theory, but there are gotcha’s in every part. PX4’s connector (https://github.com/PX4/Firmware/blob/master/src/modules/ekf2/ekf2_main.cpp) is the reference example to follow.
It’s also important that all of your sensor data is as perfect as it can be - so if you do your own device drivers you need to test all of them thoroughly for data rates, calibration, noise levels, aliasing, etc. Due to the nature of the EKF, when bad data goes in, bad data goes out but in seemingly random ways that are hard to track back to a source.