Auto-Export to Matlab | Sequencer | De​wesoft X2 SP7

Allen Gammel

Posted on 27.02.2018 19:21

Hello,

We currently have a setup file that essentially stores 20 seconds of data every 5 minutes. We plan to do this for 30 hours straight.

I have a couple questions to ask in regards to making these types of scenarios a bit easier:

  1. Can we auto-increment (i.e. TestFile 022718 1301 to TestFile MMDDYY HHMM) the file name using the sequencer or by other means?
  2. We're trying to "auto" export the 20s file to Matlab each time the "OnStopStoring" event.
    1. With our current setup this event does not ever get fired...
    1. We did manage to create a sequencer file that will start storing data for 20 seconds and then exports successfully -- but how could we make this reoccurring?
We would appreciate if you could please review the sample sequence files and let us know what we're doing wrong. We're would definately like to use the "OnStopStoring" event to switch to Analyze -> Export to Matlab -> Switch back to Measure and continue on until the next 5 minutes and repeat the process.
DEWESoft Support
Technical support
Posted on 28.02.2018 08:29

Hi,

the first thing that I would like to point out is that you should either set your storing procedure in the sequencer or in the setup file. If you configure some storing options in the setup file and another part in the sequence, this will lead to logic conflicts. I've adjusted your sequence a bit. I've added the exact naming convention that you wanted to use, and I've made the sequence loop around itself until it reaches 300 files (just a random number). This could work, the only thing that's a bit problematic here is that I don't see any way to time the export. I have no way of telling how long the export to MATLAB will take, so I don't know when exactly to start a new file. Since your data will always be the same, you could probably take some approximate measurements of the export length, and then take that into account before you start storing the next file.

The second option is to leave out the sequence and do everything via the setup file. I've attached a setup example, which uses the multi file feature to create a new file after each trigger. It also uses absolute time in its name, but it's not exactly the same as the one in your message. This will stay in measurement mode the whole time, so you'd need a plugin (ODE - Online data export) to export the data during the measurement. After writing this I realized that the ODE plugin can only write data to an SQL database or export it to CSV. Since you're looking to get your data into MATALB, I'm guessing this won't be a viable option for you.

Let me know know what you think about the two suggestions. Do the 5 minute intervals need to be exact? If so, then perhaps we could use the absolute clock as a reference instead of the sequencer.

Also, I believe you didn't receive any stop storing events because the measurement was still running. Even though it wasn't storing, the measurement was still active and armed.


Attached files:
Login to reply to this topic. If you don't have account yet, you can signup for free account .
This website uses cookies to ensure you get the best experience on our website. Learn more