I know how to use function pointers in C. But I'm writing a library in C++ and I'd like to use the C++ mechanism to pass a function pointer as parameter.
I want to add to my class a "setListener" method and pass the function pointer as parameter. This class will store the pointer, set up an interruption and call the listener function inside the ISR. The callback will be an static method defined in the main sketch file and having no arguments.
NOTE: I'm not using C++ 11, so please only traditional C++ answers.