From a647305bd905d776869edef3a7a2f0d4f44ee763 Mon Sep 17 00:00:00 2001 From: Riley King-Saunders Date: Tue, 20 Oct 2026 16:01:34 +1100 Subject: [PATCH] Fixed bug where ram datawidth was not 2^N. --- modules/ram.sv | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/modules/ram.sv b/modules/ram.sv index 40d16dd..d380550 100644 --- a/modules/ram.sv +++ b/modules/ram.sv @@ -5,8 +5,8 @@ module ram #(addrwidth=9, datawidth=5)( input logic [0:0] clk, input logic [0:0] rst, input logic [addrwidth-1:0] addr, input logic [0:0] we, - input logic [datawidth-1:0] data_in, - output logic [datawidth-1:0] data_out + input logic [2**datawidth-1:0] data_in, + output logic [2**datawidth-1:0] data_out ); // TODO: Make this byte-sized, NOT word-sized!