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

Subversion Repositories i650

[/] [i650/] [trunk/] [rtl/] [op_reg.v] - Blame information for rev 21

Details | Compare with Previous | View Log

Line No. Rev Author Line
1 21 eightycc
`timescale 1ns / 1ps
2
//////////////////////////////////////////////////////////////////////////////////
3
// IBM 650 Reconstruction in Verilog (i650)
4
// 
5
// This file is part of the IBM 650 Reconstruction in Verilog (i650) project
6
// http:////www.opencores.org/project,i650
7
//
8
// Description: Operation code register.
9
// 
10
// Additional Comments: See US 2959351, Fig. 69.
11
//
12
// Copyright (c) 2015 Robert Abeles
13
//
14
// This source file is free software; you can redistribute it
15
// and/or modify it under the terms of the GNU Lesser General
16
// Public License as published by the Free Software Foundation;
17
// either version 2.1 of the License, or (at your option) any
18
// later version.
19
//
20
// This source is distributed in the hope that it will be
21
// useful, but WITHOUT ANY WARRANTY; without even the implied
22
// warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
23
// PURPOSE.  See the GNU Lesser General Public License for more
24
// details.
25
//
26
// You should have received a copy of the GNU Lesser General
27
// Public License along with this source; if not, download it
28
// from http://www.opencores.org/lgpl.shtml
29
//////////////////////////////////////////////////////////////////////////////////
30
`include "defines.v"
31
 
32
module op_reg (
33
   input rst,
34
   input cp,
35
   input d0, d9, d10, d1_d5, d5_dx,
36
   input restart_a, restart_b, d_alt, i_alt, tlu_band_change, man_prog_reset,
37
   input [0:6] prog_step_ped,
38
 
39
   output reg[0:6] opreg_t, opreg_u,
40
   output ri_addr_reg
41
   );
42
 
43
   wire op_reg_reset;
44
   assign ri_addr_reg = (d_alt & restart_b & d5_dx)
45
                      | (i_alt & restart_b & d1_d5)
46
                      | (tlu_band_change & d1_d5);
47
   assign op_reg_reset = man_prog_reset | restart_a | (tlu_band_change & d0);
48
 
49
   // reading the program step pedistal, so must wait for c phase
50
   always @(posedge cp)
51
      if (rst) begin
52
         opreg_t <= `biq_blank;
53
         opreg_u <= `biq_blank;
54
      end else if (op_reg_reset) begin
55
         opreg_t <= `biq_blank;
56
         opreg_u <= `biq_blank;
57
      end else if (ri_addr_reg) begin
58
         if (d9)
59
            opreg_u <= prog_step_ped;
60
         if (d10)
61
            opreg_t <= prog_step_ped;
62
      end;
63
 
64
endmodule

powered by: WebSVN 2.1.0

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