MCPcopy Create free account
hub / github.com/aethersdr/AetherSDR / section16

Function section16

tests/CAT_Flex_test.cpp:1362–1385  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1360// ═════════════════════════════════════════════════════════════════════════════
1361
1362void section16(CatClient& c, Runner& r)
1363{
1364 r.section(QStringLiteral("Section 16 — ZZDE — Diversity Receive (FLEX-6700)"));
1365
1366 QString orig = c.query(QStringLiteral("ZZDE"));
1367 const bool validResp = (orig == QLatin1String("ZZDE0") ||
1368 orig == QLatin1String("ZZDE1"));
1369 const bool noSupport = (orig == QLatin1String("?"));
1370
1371 r.check(QStringLiteral("16.1 ZZDE; → ZZDE0, ZZDE1 (6700), or ?; (non-6700)"),
1372 validResp || noSupport, repr(orig));
1373
1374 if (validResp) {
1375 QString toggle = (orig == QLatin1String("ZZDE0"))
1376 ? QStringLiteral("ZZDE1") : QStringLiteral("ZZDE0");
1377 c.send(toggle);
1378 QThread::msleep(50);
1379 QString got = c.query(QStringLiteral("ZZDE"));
1380 r.check(QStringLiteral("16.2 ZZDE set/get round-trip"),
1381 got == toggle, repr(got));
1382 c.send(orig); // restore
1383 QThread::msleep(50);
1384 }
1385}
1386
1387// ═════════════════════════════════════════════════════════════════════════════
1388// Section 15 — PTY round-trip (Unix only; skips if device cannot be opened)

Callers 1

mainFunction · 0.85

Calls 5

reprFunction · 0.70
sectionMethod · 0.45
queryMethod · 0.45
checkMethod · 0.45
sendMethod · 0.45

Tested by

no test coverage detected