Yeah I didn't think about suggesting that, but I think it might get complicated. I think he would have to start a one shot timer to call a function to set the voltage. Then that function would also start another one shot timer to call another function that would read from the sample. That function then would start a one shot timer to call the first function again. This way he can be sure that things are called in order and that timing is consistent, just in case the GUI gets complicated or something makes the event loop slow down.
He could also use multiple threads. Whatever works for Fabien I guess. -Dave On 12/13/11 1:00 PM, matplotlib-users-requ...@lists.sourceforge.net wrote: > From: "Drain, Theodore R (343P)"<theodore.r.dr...@jpl.nasa.gov> > Subject: Re: [Matplotlib-users] [ploting data] Live data > > Perhaps I'm missing something, but why not use QTimer? You can't really > every call sleep in a single threaded gui (for reasons you've encountered). > If you need to poll something, create a QTimer for 2 seconds and have it call > a measurement function to update the data. You shouldn't need any > processEvents calls or sleep. ------------------------------------------------------------------------------ Systems Optimization Self Assessment Improve efficiency and utilization of IT resources. Drive out cost and improve service delivery. Take 5 minutes to use this Systems Optimization Self Assessment. http://www.accelacomm.com/jaw/sdnl/114/51450054/ _______________________________________________ Matplotlib-users mailing list Matplotlib-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/matplotlib-users