aboutsummaryrefslogtreecommitdiffstats
path: root/src/utils.cpp
diff options
context:
space:
mode:
authorshunt010 <sam@maxxwave.co.uk>2025-12-31 13:19:28 +0000
committerGitHub <noreply@github.com>2025-12-31 13:19:28 +0000
commitf8eaf51f61cdae65e90675920e427d23b8da7027 (patch)
treee70c92214ac05cf0a2001e0481e289343c094d65 /src/utils.cpp
parentf8b5402727b7e94aecbfb663a601577f97bae5b9 (diff)
parenta5f80a99e0dad51c45e8511347f27d816ae92e20 (diff)
downloaddabmux-f8eaf51f61cdae65e90675920e427d23b8da7027.tar.gz
dabmux-f8eaf51f61cdae65e90675920e427d23b8da7027.tar.bz2
dabmux-f8eaf51f61cdae65e90675920e427d23b8da7027.zip
Merge pull request #1 from Opendigitalradio/master
Bring up to date
Diffstat (limited to 'src/utils.cpp')
-rw-r--r--src/utils.cpp31
1 files changed, 4 insertions, 27 deletions
diff --git a/src/utils.cpp b/src/utils.cpp
index 1e006f7..7ea6293 100644
--- a/src/utils.cpp
+++ b/src/utils.cpp
@@ -3,7 +3,7 @@
2011, 2012 Her Majesty the Queen in Right of Canada (Communications
Research Center Canada)
- Copyright (C) 2021
+ Copyright (C) 2025
Matthias P. Braendli, matthias.braendli@mpb.li
http://www.opendigitalradio.org
@@ -29,36 +29,13 @@
#include <iostream>
#include <memory>
#include <boost/algorithm/string/join.hpp>
-#include "DabMux.h"
#include "utils.h"
#include "fig/FIG0structs.h"
using namespace std;
-static time_t dab_time_seconds = 0;
-static int dab_time_millis = 0;
-
static void printServices(const vector<shared_ptr<DabService> >& services);
-void update_dab_time()
-{
- if (dab_time_seconds == 0) {
- dab_time_seconds = time(nullptr);
- } else {
- dab_time_millis+= 24;
- if (dab_time_millis >= 1000) {
- dab_time_millis -= 1000;
- ++dab_time_seconds;
- }
- }
-}
-
-void get_dab_time(time_t *time, uint32_t *millis)
-{
- *time = dab_time_seconds;
- *millis = dab_time_millis;
-}
-
uint32_t gregorian2mjd(int year, int month, int day)
{
@@ -99,7 +76,7 @@ void header_message()
fprintf(stderr, "Her Majesty the Queen in Right of Canada\n");
fprintf(stderr, "(Communications Research Centre Canada)\n\n");
- fprintf(stderr, "Copyright (C) 2021 Matthias P. Braendli\n");
+ fprintf(stderr, "Copyright (C) 2024 Matthias P. Braendli\n");
fprintf(stderr, "LICENCE: GPLv3+\n\n");
fprintf(stderr, "http://opendigitalradio.org\n\n");
@@ -107,7 +84,7 @@ void header_message()
fprintf(stderr, "Input URLs supported: prbs udp file zmq\n");
fprintf(stderr, "Inputs format supported: raw mpeg packet epm\n");
- std::cerr << "Output URLs supported:\n" <<
+ std::cerr << "Outputs supported: " <<
#if defined(HAVE_OUTPUT_FILE)
" file" <<
#endif
@@ -126,7 +103,7 @@ void header_message()
#if defined(HAVE_OUTPUT_SIMUL)
" simul" <<
#endif
- "\n\n";
+ " edi zmq\n\n";
}