Can I use a Timer in the startup file?

2 views (last 30 days)
Pierre
Pierre on 19 Mar 2014
Hi,
I am facing a problem with a timer implementation within the startup file. For some very specific needs that I can't detail here, I have to create my own startup file and use a timer logic inside. The issue I am facing is that the timer callback is not called until all the instructions in the startup file are finished executing. That is, the timer is setup all right but at the moment the callback should run, nothing happens IF ANOTHER INTRUCTION IS BEING PROCESSED AT THE SAME TIME.
I have boiled down the problem to a single/multi thread issue, by doing different experiments, where I was able to notice that once all the instructions in the startup file are done being processed (I have experienced different length pauses in the startup file) then the callback runs, according to whatever parameters it is set to run (I am using FixedRate with a delay of 20 sec).
I am wondering if the Matlab's startup state is simply not suited for timers to run? Or even any multithread programming?
Thanks for your help

Answers (0)

Categories

Find more on Startup and Shutdown in Help Center and File Exchange

Community Treasure Hunt

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

Start Hunting!