| 147 | } |
| 148 | |
| 149 | bool SigSession::init() |
| 150 | { |
| 151 | ds_log_set_context(dsv_log_context()); |
| 152 | |
| 153 | ds_set_event_callback(device_lib_event_callback); |
| 154 | |
| 155 | ds_set_datafeed_callback(data_feed_callback); |
| 156 | |
| 157 | // firmware resource directory |
| 158 | QString resdir = GetFirmwareDir(); |
| 159 | std::string res_path = pv::path::ToUnicodePath(resdir); |
| 160 | ds_set_firmware_resource_dir(res_path.c_str()); |
| 161 | |
| 162 | if (ds_lib_init() != SR_OK) |
| 163 | { |
| 164 | dsv_err("DSView run ERROR: collect lib init failed."); |
| 165 | return false; |
| 166 | } |
| 167 | |
| 168 | return true; |
| 169 | } |
| 170 | |
| 171 | void SigSession::uninit() |
| 172 | { |
no test coverage detected