From 03fd84469e937421ad4a67037e33e20e8124dcfb Mon Sep 17 00:00:00 2001 From: Thomas Tsou Date: Wed, 19 Oct 2011 21:06:07 -0400 Subject: [PATCH] transceiver: update main to accommodate resampling With the unified transceiver, we need to select between two device sample rates, GSM symbol rate and 400ksps for resampler use. Make this selection available for configure time options. Signed-off-by: Thomas Tsou --- public-trunk/Transceiver52M/runTransceiver.cpp | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/public-trunk/Transceiver52M/runTransceiver.cpp b/public-trunk/Transceiver52M/runTransceiver.cpp index 82fadfd..743d735 100644 --- a/public-trunk/Transceiver52M/runTransceiver.cpp +++ b/public-trunk/Transceiver52M/runTransceiver.cpp @@ -1,5 +1,5 @@ /* -* Copyright 2008, 2009 Free Software Foundation, Inc. +* Copyright 2008, 2009, 2010, 2011 Free Software Foundation, Inc. * * This software is distributed under the terms of the GNU Affero Public License. * See the COPYING file in the main directory for details. @@ -34,6 +34,12 @@ #include #include +#ifdef RESAMPLE + #define DEVICERATE 400e3 +#else + #define DEVICERATE 1625e3/6 +#endif + using namespace std; ConfigurationTable gConfig; @@ -72,7 +78,7 @@ int main(int argc, char *argv[]) srandom(time(NULL)); - RadioDevice *usrp = RadioDevice::make(1625e3/6.0); + RadioDevice *usrp = RadioDevice::make(DEVICERATE); if (!usrp->open()) { //delete usrp; return EXIT_FAILURE;