diff --git a/applications/sh/commands/commands.asm b/applications/sh/commands/commands.asm index 710b567..d8efe72 100644 --- a/applications/sh/commands/commands.asm +++ b/applications/sh/commands/commands.asm @@ -26,6 +26,11 @@ shell_parse_command: call compare_string ifz jmp shell_diskrm_command + ; echo + mov r1, shell_echo_command_string + call compare_string + ifz jmp shell_echo_command + ; exit mov r1, shell_exit_command_string call compare_string @@ -72,6 +77,7 @@ shell_invalid_command_string: data.str "invalid command or FXF binary" data.8 10 #include "commands/dir.asm" #include "commands/disk.asm" #include "commands/diskrm.asm" + #include "commands/echo.asm" #include "commands/exit.asm" #include "commands/help.asm" #include "commands/rdall.asm" diff --git a/applications/sh/commands/echo.asm b/applications/sh/commands/echo.asm new file mode 100644 index 0000000..44e0c9c --- /dev/null +++ b/applications/sh/commands/echo.asm @@ -0,0 +1,11 @@ +; clear command + +shell_echo_command_string: data.strz "echo" + +shell_echo_command: + mov r0, [shell_args_ptr] + call print_str_to_terminal + mov r0, 10 + call print_character_to_terminal + + ret diff --git a/applications/sh/commands/help.asm b/applications/sh/commands/help.asm index cdf8cec..7048997 100644 --- a/applications/sh/commands/help.asm +++ b/applications/sh/commands/help.asm @@ -20,6 +20,7 @@ shell_help_text: data.str "dir | show contents of selected disk" data.8 10 data.str "disk | select disk $0" data.8 10 data.str "diskrm | remove disk $0" data.8 10 + data.str "echo | print the specified text" data.8 10 data.str "exit | exit the shell" data.8 10 data.str "help | show this help text" data.8 10 data.str "rdall | redirect all IO to $0" data.8 10