Global variables access in interrupt context need to be declared volatile otherwise the compiler might optimize them away or use old values.
Hint: sendData() is called in interrupt context.
Global variables access in interrupt context need to be declared volatile otherwise the compiler might optimize them away or use old values.
Hint: sendData() is called in interrupt context.