offtopic: need help for mcu-uuid-console with telnet logging #2289
-
Hi everyone, thanks for help und understanding ;) attached the basic sketch #include <Arduino.h>
#include <memory>
#include <string>
#include <vector>
#include <uuid/common.h>
#include <uuid/console.h>
#include <uuid/telnet.h>
#include <uuid/syslog.h>
#include "commands.h"
using uuid::read_flash_string;
using uuid::flash_string_vector;
using uuid::console::Commands;
using uuid::console::Shell;
// uuid-console + telnet
static std::shared_ptr<uuid::console::Commands> commands = std::make_shared<uuid::console::Commands>();
static uuid::telnet::TelnetService telnet{commands};
//uuid-syslog
static uuid::syslog::SyslogService syslog;
setup(){
//Setup Console
registerCommands(commands);
telnet.start();
//Setup syslog
//Setup Logger
static uuid::log::Logger logger{F("setup")};
syslog.start();
String hostname_syslog = hostname_base + get_flashmemory_id();
syslog.hostname(hostname_syslog.c_str());
syslog.log_level(uuid::log::ALL);
syslog.mark_interval(3600);
syslog.destination(IPAddress(192, 168, 0, 207), 514);
// Log testmessage
logger.info(F("LLU Client Application started"));
}
loop(){
uuid::loop();
syslog.loop();
telnet.loop();
Shell::loop_all();yield();
} |
Beta Was this translation helpful? Give feedback.
Replies: 3 comments 2 replies
-
Take a look at |
Beta Was this translation helpful? Give feedback.
-
hey Proddy, chris |
Beta Was this translation helpful? Give feedback.
-
dear Proddy, void setLoglevelCommand(uuid::console::Shell &shell, const std::vector<std::string> &) {
shell.printfln(F("Set Loglevel to ALL:"));
shell.log_level(uuid::log::Level::ALL);
} I can see the logging in the console as well. sry for disturbing sers, |
Beta Was this translation helpful? Give feedback.
dear Proddy,
no need for tsting it anymore.
Simon gave me the hint, that the standard Loglevel in the Console is NOTICE and I tried with INFO, which is lower.
After changing the level to ALL with:
I can see the logging in the console as well.
sry for disturbing
sers,
Chris