From 17bf4b036a942a5177665c43e2d848bf8d24591f Mon Sep 17 00:00:00 2001 From: Ed Gonzalez Date: Thu, 15 Jan 2015 16:23:20 -0600 Subject: [PATCH] Invoke register_mode (reads cfg file ) after the Traffic Cop has connected --- DSP_API/SmartSDR_Interface/discovery_client.c | 3 --- DSP_API/SmartSDR_Interface/traffic_cop.c | 3 +++ 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/DSP_API/SmartSDR_Interface/discovery_client.c b/DSP_API/SmartSDR_Interface/discovery_client.c index 04941ae..073eade 100644 --- a/DSP_API/SmartSDR_Interface/discovery_client.c +++ b/DSP_API/SmartSDR_Interface/discovery_client.c @@ -83,9 +83,6 @@ static void _dc_RadioFound(Radio radio) // start a keepalive to keep the channel open and know when it dies tc_Init(radio->ip, radio->port); - uint32 result = register_mode(); - // quick and dirty fail for now - if (result != SUCCESS) exit(1); tc_startKeepalive(); usleep(250000); hal_Listener_Init(); diff --git a/DSP_API/SmartSDR_Interface/traffic_cop.c b/DSP_API/SmartSDR_Interface/traffic_cop.c index 0fcb385..59885e5 100644 --- a/DSP_API/SmartSDR_Interface/traffic_cop.c +++ b/DSP_API/SmartSDR_Interface/traffic_cop.c @@ -353,6 +353,9 @@ static void* _tc_thread(void* arg) // if this fails, the program just exits _tc_openSocket(); + result = register_mode(); + if (result != SUCCESS) exit(1); + // loop receiving data from SmartSDR and sending it where it should go while (!_abort) {