aboutsummaryrefslogtreecommitdiffstats
path: root/com32/hdt/hdt-cli-hdt.c
diff options
context:
space:
mode:
Diffstat (limited to 'com32/hdt/hdt-cli-hdt.c')
-rw-r--r--com32/hdt/hdt-cli-hdt.c17
1 files changed, 17 insertions, 0 deletions
diff --git a/com32/hdt/hdt-cli-hdt.c b/com32/hdt/hdt-cli-hdt.c
index 0fd51f3e..70cd0499 100644
--- a/com32/hdt/hdt-cli-hdt.c
+++ b/com32/hdt/hdt-cli-hdt.c
@@ -260,6 +260,18 @@ static void do_dump(int argc __unused, char **argv __unused,
}
/**
+ * do_sleep - sleep a number of milliseconds
+ **/
+static void do_sleep(int argc , char **argv ,
+ struct s_hardware *hardware)
+{
+ (void) hardware;
+ if (argc != 1) return;
+ printf("Sleep %d milliseconds\n",atoi(argv[0]));
+ msleep(atoi(argv[0]));
+}
+
+/**
* do_display - display an image to user
**/
static void do_display(int argc , char **argv ,
@@ -374,6 +386,11 @@ struct cli_callback_descr list_hdt_default_modules[] = {
.nomodule = true,
},
{
+ .name = CLI_SLEEP,
+ .exec = do_sleep,
+ .nomodule = true,
+ },
+ {
.name = NULL,
.exec = NULL,
.nomodule = false},