add: GPIO module to zealot SoC
[zpu.git] / zpu / hdl / example / zpu_config.vhd
blobcd4163db71e9bac564aebe1aecff7f0b72f1b509
1 -- ZPU
2 --
3 -- Copyright 2004-2008 oharboe - Øyvind Harboe - oyvind.harboe@zylin.com
4 --
5 -- The FreeBSD license
6 --
7 -- Redistribution and use in source and binary forms, with or without
8 -- modification, are permitted provided that the following conditions
9 -- are met:
10 --
11 -- 1. Redistributions of source code must retain the above copyright
12 -- notice, this list of conditions and the following disclaimer.
13 -- 2. Redistributions in binary form must reproduce the above
14 -- copyright notice, this list of conditions and the following
15 -- disclaimer in the documentation and/or other materials
16 -- provided with the distribution.
17 --
18 -- THIS SOFTWARE IS PROVIDED BY THE ZPU PROJECT ``AS IS'' AND ANY
19 -- EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
20 -- THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A
21 -- PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE
22 -- ZPU PROJECT OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT,
23 -- INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
24 -- (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
25 -- OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
26 -- HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT,
27 -- STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
28 -- ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
29 -- ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
30 --
31 -- The views and conclusions contained in the software and documentation
32 -- are those of the authors and should not be interpreted as representing
33 -- official policies, either expressed or implied, of the ZPU Project.
35 library ieee;
36 use ieee.std_logic_1164.all;
37 use ieee.numeric_std.all;
39 package zpu_config is
40 -- generate trace output
41 constant Generate_Trace : boolean := true;
42 constant wordPower : integer := 5;
43 -- during simulation, set this to '0' to get matching trace.txt
44 constant DontCareValue : std_logic := '0';
45 -- Clock frequency in MHz.
46 constant ZPU_Frequency : std_logic_vector(7 downto 0) := x"64";
47 -- This is the msb address bit. bytes=2^(maxAddrBitIncIO+1)
48 constant maxAddrBitIncIO : integer := 27;
49 constant maxAddrBitBRAM : integer := 16;
51 -- start byte address of stack.
52 -- point to top of RAM - 2*words
53 constant spStart : std_logic_vector(maxAddrBitIncIO downto 0) :=
54 std_logic_vector(to_unsigned((2**(maxAddrBitBRAM+1))-8, maxAddrBitIncIO+1));
55 end zpu_config;