Skip to content

Commit

Permalink
Added an "echo" command! I guess you know what it does xD
Browse files Browse the repository at this point in the history
  • Loading branch information
aponigricon committed Jun 26, 2012
1 parent 3f454e5 commit 0d47acf
Showing 1 changed file with 27 additions and 0 deletions.
27 changes: 27 additions & 0 deletions apps/AtlasShell.dasm16
Expand Up @@ -105,6 +105,13 @@
JSR [0x101A]
IFE C, 0
JSR command_catf

; Check for the 'echo' command
SET A, command_echo
SET B, command_parameter_buffer
JSR [0x101A]
IFE C, 0
JSR command_echof

; Check if we're trying to run a file
IFN [ack_command], 1
Expand Down Expand Up @@ -786,6 +793,25 @@
SET B, POP
SET A, POP
SET PC, POP

:command_echof
SET [ack_command], 1
SET PUSH, A
SET PUSH, B

SET A, input_text_buffer
ADD A, 5
SET B, command_parameter_buffer
JSR [0x1018]

SET A, command_parameter_buffer
JSR [0x101C]

JSR [0x101E]

SET B, POP
SET A, POP
SET PC, POP

:AtlasShell_die
SET A, input_buffer
Expand Down Expand Up @@ -945,6 +971,7 @@
:command_cp dat "cp", 0 ; UNFINISHED
:command_ln dat "ln", 0 ; UNFINISHED
:command_mv dat "mv", 0 ; UNFINISHED
:command_echo dat "echo", 0

; Process list buffer. Used for the 'kill' command
:proc_list_buffer
Expand Down

0 comments on commit 0d47acf

Please sign in to comment.