[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Commit-gnuradio] r8530 - usrp2/trunk/fpga/sdr_lib
From: |
matt |
Subject: |
[Commit-gnuradio] r8530 - usrp2/trunk/fpga/sdr_lib |
Date: |
Wed, 28 May 2008 18:42:59 -0600 (MDT) |
Author: matt
Date: 2008-05-28 18:42:53 -0600 (Wed, 28 May 2008)
New Revision: 8530
Modified:
usrp2/trunk/fpga/sdr_lib/hb_dec.v
usrp2/trunk/fpga/sdr_lib/hb_dec_tb.v
usrp2/trunk/fpga/sdr_lib/input.dat
Log:
working halfband decimator
Modified: usrp2/trunk/fpga/sdr_lib/hb_dec.v
===================================================================
--- usrp2/trunk/fpga/sdr_lib/hb_dec.v 2008-05-29 00:41:50 UTC (rev 8529)
+++ usrp2/trunk/fpga/sdr_lib/hb_dec.v 2008-05-29 00:42:53 UTC (rev 8530)
@@ -9,7 +9,7 @@
(input clk,
input rst,
input bypass,
- input [7:0] cpi, // Clocks per input -- equal the decimation ratio ahead
of this block
+ input [8:0] cpi, // Clocks per input -- equal to the decimation ratio
ahead of this block
input stb_in,
input [IWIDTH-1:0] data_in,
output reg stb_out,
@@ -114,11 +114,12 @@
wire [IWIDTH-1:0] data_even;
reg [3:0] addr_even;
- always @*
+ always @(posedge clk)
case(cpi)
- 2 : addr_even = 9;
- 3, 4, 5, 6, 7 : addr_even = 8;
- default : addr_even = 7;
+ // 1 is an error
+ 2 : addr_even <= 9; // Maximum speed (overall decim by 4)
+ 3, 4, 5, 6, 7 : addr_even <= 8;
+ default : addr_even <= 7;
endcase // case(cpi)
srl #(.WIDTH(IWIDTH)) srl_even
Modified: usrp2/trunk/fpga/sdr_lib/hb_dec_tb.v
===================================================================
--- usrp2/trunk/fpga/sdr_lib/hb_dec_tb.v 2008-05-29 00:41:50 UTC (rev
8529)
+++ usrp2/trunk/fpga/sdr_lib/hb_dec_tb.v 2008-05-29 00:42:53 UTC (rev
8530)
@@ -1,7 +1,7 @@
module hb_dec_tb( ) ;
// Parameters for instantiation
- parameter clocks = 8'd2 ; // Number of clocks per input
+ parameter clocks = 9'd2 ; // Number of clocks per input
parameter decim = 1 ; // Sets the filter to decimate
parameter rate = 2 ; // Sets the decimation rate
Modified: usrp2/trunk/fpga/sdr_lib/input.dat
===================================================================
--- usrp2/trunk/fpga/sdr_lib/input.dat 2008-05-29 00:41:50 UTC (rev 8529)
+++ usrp2/trunk/fpga/sdr_lib/input.dat 2008-05-29 00:42:53 UTC (rev 8530)
@@ -5,7 +5,6 @@
0
0
0
-20000
0
0
0
@@ -22,6 +21,7 @@
0
0
0
+100000
0
0
0
@@ -30,7 +30,6 @@
0
0
0
-20000
0
0
0
@@ -46,48 +45,6 @@
0
0
0
-20000
-20000
-20000
-20000
-20000
-20000
-20000
-20000
-20000
-20000
-20000
-20000
-20000
-20000
-20000
-20000
-20000
-20000
-20000
-20000
-20000
-20000
-20000
-20000
-20000
-20000
-20000
-20000
-20000
-20000
-20000
-20000
-20000
-20000
-20000
-20000
-20000
-20000
-20000
-20000
-20000
-20000
0
0
0
@@ -115,9 +72,136 @@
0
0
0
+100000
0
0
0
0
0
0
+0
+0
+0
+0
+0
+0
+0
+0
+0
+0
+0
+0
+0
+0
+0
+0
+0
+0
+0
+0
+0
+0
+0
+0
+0
+0
+0
+0
+0
+0
+0
+0
+0
+100000
+100000
+100000
+100000
+100000
+100000
+100000
+100000
+100000
+100000
+100000
+100000
+100000
+100000
+100000
+100000
+100000
+100000
+100000
+100000
+100000
+100000
+100000
+100000
+100000
+100000
+100000
+100000
+100000
+100000
+100000
+100000
+100000
+100000
+100000
+100000
+100000
+100000
+100000
+100000
+100000
+100000
+0
+0
+0
+0
+0
+0
+0
+0
+0
+0
+0
+0
+0
+0
+0
+0
+0
+0
+0
+0
+0
+0
+0
+0
+0
+0
+0
+0
+0
+0
+0
+0
+0
+0
+0
+0
+0
+0
+0
+0
+0
+0
+0
+0
+0
+0
+0
+0
+0
+0
+0
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Commit-gnuradio] r8530 - usrp2/trunk/fpga/sdr_lib,
matt <=