瀏覽代碼

Update shell.c

To enhance the robustness of key recognition and solve the problem of errors and omissions caused by the lag of state assignment statement
增强方向键识别的鲁棒性,解决状态赋值语句滞后带来的错漏问题
LTreeshu 4 周之前
父節點
當前提交
cd3789f8ec
共有 1 個文件被更改,包括 1 次插入1 次删除
  1. 1 1
      components/finsh/shell.c

+ 1 - 1
components/finsh/shell.c

@@ -535,7 +535,7 @@ static void finsh_thread_entry(void *parameter)
         }
         }
         else if (shell->stat == WAIT_SPEC_KEY)
         else if (shell->stat == WAIT_SPEC_KEY)
         {
         {
-            if (ch == 0x5b)
+            if (ch == 0x5b || ch == 0x41 || ch == 0x42 || ch == 0x43 || ch == 0x44)
             {
             {
                 shell->stat = WAIT_FUNC_KEY;
                 shell->stat = WAIT_FUNC_KEY;
                 continue;
                 continue;