From 31be4bd348fdbdd13cd6228f97aa069e0dee5671 Mon Sep 17 00:00:00 2001 From: Zihao Yu Date: Thu, 11 Jan 2024 01:43:46 +0800 Subject: [PATCH] components,finsh,shell: do not sleep when there is no input --- components/finsh/shell.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/components/finsh/shell.c b/components/finsh/shell.c index cfd0855..6b9405a 100644 --- a/components/finsh/shell.c +++ b/components/finsh/shell.c @@ -171,7 +171,7 @@ int finsh_getchar(void) while (rt_device_read(device, -1, &ch, 1) != 1) { - rt_sem_take(&shell->rx_sem, RT_WAITING_FOREVER); + //rt_sem_take(&shell->rx_sem, RT_WAITING_FOREVER); if (shell->device != device) { device = shell->device;