Page 1 of 1

ESP_LOGx() slow down the speed?

Posted: Mon Jan 15, 2018 2:22 pm
by Gfast2
Hi ESP-IDF,

If I don't connect ESP32's serial port. Would be all "ESP_LOGx()" still get called? Will they drag down ESP32's performance & eating up my precious 512KB SRAM?

If it is the case, are there ways to turn them off or just turn off some of them "on-fly"? Say turn these log level through Web Server, and the webserver call some kind of System API?

Cheers

Gfast2

Re: ESP_LOGx() slow down the speed?

Posted: Mon Jan 15, 2018 3:50 pm
by ESP_igrr
esp_log_level_set allows filtering log messages by tag at run time. It also has a '*' wildcard to change log level for all tags.

esp_log_set_vprintf, which you already know of, can be replaced with a no-op function to prevent formatting from happening.

http://esp-idf.readthedocs.io/en/latest ... m/log.html

Re: ESP_LOGx() slow down the speed?

Posted: Mon Jan 15, 2018 4:36 pm
by Gfast2
Hi ESP_igrr,

BIG THANKS again! I really appreciate your answers!

(It's a shame to asking this question. After I saw your answers, I can remember, that I even have had used this API some months before... :oops: But any way. I will push myself to brew the best ESP32 project I can, and let my colleagues who develops Linux Box & pround of their achievements get a big "wow" from my ESP32 based project! :lol: 8-) )

Cheers

Gfast2