Skip to content

Commit

Permalink
Merge pull request #1293 from srcejon/fix_1284
Browse files Browse the repository at this point in the history
USRP: Attempt to support radios without AGC
  • Loading branch information
f4exb authored Jun 20, 2022
2 parents ea11183 + 9b34412 commit e45b4e9
Showing 1 changed file with 9 additions and 2 deletions.
11 changes: 9 additions & 2 deletions plugins/samplesource/usrpinput/usrpinput.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -823,8 +823,15 @@ bool USRPInput::applySettings(const USRPInputSettings& settings, bool preGetStre
{
if (settings.m_gainMode == USRPInputSettings::GAIN_AUTO)
{
m_deviceShared.m_deviceParams->getDevice()->set_rx_agc(true, m_deviceShared.m_channel);
qDebug() << "USRPInput::applySettings: AGC enabled for channel " << m_deviceShared.m_channel;
try
{
m_deviceShared.m_deviceParams->getDevice()->set_rx_agc(true, m_deviceShared.m_channel);
qDebug() << "USRPInput::applySettings: AGC enabled for channel " << m_deviceShared.m_channel;
}
catch (uhd::not_implemented_error &e)
{
qDebug() << "USRPInput::applySettings: AGC not implemented on this radio. Please set to manual.";
}
}
else
{
Expand Down

0 comments on commit e45b4e9

Please sign in to comment.