summaryrefslogtreecommitdiff
path: root/usrp2/firmware/lib/db_rfx.c
diff options
context:
space:
mode:
authorjblum2009-02-02 18:51:13 +0000
committerjblum2009-02-02 18:51:13 +0000
commit40d6c72b9b62f7074a0607479b6a093f66c7c364 (patch)
treee744eb2182ab3bc8c12ccfbf22fafa1d459823fd /usrp2/firmware/lib/db_rfx.c
parent04defa6b9337b2499e906dc06ac49a3e690a4946 (diff)
downloadgnuradio-40d6c72b9b62f7074a0607479b6a093f66c7c364.tar.gz
gnuradio-40d6c72b9b62f7074a0607479b6a093f66c7c364.tar.bz2
gnuradio-40d6c72b9b62f7074a0607479b6a093f66c7c364.zip
work in progress: setting gpio on xcvr
git-svn-id: http://gnuradio.org/svn/gnuradio/trunk@10375 221aa14e-8319-0410-a670-987f0aec2ac5
Diffstat (limited to 'usrp2/firmware/lib/db_rfx.c')
-rw-r--r--usrp2/firmware/lib/db_rfx.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/usrp2/firmware/lib/db_rfx.c b/usrp2/firmware/lib/db_rfx.c
index b127f2c33..0d5c89a81 100644
--- a/usrp2/firmware/lib/db_rfx.c
+++ b/usrp2/firmware/lib/db_rfx.c
@@ -488,7 +488,7 @@ rfx_set_freq(struct db_base *dbb, u2_fxpt_freq_t freq, u2_fxpt_freq_t *dc)
*dc = 0;
struct db_rfx_dummy *db = (struct db_rfx_dummy *) dbb;
- u2_fxpt_freq_t desired_n = ((1LL<<20)*db->common.freq_mult*(freq+db->common.freq_offset))/phdet_freq;
+ u2_fxpt_freq_t desired_n = (U2_DOUBLE_TO_FXPT_FREQ(1.0)*db->common.freq_mult*(freq+db->common.freq_offset))/phdet_freq;
int N_DIV = u2_fxpt_freq_round_to_int(desired_n);
int B = N_DIV/PRESCALER;
int A = N_DIV - PRESCALER*B;