SIGNAL TEMPBUF: STD_LOGIC_VECTOR(15 downto 0);
SIGNAL MYREG: STD_LOGIC_VECTOR(31 downto 0);
PROCESS(nRESET,nWE)
BEGIN
IF nRESET = '0' THEN
TEMPBUF <= X"0000";
MYREG <= X"00000000";
ELSIF nWE'EVENT AND nWE = '1' THEN
IF Addr = LOADDR AND nCS = '0' THEN
TEMPBUF <= DATABUS;
END IF;
IF Addr = HIADDR AND nCS = '0' THEN
MYREG <= DATABUS & TEMPBUF;
END IF;
END IF;
END PROCESS; |