I am working on a project(quad copter) which includes speed control of a brushless motor with raspberry pi.
To control the speed of the motor, I will use PID controller, however I could not find a way how to read rpm from ESC. I have read some articles about brushless motors and ESCs, and I understand the principle they work on. I also know that some ESCs use Back-EMF to detect which coil to power.
I have been looking for relevant article on reading motor position or directly rpm from the ESC for quite some time now, with little success. I would be grateful if someone could explain it in detail how to do it, or send a python/c/c++ code example.