serial log level

micdj
Posts: 31
Joined: Wed Jan 06, 2021 2:23 am

Post

is possible to change serial log level? for exmaple I don't want see this:

Send: [53 55 50 4C 41 ]
20:33:25.549 -> Recv: [53 55 50 4C 41 10 96 00 00 00 32 00 00 00 10 00 00 00 86 BF F7 63 00 00 00 00 58 20 02 00 00 00 00 00 53 55 50 4C 41 ]
20:33:50.448 -> Send: [53 55 50 4C 41 10 71 01 00 00 28 00 00 00 10 00 00 00 4C 0D 00 00 00 00 00 00 10 BB 01 00 00 00 00 00 ]
20:33:50.448 -> Send: [53 55 50 4C 41 ]

Is it possible?
User avatar
pzygmunt
Posts: 20302
Joined: Tue Jan 19, 2016 9:26 am
Location: Paczków
Been thanked: 59 times

Post

What software?
SUPLA.... Nareszcie w domu.
User avatar
klew
Posts: 13908
Joined: Thu Jun 27, 2019 12:16 pm
Location: Wrocław
Has thanked: 134 times
Been thanked: 137 times

Post

micdj wrote: Thu Feb 23, 2023 7:36 pm is possible to change serial log level? for exmaple I don't want see this:

Send: [53 55 50 4C 41 ]
20:33:25.549 -> Recv: [53 55 50 4C 41 10 96 00 00 00 32 00 00 00 10 00 00 00 86 BF F7 63 00 00 00 00 58 20 02 00 00 00 00 00 53 55 50 4C 41 ]
20:33:50.448 -> Send: [53 55 50 4C 41 10 71 01 00 00 28 00 00 00 10 00 00 00 4C 0D 00 00 00 00 00 00 10 BB 01 00 00 00 00 00 ]
20:33:50.448 -> Send: [53 55 50 4C 41 ]

Is it possible?
On linux based compilation you can change log level in config (see: https://github.com/SUPLA/supla-device/t ... -log_level ).

Those logs are currently printed with "debug" level, however I will change it to "verbose" log level. Commit is on the main branch already, but not released officially yet. So if you use github you can pull latest version. If you use i.e. Arduino library manager, you'll have to wait for new version official release to get this log at "verbose" level.

On any other target, you have to change code to disable this log level. Please check this file: https://github.com/SUPLA/supla-device/b ... pper.h#L50
If you'll move this line above "if def", it will cut off all verbose logs.

You can also disable this particular log, by commenting it out from source code:
https://github.com/SUPLA/supla-device/b ... k.cpp#L170
Najlepsze suple dla Twojego domu :mrgreen:
micdj
Posts: 31
Joined: Wed Jan 06, 2021 2:23 am

Post

Perfect, thank you, all is clear!!

Return to “Help”