mirror of
https://github.com/esphome/esphome.git
synced 2025-10-03 18:42:23 +01:00
Fix compile errors on ESP32-C6 with latest ESP-IDF (#6822)
* Use <cinttypes> PRI macros to fix ESP32-C6 compile * Fix compile error on latest ESP-IDF framework & platform
This commit is contained in:
@@ -1,5 +1,6 @@
|
||||
#include "ade7953_base.h"
|
||||
#include "esphome/core/log.h"
|
||||
#include <cinttypes>
|
||||
|
||||
namespace esphome {
|
||||
namespace ade7953_base {
|
||||
@@ -105,7 +106,7 @@ void ADE7953::update() {
|
||||
this->last_update_ = now;
|
||||
// prevent DIV/0
|
||||
pf = ADE_WATTSEC_POWER_FACTOR * (diff < 10 ? 10 : diff) / 1000;
|
||||
ESP_LOGVV(TAG, "ADE7953::update() diff=%d pf=%f", diff, pf);
|
||||
ESP_LOGVV(TAG, "ADE7953::update() diff=%" PRIu32 " pf=%f", diff, pf);
|
||||
}
|
||||
|
||||
// Apparent power
|
||||
|
Reference in New Issue
Block a user