exos_log_process(): Receive current log configuration

<< 点击显示目录 >>

主页  exOS使用助手 > exOS Automation Help > Development > Programming > exOS Log API reference (exos_log.h) >

exos_log_process(): Receive current log configuration

 EXOS_ERROR_CODE exos_log_process(const exos_log_handle_t *log);

该函数用于接收日志服务器广播的日志配置(过滤器)。一旦收到配置(即模块知道日志服务器/系统设置了哪个过滤器),应用程序就可以向日志服务器发送日志。

exos_datamodel_process() 类似 ,exos_log_process ()也 需要循环调用 。

在应用程序从日志服务器接收到日志配置(过滤器)之前,日志信息存储在 exos_log_handle_t的内部缓冲区(有 100 个条目)中 。一旦应用程序接收到配置,之前缓冲的所有日志信息都会发送到日志服务器,除非使用了级别、类型或排除过滤器。

参数

log:指向  接收配置更改的exos_log_handle_t的指针


 EXOS_ERROR_CODE exos_log_process(const exos_log_handle_t *log);

This function is used to receive the log configuration (filter) that is broadcast by the log server. As soon as a configuration has been recieved (i.e. the module knows which filter the log-server / system has set), the application can send out its logs to the log-server.

The exos_log_process() needs to be called cyclically, similar to exos_datamodel_process().

Until the application has received the log configuration (filter) from the log server, the logged messages are stored in an internal buffer (with 100 entries) in the exos_log_handle_t. As soon as the application receives the configuration, all previously buffered log messages are sent out to the log-server, unless a level, type or exclude filter applies.

Parameters:

log: pointer to the exos_log_handle_t that receives the configuration changes