mirror of
https://github.com/esphome/esphome.git
synced 2025-01-18 20:10:55 +00:00
Increased debug message precision (#5496)
This commit is contained in:
parent
fa0dcac2c7
commit
ee4ccf2762
@ -37,7 +37,7 @@ void UltrasonicSensorComponent::update() {
|
||||
this->publish_state(NAN);
|
||||
} else {
|
||||
float result = UltrasonicSensorComponent::us_to_m(pulse_end - pulse_start);
|
||||
ESP_LOGD(TAG, "'%s' - Got distance: %.2f m", this->name_.c_str(), result);
|
||||
ESP_LOGD(TAG, "'%s' - Got distance: %.3f m", this->name_.c_str(), result);
|
||||
this->publish_state(result);
|
||||
}
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user