Line 62... |
Line 62... |
constant jtag_tap_idcode_manid_c : std_ulogic_vector(10 downto 0) := "00000000000"; -- manufacturer id
|
constant jtag_tap_idcode_manid_c : std_ulogic_vector(10 downto 0) := "00000000000"; -- manufacturer id
|
|
|
-- Architecture Constants (do not modify!) ------------------------------------------------
|
-- Architecture Constants (do not modify!) ------------------------------------------------
|
-- -------------------------------------------------------------------------------------------
|
-- -------------------------------------------------------------------------------------------
|
constant data_width_c : natural := 32; -- native data path width - do not change!
|
constant data_width_c : natural := 32; -- native data path width - do not change!
|
constant hw_version_c : std_ulogic_vector(31 downto 0) := x"01060300"; -- no touchy!
|
constant hw_version_c : std_ulogic_vector(31 downto 0) := x"01060301"; -- no touchy!
|
constant archid_c : natural := 19; -- official NEORV32 architecture ID - hands off!
|
constant archid_c : natural := 19; -- official NEORV32 architecture ID - hands off!
|
|
|
-- External Interface Types ---------------------------------------------------------------
|
-- External Interface Types ---------------------------------------------------------------
|
-- -------------------------------------------------------------------------------------------
|
-- -------------------------------------------------------------------------------------------
|
type sdata_8x32_t is array (0 to 7) of std_ulogic_vector(31 downto 0);
|
type sdata_8x32_t is array (0 to 7) of std_ulogic_vector(31 downto 0);
|
Line 205... |
Line 205... |
|
|
-- reserved --
|
-- reserved --
|
--constant reserved_base_c : std_ulogic_vector(data_width_c-1 downto 0) := x"ffffff40"; -- base address
|
--constant reserved_base_c : std_ulogic_vector(data_width_c-1 downto 0) := x"ffffff40"; -- base address
|
--constant reserved_size_c : natural := 8*4; -- module's address space size in bytes
|
--constant reserved_size_c : natural := 8*4; -- module's address space size in bytes
|
|
|
-- reserved --
|
-- General Purpose Timer (GPTMR) --
|
--constant reserved_base_c : std_ulogic_vector(data_width_c-1 downto 0) := x"ffffff60"; -- base address
|
constant gptmr_base_c : std_ulogic_vector(data_width_c-1 downto 0) := x"ffffff60"; -- base address
|
--constant reserved_size_c : natural := 4*4; -- module's address space size in bytes
|
constant gptmr_size_c : natural := 4*4; -- module's address space size in bytes
|
|
constant gptmr_ctrl_addr_c : std_ulogic_vector(data_width_c-1 downto 0) := x"ffffff60";
|
|
constant gptmr_thres_addr_c : std_ulogic_vector(data_width_c-1 downto 0) := x"ffffff64";
|
|
constant gptmr_count_addr_c : std_ulogic_vector(data_width_c-1 downto 0) := x"ffffff68";
|
|
--constant gptmr_reserve_addr_c : std_ulogic_vector(data_width_c-1 downto 0) := x"ffffff6c";
|
|
|
-- reserved --
|
-- reserved --
|
--constant reserved_base_c : std_ulogic_vector(data_width_c-1 downto 0) := x"ffffff70"; -- base address
|
--constant reserved_base_c : std_ulogic_vector(data_width_c-1 downto 0) := x"ffffff70"; -- base address
|
--constant reserved_size_c : natural := 2*4; -- module's address space size in bytes
|
--constant reserved_size_c : natural := 2*4; -- module's address space size in bytes
|
|
|
Line 968... |
Line 972... |
IO_CFS_EN : boolean := false; -- implement custom functions subsystem (CFS)?
|
IO_CFS_EN : boolean := false; -- implement custom functions subsystem (CFS)?
|
IO_CFS_CONFIG : std_ulogic_vector(31 downto 0) := x"00000000"; -- custom CFS configuration generic
|
IO_CFS_CONFIG : std_ulogic_vector(31 downto 0) := x"00000000"; -- custom CFS configuration generic
|
IO_CFS_IN_SIZE : positive := 32; -- size of CFS input conduit in bits
|
IO_CFS_IN_SIZE : positive := 32; -- size of CFS input conduit in bits
|
IO_CFS_OUT_SIZE : positive := 32; -- size of CFS output conduit in bits
|
IO_CFS_OUT_SIZE : positive := 32; -- size of CFS output conduit in bits
|
IO_NEOLED_EN : boolean := false; -- implement NeoPixel-compatible smart LED interface (NEOLED)?
|
IO_NEOLED_EN : boolean := false; -- implement NeoPixel-compatible smart LED interface (NEOLED)?
|
IO_NEOLED_TX_FIFO : natural := 1 -- NEOLED TX FIFO depth, 1..32k, has to be a power of two
|
IO_NEOLED_TX_FIFO : natural := 1; -- NEOLED TX FIFO depth, 1..32k, has to be a power of two
|
|
IO_GPTMR_EN : boolean := false -- implement general purpose timer (GPTMR)?
|
);
|
);
|
port (
|
port (
|
-- Global control --
|
-- Global control --
|
clk_i : in std_ulogic; -- global clock, rising edge
|
clk_i : in std_ulogic; -- global clock, rising edge
|
rstn_i : in std_ulogic; -- global reset, low-active, async
|
rstn_i : in std_ulogic; -- global reset, low-active, async
|
Line 1909... |
Line 1914... |
-- CPU interrupt --
|
-- CPU interrupt --
|
cpu_irq_o : out std_ulogic
|
cpu_irq_o : out std_ulogic
|
);
|
);
|
end component;
|
end component;
|
|
|
|
-- Component: General Purpose Timer (GPTMR) -----------------------------------------------
|
|
-- -------------------------------------------------------------------------------------------
|
|
component neorv32_gptmr
|
|
port (
|
|
-- host access --
|
|
clk_i : in std_ulogic; -- global clock line
|
|
addr_i : in std_ulogic_vector(31 downto 0); -- address
|
|
rden_i : in std_ulogic; -- read enable
|
|
wren_i : in std_ulogic; -- write enable
|
|
data_i : in std_ulogic_vector(31 downto 0); -- data in
|
|
data_o : out std_ulogic_vector(31 downto 0); -- data out
|
|
ack_o : out std_ulogic; -- transfer acknowledge
|
|
-- clock generator --
|
|
clkgen_en_o : out std_ulogic; -- enable clock generator
|
|
clkgen_i : in std_ulogic_vector(07 downto 0);
|
|
-- interrupt --
|
|
irq_o : out std_ulogic -- transmission done interrupt
|
|
);
|
|
end component;
|
|
|
-- Component: System Configuration Information Memory (SYSINFO) ---------------------------
|
-- Component: System Configuration Information Memory (SYSINFO) ---------------------------
|
-- -------------------------------------------------------------------------------------------
|
-- -------------------------------------------------------------------------------------------
|
component neorv32_sysinfo
|
component neorv32_sysinfo
|
generic (
|
generic (
|
-- General --
|
-- General --
|
Line 1959... |
Line 1984... |
IO_WDT_EN : boolean; -- implement watch dog timer (WDT)?
|
IO_WDT_EN : boolean; -- implement watch dog timer (WDT)?
|
IO_TRNG_EN : boolean; -- implement true random number generator (TRNG)?
|
IO_TRNG_EN : boolean; -- implement true random number generator (TRNG)?
|
IO_CFS_EN : boolean; -- implement custom functions subsystem (CFS)?
|
IO_CFS_EN : boolean; -- implement custom functions subsystem (CFS)?
|
IO_SLINK_EN : boolean; -- implement stream link interface?
|
IO_SLINK_EN : boolean; -- implement stream link interface?
|
IO_NEOLED_EN : boolean; -- implement NeoPixel-compatible smart LED interface (NEOLED)?
|
IO_NEOLED_EN : boolean; -- implement NeoPixel-compatible smart LED interface (NEOLED)?
|
IO_XIRQ_NUM_CH : natural -- number of external interrupt (XIRQ) channels to implement
|
IO_XIRQ_NUM_CH : natural; -- number of external interrupt (XIRQ) channels to implement
|
|
IO_GPTMR_EN : boolean -- implement general purpose timer (GPTMR)?
|
);
|
);
|
port (
|
port (
|
-- host access --
|
-- host access --
|
clk_i : in std_ulogic; -- global clock line
|
clk_i : in std_ulogic; -- global clock line
|
addr_i : in std_ulogic_vector(31 downto 0); -- address
|
addr_i : in std_ulogic_vector(31 downto 0); -- address
|