pause function doesn't work R20a

9 ビュー (過去 30 日間)
Mohanad
Mohanad 2023 年 6 月 9 日
コメント済み: Walter Roberson 2023 年 6 月 10 日
y=1;
while y<5
x=8
pause()
y=y+1;
end
this is just a simplified example to show that pause function is not working, I am not getting the code to be paused, any idea or relative function does the same job?

回答 (2 件)

the cyclist
the cyclist 2023 年 6 月 9 日
Is it possible that another pause function was defined? When do you get from typing
which pause -all
in the command window?
  1 件のコメント
Mohanad
Mohanad 2023 年 6 月 9 日
編集済み: Mohanad 2023 年 6 月 9 日
this is very good observation, unfortunatly this is the only pause function defined in the matlab2020a/toolbox/matlab/timefun/pause
there is no other pause defined.

サインインしてコメントする。


Walter Roberson
Walter Roberson 2023 年 6 月 9 日
Is that definitely the code? pause() without any parameter waits for a key to be pressed on the keyboard
Exception: if
pause off
has been executed, then the wait for keyboard is skipped.
  2 件のコメント
Mohanad
Mohanad 2023 年 6 月 9 日
this is not the code that I am trying to use pause function with, this is just a very basic code shows that pause function is not working with MATLAB R2020a, pause on or puase off or pause('on') and pasue('off') nothing is working, the pause function is completely useless in 2020a
Walter Roberson
Walter Roberson 2023 年 6 月 10 日
I just tried on my R2020a on my Mac, and pause() worked fine

サインインしてコメントする。

カテゴリ

Help Center および File ExchangeMatrix Indexing についてさらに検索

製品


リリース

R2020a

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by