commit-gnuradio
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Commit-gnuradio] r8638 - usrp2/trunk/fpga/control_lib


From: matt
Subject: [Commit-gnuradio] r8638 - usrp2/trunk/fpga/control_lib
Date: Thu, 19 Jun 2008 17:50:54 -0600 (MDT)

Author: matt
Date: 2008-06-19 17:50:53 -0600 (Thu, 19 Jun 2008)
New Revision: 8638

Modified:
   usrp2/trunk/fpga/control_lib/shortfifo.v
Log:
report how much free space we have


Modified: usrp2/trunk/fpga/control_lib/shortfifo.v
===================================================================
--- usrp2/trunk/fpga/control_lib/shortfifo.v    2008-06-19 23:49:58 UTC (rev 
8637)
+++ usrp2/trunk/fpga/control_lib/shortfifo.v    2008-06-19 23:50:53 UTC (rev 
8638)
@@ -8,10 +8,11 @@
      input write,
      input clear,
      output reg full,
-     output reg empty);
+     output reg empty,
+     output [3:0] space);
    
-   reg [3:0] a;
-   genvar    i;
+   reg [3:0]     a;
+   genvar        i;
    
    generate
       for (i=0;i<WIDTH;i=i+1)
@@ -55,4 +56,6 @@
 
    // NOTE will fail if you write into a full fifo or read from an empty one
 
+   assign space = full ? 0 : empty ? 15 : 15-a;
+   
 endmodule // shortfifo





reply via email to

[Prev in Thread] Current Thread [Next in Thread]