-
Notifications
You must be signed in to change notification settings - Fork 853
Description
Is your feature request related to a problem? Please describe.
It seems to me that if we have 2 or 3 modules enabled (like RF + BT + IR) it is very difficult to understand the logs on the console because each module writes something when requested without providing context (probably all assuming only their own module is active). Sometimes you log multi-lines not with a simple call to the LOG function but with a call to multiple LOGs... this makes it a nightmare to understand the flow.
Describe the solution you'd like
Having a clear console register in which registers are always contextualised and encapsulated.
Describe alternatives you've considered
Create a soft rules like:
A - The log need to have a prefix the module involved (Example "BT .... " or "RF ..." etc )
B - The log need to be encapsulated:
As example:
Log.trace(F("Looking for Model_id: %d" CR), p->sensorModel_id);
std::string properties = decoder.getTheengProperties(p->sensorModel_id);
Log.trace(F("properties: %s" CR), properties.c_str());
should be
Log.trace(F("BT - Looking for Model_id: %d with properties: %s" CR),
p->sensorModel_id,
decoder.getTheengProperties(p->sensorModel_id).c_str()
);