fix #43 added a config interface to change the newline character expected

This commit is contained in:
prozessorkern
2020-03-27 18:34:43 +01:00
parent c2e4324236
commit 3b99ad2a56
5 changed files with 79 additions and 17 deletions

View File

@@ -140,6 +140,7 @@ typedef struct
bool echoEnabled; /**< if true the input is printed */
bool dirty; /**< dirty flag to show changes */
const char *prompt; /**< prompt is printed after every command */
char delimiter; /**< delimiter (return) to terminate a cmd */
shellmatta_mode_t mode; /**< mode of the shell */
shellmatta_write_t write; /**< pointer to write function */
shellmatta_cmd_t helpCmd; /**< help command structure */
@@ -172,7 +173,8 @@ shellmatta_retCode_t shellmatta_removeCmd( shellmatta_handle_t handle,
shellmatta_retCode_t shellmatta_configure( shellmatta_handle_t handle,
shellmatta_mode_t mode,
bool echoEnabled);
bool echoEnabled,
char delimiter);
shellmatta_retCode_t shellmatta_processData(shellmatta_handle_t handle,
char *data,