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

Subversion Repositories Aquarius

[/] [Aquarius/] [trunk/] [application/] [shc_pi/] [common.h] - Blame information for rev 12

Details | Compare with Previous | View Log

Line No. Rev Author Line
1 6 thorn_aitc
//===============================
2
// C Source Header
3
//-------------------------------
4
// for VirtexE Evaluation Board
5
// Apr.19 2003 Ver.1
6
//===============================
7
 
8
//--------------------------
9
// Peripheral I/O definition
10
//--------------------------
11
struct st_porto
12
{
13
    unsigned char RESERVED_0;
14
    union
15
    {
16
        unsigned char BYTE;
17
        struct
18
        {
19
            unsigned char    :3;
20
            unsigned char KY4:1;
21
            unsigned char KY3:1;
22
            unsigned char KY2:1;
23
            unsigned char KY1:1;
24
            unsigned char KY0:1;
25
        } BIT;
26
    } KEYYO;
27
    union
28
    {
29
        unsigned char BYTE;
30
        struct
31
        {
32
            unsigned char   :5;
33
            unsigned char E :1;
34
            unsigned char RW:1;
35
            unsigned char RS:1;
36
        } BIT;
37
    } LCDCON;
38
    unsigned char LCDOUT;
39
};
40
 
41
struct st_porti
42
{
43
    unsigned char RESERVED_0;
44
    union
45
    {
46
        unsigned char BYTE;
47
        struct
48
        {
49
            unsigned char    :3;
50
            unsigned char KX4:1;
51
            unsigned char KX3:1;
52
            unsigned char KX2:1;
53
            unsigned char KX1:1;
54
            unsigned char KX0:1;
55
        } BIT;
56
    } KEYXI;
57
    unsigned char RESERVED_2;
58
    unsigned char LCDIN;
59
};
60
 
61
struct st_uart
62
{
63
    unsigned char UARTBG0;
64
    unsigned char UARTBG1;
65
    union
66
    {
67
        unsigned char BYTE;
68
        struct
69
        {
70
          unsigned char    :6;
71
          unsigned char TXF:1;
72
          unsigned char RXE:1;
73
        } BIT;
74
    } UARTCON;
75
    union
76
    {
77
        unsigned char TX;
78
        unsigned char RX;
79
    } BYTE;
80
};
81
 
82
struct st_sys
83
{
84
    unsigned long  INTCTL;
85
    unsigned short BRKADR;
86
};
87
 
88
 
89
#define PORTO (*(volatile struct st_porto  *)0xabcd0000)
90
#define PORTI (*(volatile struct st_porti  *)0xabcd0000)
91
#define UART  (*(volatile struct st_uart   *)0xabcd0100)
92
#define SYS   (*(volatile struct st_sys    *)0xabcd0200)
93
 
94
//-----------
95
// LCD Access
96
//-----------
97
#define INST 0
98
#define DATA 1
99
 
100
//---------
101
// Key Code
102
//---------
103
#define KEY0 0
104
#define KEY1 1
105
#define KEY2 2
106
#define KEY3 3
107
#define KEY4 4
108
#define KEY5 5
109
#define KEY6 6
110
#define KEY7 7
111
#define KEY8 8
112
#define KEY9 9
113
#define KEYA 10
114
#define KEYB 11
115
#define KEYC 12
116
#define KEYD 13
117
#define KEYE 14
118
#define KEYF 15
119
#define KEYUTL 16
120
#define KEYRUN 17
121
#define KEYGET 18
122
#define KEYPUT 19
123
#define KEYADR 20
124
#define KEYINC 21
125
#define KEYDEC 22
126
#define KEYDAT 23
127
#define KEYNONE 255
128
 
129
 
130
 
131
 

powered by: WebSVN 2.1.0

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