https://github.com/m5stack/M5-ProductExampleCodes/blob/fcc2bf58c86aa2502f735c6f60051dfe24861adb/App/IIoT%20Dual/IIoT%20Dual.ino#L51 It appears this line is using the wrong pin, if you compare button codes in loop().
M5-ProductExampleCodes/App/IIoT Dual/IIoT Dual.ino
Line 51 in fcc2bf5
It appears this line is using the wrong pin, if you compare button codes in loop().