From 16909b37a0b65f20716ba6dbd6ae8b35e82a0228 Mon Sep 17 00:00:00 2001 From: none Date: Thu, 17 Sep 2020 09:59:58 +0200 Subject: [PATCH] get PLS code and show as debug message --- lib/src/dddvb.h | 1 + lib/src/dvb_quality.c | 3 +++ 2 files changed, 4 insertions(+) diff --git a/lib/src/dddvb.h b/lib/src/dddvb.h index f9e76d8..4f2390f 100644 --- a/lib/src/dddvb.h +++ b/lib/src/dddvb.h @@ -75,6 +75,7 @@ struct dddvb_fe { uint32_t level; uint32_t lock; uint32_t quality; + uint32_t pls_code; int64_t strength; int64_t cnr; int64_t ber; diff --git a/lib/src/dvb_quality.c b/lib/src/dvb_quality.c index f9bc86a..ecef831 100644 --- a/lib/src/dvb_quality.c +++ b/lib/src/dvb_quality.c @@ -331,6 +331,9 @@ static void calc_lq(struct dddvb_fe *fe) int64_t str, snr; uint32_t mod, fec, ber_num, ber_den, trans, pilot = 0, quality = 0; + get_property(fe->fd, DTV_TRANSMISSION_MODE, &fe->pls_code); + dbgprintf(DEBUG_DVB, "fe%d: pls=0x%02x\n", fe->nr, fe->pls_code); + get_stat(fe->fd, DTV_STAT_SIGNAL_STRENGTH, &st); str = st.stat[0].svalue; dbgprintf(DEBUG_DVB, "fe%d: str=%lld\n", fe->nr, str);