Automatically Run a Matlab Script
Afficher commentaires plus anciens
I have a script that I want to run automatically, every 5 seconds. How could I set this up so that it runs in an unattended manner?
Réponses (1)
the cyclist
le 3 Mar 2020
0 votes
9 commentaires
fahd Belmajdoub
le 3 Mar 2020
the cyclist
le 3 Mar 2020
Oh, sorry. I should have clicked through to link they suggested. But I think what you want in Windows is the Task Scheduler.
To my knowledge, there is no task-scheduling ability that is fully internal to MATLAB.
fahd Belmajdoub
le 3 Mar 2020
Steven Lord
le 3 Mar 2020
I'm not completely certain since I haven't used it myself, but if you're not already aware there is an OPC Toolbox that may be of use to you. The "Data Access" section may describe functions and functionality that would be useful to you.
fahd Belmajdoub
le 5 Mar 2020
the cyclist
le 5 Mar 2020
The page I linked has a section entitled "How to create an advanced task ...".
It looks to me that #21 in that section describes how to repeat the task at higher frequency. (The internet suggested the same to me.)
I don't know if you can go down all the way to 5 seconds, though.
fahd Belmajdoub
le 5 Mar 2020
Steven Lord
le 5 Mar 2020
Do you need to run the script from the beginning every five seconds, or would running a script that loops indefinitely and polls for data to process every five seconds be sufficient?
fahd Belmajdoub
le 5 Mar 2020
Modifié(e) : fahd Belmajdoub
le 5 Mar 2020
Catégories
En savoir plus sur Historical Data Access dans Centre d'aide et File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!