FreeCalypso > hg > freecalypso-sw
comparison rvinterf/etm/usercmd.c @ 189:a95d253ef952
fc-tmsh: some basic tmcore commands implemented
author | Michael Spacefalcon <msokolov@ivan.Harhan.ORG> |
---|---|
date | Mon, 25 Nov 2013 03:10:41 +0000 |
parents | 13a0348ffce4 |
children | 707aa640b2dc |
comparison
equal
deleted
inserted
replaced
188:9f4f331ac24d | 189:a95d253ef952 |
---|---|
9 #include <strings.h> | 9 #include <strings.h> |
10 #include <stdlib.h> | 10 #include <stdlib.h> |
11 | 11 |
12 extern char usercmd[]; | 12 extern char usercmd[]; |
13 | 13 |
14 extern void cmd_dieid(); | |
14 extern void cmd_etmpkt(); | 15 extern void cmd_etmpkt(); |
16 extern void cmd_ping(); | |
17 extern void cmd_r8(); | |
18 extern void cmd_r16(); | |
19 extern void cmd_r32(); | |
20 extern void cmd_tgtreset(); | |
21 extern void cmd_version(); | |
15 | 22 |
16 void | 23 void |
17 cmd_exit() | 24 cmd_exit() |
18 { | 25 { |
19 tty_cleanup(); | 26 tty_cleanup(); |
24 char *cmd; | 31 char *cmd; |
25 int minargs; | 32 int minargs; |
26 int maxargs; | 33 int maxargs; |
27 void (*func)(); | 34 void (*func)(); |
28 } cmdtab[] = { | 35 } cmdtab[] = { |
36 {"dieid", 0, 0, cmd_dieid}, | |
29 {"etmpkt", 1, 253, cmd_etmpkt}, | 37 {"etmpkt", 1, 253, cmd_etmpkt}, |
30 {"exit", 0, 0, cmd_exit}, | 38 {"exit", 0, 0, cmd_exit}, |
39 {"ping", 0, 2, cmd_ping}, | |
31 {"quit", 0, 0, cmd_exit}, | 40 {"quit", 0, 0, cmd_exit}, |
41 {"r8", 1, 2, cmd_r8}, | |
42 {"r16", 1, 2, cmd_r16}, | |
43 {"r32", 1, 2, cmd_r32}, | |
44 {"tgtreset", 0, 0, cmd_tgtreset}, | |
45 {"version", 1, 1, cmd_version}, | |
32 {0, 0, 0, 0} | 46 {0, 0, 0, 0} |
33 }; | 47 }; |
34 | 48 |
35 void | 49 void |
36 dispatch_user_cmd() | 50 dispatch_user_cmd() |