SparkFun Digital Temperature Sensor Breakout - AS6212 (Qwiic) SEN-18521
was testing this sensor using example 5 alert, and noticed when I specify the high and low thresholds the get functions return a slightly different value, examples:
sensor.setTHighF(80); // set high threshhold ALERT ACTIVE alertstatus = 0
sensor.setTLowF(70); // set low threshhold at 78 ALERT ACTIVE LOW cleared alertstatus = 1
Serial.print("\tThighF: “); Serial.print(sensor.getTHighF(), 2); Serial.print(”\tTlowF: "); Serial.println(sensor.getTLowF(), 2);
// ThighF: 78.80 TlowF: 69.80
sensor.setTHighF(75); // set high threshhold ALERT ACTIVE alertstatus = 0
sensor.setTLowF(70); // set low threshhold at 78 ALERT ACTIVE LOW cleared alertstatus = 1
Serial.print("\tThighF: “); Serial.print(sensor.getTHighF(), 2); Serial.print(”\tTlowF: "); Serial.println(sensor.getTLowF(), 2);
// ThighF: 73.40 TlowF: 69.80
sensor.setTHighF(70); // set high threshhold ALERT ACTIVE alertstatus = 0
sensor.setTLowF(65); // set low threshhold at 78 ALERT ACTIVE LOW cleared alertstatus = 1
Serial.print("\tThighF: “); Serial.print(sensor.getTHighF(), 2); Serial.print(”\tTlowF: "); Serial.println(sensor.getTLowF(), 2);
// ThighF: 69.80 TlowF: 64.40
sensor.setTHighF(70); // set high threshhold ALERT ACTIVE alertstatus = 0
sensor.setTLowF(64.4); // set low threshhold at 78 ALERT ACTIVE LOW cleared alertstatus = 1
Serial.print("\tThighF: “); Serial.print(sensor.getTHighF(), 2); Serial.print(”\tTlowF: "); Serial.println(sensor.getTLowF(), 2);
//ThighF: 69.80 TlowF: 62.60
thanks