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

Subversion Repositories ahb_master

[/] [ahb_master/] [trunk/] [src/] [base/] [axi2ahb_ctrl.v] - Diff between revs 2 and 3

Go to most recent revision | Show entire file | Details | Blame | View Log

Rev 2 Rev 3
Line 42... Line 42...
   wire                   ahb_last;
   wire                   ahb_last;
   wire                   data_last;
   wire                   data_last;
   reg [4:0]              cmd_counter;
   reg [4:0]              cmd_counter;
   reg                    rdata_phase;
   reg                    rdata_phase;
   reg                    wdata_phase;
   reg                    wdata_phase;
 
   wire                   data_phase;
   reg [1:0]              HTRANS;
   reg [1:0]              HTRANS;
   reg [2:0]              HBURST;
   reg [2:0]              HBURST;
   reg [1:0]              HSIZE;
   reg [1:0]              HSIZE;
   reg                    HWRITE;
   reg                    HWRITE;
   reg [ADDR_BITS-1:0]    HADDR;
   reg [ADDR_BITS-1:0]    HADDR;
 
 
 
 
   assign                 ahb_finish   = ahb_ack_last;
   assign                 ahb_finish   = ahb_ack_last;
 
 
   assign                 data_ready   = cmd_read ? rdata_ready : wdata_ready;
   assign                 data_ready   = cmd_read ? rdata_ready : wdata_ready;
 
   assign                 data_phase   = wdata_phase | rdata_phase;
 
 
   assign                 ahb_idle     = HTRANS == TRANS_IDLE;
   assign                 ahb_idle     = HTRANS == TRANS_IDLE;
   assign                 ahb_ack      = HTRANS[1] & HREADY;
   assign                 ahb_ack      = HTRANS[1] & HREADY;
   assign                 ahb_ack_last = ahb_last & ahb_ack;
   assign                 ahb_ack_last = ahb_last & ahb_ack;
   assign                 ahb_start    = (~cmd_empty) & data_ready & ahb_idle;
   assign                 ahb_start    = (~cmd_empty) & data_ready & ahb_idle & (HREADY | (~data_phase));
   assign                 data_last    = HREADY & (ahb_idle || (HTRANS == TRANS_NONSEQ));
   assign                 data_last    = HREADY & (ahb_idle || (HTRANS == TRANS_NONSEQ));
 
 
   always @(posedge clk or posedge reset)
   always @(posedge clk or posedge reset)
     if (reset)
     if (reset)
       cmd_counter <= #FFD 4'd0;
       cmd_counter <= #FFD 4'd0;

powered by: WebSVN 2.1.0

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