I tried making 'bool NewMsg' volatile but that did not solve the issue.
Making it an integer 'int NewMsg' and switching it between 0 and 1 seems to solve the issue.
It's not the most elegant solution but it works. ( "if you can't solve the problem, avoid it "
)
All the Serial.print lines and the delays are for debugging only.
I will remove them in the final version.
The M5Stick Cplus is indeed an ESP32.
I will try your suggestion to put the ISR before Setup. Thanks Idahowalker.