diff options
author | Matthias P. Braendli <matthias.braendli@mpb.li> | 2014-03-14 13:24:12 +0100 |
---|---|---|
committer | Matthias P. Braendli <matthias.braendli@mpb.li> | 2014-03-14 13:24:12 +0100 |
commit | a1c36919884e76c67c19896c526b139d84b8478c (patch) | |
tree | ab59345868766e0a0eb36b6bdfb123a6329abec7 /src/DabMod.cpp | |
parent | 33fab4f1008c1af305e6426233a1a87bd683782d (diff) | |
download | dabmod-a1c36919884e76c67c19896c526b139d84b8478c.tar.gz dabmod-a1c36919884e76c67c19896c526b139d84b8478c.tar.bz2 dabmod-a1c36919884e76c67c19896c526b139d84b8478c.zip |
Update RemoteControl from dabmux
Diffstat (limited to 'src/DabMod.cpp')
-rw-r--r-- | src/DabMod.cpp | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/src/DabMod.cpp b/src/DabMod.cpp index 7a147a0..bd83531 100644 --- a/src/DabMod.cpp +++ b/src/DabMod.cpp @@ -327,7 +327,6 @@ int main(int argc, char* argv[]) try { int telnetport = pt.get<int>("remotecontrol.telnetport"); RemoteControllerTelnet* telnetrc = new RemoteControllerTelnet(telnetport); - telnetrc->start(); rc = telnetrc; } catch (std::exception &e) { @@ -686,6 +685,14 @@ int main(int argc, char* argv[]) // Proccessing data //////////////////////////////////////////////////////////////// flowgraph->run(); + + /* Check every once in a while if the remote control + * is still working */ + if (rc && (frame % 250) == 0 && rc->fault_detected()) { + fprintf(stderr, + "Detected Remote Control fault, restarting it\n"); + rc->restart(); + } } if (framesize == 0) { fprintf(stderr, "End of file reached.\n"); |