Question: is there a way to write this code more efficient using a loop for 'load' and 'read' from ram? - - 8 Register Ram -
is there a way to write this code more efficient using a loop for 'load' and 'read' from ram?
Register Ram
RamRegisterSarahJohn
Created by John Sarah
library ieee;
use ieee.stdlogicall;
use ieee.stdlogicarith.all;
use ieee.stdlogicunsigned.all;
use ieee.numericstdall;
entity RamRegisterSarahJohn is
port
D : in stdlogicvector downto ;
Clock, Load : in stdlogic;
address : in stdlogicvector downto ;
Q : out stdlogicvector downto
;
end RamRegisterSarahJohn;
Architecture behavioral of RamRegisterSarahJohn is
type Arrayx is array downto of stdlogicvector downto ;
signal RAM : Arrayx;
signal index : integer range to ;
Begin
process Clock
Begin
if RisingedgeCLock then
if Load then
if addressB then RAM D;
elsif addressB then RAM D;
elsif addressB then RAM D;
elsif addressB then RAM D;
elsif addressB then RAM D;
elsif addressB then RAM D;
elsif addressB then RAM D;
elsif addressB then RAM D;
End if;
QD;
else
if addressB then QRam ;
elsif addressB then QRAM ;
elsif addressB then QRAM ;
elsif addressB then QRAM ;
elsif addressB then QRAM ;
elsif addressB then QRAM ;
elsif addressB then QRAM ;
elsif addressB then QRAM ;
end if;
end if;
end if;
end process;
end behavioral;
Step by Step Solution
There are 3 Steps involved in it
1 Expert Approved Answer
Step: 1 Unlock
Question Has Been Solved by an Expert!
Get step-by-step solutions from verified subject matter experts
Step: 2 Unlock
Step: 3 Unlock
