24 0, 0, 0, 1, 1, 1, 2, 2, 2, 3, 3, 3, 4, 4, 4, 5,
25 5, 5, 6, 6, 6, 7, 7, 7, 8, 9, 10, 11, 11, 11, 11, 11,
26 11, 11, 11, 11, 11, 11, 11, 11, 12, 13, 14, 14, 14, 14, 14, 14,
27 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14,
28 14, 14, 14, 14, 14, 14, 14, 14, 14, 14
32 0, 1, 2, 0, 1, 2, 0, 1, 2, 0, 1, 2, 0, 1, 2, 0,
33 1, 2, 0, 1, 2, 0, 1, 2, 0, 0, 0, 0, 1, 2, 3, 4,
34 5, 6, 7, 8, 9, 10, 11, 12, 12, 12, 12, 4, 5, 6, 7, 8,
35 9, 10, 11, 12, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21,
36 22, 23, 24, 25, 26, 27, 28, 29, 30, 31
57 qDebug(
"DeviceXTRX::open: serial: %s", (
const char *) deviceStr);
59 res = xtrx_open(deviceStr, XTRX_O_RESET | 4, &
m_dev);
63 qCritical() <<
"DeviceXTRX::open: cannot open device " << deviceStr;
81 uint32_t value = autoGain + 12 > 73 ? 73 : autoGain + 12;
85 }
else if (value > 42) {
114 int res = xtrx_set_samplerate(
m_dev,
125 qCritical(
"DeviceXTRX::set_samplerate: Unable to set %s samplerate, m_masterRate: %f, m_inputRate: %f, m_outputRate: %f, error=%d\n",
131 qDebug() <<
"DeviceXTRX::set_samplerate: sample rate set: " 132 <<
"output: "<< output
static const uint32_t m_lnaTbl[m_nbGains]
double set_samplerate(double rate, double master, bool output)
static const uint32_t m_pgaTbl[m_nbGains]
struct xtrx_dev * m_dev
device handle
static void getAutoGains(uint32_t autoGain, uint32_t &lnaGain, uint32_t &tiaGain, uint32_t &pgaGain)
bool open(const char *deviceStr)
double m_actualOutputRate