[solved] crazyflie firmware and c++
Posted: Sun Mar 29, 2020 7:58 pm
Hello,
I'm trying to embed c++ code into the freertos-based firmware of the crazyflie drone, with the "app" framework and the push-demo as a basis.
I succeeded in compiling, linking, launching, but dynamic_cast<> always returns nullptr, and exceptions raised are not caught. I enabled flags such as -fexceptions, -rtti, and removed --specs=nano.specs to no avail. Something to know: it's the app task that eventually calls a c++ function which in turn does c++ stuff.
Does anybody know if the specific flags of the crazyflie firmware compilation process prevent c++ to behave correctly wrt to dynamic_cast?
(and I’m aware rtti and exceptions are not recommended in embedded apps, but I still want to try)
Best,
Stéphane
I'm trying to embed c++ code into the freertos-based firmware of the crazyflie drone, with the "app" framework and the push-demo as a basis.
I succeeded in compiling, linking, launching, but dynamic_cast<> always returns nullptr, and exceptions raised are not caught. I enabled flags such as -fexceptions, -rtti, and removed --specs=nano.specs to no avail. Something to know: it's the app task that eventually calls a c++ function which in turn does c++ stuff.
Does anybody know if the specific flags of the crazyflie firmware compilation process prevent c++ to behave correctly wrt to dynamic_cast?
(and I’m aware rtti and exceptions are not recommended in embedded apps, but I still want to try)
Best,
Stéphane