OpenCores
URL https://opencores.org/ocsvn/qaz_libs/qaz_libs/trunk

Subversion Repositories qaz_libs

[/] [qaz_libs/] [trunk/] [basal/] [src/] [FIFOs/] [CummingsSNUG2002SJ_FIFO1/] [sync_r2w.v] - Blame information for rev 34

Details | Compare with Previous | View Log

Line No. Rev Author Line
1 34 qaztronic
// --------------------------------------------------------------------
2
//
3
 
4
 
5
module
6
  sync_r2w
7
  #(
8
    parameter ADDRSIZE = 4
9
  )
10
  (
11
    output reg [ADDRSIZE:0] wq2_rptr,
12
    input [ADDRSIZE:0]      rptr,
13
    input                   wclk,
14
    input                   wrst_n
15
  );
16
 
17
  reg [ADDRSIZE:0] wq1_rptr;
18
 
19
  always @(posedge wclk or negedge wrst_n)
20
    if (!wrst_n)
21
      {wq2_rptr,wq1_rptr} <= 0;
22
    else
23
      {wq2_rptr,wq1_rptr} <= {wq1_rptr,rptr};
24
 
25
endmodule
26
 

powered by: WebSVN 2.1.0

© copyright 1999-2019 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.