1
0
mirror of https://github.com/f4exb/sdrangel.git synced 2024-12-23 18:15:45 -05:00

BladeRF: open device by serial number

This commit is contained in:
f4exb 2017-04-14 01:59:09 +02:00
parent 651303e860
commit 01b2c42a5f
2 changed files with 4 additions and 4 deletions

View File

@ -83,9 +83,9 @@ bool BladerfOutput::openDevice()
}
else
{
if (!DeviceBladeRF::open_bladerf(&m_dev, 0)) // TODO: fix; Open first available device as there is no proper handling for multiple devices
if (!DeviceBladeRF::open_bladerf(&m_dev, qPrintable(m_deviceAPI->getSampleSinkSerial())))
{
qCritical("BladerfOutput::start: could not open BladeRF");
qCritical("BladerfOutput::start: could not open BladeRF %s", qPrintable(m_deviceAPI->getSampleSinkSerial()));
return false;
}

View File

@ -88,9 +88,9 @@ bool BladerfInput::openDevice()
}
else
{
if (!DeviceBladeRF::open_bladerf(&m_dev, 0)) // TODO: fix; Open first available device as there is no proper handling for multiple devices
if (!DeviceBladeRF::open_bladerf(&m_dev, qPrintable(m_deviceAPI->getSampleSourceSerial())))
{
qCritical("BladerfInput::start: could not open BladeRF");
qCritical("BladerfInput::start: could not open BladeRF %s", qPrintable(m_deviceAPI->getSampleSourceSerial()));
return false;
}