MCPcopy Create free account
hub / github.com/cjcliffe/CubicSDR / enableRig

Method enableRig

src/AppFrame.cpp:1238–1256  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1236
1237#ifdef USE_HAMLIB
1238void AppFrame::enableRig() {
1239 wxGetApp().stopRig();
1240 wxGetApp().initRig(rigModel, rigPort, rigSerialRate);
1241
1242 if (devInfo != nullptr) {
1243 std::string deviceId = devInfo->getDeviceId();
1244 DeviceConfig *devConfig = wxGetApp().getConfig()->getDevice(deviceId);
1245 rigSDRIF = devConfig->getRigIF(rigModel);
1246 if (rigSDRIF) {
1247 wxGetApp().lockFrequency(rigSDRIF);
1248 } else {
1249 wxGetApp().unlockFrequency();
1250 }
1251 } else {
1252 wxGetApp().unlockFrequency();
1253 }
1254
1255 wxGetApp().getConfig()->setRigEnabled(true);
1256}
1257
1258void AppFrame::disableRig() {
1259 wxGetApp().stopRig();

Callers

nothing calls this directly

Calls 9

stopRigMethod · 0.80
getConfigMethod · 0.80
getRigIFMethod · 0.80
setRigEnabledMethod · 0.80
initRigMethod · 0.45
getDeviceIdMethod · 0.45
getDeviceMethod · 0.45
lockFrequencyMethod · 0.45
unlockFrequencyMethod · 0.45

Tested by

no test coverage detected