Avalon PIO oder am besten AVALON-Interface, sowas in der Art:
entity Component is
port (
clk : in std_logic;
-- AVALON Slave Interface
as_address : in std_logic_vector(7 downto 0);
as_chipselect : in std_logic;
as_read : in std_logic;
as_write : in std_logic;
as_writedata : in std_logic_vector(31 downto 0);
as_readdata : out std_logic_vector(31 downto 0);
as_readdatavalid : out std_logic;
as_waitrequest : out std_logic
);
end Component;
architecture behave of Component is
as_waitrequest <= not (as_write or as_read);
process(clk)
begin
if rising_edge(clk) then
if as_chipselect = '1' and as_write = '1' then
-- Schreiben von Registern
case as_address is
when x"00" => bla lba
when others => null;
end case;
end if;
end if;
end behave
in NIOS hast Du dann
IOWR_32DIRECT(BASE, adresse, value) und IORD_32DIRECT(BASE, adresse)
oder entsprechend 8 oder 16 Bit.
Grüße,
Kest