Changeset 2817


Ignore:
Timestamp:
Aug 15, 2019 6:24:50 PM (3 months ago)
Author:
alexey
Message:

These 4 files were reverted to v2802 as they may contain bugs...

Location:
trunk/programs
Files:
4 edited

Legend:

Unmodified
Added
Removed
  • trunk/programs/us_com_project/us_com_project_gui.cpp

    r2809 r2817  
    2828
    2929
     30//ALEXEY: reverted, based on v2802
     31
    3032//// Constructor:  ACADEMIC: 'Data Acquision' / us_comproject_academic programs
    3133US_ComProjectMain::US_ComProjectMain(QString us_mode) : US_Widgets()
     
    385387          1. Avaiting for run to be launched ("Back to Managing Optima Runs") -- SET
    386388    2. More complex: Back to Managing runs from active LIVE_UPDATE stage -- stop all timers and other processes...
    387     */
    388 
     389    */
    389390    qDebug() << "Jumping from LIVE UPDATE.";
    390391   
    391392    //2. Stop all timers/threads, reset GUI - when stopping fully working LIVE UPDATE
    392393    if ( !xpn_viewer_closed_soft )
    393       {
    394         //emit reset_live_update();
    395         epanObserv->sdiag->reset_liveupdate_panel_public();
    396       }
     394      emit reset_live_update();
    397395  }
    398396
  • trunk/programs/us_com_project/us_com_project_gui.h

    r2809 r2817  
    3636#include "us_select_item.h"
    3737
     38//ALEXEY: reverted, based on v2802
     39
    3840class US_ComProjectMain;
    3941
     
    173175      ~US_ObservGui() {};
    174176
    175       US_XpnDataViewer*     sdiag;
    176 
    177177 private:
    178178      US_ComProjectMain*    mainw;      // Parent to all panels
    179       //US_XpnDataViewer*     sdiag;
     179      US_XpnDataViewer*    sdiag;
    180180      int offset;
    181181
  • trunk/programs/us_xpn_viewer/us_xpn_viewer_gui.cpp

    r2810 r2817  
    4646#endif
    4747
     48//ALEXEY: reverted, based on v2802
     49
    4850// DialBox
    4951DialBox::DialBox( QWidget *parent ):
     
    245247   in_reload_data_init = false;
    246248   in_reload_check_sysdata  = false;
    247    in_reload_end_processes  = false;
    248    
     249
    249250   ElapsedTimeOffset = 0;
    250251
     
    11641165   //le_dbhost  ->setText( xpnhost + ":" + xpnport + "   (" + xpndesc + ")" );       //New
    11651166
    1166    //Also clear Wavelengths && Lambda ranges:
    1167    cb_pltrec ->clear();
    1168    le_lrange ->setText("");
    1169    
    1170    
    11711167   pb_loadXpn ->setEnabled( true );
    11721168   pb_loadAUC ->setEnabled( true );
     
    15871583      //msg_data_avail->close();
    15881584      //ok_msg_data->click();
    1589 
    1590       //ALEXEY: make sure ExpID is coupled to the RunID which is already in the autoflow DB
    1591       if ( !runID_passed.isEmpty() || runID_passed != "NULL" )
    1592   {
    1593     if ( runID_passed.toInt() != RunID_to_retrieve.toInt() )
    1594       {
    1595         RunID_to_retrieve = runID_passed;
    1596         qDebug() << "Correcting RunID to : " << RunID_to_retrieve;
    1597       }
    1598   }
    1599  
    16001585     
    16011586      //ALEXEY: need to update 'autoflow' table with the unique RunID_to_retrieve && Start Run Time fields !!!
     
    20011986        //emit experiment_complete_auto( currentDir, ProtocolName, invID_passed, correctRadii  );  // Updtade later: what should be passed with signal ??
    20021987
    2003         //reset_auto();
     1988        reset_auto();
    20041989        emit experiment_complete_auto( details_at_live_update );
    20051990       
     
    20952080void US_XpnDataViewer::check_for_data( QMap < QString, QString > & protocol_details)
    20962081{
    2097   //Also reset the panel before reattachement
    2098   reset_auto();
    2099  
    21002082  xpn_data->setEtimOffZero(); //ALEXEY: intialize etimoff to zero for the first time
    21012083
     
    21552137    disconnect(timer_data_init, SIGNAL(timeout()), 0, 0);   //Disconnect timer from anything
    21562138   
    2157     //reset_auto();
     2139    reset_auto();
    21582140
    21592141    emit close_program();
     
    21612143    }
    21622144}
    2163 
    2164 
    2165 // Reset LIVE UPDATE panel && stop timers && quit threads
    2166 void US_XpnDataViewer::reset_liveupdate_panel_public ( void )
    2167 {
    2168   reset_liveupdate_panel();
    2169 }
    2170 
    21712145
    21722146// Reset LIVE UPDATE panel && stop timers && quit threads
     
    22242198    qDebug() << "QTimer timer_data_reload STOPPED by clickig Manage Optima runs !!! ";
    22252199  /*************************************/
    2226 
    2227   qDebug() << "BEFORE: " << in_reload_auto << ", " << in_reload_all_data << ", " << in_reload_data_init << ", " << in_reload_check_sysdata;
    22282200 
    2229   //ALEXEY: should wait for execution of all below variables to be false (end of all timer functions) BEFORE reset_all();
    2230   // Introduce QTimer which checks for all abpve vartibales to be false (check all related functions to always reset them to false on completion)
    2231   // Put reset_auto() into the timer && and stop/disconnect timer from within connected SLOT.
    2232   timer_end_processes = new QTimer;
    2233   connect(timer_end_processes, SIGNAL(timeout()), this, SLOT( end_processes ( ) ));
    2234   timer_end_processes->start(2000);     // 5 sec
     2201  reset_auto();
     2202
     2203  qDebug() << in_reload_auto << ", " << in_reload_all_data << ", " << in_reload_data_init << ", " << in_reload_check_sysdata;
    22352204 
    2236   //reset_auto();
    2237   //qApp->processEvents();
    2238 }
    2239 
    2240 //to end all existing update processes
    2241 void US_XpnDataViewer::end_processes( void )
    2242 {
    2243   if ( in_reload_end_processes )            // If already doing a reload,
    2244     return;                              //  skip starting a new one
     2205  in_reload_auto    = false;
     2206  in_reload_all_data  = false;
     2207  in_reload_data_init = false;
     2208  in_reload_check_sysdata  = false;
    22452209 
    2246   in_reload_end_processes   = true;          // Flag in the midst of a reload
    2247  
    2248   if ( !in_reload_auto && !in_reload_all_data &&  !in_reload_data_init && !in_reload_check_sysdata )
    2249     {
    2250      
    2251       timer_end_processes->stop();
    2252       disconnect(timer_end_processes, SIGNAL(timeout()), 0, 0);   //Disconnect timer from anything
    2253 
    2254       //ALEXEY: may not be needed
    2255       //reset_auto();
    2256       qDebug() << "LIVE UPDATE panel has been reset!";
    2257       qDebug() << "AFTER: " << in_reload_auto << ", " << in_reload_all_data << ", " << in_reload_data_init << ", " << in_reload_check_sysdata;
    2258      
    2259       qApp->processEvents();
    2260        
    2261       //in_reload_end_processes   = false;
    2262     }
    2263   else
    2264     in_reload_end_processes   = false;
     2210  qApp->processEvents();
    22652211}
    22662212
     
    25682514     updateautoflow_record_atLiveUpdate();
    25692515
    2570      //reset_auto();
     2516     reset_auto();
    25712517     emit experiment_complete_auto( details_at_live_update  );
    25722518     return;
     
    39843930
    39853931        updateautoflow_record_atLiveUpdate();
    3986         //reset_auto();
    3987 
    3988         in_reload_auto   = false;
     3932        reset_auto();
    39893933       
    39903934        //emit experiment_complete_auto( currentDir, ProtocolName, invID_passed, correctRadii  );  // Updtade later: what should be passed with signal ??
  • trunk/programs/us_xpn_viewer/us_xpn_viewer_gui.h

    r2809 r2817  
    2525#include "us_xpn_run_auc.h"
    2626
     27
     28//ALEXEY: reverted, based on v2802
    2729
    2830class SpeedoMeter: public QwtDial
     
    9698     US_XpnDataViewer(QString auto_mode);
    9799
    98      void   reset_liveupdate_panel_public ( void );
    99      
    100100  private:
    101101     bool auto_mode_bool;
     
    256256     bool           in_reload_all_data;
    257257     bool           in_reload_check_sysdata;
    258      bool           in_reload_end_processes;
    259258
    260259     
     
    270269     QTimer*        timer_all_data_avail;
    271270     QTimer*        timer_check_sysdata;
    272 
    273      QTimer*        timer_end_processes;
    274271
    275272     QElapsedTimer*  elapsed_timer;
     
    314311     //void   retrieve_xpn_raw_auto ( QString & );
    315312     void   retrieve_xpn_raw_auto ( void );
    316      void   end_processes ( void );
    317313     void   reloadData_auto     ( void );
    318314     int    CheckExpComplete_auto( QString & );
Note: See TracChangeset for help on using the changeset viewer.