Router_5Port is the complete switching element that ties together:
Network Interface bridges the core and router:
Together, they form the complete node of the NoC. Multiple router_5port instances are instantiated in the mesh fabric with their local ports connected to network interfaces, and their cardinal ports connected to neighboring routers. The timestamp mechanism enables cycle-accurate latency measurement, critical for understanding network performance and detecting congestion hotspots.
module router_5port #(
parameter DATA_WIDTH = 34,
parameter COORD_WIDTH = 1,
parameter FIFO_DEPTH = 8
)(
input logic clk, rst_n,
input logic [COORD_WIDTH-1:0] router_x, router_y, // This router's position
input logic [4:0] [DATA_WIDTH-1:0] rx_flit_arr, // 5 input ports
input logic [4:0] rx_valid_arr,
output logic [4:0] rx_ready_arr,
output logic [4:0] [DATA_WIDTH-1:0] tx_flit_arr, // 5 output ports
output logic [4:0] tx_valid_arr,
input logic [4:0] tx_ready_arr
);
Port Index Convention: