aboutsummaryrefslogtreecommitdiffstats
path: root/src/utils.cpp
diff options
context:
space:
mode:
authorMatthias P. Braendli <matthias.braendli@mpb.li>2025-10-06 17:21:13 +0200
committerMatthias P. Braendli <matthias.braendli@mpb.li>2025-10-06 17:21:13 +0200
commitb6b840f6072e950f2ded719ae51badfba7566fa8 (patch)
tree67fa420ad7de127290c85ffb84196ae2e3fe1c7a /src/utils.cpp
parentf34c15338bc07357f1a1665e2c6e8fc1eaca7eed (diff)
downloaddabmux-b6b840f6072e950f2ded719ae51badfba7566fa8.tar.gz
dabmux-b6b840f6072e950f2ded719ae51badfba7566fa8.tar.bz2
dabmux-b6b840f6072e950f2ded719ae51badfba7566fa8.zip
Add frequency_information hot-reload
Diffstat (limited to 'src/utils.cpp')
-rw-r--r--src/utils.cpp17
1 files changed, 6 insertions, 11 deletions
diff --git a/src/utils.cpp b/src/utils.cpp
index 7ea6293..fc4c864 100644
--- a/src/utils.cpp
+++ b/src/utils.cpp
@@ -171,8 +171,6 @@ void printOutputs(const vector<shared_ptr<DabOutput> >& outputs)
void printServices(const vector<shared_ptr<DabService> >& services)
{
- int index = 0;
-
etiLog.log(info, "--- Services list ---");
for (auto service : services) {
@@ -200,7 +198,6 @@ void printServices(const vector<shared_ptr<DabService> >& services)
clusters_s.push_back(std::to_string(cluster));
}
etiLog.level(info) << " clusters: " << boost::join(clusters_s, ",");
- ++index;
}
}
@@ -279,8 +276,6 @@ void printComponent(const shared_ptr<DabComponent>& component, const std::shared
void printSubchannels(const vec_sp_subchannel& subchannels)
{
- int index = 0;
-
int total_num_cu = 0;
etiLog.log(info, "--- Subchannels list ---");
@@ -330,7 +325,6 @@ void printSubchannels(const vec_sp_subchannel& subchannels)
etiLog.log(info, " size (CU): %i",
subchannel->getSizeCu());
total_num_cu += subchannel->getSizeCu();
- ++index;
}
etiLog.log(info, "Total ensemble size (CU): %i", total_num_cu);
@@ -338,12 +332,12 @@ void printSubchannels(const vec_sp_subchannel& subchannels)
static void printLinking(const shared_ptr<dabEnsemble>& ensemble)
{
+ const auto linkagesets = ensemble->get_linkagesets();
etiLog.log(info, " Linkage Sets");
- if (ensemble->linkagesets.empty()) {
+ if (linkagesets.empty()) {
etiLog.level(info) << " None ";
}
- for (const auto& ls : ensemble->linkagesets) {
-
+ for (const auto& ls : linkagesets) {
etiLog.level(info) << " set " << ls->get_name();
etiLog.log(info, " LSN 0x%04x", ls->lsn);
etiLog.level(info) << " active " << (ls->active ? "true" : "false");
@@ -399,11 +393,12 @@ static void printLinking(const shared_ptr<dabEnsemble>& ensemble)
static void printFrequencyInformation(const shared_ptr<dabEnsemble>& ensemble)
{
+ const auto frequency_information = ensemble->get_frequency_information();
etiLog.log(info, " Frequency Information");
- if (ensemble->frequency_information.empty()) {
+ if (frequency_information.empty()) {
etiLog.level(info) << " None ";
}
- for (const auto& fi : ensemble->frequency_information) {
+ for (const auto& fi : frequency_information) {
etiLog.level(info) << " FI " << fi.uid;
etiLog.level(info) << " OE=" << (fi.other_ensemble ? 1 : 0);
switch (fi.rm) {