mirror of
https://github.com/emsesp/EMS-ESP32.git
synced 2025-12-06 15:59:52 +03:00
some refactoring
This commit is contained in:
@@ -399,7 +399,7 @@ bool TemperatureSensor::get_value_info(JsonObject output, const char * cmd, cons
|
||||
// match custom name or sensor ID
|
||||
if (cmd == Helpers::toLower(sensor.name()) || cmd == Helpers::toLower(sensor.id())) {
|
||||
get_value_json(output, sensor);
|
||||
return Command::set_attribute(output, cmd, attribute_s);
|
||||
return Command::get_attribute(output, cmd, attribute_s);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -618,7 +618,7 @@ bool TemperatureSensor::Sensor::apply_customization() {
|
||||
|
||||
// hard coded tests
|
||||
#if defined(EMSESP_TEST)
|
||||
void TemperatureSensor::test() {
|
||||
void TemperatureSensor::load_test_data() {
|
||||
// add 2 temperature sensors
|
||||
// Sensor ID: 01_0203_0405_0607
|
||||
uint8_t addr[ADDR_LEN] = {1, 2, 3, 4, 5, 6, 7, 8};
|
||||
|
||||
Reference in New Issue
Block a user