clear old sensors when testing standalone

This commit is contained in:
proddy
2025-10-05 15:36:30 +02:00
parent 145172b6e9
commit 93de0e2f42

View File

@@ -619,6 +619,8 @@ bool TemperatureSensor::Sensor::apply_customization() {
// hard coded tests
#if defined(EMSESP_TEST)
void TemperatureSensor::load_test_data() {
sensors_.clear(); // delete all existing sensors
// add 2 temperature sensors
// Sensor ID: 01_0203_0405_0607
uint8_t addr[ADDR_LEN] = {1, 2, 3, 4, 5, 6, 7, 8};