Issue #28: Start GUI for Temp Profile execution
This commit is contained in:
@@ -695,11 +695,37 @@ shellmatta_retCode_t shell_cmd_execute(const shellmatta_handle_t handle, const c
|
||||
uint32_t dlen;
|
||||
(void)args;
|
||||
(void)len;
|
||||
int opt_stat;
|
||||
char option;
|
||||
char *argument;
|
||||
uint32_t arg_len;
|
||||
const char *script_name = NULL;
|
||||
const shellmatta_opt_long_t options[] = {
|
||||
{NULL, '\0', SHELLMATTA_OPT_ARG_NONE},
|
||||
};
|
||||
|
||||
while (1) {
|
||||
opt_stat = shellmatta_opt_long(handle, options, &option, &argument, &arg_len);
|
||||
if (opt_stat != SHELLMATTA_OK)
|
||||
break;
|
||||
switch (option) {
|
||||
case '\0':
|
||||
script_name = argument;
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
if (!script_name) {
|
||||
shellmatta_printf(handle, "No script name specified!\r\n");
|
||||
return SHELLMATTA_ERROR;
|
||||
}
|
||||
|
||||
shellmatta_read(handle, &data, &dlen);
|
||||
|
||||
if (!running) {
|
||||
res = temp_profile_executer_start("profile.tpr");
|
||||
res = temp_profile_executer_start(script_name);
|
||||
|
||||
if (res != PL_RET_SUCCESS) {
|
||||
switch (res) {
|
||||
|
Reference in New Issue
Block a user