「App:Library:LVGL:docs:Porting:Logging」の版間の差分
| 12行目: | 12行目: | ||
= Logging = | = Logging = | ||
| + | {| class="wikitable" | ||
| + | !英文 | ||
| + | !自動翻訳 | ||
| + | |- | ||
| + | | | ||
LVGL has a built-in ''Log'' module to inform the user about what is happening in the library. | LVGL has a built-in ''Log'' module to inform the user about what is happening in the library. | ||
| + | |LVGLには、ライブラリで何が起こっているかをユーザーに通知するため の組み込みのログモジュールがあります。 | ||
| + | |} | ||
| + | :[[App:Library:LVGL:docs:Porting|戻る : Previous]] | ||
| + | |||
== Log level == | == Log level == | ||
2022年6月22日 (水) 14:44時点における版
https://docs.lvgl.io/8.2/porting/log.html
| 英文 | 自動翻訳 |
|---|---|
Logging
| 英文 | 自動翻訳 |
|---|---|
|
LVGL has a built-in Log module to inform the user about what is happening in the library. |
LVGLには、ライブラリで何が起こっているかをユーザーに通知するため の組み込みのログモジュールがあります。 |
Log level
| 英文 | 自動翻訳 |
|---|---|
|
To enable logging, set
|
ロギングを有効にするには、次のいずれかの値に設定LV_USE_LOG 1しlv_conf.hて設定LV_LOG_LEVELします。
設定されたログレベルよりも高いレベルのイベントもログに記録されます。たとえば |
Printing logs
Logging with printf
| 英文 | 自動翻訳 |
|---|---|
|
If your system supports |
システムがをサポートしている場合は、でログを送信するためにを有効にprintfする必要があります。 LV_LOG_PRINTFlv_conf.hprintf
|
Custom log function
| 英文 | 自動翻訳 |
|---|---|
|
If you can't use
void my_log_cb(const char * buf)
{
serial_send(buf, strlen(buf));
}
...
lv_log_register_print_cb(my_log_cb);
|
例えば: void my_log_cb (const char * buf )
{
serial_send (buf 、 strlen (buf ));
}
...
lv_log_register_print_cb (my_log_cb );
|
Add logs
| 英文 | 自動翻訳 |
|---|---|
|
You can also use the log module via the |
関数を介してログモジュールを使用することもできますLV_LOG_TRACE/INFO/WARN/ERROR/USER(text)。
|