|
Golioth Firmware SDK
|
Functions | |
| enum golioth_status | golioth_log_error (struct golioth_client *client, const char *tag, const char *log_message, golioth_set_cb_fn callback, void *callback_arg) |
| enum golioth_status | golioth_log_warn (struct golioth_client *client, const char *tag, const char *log_message, golioth_set_cb_fn callback, void *callback_arg) |
| Same as golioth_log_error, but for warning level. | |
| enum golioth_status | golioth_log_info (struct golioth_client *client, const char *tag, const char *log_message, golioth_set_cb_fn callback, void *callback_arg) |
| Same as golioth_log_error, but for info level. | |
| enum golioth_status | golioth_log_debug (struct golioth_client *client, const char *tag, const char *log_message, golioth_set_cb_fn callback, void *callback_arg) |
| Same as golioth_log_error, but for debug level. | |
Functions for logging messages to Golioth
https://docs.golioth.io/reference/protocols/coap/logging
| enum golioth_status golioth_log_debug | ( | struct golioth_client * | client, |
| const char * | tag, | ||
| const char * | log_message, | ||
| golioth_set_cb_fn | callback, | ||
| void * | callback_arg ) |
Same as golioth_log_error, but for debug level.
| enum golioth_status golioth_log_error | ( | struct golioth_client * | client, |
| const char * | tag, | ||
| const char * | log_message, | ||
| golioth_set_cb_fn | callback, | ||
| void * | callback_arg ) |
Log an error to Golioth
This function will enqueue a request and return immediately without waiting for a response from the server. The callback will be invoked when a response is received or a timeout occurs.
| client | The client handle from golioth_client_create |
| tag | A free-form string to identify/tag the message |
| log_message | String to log. Must be NULL-terminated. |
| callback | Callback to call on response received or timeout. Can be NULL. |
| callback_arg | Callback argument, passed directly when callback invoked. Can be NULL. |
| enum golioth_status golioth_log_info | ( | struct golioth_client * | client, |
| const char * | tag, | ||
| const char * | log_message, | ||
| golioth_set_cb_fn | callback, | ||
| void * | callback_arg ) |
Same as golioth_log_error, but for info level.
| enum golioth_status golioth_log_warn | ( | struct golioth_client * | client, |
| const char * | tag, | ||
| const char * | log_message, | ||
| golioth_set_cb_fn | callback, | ||
| void * | callback_arg ) |
Same as golioth_log_error, but for warning level.