Hi
I have a MAX31855 used for K thermocouple that sometimes send a "nan" instead of a number.
This crashes my program, so I need to handle it and take the right action so my program can continu without crashing.
First I was requesting a
thermocouple.readCelsius();
thermocouple.readInternal();
every 200ms and I thought it was too much despite the 70-100ms request time advise in the datasheet (don't know if this delay time is for 1 request or for both (Tc and internal).
So I requested both every 300ms but the MAX 31855 still sometime send "nan" !
So I need to handle this situation but I don't know how since I declared the variable storing these value as
double temperature_Tc_K = thermocouple.readCelsius();
I would like to update a counter relating to each "nan" and send the last value is case of a "nan"