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

Subversion Repositories rtf8088

[/] [rtf8088/] [trunk/] [rtl/] [verilog/] [wb_task.v] - Blame information for rev 7

Details | Compare with Previous | View Log

Line No. Rev Author Line
1 7 robfinch
 
2
task code_read;
3
begin
4
        cyc_type <= `CT_CODE;
5
        cyc_o <= 1'b1;
6
        stb_o <= 1'b1;
7
        we_o <= 1'b0;
8
        adr_o <= csip;
9
end
10
endtask
11
 
12
task read;
13
input [2:0] ct;
14
input [19:0] ad;
15
begin
16
        cyc_type <= ct;
17
        cyc_o <= 1'b1;
18
        stb_o <= 1'b1;
19
        we_o <= 1'b0;
20
        adr_o <= ad;
21
end
22
endtask
23
 
24
task pause_read;
25
begin
26
        cyc_type <= `CT_PASSIVE;
27
        stb_o <= 1'b0;
28
end
29
endtask
30
 
31
task write;
32
input [2:0] ct;
33
input [19:0] ad;
34
input [7:0] dat;
35
begin
36
        cyc_type <= ct;
37
        cyc_o <= 1'b1;
38
        stb_o <= 1'b1;
39
        we_o <= 1'b1;
40
        adr_o <= ad;
41
        dat_o <= dat;
42
end
43
endtask
44
 
45
task nack;
46
begin
47
        cyc_type <= `CT_PASSIVE;
48
        cyc_o <= 1'b0;
49
        stb_o <= 1'b0;
50
        we_o <= 1'b0;
51
        adr_o <= 20'd0;
52
        dat_o <= 8'd0;
53
end
54
endtask
55
 
56
task nack_ir;
57
begin
58
        nack();
59
        ir <= dat_i;
60
        ip <= ip_inc;
61
end
62
endtask
63
 
64
task nack_ir2;
65
begin
66
        nack();
67
        ir2 <= dat_i;
68
        ip <= ip_inc;
69
end
70
endtask
71
 
72
task pause_code_read;
73
begin
74
        cyc_type <= `CT_PASSIVE;
75
        stb_o <= 1'b0;
76
        ip <= ip_inc;
77
end
78
endtask
79
 
80
task continue_code_read;
81
begin
82
        cyc_type <= `CT_CODE;
83
        stb_o <= 1'b1;
84
        adr_o <= csip;
85
end
86
endtask
87
 
88
task term_code_read;
89
begin
90
        nack();
91
        ip <= ip_inc;
92
end
93
endtask
94
 
95
task stack_push;
96
begin
97
        cyc_type <= `CT_WRMEM;
98
        cyc_o <= 1'b1;
99
        stb_o <= 1'b1;
100
        we_o <= 1'b1;
101
        adr_o <= sssp;
102
end
103
endtask
104
 
105
task pause_stack_push;
106
begin
107
        cyc_type <= `CT_PASSIVE;
108
        sp <= sp_dec;
109
        stb_o <= 1'b0;
110
        we_o <= 1'b0;
111
end
112
endtask
113
 
114
task stack_pop;
115
begin
116
        cyc_type <= `CT_RDMEM;
117
        lock_o <= 1'b1;
118
        cyc_o <= 1'b1;
119
        stb_o <= 1'b1;
120
        adr_o <= sssp;
121
end
122
endtask
123
 
124
task pause_stack_pop;
125
begin
126
        cyc_type <= `CT_PASSIVE;
127
        stb_o <= 1'b0;
128
        sp <= sp_inc;
129
end
130
endtask
131
 
132
task continue_stack_pop;
133
begin
134
        cyc_type <= `CT_RDMEM;
135
        stb_o <= 1'b1;
136
        adr_o <= sssp;
137
end
138
endtask
139
 
140
task stack_pop_nack;
141
begin
142
        lock_o <= bus_locked;
143
        sp <= sp_inc;
144
        nack();
145
end
146
endtask
147
 

powered by: WebSVN 2.1.0

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