ep.h
3.46 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
/*
* ep.h: types, macros, etc. for Edge Walker Pipe
*
* 9/1/94 RJM
*/
#ifndef EWPIPE_UNIT_INCLD
#define EWPIPE_UNIT_INCLD
/* Total Pipe Depth for edge pipe */
#define EP_ST_SPAN_DLY (22+5)
#define EP_DATA_DLY (11+5)
#define EP_XOFFSET_DLY (23+5)
#define EP_YOFFSET_DLY (23+5)
#define EP_CVG_DLY (22+5)
#define EP_MASK_DLY (25+5)
#define EP_DITHER_DLY 32
/* Signal delays */
#define EP_RGB_DITHER_DLY 30
#define EP_A_DITHER_DLY 26
#define EP_ST_SPAN_W_DLY 4
#define EP_ST_SPAN_S_DLY 6
#define EP_ST_SPAN_T_DLY 6
#define EP_ST_SPAN_R_DLY (17+5)
#define EP_ST_SPAN_G_DLY (17+5)
#define EP_ST_SPAN_B_DLY (17+5)
#define EP_ST_SPAN_A_DLY (17+5)
#define EP_ST_SPAN_Z_DLY (20+5)
#define EP_ST_SPAN_TC_DLY 5
#define EP_ST_SPAN_TF_DLY (15+5)
#define EP_ST_SPAN_CC_DLY (17+5)
#define EP_ST_SPAN_BL_DLY (20+5)
#define EP_ST_SPAN_MS_DLY (17+5)
#define EP_DATA_W_DLY 2
#define EP_DATA_S_DLY 2
#define EP_DATA_T_DLY 1
#define EP_DATA_R_DLY (9+5)
#define EP_DATA_G_DLY (8+5)
#define EP_DATA_B_DLY (7+5)
#define EP_DATA_A_DLY (6+5)
#define EP_DATA_Z_DLY (8+5)
#define EP_XOFFSET_R_DLY (18+5)
#define EP_XOFFSET_G_DLY (18+5)
#define EP_XOFFSET_B_DLY (18+5)
#define EP_XOFFSET_A_DLY (18+5)
#define EP_XOFFSET_Z_DLY (21+5)
#define EP_YOFFSET_R_DLY (18+5)
#define EP_YOFFSET_G_DLY (18+5)
#define EP_YOFFSET_B_DLY (18+5)
#define EP_YOFFSET_A_DLY (18+5)
#define EP_YOFFSET_Z_DLY (21+5)
#define EP_CVG_CC_DLY (20+5)
#define EP_MASK_BL_DLY (23+5)
typedef struct
{
/* required by C-sim */
char *label; /* label must be first */
char **argv;
int argc;
int gclk_old;
/* I n p u t S i g n a l s */
int gclk;
int tlut_en;
int ew_st_span;
int ew_d; /* [21:0] */
int cv_x_offset; /* [1:0] */
int cv_y_offset; /* [1:0] */
int cv_cvg; /* [3:0] */
int cv_mask; /* */
int tc_load; /* */
int cycle_type; /* [1:0] */
int dither_type; /* flag */
int x_dither; /* [1:0] */
int y_dither; /* [1:0] */
/* O u t p u t S i g n a l s */
int st_span_st_w;
int st_span_st_s;
int st_span_st_t;
int st_span_st_r;
int st_span_st_g;
int st_span_st_b;
int st_span_st_a;
int st_span_st_z;
int st_span_tc;
int st_span_tf;
int st_span_cc;
int st_span_bl;
int st_span_ms;
int d_w; /* [21:0], s,.21 */
int d_s; /* [21:0], s,10.11 */
int d_t; /* [21:0], s,10.11 */
int d_r; /* [15:0], s,9.6 */
int d_g; /* [15:0], s,9.6 */
int d_b; /* [15:0], s,9.6 */
int d_a; /* [15:0], s,9.6 */
int d_z; /* [21:0], s,15.6 */
int x_offset_r; /* [1:0] */
int x_offset_g; /* [1:0] */
int x_offset_b; /* [1:0] */
int x_offset_a; /* [1:0] */
int x_offset_z; /* [1:0] */
int y_offset_r; /* [1:0] */
int y_offset_g; /* [1:0] */
int y_offset_b; /* [1:0] */
int y_offset_a; /* [1:0] */
int y_offset_z; /* [1:0] */
int cvg_cc; /* [3:0] */
int mask_bl; /* */
/* dither output */
int rgb_dither; /* [2:0] */
int alpha_dither; /* [2:0] */
/* I n t e r n a l R e g i s t e r s */
unsigned int st_span[EP_ST_SPAN_DLY];
unsigned int d[EP_DATA_DLY];
unsigned int x_offset[EP_XOFFSET_DLY];
unsigned int y_offset[EP_YOFFSET_DLY];
unsigned int cvg[EP_CVG_DLY];
unsigned int mask[EP_MASK_DLY];
unsigned int dither[EP_DITHER_DLY];
unsigned int tc_load_1d: 1;
} ep_t;
/*
* Prototypes
*/
void ep(ep_t **pp0, ep_t **pp1);
void ep_init(ep_t *p0, ep_t *p1);
#endif /* EWPIPE_UNIT_INCLD */