Revision 74
Added by markw over 11 years ago
| common/zpu/zpu_glue.vhdl | ||
|---|---|---|
| 
     	-- stack request
 
   | 
||
| 
     	ZPU_STACK_WRITE : out std_logic_vector(3 downto 0);
 
   | 
||
| 
     | 
||
| 
     	-- write to ROM!!
 
   | 
||
| 
     	ZPU_ROM_WREN : out std_logic;
 
   | 
||
| 
     | 
||
| 
     	-- response
 
   | 
||
| 
     	MEMORY_READY : in std_logic
 
   | 
||
| 
     );
 
   | 
||
| ... | ... | |
| 
     		result_next <= result_reg;
 
   | 
||
| 
     		memory_ready_next <= memory_ready;
 
   | 
||
| 
     		zpu_stACK_WRITE <= (others=>'0');
 
   | 
||
| 
     		ZPU_ROM_WREN <= '0';
 
   | 
||
| 
     		ZPU_config_write <= '0';
 
   | 
||
| 
     		zpu_addr_next <= zpu_addr_reg;
 
   | 
||
| 
     		zpu_do_next <= zpu_do_reg;
 
   | 
||
| ... | ... | |
| 
     				else
 
   | 
||
| 
     					result_next <= result_rom;
 
   | 
||
| 
     				end if;
 
   | 
||
| 
     				ZPU_ROM_WREN <= ZPU_WRITE_TEMP;
 
   | 
||
| 
     				ZPU_MEM_BUSY <= '1';
 
   | 
||
| 
     				zpu_addr_next <= std_logic_vector(zpu_addr_unsigned);
 
   | 
||
| 
     			when "01110" =>
 
   | 
||
| common/zpu/zpucore.vhd | ||
|---|---|---|
| 
     		-- data on next cycle after addr
 
   | 
||
| 
     		ZPU_ADDR_ROM : out std_logic_vector(15 downto 0);
 
   | 
||
| 
     		ZPU_ROM_DATA : in std_logic_vector(31 downto 0);
 
   | 
||
| 
     		ZPU_ROM_WREN : out std_logic;
 
   | 
||
| 
     | 
||
| 
     		-- spi master
 
   | 
||
| 
     		-- Too painful to bit bang spi from zpu, so we have a hardware master in here
 
   | 
||
| ... | ... | |
| 
     		 ZPU_ADDR_FETCH => ZPU_ADDR_FETCH,
 
   | 
||
| 
     		 ZPU_ADDR_ROM_RAM => ZPU_ADDR_ROM_RAM,
 
   | 
||
| 
     		 ZPU_DO => ZPU_DO,
 
   | 
||
| 
     		 ZPU_STACK_WRITE => ZPU_STACK_WRITE);
 
   | 
||
| 
     		 ZPU_STACK_WRITE => ZPU_STACK_WRITE,
 
   | 
||
| 
     		 ZPU_ROM_WREN => ZPU_ROM_WREN);
 
   | 
||
| 
     | 
||
| 
     config_regs : entity work.zpu_config_regs
 
   | 
||
| 
     GENERIC MAP (
 
   | 
||
Added 32-byte write support to ROM area! For MIST external sector buffer. TODO: Smarter method...