Forum Discussion
Altera_Forum
Honored Contributor
20 years agoC++ & ISR
Dear all, I develop my project with C++ language. But I encounter a problem: how to register a ISR? For example: I define a UART class class UART { //Internal Data ...
Altera_Forum
Honored Contributor
20 years agoI usually use a private static member function in this case, static is necessary, the visibility does not matter. Inside the function you can reinterpret_cast the void pointer to a pointer to your object (assuming you passed 'this' when the ISR was registered).