Discover MakerZone

MATLAB and Simulink resources for Arduino, LEGO, and Raspberry Pi

Learn more

Discover what MATLAB® can do for your career.

Opportunities for recent engineering grads.

Apply Today

Thread Subject:
tmtool hangs when launched and MATLAB stop responding

Subject: tmtool hangs when launched and MATLAB stop responding

From: Francesco

Date: 20 Nov, 2013 17:04:19

Message: 1 of 8

I used MATLAB with ICT (Instrument Control Toolbox) for many years whitout any problem; suddenly, in the past days I begun to have serious problems with tmtool and other ICT functions (like gpib, visa, etc.).

When I start tmtool (in MATLAB R2013a) it requires a long time to open its GUI (a time in the order of many minutes); also, when it starts, any scan/refresh/connect/disconnect command I give on any node of the tree on the left or on the control panel on the right requires a very long time to complete and often fails, even if the interface (I use a National Instruments' USB-GPIB-HS adapter) is correctly configured and works fine in other development environments.

The instruments connected to the PC by means of the GPIB adapter are correctly identified but only after a long delay; if I use the NI's utility "I/O Trace", I can see that the calls to the underlying GPIB functions are not made at all within the pause period.

I run MATLAB 32-bit on a Windows 7 Professional 64-bit (this is due to the lack of complete support of Nationa Instruments DAQ under MATLAB 64-bit); the installed driver software for GPIB is NI-488 v3.1.1 and NI-VISA v5.4

If I open tmtool.m I find only a row of code:
awtinvoke('com.mathworks.toolbox.instrument.browser.ICTBrowserDesktop','openDesktop');

Is there a way to debug at low level this problem?

Any hint will be appreciated.

Subject: tmtool hangs when launched and MATLAB stop responding

From: Steven Lord

Date: 20 Nov, 2013 18:14:16

Message: 2 of 8


"Francesco " <adamo@misure.poliba.it> wrote in message
news:l6iq2j$7f1$1@newscl01ah.mathworks.com...
> I used MATLAB with ICT (Instrument Control Toolbox) for many years whitout
> any problem; suddenly, in the past days I begun to have serious problems
> with tmtool and other ICT functions (like gpib, visa, etc.).

What changed between the last time this worked and the first time you
encountered problems?

* Did you connect new hardware to your computer? If so, what happens if you
replace the new hardware with your original hardware?
* Did you switch computers? If so, can you reproduce this behavior with your
original computer (if it's still available?)
* Did you install any Windows updates? If so, do the descriptions of those
Windows updates suggest that they might interfere with hardware connected to
your computer?
* Did you update your hardware drivers? If so, can you try reverting that
update to check if the new driver is the cause?
* Did you install a new version of MATLAB and/or Instrument Control Toolbox?
If so, does the older version of MATLAB and/or Instrument Control Toolbox
exhibit this same behavior now?

I'm not that familiar with the details of TMTOOL or the hardware interface,
but those are some of the changes that I think off the top of my head might
have caused the behavior you described.

If none of those are applicable, you should contact your local Technical
Support office using the instructions in my signature and ask them for help
diagnosing the problem.

*snip*

--
Steve Lord
slord@mathworks.com
To contact Technical Support use the Contact Us link on
http://www.mathworks.com

Subject: tmtool hangs when launched and MATLAB stop responding

From: Francesco

Date: 21 Nov, 2013 08:36:11

Message: 3 of 8

Steven,

thank you for your answer!

Really I made many software updates to my PC from last time I used tmtool; however all other development environments that I use don't show any problem with them.

I already tried to revert the MATLAB and the GPIB adapter driver versions to their original ones, but the behaviour of tmtool has not changed.

I suspect that the problem is related to JAVA; I will try to find a way to debug the call to com.mathworks.toolbox.instrument.browser.ICTBrowserDesktop inside tmtool.

If I don't solve the problem in this way I'll call the technical support.

Thank you again for your suggestions; regards.

Subject: tmtool hangs when launched and MATLAB stop responding

From: Steven Lord

Date: 21 Nov, 2013 14:39:41

Message: 4 of 8


"Francesco " <adamo@misure.poliba.it> wrote in message
news:l6kglr$9pj$1@newscl01ah.mathworks.com...
> Steven,
>
> thank you for your answer!
>
> Really I made many software updates to my PC from last time I used tmtool;
> however all other development environments that I use don't show any
> problem with them.
>
> I already tried to revert the MATLAB and the GPIB adapter driver versions
> to their original ones, but the behaviour of tmtool has not changed.
>
> I suspect that the problem is related to JAVA; I will try to find a way to
> debug the call to
> com.mathworks.toolbox.instrument.browser.ICTBrowserDesktop inside tmtool.
>
> If I don't solve the problem in this way I'll call the technical support.

I would be extremely surprised if you could debug that Java call. Technical
Support can, or can work with the developers who can.

--
Steve Lord
slord@mathworks.com
To contact Technical Support use the Contact Us link on
http://www.mathworks.com

Subject: tmtool hangs when launched and MATLAB stop responding

From: Shreenath

Date: 27 Nov, 2013 19:03:05

Message: 5 of 8

Hi,

If TMTOOL takes too long to open then the issue can also be because the tmtool.cfg file in your preference directory is too large to parse. Just rename that file and try opening TMTOOL.

Thanks
Shreenath.R


"Steven Lord" <Steven_Lord@mathworks.com> wrote in message <l6iu5o$lds$1@newscl01ah.mathworks.com>...
>
> "Francesco " <adamo@misure.poliba.it> wrote in message
> news:l6iq2j$7f1$1@newscl01ah.mathworks.com...
> > I used MATLAB with ICT (Instrument Control Toolbox) for many years whitout
> > any problem; suddenly, in the past days I begun to have serious problems
> > with tmtool and other ICT functions (like gpib, visa, etc.).
>
> What changed between the last time this worked and the first time you
> encountered problems?
>
> * Did you connect new hardware to your computer? If so, what happens if you
> replace the new hardware with your original hardware?
> * Did you switch computers? If so, can you reproduce this behavior with your
> original computer (if it's still available?)
> * Did you install any Windows updates? If so, do the descriptions of those
> Windows updates suggest that they might interfere with hardware connected to
> your computer?
> * Did you update your hardware drivers? If so, can you try reverting that
> update to check if the new driver is the cause?
> * Did you install a new version of MATLAB and/or Instrument Control Toolbox?
> If so, does the older version of MATLAB and/or Instrument Control Toolbox
> exhibit this same behavior now?
>
> I'm not that familiar with the details of TMTOOL or the hardware interface,
> but those are some of the changes that I think off the top of my head might
> have caused the behavior you described.
>
> If none of those are applicable, you should contact your local Technical
> Support office using the instructions in my signature and ask them for help
> diagnosing the problem.
>
> *snip*
>
> --
> Steve Lord
> slord@mathworks.com
> To contact Technical Support use the Contact Us link on
> http://www.mathworks.com

Subject: tmtool hangs when launched and MATLAB stop responding

From: Kai Shi

Date: 10 Dec, 2013 17:18:05

Message: 6 of 8

Hi Shreenath,

Could you give me some more details of how to locate this tmtool.cfg file?

Thanks
Kai

"Shreenath " <shreenathr@gmail.com> wrote in message <l75fl9$b4p$1@newscl01ah.mathworks.com>...
> Hi,
>
> If TMTOOL takes too long to open then the issue can also be because the tmtool.cfg file in your preference directory is too large to parse. Just rename that file and try opening TMTOOL.
>
> Thanks
> Shreenath.R
>
>
> "Steven Lord" <Steven_Lord@mathworks.com> wrote in message <l6iu5o$lds$1@newscl01ah.mathworks.com>...
> >
> > "Francesco " <adamo@misure.poliba.it> wrote in message
> > news:l6iq2j$7f1$1@newscl01ah.mathworks.com...
> > > I used MATLAB with ICT (Instrument Control Toolbox) for many years whitout
> > > any problem; suddenly, in the past days I begun to have serious problems
> > > with tmtool and other ICT functions (like gpib, visa, etc.).
> >
> > What changed between the last time this worked and the first time you
> > encountered problems?
> >
> > * Did you connect new hardware to your computer? If so, what happens if you
> > replace the new hardware with your original hardware?
> > * Did you switch computers? If so, can you reproduce this behavior with your
> > original computer (if it's still available?)
> > * Did you install any Windows updates? If so, do the descriptions of those
> > Windows updates suggest that they might interfere with hardware connected to
> > your computer?
> > * Did you update your hardware drivers? If so, can you try reverting that
> > update to check if the new driver is the cause?
> > * Did you install a new version of MATLAB and/or Instrument Control Toolbox?
> > If so, does the older version of MATLAB and/or Instrument Control Toolbox
> > exhibit this same behavior now?
> >
> > I'm not that familiar with the details of TMTOOL or the hardware interface,
> > but those are some of the changes that I think off the top of my head might
> > have caused the behavior you described.
> >
> > If none of those are applicable, you should contact your local Technical
> > Support office using the instructions in my signature and ask them for help
> > diagnosing the problem.
> >
> > *snip*
> >
> > --
> > Steve Lord
> > slord@mathworks.com
> > To contact Technical Support use the Contact Us link on
> > http://www.mathworks.com

Subject: tmtool hangs when launched and MATLAB stop responding

From: Francesco

Date: 10 Dec, 2013 18:19:07

Message: 7 of 8

"Kai Shi" wrote in message <l87icd$hr4$1@newscl01ah.mathworks.com>...
> Hi Shreenath,
>
> Could you give me some more details of how to locate this tmtool.cfg file?
>
> Thanks
> Kai
>

I found tmtool.cfg file in

C:\Users\<your_user_name>\AppData\Roaming\MathWorks\MATLAB\R2013b

My PC is based on Windows 7 Professional 64 bit.

However the solution proposed by Shreenath (thanks!) doesn't work in my case.

I managed to make the UI of tmtool to start normally modifying row 121 of awtinvoke.m from:

com.mathworks.jmi.AWTUtilities.invokeLater(obj, meth, arglist);

to:

 com.mathworks.jmi.AWTUtilities.invokeAndWait(obj, meth, arglist);

That is changing the calling from asynchronous to synchronous.

However tmtool still continue to hang for minutes when scanning for instruments!

Subject: tmtool hangs when launched and MATLAB stop responding

From: Shreenath

Date: 10 Dec, 2013 18:19:07

Message: 8 of 8

Hi Kai,

Execute the following command in MATLAB command prompt
>> cd(prefdir)

More information about prefdir:
http://www.mathworks.com/help/matlab/ref/prefdir.html

This should take you to the MATLAB preference directory, you should be able to see the tmtool.cfg file in this directory.

Thanks
Shreenath.R

Tags for this Thread

What are tags?

A tag is like a keyword or category label associated with each thread. Tags make it easier for you to find threads of interest.

Anyone can tag a thread. Tags are public and visible to everyone.

Contact us