diff --git a/DSView/pv/sigsession.cpp b/DSView/pv/sigsession.cpp index 1ce87596..52b2c288 100644 --- a/DSView/pv/sigsession.cpp +++ b/DSView/pv/sigsession.cpp @@ -495,7 +495,7 @@ namespace pv dsv_err("%s", "Error!No device selected"); assert(false); } - if (_device_agent.is_collecting()) + if (_device_status == ST_RUNNING || _device_agent.is_collecting()) { dsv_err("%s", "Error!Device is running."); return false; @@ -1329,6 +1329,8 @@ namespace pv } case SR_DF_END: { + dsv_info("------------SR_DF_END packet."); + _capture_data->get_logic()->capture_ended(); _capture_data->get_dso()->capture_ended(); _capture_data->get_analog()->capture_ended(); diff --git a/DSView/pv/sigsession.h b/DSView/pv/sigsession.h index 5cb45574..9ad4d1b3 100644 --- a/DSView/pv/sigsession.h +++ b/DSView/pv/sigsession.h @@ -566,7 +566,7 @@ private: int _repeat_wait_prog_step; bool _is_saving; bool _is_instant; - int _device_status; + volatile int _device_status; int _work_time_id; int _capture_times; int _confirm_store_time_id;