mod_installer.h
Defines
-
DLMODULE_STRINGIFY_(val)
-
DLMODULE_STRINGIFY(val)
Converts a macro argument into a character constant.
-
DLMODULE_CONCAT_2_(p1, p2)
-
DLMODULE_CONCAT_2(p1, p2)
Concatenates two parameters.
It realizes two level expansion to make it sure that all the parameters are actually expanded before gluing them together.
- Parameters:
p1 – First parameter to concatenating
p2 – Second parameter to concatenating
- Returns:
Two parameters glued together. They have to create correct C mnemonic in other case preprocessor error would be generated.
-
MODULE_CONTEXT
-
MODULE_CONTEXT_DEFINE
-
MODULE_CONTEXT_ALLOC()
-
MODULE_CONTEXT_FREE()
-
MODULE_INIT_DEF(init_func)
-
MODULE_CLEANUP_DEF(cleanup_func)
-
MODULE_NAME
Functions
-
rt_err_t mod_install(const char *mod_name, const char *package_path, const char *install_path)
Install dlmodule.
- Parameters:
mod_name – [in] module name
package_path – [in] .so file path
install_path – [in] where to install the module
- Return values:
RT_EOK – success, other: fail, negative value for error code, such as -RT_ERROR
-
rt_err_t app_install(app_installer_info_t *info)
Install application.
- Parameters:
info – [in] Application installer info
- Return values:
RT_EOK – success, other: fail, negative value for error code, such as -RT_ERROR
-
int32_t app_uninstall(const char *app_name, const char *res_install_path, const char *pgm_install_path)
Uninstall application.
- Parameters:
app_name – [in] application name
res_install_path – [in] Resource install path
pgm_install_path – [in] Program install path
- Return values:
0 – success, other: fail
-
int32_t mod_installer_init(uint32_t sys_prog_start_addr, uint32_t sys_prog_end_addr)
Init mod_installer.
- Parameters:
sys_prog_start_addr – [in] Start address of system program
sys_prog_end_addr – [in] End address of system program
- Return values:
0 – success, other: fail
-
struct rt_dlmodule *app_open(const char *res_package_path, const char *package_path)
Open application.
- Parameters:
res_package_path – [in] App resource .so file full path
package_path – [in] App program .so file full path
- Return values:
module – instance of App
-
rt_err_t app_close(struct rt_dlmodule *module)
Close application.
- Parameters:
module – [in] Module instance of App
- Return values:
RT_EOK – success, other: fail
-
struct app_installer_info_t
- #include <mod_installer.h>
Application installer info