|
MRTKLIB 0.7.14
Modernized GNSS Positioning Library
|
Go to the source code of this file.
Functions | |
| mrtk_ctx_t * | mrtk_ctx_create (void) |
| Create a new runtime context. | |
| void | mrtk_ctx_destroy (mrtk_ctx_t *ctx) |
| Destroy a runtime context. | |
Variables | |
| mrtk_ctx_t * | g_mrtk_ctx = NULL |
| Global context pointer for transitional migration. | |
| mrtk_ctx_t * mrtk_ctx_create | ( | void | ) |
Create a new runtime context.
Allocates and zero-initialises a context. Default settings:
Definition at line 31 of file mrtk_context.c.
References calloc, mrtk_ctx_t::cancel_requested, mrtk_ctx_t::cb_showmsg, mrtk_ctx_t::is_running, mrtk_ctx_t::last_err_code, mrtk_ctx_t::last_err_msg, MRTK_OK, mrtk_ctx_t::tick_trace, mrtk_ctx_t::trace_fp, mrtk_ctx_t::trace_level, and mrtk_ctx_t::user_data.
| void mrtk_ctx_destroy | ( | mrtk_ctx_t * | ctx | ) |
Destroy a runtime context.
Closes the trace file (unless stdout/stderr) and frees memory. Safe to call with NULL.
| [in] | ctx | Context to destroy, or NULL (no-op) |
Definition at line 50 of file mrtk_context.c.
References free, and mrtk_ctx_t::trace_fp.
| mrtk_ctx_t* g_mrtk_ctx = NULL |
Global context pointer for transitional migration.
Functions that have not yet received an explicit ctx parameter use this global as a fallback. Applications should set this at startup and clear it at shutdown.
Definition at line 25 of file mrtk_context.c.
Referenced by rtksvrstart().