Why does the timer object fail when I run MATLAB remotely through a text window?
이전 댓글 표시
I use telnet or ssh to log into a remote UNIX/Linux machine and run MATLAB on that machine. I only have a text-based window, and do not have X11 forwarding enabled for this connection (or I do not have an X-server running on my local machine).
When I run MATLAB, I see the following warning:
Warning: Unable to open display , MATLAB is starting without a display.
You will not be able to display graphics on the screen.
While running MATLAB, issuing a command such as FIGURE does not produce any output on the screen.
I then create a timer object and start it as shown below:
a=1;
t=timer('TimerFcn','a=5','Period',2,'ExecutionMode', 'fixedRate');
start(t)
The "TimerFcn" is never executed as I can verify by checking the value of the variable "a" at any point after the timer has been started. In other words, the following command typed at the MATLAB prompt:
a
will produce
a =
1
whereas it should return a value of 5 for "a", since I expect the "TimerFcn" to execute at least once at this point.
채택된 답변
추가 답변 (0개)
카테고리
도움말 센터 및 File Exchange에서 Entering Commands에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!