jfiddler Posted September 28, 2007 Share Posted September 28, 2007 I'm doing runs of a process. I see how to log the data from a run, but I don't see how to display the data from a prior run. Is there a way to open the same program I use in real time, but have it in a virtual mode, where I can replay a previously logged run? Thanks Link to comment Share on other sites More sharing options...
AzeoTech Posted October 3, 2007 Share Posted October 3, 2007 I wrote this whole post and then remembered that we actually have a knowledgebase / sample download for this here. Its even better because it has transport controls to allow you to scroll back and forth: http://www.azeotech.com/index.php?_m=downl...wnloaditemid=50 I'll keep the rest of the post just in case: Yes, but its not really a built in feature. Here are the general steps: 1) you would have to have all your channels have a timing of 0. Technically you could change the timing dynamically using script, just remember to reset the timing loops once they are changed. Use mychannel.Timing = 0 to set the timing of mychannel to 0. Do this for all channels. Then do Channel.Restart() to reset the timing loops. See the Channel Functions and Channel List Functions sections of the Channels and Conversions chapter of help. 2) Now you can load the data into DAQFactory, again with script. This time with the low level File. functions. If you are logging as CSV, you can use the readdelim() function to do it quickly. See File. functions in the Logging chapter of help. 3) Once loaded, you can create a simple loop to stuff the data into the channels at intervals. It would just be a while loop with a delay and AddValue() functions to put the data into the channels. AddValue() is also in the Channel Functions section of the help. Now depending on how big your files are, you might instead want to read one line of data at a time in that loop as you stuff it into the channels rather than reading the entire file first. The nice part about Its tough to be more specific as the best method really depends on how your application is setup and your data is logged. If, for example, you were logging to an odbc database, you'd have to query the database instead of using File. functions. Fortunately, its not terribly difficult. Link to comment Share on other sites More sharing options...
jfiddler Posted October 5, 2007 Author Share Posted October 5, 2007 Thanks. I'll give this a try. The logging works great, by the way. And, since I'm not sure I've said it before, thanks for a great program! Link to comment Share on other sites More sharing options...
Mylogger Posted May 19, 2012 Share Posted May 19, 2012 First of all thanks for DAQFactory software and for the precious help from the forum. I m looking how to download .csv files back to DAQfactory for example to export a chart afterwards. I found similar querry above . Unfortunately the link to the sample is directing me to the home page. Is it possible to get a sample in .ctl file ? Thanks in advance Link to comment Share on other sites More sharing options...
AzeoTech Posted May 20, 2012 Share Posted May 20, 2012 Here's the sample, or at least a sample. Check it out and see if it helps, and the feel free to post more questions. histsample.ctl Link to comment Share on other sites More sharing options...
Mylogger Posted May 25, 2012 Share Posted May 25, 2012 Almost working ! I ve tried to to download a .csv file (extract of the content below) by replacing .dat with .csv in the "change" button properties. I get the graph with the right date , time and scale for Y values. Missing item : the data are not plotted. Any suggestion ? Thanks in advance and looking forward to see it running Time_Pressure Pressure Time_Temperature Temperature 1.337.437.225.100 0.4527726 1.337.437.225.100 0.6986279 1.337.437.225.150 0.2339403 1.337.437.225.150 0.6985501 1.337.437.225.200 0.4545637 1.337.437.225.200 0.6985501 Link to comment Share on other sites More sharing options...
Mylogger Posted May 25, 2012 Share Posted May 25, 2012 I also tried with different sample rate ( 1 sec , 0,1 sec and 0,05 sec ) and no change .... Link to comment Share on other sites More sharing options...
AzeoTech Posted May 25, 2012 Share Posted May 25, 2012 Your data appears to be tab or space delimited? If so, you'll need to change the delimiter in the readDelim() call of updateGraph from "," to either chr(9) or " " Also please note that these forums are moderated. You only need to submit your query once. It won't appear until we have viewed it and approved it. If we didn't moderate the forum, we would be inundated by spam posts. Link to comment Share on other sites More sharing options...
Mylogger Posted May 29, 2012 Share Posted May 29, 2012 It's working! I 've changed the file type : each time stamp is now recorded on a line with ";" separators between time and channels. The file is a txt file and I also modified the change button properties to read all types of file (*.*). I also indicated in ReadDelim () the correct separator (. I ve only one remark : the display of the historical trend is picking all points (no effect visible of the delay in data read). I don't really need this function. Thanks again for the great support !!! Link to comment Share on other sites More sharing options...
AzeoTech Posted May 29, 2012 Share Posted May 29, 2012 I'm not sure I understand what you mean in your last remark. Link to comment Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.