Automatically re-launch max patch upon crashing in XP.. A solution!!

Dec 29, 2010 at 11:46pm

Automatically re-launch max patch upon crashing in XP.. A solution!!

Hi Everyone,

So it took me ages before I worked out how to do this, the big problem was dealing with those XP dialogue boxes when you get a crash; they would insist on a user click before killing the thread! However now that I have finally come across a solution I thought I would share it with y’all.

Enjoy!
Henrik

How to setup an XP computer to automatically load a max patch on bootup and to automatically relaunch the max patch if it crashes.

1) Open the main patch in Max/MSP, go to edit mode, create a new message box and in it type
; max crash

Now lock the patch. Save the patch. This message box is now a ╩╗self-destruct╩╝ button that we will use to make max/msp crash and burn (with a simulated memory access violation). Press it and make sure that the patch crashes.

2) Download ╩╗Restart on Crash╩╝ (RoC). Go to http://w-shadow.com/blog/2009/03/04/restart-on-crash/

4) open the patch in MaxRuntime.

5) open RestartOnCrash.exe
– click Add
– press ╩╗Select a running application..╩╝
– select ╩╗MaxRT.exe╩╝ (this is Max/MSP runtime)
– in the ╩╗Execute a command╩╝ window, add the path to the patch you want to launch in a separate pair of quotes. i.e. it should contain the path to MaxRT.exe in one pair of quotes, a space, and the path to the patch in another pair of quotes.

For example: ÔÇťC:Program FilesCycling ╩╝74Max 5.0MaxRT.exeÔÇŁ ÔÇťC:Documents and SettingsFred DesktopCrazyPatch.maxpatÔÇŁ

6) Make sure the tick boxes ╩╗It╩╝s not responding to Windows messages╩╝ AND ╩╗It isn╩╝t running╩╝ are both ticked. Also make sure both ╩╗Kill the process╩╝ and ╩╗Execute a command:╩╝ are both ticked. Press ok. If your patch isn╩╝t running RoC will now launch it.

7) Do a couple of tests.
a: Close the patch. It should be relaunched.
b: Press our magic ╩╗auto-destruct╩╝ button. We╩╝ll get an error message, but the patch will be killed and restarted anyway. (Even without needing to press anything on the error dialogue box.. yeay!! The dialogue box will still be there, and we may build up a small collection of them, but they are harmless ;)

8) In ╩╗Restart On Crash╩╝, press the Settings button. Tick ╩╗Run RoC when Windows starts╩╝.
Press Ok.

9) Quit everything and restart the computer. Voila! Victory!

NOTE: If the patch takes a long time to boot, RoC might kill it before it has fully booted. This might happen a couple of times while windows is booting, but once all of windows is up and running, it should do it fine. If the patch under normal circumstances takes over a minute to boot, increase the ╩╗Grace period╩╝ value in the RoC general settings.

—-

#53817

You must be logged in to reply to this topic.