Commit Graph

9 Commits

Author SHA1 Message Date
Lefucjusz
4e685bb7ec [MOS-999] Provide additional info in log filename
Added info about product, OS version, commit hash
and serial number to log filename to simplify
triage and quick sanity check of the logs in
cases many log files have to be analyzed.
2023-06-23 12:08:32 +02:00
Lefucjusz
8d96f2d354 [MOS-993] Logger bug fixes and optimizations
Fixes and optimizations in logger:

* fixed possible buffer overflow when logging
logs over line buffer size;
* reduced max log line length to 2048;
* moved pubsetbuf before file opening;
* log file stream buffer created once
in logger ctor;
* updatet UTs;
* additional minor cleanup.
2023-05-29 09:38:57 +02:00
Adam Dobrowolski
30487c6008 [MOS-110] Statistics api for system
Gets data from freertos and prints on frequency change depending
if it's important. Gathering is not costly, printing is though.
For less intrusive checks I would rather disable names gathering
as in worst case scenario it hangs rtos context switching till
thread id is found.
2022-02-17 16:46:56 +01:00
Marcin Smoczyński
bd90e57516 [BH-907] Split utils module into components
Split module-utils into smaller components for better dependency
management. Fix many dependencies throughout the project.

Signed-off-by: Marcin Smoczyński <smoczynski.marcin@gmail.com>
2021-09-23 15:14:40 +02:00
Lukasz Skrzypczak
eecde32337 [BH-378] Corrected includes
Corrected includes
2021-06-08 12:24:29 +02:00
Lukasz Skrzypczak
2911b6b4a1 [BH-378] PR changes
PR changes - mainly includes
2021-06-08 12:24:29 +02:00
Maciej Gibowicz
06fa920e20 [EGD-6768] Disable logs in interrupts
Temporarily disable logs in interrupts
for heap overwriting reasons
2021-05-19 09:05:16 +02:00
Mateusz Grzegorzek
def5dbcfa9 [EGD-5908] Fix bug in Logger + add log unit test
Because `vsnprintf` return value means:
"
The number of characters that would have been
written if n had been sufficiently large,
not counting the terminating null character.
If an encoding error occurs, a negative number is returned.
"

`Logger` crashed when log msg was longer than LOGGER_BUFFER_SIZE.
Checking `vsnprintf` return value solves this issue.
2021-03-05 09:06:39 +01:00
Mateusz Grzegorzek
0c3cc549b6 [EGD-4706] Change log for RT1051 and Linux platform
Unify log for RT1051 and linux platform.
Add Logger class where common functions
for RT1051 and Linux are stored.
2021-01-11 12:39:15 +01:00