void CMainWindow::connectSignals() { connect(backend,SIGNAL(sigStatus(CCommand::status_t)), this, SLOT(slotReceivedData(CCommand::status_t))); connect(ui->pushPower, SIGNAL(toggled(bool)), this, SLOT(powerOn(bool))); connect(dbgWin,SIGNAL(sendData(QString&)),this,SLOT(slotSendData(QString&))); //connect(cmd,SIGNAL(sendData(QString&)),this,SLOT(slotSendData(QString&))); connect(ui->volume1, SIGNAL(valueChanged(double)), this,SLOT(slotVolume1(double))); //connect(ui->volume2, SIGNAL(valueChanged(double)), this,SLOT(slotVolume2(double))); connect(ui->knobSquelch,SIGNAL(valueChanged(double)), this, SLOT(slotSquelch(double))); connect(ui->knobIF,SIGNAL(valueChanged(double)), this, SLOT(slotIF(double))); connect(ui->pushNoiseBlanker,SIGNAL(toggled(bool)),this,SLOT(slotNoiseBlanker(bool))); connect(ui->pushAGC,SIGNAL(toggled(bool)),this,SLOT(slotAGC(bool))); connect(ui->pushVSC,SIGNAL(toggled(bool)),this,SLOT(slotVSC(bool))); // Connect filters connect(ui->filterGroup, SIGNAL(buttonClicked(int)), this, SLOT(slotFilter(int))); // Connect Moudlation mode connect(ui->modeGroup,SIGNAL(buttonClicked(int)),this, SLOT(slotModulation(int))); // Frequency connect( display, SIGNAL(frequencyChanged(QString)), this,SLOT(slotFrequency(QString))); connect( myBandScope, SIGNAL(frequencyChanged(QString)), this, SLOT(slotFrequency(QString))); // Set threshold connect(ui->threshold, SIGNAL(valueChanged(int)), backend->getDecoder(), SLOT(slotThreshold(int))); connect(ui->correlationLength,SIGNAL(valueChanged(int)), backend->getDecoder(), SLOT(slotSetCorrelationLength(int))); // Connect Decoder connect(ui->decoderList, SIGNAL(currentIndexChanged(int)), this, SLOT(slotDecoderChange(int))); // Channel change connect(ui->channel, SIGNAL(currentIndexChanged(int)), backend->getDecoder(), SLOT(slotSetChannel(int))); // Connect Scope type connect(ui->cbPlotterType , SIGNAL(currentIndexChanged(int)),this, SLOT(slotScopeChanged(int))); connect(ui->refreshRate, SIGNAL(valueChanged(int)), this, SLOT(slotRefreshRate(int))); connect(ui->cbWindow, SIGNAL(currentIndexChanged(QString)), this, SLOT(slotWindowFunction(QString))); // Band Scope connect(ui->pushBandscope,SIGNAL(clicked(bool)),this,SLOT(slotBandScope(bool))); connect(ui->cbBandwidth, SIGNAL(currentIndexChanged(int)), this, SLOT(slotBandScopeWidth(int))); connect(ui->cbStepsize, SIGNAL(currentIndexChanged(int)), this, SLOT(slotBandScopeStep(int))); // Step size change connect(ui->pushStepUp,SIGNAL(clicked()), this, SLOT(slotStepUp())); connect(ui->pushStepDown,SIGNAL(clicked()), this, SLOT(slotStepDown())); // Connect load file connect(ui->actionLoad, SIGNAL(triggered()), this, SLOT(slotLoadFile())); connect(display, SIGNAL(radioChanged(int)), this, SLOT(slotRadioClicked(int))); connect(ui->actionSettings, SIGNAL(triggered()), this, SLOT(slotSettings())); // Connect spectrum widget connect(backend->getDecoder(),SIGNAL(sigRawSamples(double*,double*,int)),mySpectrum,SLOT(slotRawSamples(double*,double*,int))); // Connect Demodulator to debug windows connect(backend->getDecoder(),SIGNAL(sendData(QString)),this,SLOT(slotDemodulatorData(QString))); }
void vfo::on_pBtnExch_clicked() { long long exchTemp1; long long exchTemp2; exchTemp1 = readA(); exchTemp2 = readB(); writeA(exchTemp2); writeB(exchTemp1); if(selectedVFO == 'B') { emit frequencyChanged(exchTemp1); } else { emit frequencyChanged(exchTemp2); } }
//Called when subRx is checked in main menu via actionSubRx() void vfo::checkSubRx(long long f, int samplerate) { long long vfoAfreq; if(selectedVFO == 'B') { on_pBtnBtoA_clicked(); } vfoAfreq = readA(); if ((f < (vfoAfreq - (samplerate / 2))) || (f > (vfoAfreq + (samplerate / 2)))) { f=vfoAfreq; } writeB(f); emit frequencyChanged(readA()); // on_pBtnvfoA_clicked(); ui->pBtnvfoB->setText("subRx"); ui->pBtnvfoA->setText("mainRx"); selectedVFO = 'B'; ui->pBtnvfoB->setStyleSheet("background-color: rgb(85, 255, 0)"); ui->pBtnvfoA->setStyleSheet("background-color: normal"); ui->pBtnSplit->setStyleSheet("background-color: normal"); ui->pBtnvfoA->setEnabled(FALSE); vfoEnabled(false, true); // ui->pBtnvfoA->setEnabled(FALSE); //qDebug()<<Q_FUNC_INFO<<": About to check pBtnSubRx"; ui->pBtnSubRx->setChecked(TRUE); }
void V4LRadioControl::setFrequency(int frequency) { qint64 f = frequency; v4l2_frequency freq; if(frequency < freqMin) f = freqMax; if(frequency > freqMax) f = freqMin; if(fd > 0) { memset( &freq, 0, sizeof( freq ) ); // Use the first tuner freq.tuner = 0; if ( ioctl( fd, VIDIOC_G_FREQUENCY, &freq ) >= 0 ) { if(low) { // For low, freq in units of 62.5Hz, so convert from Hz to units. freq.frequency = (int)(f/62.5); } else { // For high, freq in units of 62.5kHz, so convert from Hz to units. freq.frequency = (int)(f/62500); } ioctl( fd, VIDIOC_S_FREQUENCY, &freq ); currentFreq = f; playTime.restart(); emit frequencyChanged(currentFreq); } } playTime.restart(); }
void S60RadioTunerControl::MTcoFrequencyChanged(const TFrequency& aOldFrequency, const TFrequency& aNewFrequency) { TRACE("S60RadioTunerControl::MTcoFrequencyChanged" << qtThisPtr() << "oldFreq" << aOldFrequency.iFrequency << "newFreq" << aNewFrequency.iFrequency); m_currentFreq = aNewFrequency.iFrequency; m_scanning = false; emit frequencyChanged(m_currentFreq); }
void InstancedHistogramScene::setFrequency( float frequency ) { if ( qFuzzyCompare( m_frequency, frequency ) ) return; QMutexLocker locker( &m_mutex ); m_frequency = frequency; emit frequencyChanged(); }
void CDisplay::wheelEvent(QWheelEvent *event) { int numDegrees = event->delta() / 8; int numSteps = numDegrees / 15; if (event->delta() >0) { if (radio==0) frequency1 = format(frequency1,StepSize[Step1]); else frequency2 = format(frequency2,StepSize[Step2]); } else { if (radio==0) frequency1 = format(frequency1,StepSize[Step1] * -1); else frequency2 = format(frequency2,StepSize[Step2] * -1); } repaint(); if (radio==0) emit frequencyChanged(frequency1.replace(".","")); else emit frequencyChanged(frequency2.replace(".","")); }
void vfo::pttChange(bool pttState) { long long temp; ptt = pttState; if(ptt) { // Going from Rx to Tx if(selectedVFO=='S') { //We are going to transmit on vfoB frequency temp = readA(); //Because we are switched to vfoA we will place the emit frequencyChanged(readB()); //value of vfoB in it when doing the frequency change writeA(temp); //hence needing to save and restore vfoA via temp. } } else { // Going from Tx to Rx if(selectedVFO=='S') { //We are going to receive on vfoA frequency emit frequencyChanged(readA()); } } setVfoBtnColour(); }
void LocationDiagnostics::setFrequency(int frequency) { if (m_frequency == frequency) return; m_frequency = frequency; QSettings settings; settings.setValue("frequency", m_frequency); emit frequencyChanged(); }
void ConnectionInfoWirelessTab::updateAccessPoint(const QString &uni) { Solid::Control::AccessPoint *ap = m_iface->findAccessPoint(uni); // drop input from previous AP (if any) if (m_ap != 0) { disconnect(m_ap, SIGNAL(ssidChanged(QString)), this, SLOT(updateSsid(QString))); disconnect(m_ap, SIGNAL(signalStrengthChanged(int)), this, SLOT(updateSignalStrength(int))); disconnect(m_ap, SIGNAL(bitRateChanged(int)), this, SLOT(updateMaxBitRate(int))); disconnect(m_ap, SIGNAL(frequencyChanged(uint)), this, SLOT(updateFrequency(uint))); disconnect(m_ap, SIGNAL(wpaFlagsChanged(Solid::Control::AccessPoint::WpaFlags)), this, SLOT(updateWpa(Solid::Control::AccessPoint::WpaFlags))); disconnect(m_ap, SIGNAL(rsnFlagsChanged(Solid::Control::AccessPoint::WpaFlags)), this, SLOT(updateRsn(Solid::Control::AccessPoint::WpaFlags))); }
void CBandScope::slotClicked(QPointF p) { double min = qwtPlot->axisWidget(QwtPlot::xBottom)->scaleDraw()->scaleMap().s1(); double max = qwtPlot->axisWidget(QwtPlot::xBottom)->scaleDraw()->scaleMap().s2(); double middle = (max - min) / 2.0; double size = max-min; double minfreq = frequency - middle * step; // Middle is tuned frequency //emit fre minfreq + v * stepSize; frequency = minfreq + (p.toPoint().x()-min) * step; emit frequencyChanged(QString("%1").arg(frequency)); setCentralFrequency(frequency); }
void vfo::on_pBtnSplit_clicked() { if (selectedVFO != 'S' && ptt == false) { if (ui->pBtnRIT->isChecked()) { ui->pBtnRIT->setChecked(false); on_pBtnRIT_clicked(); } selectedVFO = 'S'; setVfoBtnColour(); vfoEnabled(true, false); emit frequencyChanged(readA()); } }
void CDisplay::keyPressEvent(QKeyEvent *event) { if (event->key() == Qt::Key_Enter) { if (radio == 0) frequency1 = format(frequency1,0); else frequency2 = format(frequency2,0); releaseKeyboard(); repaint(); if (radio == 0) emit frequencyChanged(frequency1.replace(".","")); else emit frequencyChanged(frequency2.replace(".","")); return; } if (radio == 0) frequency1.append( event->text()); else frequency2.append( event->text()); repaint(); }
void S60VideoFrameRate::sample() { const int ms = m_elapsedTimer->restart(); const qreal freq = qreal(m_count * 1000) / ms; m_frequencySum -= m_history[m_historyIndex]; m_frequencySum += freq; m_history[m_historyIndex] = freq; m_historyIndex = (m_historyIndex + 1) % m_history.count(); if (m_historyCount < m_history.count()) ++m_historyCount; m_frequency = m_frequencySum / m_historyCount; emit frequencyChanged(m_frequency); m_count = 0; }
int MainWindow::qt_metacall(QMetaObject::Call _c, int _id, void **_a) { _id = QWidget::qt_metacall(_c, _id, _a); if (_id < 0) return _id; if (_c == QMetaObject::InvokeMetaMethod) { switch (_id) { case 0: amplitudeChanged((*reinterpret_cast< double(*)>(_a[1]))); break; case 1: frequencyChanged((*reinterpret_cast< double(*)>(_a[1]))); break; case 2: signalIntervalChanged((*reinterpret_cast< double(*)>(_a[1]))); break; default: ; } _id -= 3; } return _id; }
void UI::setKeypadFrequency(long long f) { frequencyChanged(f); }
void vfo::on_pBtnAtoB_clicked() { writeB(readA()); emit frequencyChanged(readA()); //Doesn't matter which vfo as both now the same freq }
void vfo::on_pBtnBtoA_clicked() { writeA(readB()); emit frequencyChanged(readB()); }
void VentanaClasificadorAcordes::on_nota3Spin_valueChanged(double freq) { infoNotas[2] = eqTemp.getNota(freq); frequencyChanged(ui->nota3Combo, freq); }
void QXARadioSession::CBFrequencyChanged(TInt newFrequency) { emit frequencyChanged(newFrequency); }