OpenCores
URL https://opencores.org/ocsvn/yavga/yavga/trunk

Subversion Repositories yavga

[/] [yavga/] [trunk/] [vhdl/] [yavga_pkg.vhd] - Blame information for rev 28

Go to most recent revision | Details | Compare with Previous | View Log

Line No. Rev Author Line
1 24 sandroamt
--      Package File Template
2
--
3
--      Purpose: This package defines supplemental types, subtypes, 
4
--               constants, and functions 
5
 
6
 
7
library IEEE;
8
use IEEE.STD_LOGIC_1164.all;
9
 
10
package yavga_pkg is
11
 
12
-- Declare constants
13
 
14
  -- chars address and data bus size
15
  constant c_CHR_ADDR_BUS_W : integer := 11;
16
  constant c_CHR_DATA_BUS_W : integer := 32;
17 28 sandroamt
  constant c_CHR_WE_BUS_W   : integer := 4;
18 24 sandroamt
 
19
  -- internal used chars address and data bus size 
20
  constant c_INTCHR_ADDR_BUS_W : integer := 13;
21
  constant c_INTCHR_DATA_BUS_W : integer := 8;
22
 
23
  -- internal ROM chmaps address and data bus
24
  constant c_INTCHMAP_ADDR_BUS_W : integer := 11;
25
  constant c_INTCHMAP_DATA_BUS_W : integer := 8;
26
 
27
  -- waveform address and data bus size
28
  constant c_WAVFRM_ADDR_BUS_W : integer := 10;
29
  constant c_WAVFRM_DATA_BUS_W : integer := 16;
30
 
31
  constant c_GRID_SIZE : std_logic_vector(6 downto 0) := "1111111";
32
  constant c_GRID_BIT  : integer                      := 6;
33
 
34
  --
35
  -- horizontal timing signals (in pixels count )
36
  constant c_H_DISPLAYpx    : integer := 800;
37
  constant c_H_BACKPORCHpx  : integer := 63;  -- also 60;
38
  constant c_H_SYNCTIMEpx   : integer := 120;
39
  constant c_H_FRONTPORCHpx : integer := 56;  --also 60;
40
  constant c_H_PERIODpx     : integer := c_H_DISPLAYpx +
41
                                         c_H_BACKPORCHpx +
42
                                         c_H_SYNCTIMEpx +
43
                                         c_H_FRONTPORCHpx;
44 28 sandroamt
  constant c_H_COUNT_W : integer := 11;       -- = ceil(ln2(c_H_PERIODpx))
45 24 sandroamt
 
46
  --
47
  -- vertical timing signals (in lines count)
48
  constant c_V_DISPLAYln    : integer := 600;
49
  constant c_V_BACKPORCHln  : integer := 23;
50
  constant c_V_SYNCTIMEln   : integer := 6;
51
  constant c_V_FRONTPORCHln : integer := 37;
52
  constant c_V_PERIODln     : integer := c_V_DISPLAYln +
53
                                         c_V_BACKPORCHln +
54
                                         c_V_SYNCTIMEln +
55
                                         c_V_FRONTPORCHln;
56 28 sandroamt
  constant c_V_COUNT_W : integer := 10;  -- = ceil(ln2(c_V_PERIODln))
57 24 sandroamt
 
58 28 sandroamt
  constant c_X_W : integer := c_H_COUNT_W;
59
  constant c_Y_W : integer := c_V_COUNT_W;
60 24 sandroamt
 
61
--  constant c_CHARS_WIDTH: std_logic_vector(2 downto 0) := "111";
62
--  constant c_CHARS_HEIGHT: std_logic_vector(3 downto 0) := "1111";
63
--  constant c_CHARS_COLS: std_logic_vector(6 downto 0) := "1100011";
64
--  constant c_CHARS_ROWS: std_logic_vector(5 downto 0) := "100100";
65
 
66
  -- to manage the background and cursor colors
67 28 sandroamt
  constant c_CFG_BG_CUR_COLOR_ADDR : std_logic_vector(12 downto 0) := "0000001101100";  -- 108 BG:5..3 CUR:2..0
68 24 sandroamt
 
69
  -- to manage the cursor position  
70 28 sandroamt
  constant c_CFG_CURS_XY1 : std_logic_vector(12 downto 0) := "0000001101101";  -- 109
71
  constant c_CFG_CURS_XY2 : std_logic_vector(12 downto 0) := "0000001101110";  -- 110
72
  constant c_CFG_CURS_XY3 : std_logic_vector(12 downto 0) := "0000001101111";  -- 111
73 24 sandroamt
 
74
end yavga_pkg;
75
 
76
 
77
package body yavga_pkg is
78
 
79
end yavga_pkg;

powered by: WebSVN 2.1.0

© copyright 1999-2024 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.