The device immediately exits the sleep mode and goes to standby mode after calling setupWakeUpAndSleep() and setOperatingMode(uint8_t opMode). I believe it is caused by the line "return getError();" in both functions which calls getDeviceStatus() which makes a read on the I2C bus waking up the sensor and putting it back into standby mode. For testing, I added a sfTkArdI2C device and called writeRegister(TMAG5273_REG_DEVICE_CONFIG_2, Data); where Data = 0x23. This allows the sensor to sleep.
The device immediately exits the sleep mode and goes to standby mode after calling setupWakeUpAndSleep() and setOperatingMode(uint8_t opMode). I believe it is caused by the line "return getError();" in both functions which calls getDeviceStatus() which makes a read on the I2C bus waking up the sensor and putting it back into standby mode. For testing, I added a sfTkArdI2C device and called writeRegister(TMAG5273_REG_DEVICE_CONFIG_2, Data); where Data = 0x23. This allows the sensor to sleep.