| 292 | } |
| 293 | |
| 294 | bool |
| 295 | WaveSampler::work(void) |
| 296 | { |
| 297 | bool more = false; |
| 298 | bool decided = false; |
| 299 | |
| 300 | switch (this->properties.sync) { |
| 301 | case MANUAL: |
| 302 | more = this->sampleManual(); |
| 303 | break; |
| 304 | |
| 305 | case GARDNER: |
| 306 | more = this->sampleGardner(); |
| 307 | break; |
| 308 | |
| 309 | case ZERO_CROSSING: |
| 310 | more = this->sampleZeroCrossing(); |
| 311 | decided = true; |
| 312 | break; |
| 313 | } |
| 314 | |
| 315 | // Perform decision, if necessary |
| 316 | if (!decided) |
| 317 | this->decider->decide(this->set.block, this->set.symbols, this->set.len); |
| 318 | |
| 319 | this->setStatus("Demodulating (" |
| 320 | + QString::number(static_cast<int>(this->progress * 100)) |
| 321 | + ")..."); |
| 322 | |
| 323 | this->setProgress(this->progress); |
| 324 | |
| 325 | // Deliver data |
| 326 | if (this->set.len > 0) |
| 327 | emit data(this->set); |
| 328 | |
| 329 | if (!more) |
| 330 | emit done(); |
| 331 | |
| 332 | return more; |
| 333 | } |
| 334 | |
| 335 | void |
| 336 | WaveSampler::cancel(void) |
nothing calls this directly
no test coverage detected