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

Subversion Repositories rtf8088

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

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

Line No. Rev Author Line
1 2 robfinch
// ============================================================================
2
//  JUMP_VECTOR
3
//  - fetch 32 bit vector into selector:offset and jump to it
4
//
5
//
6
//  2009,2010,2012  Robert Finch
7
//  robfinch[remove]@opencores.org
8
//  Stratford
9
//
10
//
11
// This source file is free software: you can redistribute it and/or modify 
12
// it under the terms of the GNU Lesser General Public License as published 
13
// by the Free Software Foundation, either version 3 of the License, or     
14
// (at your option) any later version.                                      
15
//                                                                          
16
// This source file is distributed in the hope that it will be useful,      
17
// but WITHOUT ANY WARRANTY; without even the implied warranty of           
18
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the            
19
// GNU General Public License for more details.                             
20
//                                                                          
21
// You should have received a copy of the GNU General Public License        
22
// along with this program.  If not, see <http://www.gnu.org/licenses/>.    
23
//
24
//  Verilog 
25
//
26
// ============================================================================
27
//
28
JUMP_VECTOR1:
29
        begin
30
                lock_o <= 1'b1;
31
                cyc_o <= 1'b1;
32
                stb_o <= 1'b1;
33
                we_o  <= 1'b0;
34
                adr_o <= ea;            // ea set by EACALC
35
                state <= JUMP_VECTOR2;
36
        end
37
JUMP_VECTOR2:
38
        if (ack_i) begin
39
                ea    <= ea_inc;
40
                offset[7:0] <= dat_i;
41
                stb_o <= 1'b0;
42
                state <= JUMP_VECTOR3;
43
        end
44
JUMP_VECTOR3:
45
        begin
46
                stb_o <= 1'b1;
47
                adr_o <= ea;
48
                state <= JUMP_VECTOR4;
49
        end
50
JUMP_VECTOR4:
51
        if (ack_i) begin
52
                ea    <= ea_inc;
53
                stb_o <= 1'b0;
54
                offset[15:8] <= dat_i;
55
                state <= JUMP_VECTOR5;
56
        end
57
JUMP_VECTOR5:
58
        begin
59
                stb_o <= 1'b1;
60
                adr_o <= ea;
61
                state <= JUMP_VECTOR6;
62
        end
63
JUMP_VECTOR6:
64
        if (ack_i) begin
65
                ea    <= ea_inc;
66
                selector[7:0] <= dat_i;
67
                stb_o <= 1'b0;
68
                state <= JUMP_VECTOR7;
69
        end
70
JUMP_VECTOR7:
71
        begin
72
                stb_o <= 1'b1;
73
                adr_o <= ea;
74
                state <= JUMP_VECTOR8;
75
        end
76
JUMP_VECTOR8:
77
        if (ack_i) begin
78
                cyc_o <= 1'b0;
79
                stb_o <= 1'b0;
80
                selector[15:8] <= dat_i;
81
                state <= JUMP_VECTOR9;
82
        end
83
JUMP_VECTOR9:
84
        begin
85
                ip <= offset;
86
                cs <= selector;
87
                state <= IFETCH;
88
        end

powered by: WebSVN 2.1.0

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