I am using the BLE Group library that @mariano has developed to utilise the defunct but otherwise neat Xenon to create a BLE connected sensor group - in this case the sensor is an I2C interfaced AMG8833 a thermal array sensor that I am using to sense body temperature. I have migrated the Mesh network pub-sub to use the BLE Group. This has worked really well and the 3 sensors can be switched and start working with results going to a gateway device and off to the cloud.
The ‘however’ is that 2 of the 3 peripheral devices will stop working after a period and SOS 1 red flash. The third device can carry on until the battery is used up - several days. They are all running the same application software and device OS (1.4.4). Looking at the hard fault reasons it could be; invalid pointer, memory corruption or I2C wire call before Wire.begin() called.
The peripheral devices do a lot of sleeping and waking and can be woken interrupt from the AMG8833 which is put in a background checking whilst the Xenon is sleeping and can wake the Xenon to resume more intensive and nuanced reading and processing of the thermal camera array. There is also a RTC (DS3231) in the sensor.
I am looking for any advice about how to approach fault finding in this case, I am assuming it is I2C issue? One thing I don’t understand is that the only way to stop a device hard faulting is to remove the power and re-applying the power will see it continue to flash 1 red. A recovery requires the application to be reflashed.