desactivation of the "MATLAB system error" dialog box ?

2 ビュー (過去 30 日間)
Terence Acconci
Terence Acconci 2013 年 2 月 8 日
回答済み: Jan 2019 年 6 月 12 日
Hello,
I'm currently programming a Matlab file (on Windows, with R2008b Matlab) that will be included in a stand-alone PC (i.e. once the program will be started, no human intervention will be possible anymore). This program will have to run during some days, without interruptions. I've already tried to test the code during some hours, but a "segmentation violation" error occurred, after, at least, several hours. When this occurs, a "Matlab system error" dialog box appears, and a click has to be done in order to exit Matlab.
I was wondering if it was possible, when a segmentation violation error occurs, to automatically exit Matlab without having to click on that button. This would be useful for me, because, in that case, it would be possible for Windows to detect the end of the Matlab process, and to re-execute it automatically, as well as the Matlab file (-> no human intervention required).
Thank you in advance for your answers.
Terence.
  1 件のコメント
Arthur
Arthur 2019 年 6 月 12 日
編集済み: Arthur 2019 年 6 月 12 日
Hello,
Was such a feature implemented between R2008 and more recent versions (e.g. R2015b) ?
This dialog box that pauses matlab is quite annoying when wanting to use matlab for continuous testing.
Best,
Arthur

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

回答 (2 件)

Jason Ross
Jason Ross 2013 年 2 月 8 日
I don't know the answer to your immediate question, but I'd suggest that you develop a means of monitoring this machine, as well as the program, given how it's going to be running. If it's not MATLAB throwing up a dialog box, it could be something else.
For monitoring the machine, there are a number of packages available such as Nagios and Cacti, in addition to roll-your-own solutions like pinging the host to see if it's still up and responsive.
For the code in MATLAB that's executing unattended, I'd suggest you develop a "heartbeat" method that you can monitor and alert on if the program stops working. An example might be as simple as touching a file every five minutes to let you know the program is still running, and setting up a script that alerts you if it hasn't happened. You might already be putting data down on disk with some regularity, so you could use that, too. You can use a monitoring tool as mentioned above to check for this, or roll-your-own.
Depending on your environment/organization, there might be something in place already.
  1 件のコメント
Jan
Jan 2013 年 2 月 8 日
Does a seg fault stop a running timer()?

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


Jan
Jan 2019 年 6 月 12 日
I'm running a long test also. The code displays some logging messages every few seconds. A second Matlab session takes a screenshot every minute. If there is no change, the first session is assumed to hang. Now the java awt robot can be used to press the "Cancel" button, but its position depends on the shown error message. It is easier to use taskkill to remove the process.

カテゴリ

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

Community Treasure Hunt

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

Start Hunting!

Translated by