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

Subversion Repositories 8051

[/] [8051/] [trunk/] [rtl/] [verilog/] [oc8051_sfr.v] - Blame information for rev 120

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

Line No. Rev Author Line
1 75 simont
//////////////////////////////////////////////////////////////////////
2
////                                                              ////
3
////  8051 cores sfr top level module                             ////
4
////                                                              ////
5
////  This file is part of the 8051 cores project                 ////
6
////  http://www.opencores.org/cores/8051/                        ////
7
////                                                              ////
8
////  Description                                                 ////
9
////   special function registers for oc8051                      ////
10
////                                                              ////
11
////  To Do:                                                      ////
12
////    nothing                                                   ////
13
////                                                              ////
14
////  Author(s):                                                  ////
15
////      - Simon Teran, simont@opencores.org                     ////
16
////                                                              ////
17
//////////////////////////////////////////////////////////////////////
18
////                                                              ////
19
//// Copyright (C) 2000 Authors and OPENCORES.ORG                 ////
20
////                                                              ////
21
//// This source file may be used and distributed without         ////
22
//// restriction provided that this copyright statement is not    ////
23
//// removed from the file and that any derivative work contains  ////
24
//// the original copyright notice and the associated disclaimer. ////
25
////                                                              ////
26
//// This source file is free software; you can redistribute it   ////
27
//// and/or modify it under the terms of the GNU Lesser General   ////
28
//// Public License as published by the Free Software Foundation; ////
29
//// either version 2.1 of the License, or (at your option) any   ////
30
//// later version.                                               ////
31
////                                                              ////
32
//// This source is distributed in the hope that it will be       ////
33
//// useful, but WITHOUT ANY WARRANTY; without even the implied   ////
34
//// warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR      ////
35
//// PURPOSE.  See the GNU Lesser General Public License for more ////
36
//// details.                                                     ////
37
////                                                              ////
38
//// You should have received a copy of the GNU Lesser General    ////
39
//// Public License along with this source; if not, download it   ////
40
//// from http://www.opencores.org/lgpl.shtml                     ////
41
////                                                              ////
42
//////////////////////////////////////////////////////////////////////
43
//
44
// CVS Revision History
45
//
46
// $Log: not supported by cvs2svn $
47 120 simont
// Revision 1.9  2003/04/09 16:24:03  simont
48
// change wr_sft to 2 bit wire.
49
//
50 118 simont
// Revision 1.8  2003/04/09 15:49:42  simont
51
// Register oc8051_sfr dato output, add signal wait_data.
52
//
53 117 simont
// Revision 1.7  2003/04/07 14:58:02  simont
54
// change sfr's interface.
55
//
56 116 simont
// Revision 1.6  2003/04/07 13:29:16  simont
57
// change uart to meet timing.
58
//
59 115 simont
// Revision 1.5  2003/04/04 10:35:07  simont
60
// signal prsc_ow added.
61
//
62 113 simont
// Revision 1.4  2003/03/28 17:45:57  simont
63
// change module name.
64
//
65 90 simont
// Revision 1.3  2003/01/21 13:51:30  simont
66
// add include oc8051_defines.v
67
//
68 87 simont
// Revision 1.2  2003/01/13 14:14:41  simont
69
// replace some modules
70
//
71 82 simont
// Revision 1.1  2002/11/05 17:22:27  simont
72
// initial import
73 75 simont
//
74 82 simont
//
75 75 simont
 
76
// synopsys translate_off
77
`include "oc8051_timescale.v"
78
// synopsys translate_on
79
 
80 87 simont
`include "oc8051_defines.v"
81 75 simont
 
82 87 simont
 
83 120 simont
module oc8051_sfr (rst, clk,
84 117 simont
       adr0, adr1, dat0,
85 120 simont
       dat1, dat2, bit_in,
86
       we, wr_bit,
87 117 simont
       bit_out,
88 120 simont
       wr_sfr, acc,
89
       ram_wr_sel, ram_rd_sel,
90
       sp, sp_w,
91
       bank_sel,
92
       desAc, desOv,
93
       srcAc, cy,
94
       psw_set, rmw,
95 75 simont
 
96 120 simont
`ifdef OC8051_PORTS
97 75 simont
 
98 120 simont
  `ifdef OC8051_PORT0
99
       p0_out,
100
       p0_in,
101
  `endif
102 75 simont
 
103 120 simont
  `ifdef OC8051_PORT1
104
       p1_out,
105
       p1_in,
106
  `endif
107 75 simont
 
108 120 simont
  `ifdef OC8051_PORT2
109
       p2_out,
110
       p2_in,
111
  `endif
112 75 simont
 
113 120 simont
  `ifdef OC8051_PORT3
114
       p3_out,
115
       p3_in,
116
  `endif
117
 
118
`endif
119
 
120
 
121
  `ifdef OC8051_UART
122
       rxd, txd,
123
  `endif
124
 
125
       int_ack, intr,
126
       int0, int1,
127
       int_src,
128
       reti,
129
 
130
  `ifdef OC8051_TC01
131
       t0, t1,
132
  `endif
133
 
134
  `ifdef OC8051_TC2
135
       t2, t2ex,
136
  `endif
137
 
138
       dptr_hi, dptr_lo,
139
       wait_data);
140
 
141
 
142
input       rst,        // reset - pin
143
            clk,        // clock - pin
144
            we,         // write enable
145
            bit_in,
146
            desAc,
147
            desOv,
148
            rmw;
149
input       int_ack,
150
            int0,
151
            int1,
152
            reti,
153
            wr_bit;
154
input [1:0] psw_set,
155
            wr_sfr;
156
input [2:0] ram_rd_sel,
157
            ram_wr_sel;
158
input [7:0] adr0,        //address 0 input
159
            adr1,       //address 1 input
160
            dat1,       //data 1 input (des1)
161
            dat2;       //data 2 input (des2)
162
 
163
output       bit_out,
164
             intr,
165
             srcAc,
166
             cy,
167
             wait_data;
168 82 simont
output [1:0] bank_sel;
169 120 simont
output [7:0] dat0,       //data output
170
             int_src,
171
             dptr_hi,
172
             dptr_lo,
173
             acc;
174
output [7:0] sp,
175
             sp_w;
176 75 simont
 
177 120 simont
// ports
178
`ifdef OC8051_PORTS
179 82 simont
 
180 120 simont
`ifdef OC8051_PORT0
181
input  [7:0] p0_in;
182
output [7:0] p0_out;
183
wire   [7:0] p0_data;
184
`endif
185 75 simont
 
186 120 simont
`ifdef OC8051_PORT1
187
input  [7:0] p1_in;
188
output [7:0] p1_out;
189
wire   [7:0] p1_data;
190
`endif
191 116 simont
 
192 120 simont
`ifdef OC8051_PORT2
193
input  [7:0] p2_in;
194
output [7:0] p2_out;
195
wire   [7:0] p2_data;
196
`endif
197 116 simont
 
198 120 simont
`ifdef OC8051_PORT3
199
input  [7:0] p3_in;
200
output [7:0] p3_out;
201
wire   [7:0] p3_data;
202
`endif
203 75 simont
 
204 120 simont
`endif
205
 
206
 
207 116 simont
// serial interface
208 120 simont
`ifdef OC8051_UART
209
input        rxd;
210
output       txd;
211
`endif
212 116 simont
 
213 120 simont
// timer/counter 0,1
214
`ifdef OC8051_TC01
215
input        t0, t1;
216
`endif
217 82 simont
 
218 120 simont
// timer/counter 2
219
`ifdef OC8051_TC2
220
input        t2, t2ex;
221
`endif
222 117 simont
 
223 120 simont
reg        bit_out,
224
           wait_data;
225
reg [7:0]  dat0,
226
           adr0_r;
227
 
228
reg        wr_bit_r;
229
reg [2:0]  ram_wr_sel_r;
230
 
231
 
232
wire       p,
233
           uart_int,
234
           tf0,
235
           tf1,
236
           tr0,
237
           tr1,
238
           rclk,
239
           tclk,
240
           brate2,
241
           tc2_int;
242
 
243
 
244
wire [7:0] b_reg,
245
           psw,
246
 
247
`ifdef OC8051_TC2
248
  // t/c 2
249
           t2con,
250
           tl2,
251
           th2,
252
           rcap2l,
253
           rcap2h,
254
`endif
255
 
256
`ifdef OC8051_TC01
257
  // t/c 0,1
258
           tmod,
259
           tl0,
260
           th0,
261
           tl1,
262
           th1,
263
`endif
264
 
265
  // serial interface
266
`ifdef OC8051_UART
267
           scon,
268
           pcon,
269
           sbuf,
270
`endif
271
 
272
  //interrupt control
273
           ie,
274
           tcon,
275
           ip;
276
 
277
 
278
reg        pres_ow;
279
reg [3:0]  prescaler;
280
 
281
 
282 75 simont
assign cy = psw[7];
283
assign srcAc = psw [6];
284
 
285 82 simont
 
286
 
287 75 simont
//
288
// accumulator
289
// ACC
290 120 simont
oc8051_acc oc8051_acc1(.clk(clk),
291
                       .rst(rst),
292
                       .bit_in(bit_in),
293
                       .data_in(dat1),
294
                       .data2_in(dat2),
295
                       .wr(we),
296
                       .wr_bit(wr_bit_r),
297
                       .wr_sfr(wr_sfr),
298
                       .wr_addr(adr1),
299
                       .data_out(acc),
300
                       .p(p));
301 75 simont
 
302
 
303
//
304
// b register
305
// B
306 120 simont
oc8051_b_register oc8051_b_register (.clk(clk),
307
                                     .rst(rst),
308
                                     .bit_in(bit_in),
309
                                     .data_in(dat1),
310
                                     .wr(we),
311
                                     .wr_bit(wr_bit_r),
312
                                     .wr_addr(adr1),
313
                                     .data_out(b_reg));
314 75 simont
 
315
//
316
//stack pointer
317
// SP
318 120 simont
oc8051_sp oc8051_sp1(.clk(clk),
319
                     .rst(rst),
320
                     .ram_rd_sel(ram_rd_sel),
321
                     .ram_wr_sel(ram_wr_sel),
322
                     .wr_addr(adr1),
323
                     .wr(we),
324
                     .wr_bit(wr_bit_r),
325
                     .data_in(dat1),
326
                     .sp_out(sp),
327
                     .sp_w(sp_w));
328 75 simont
 
329
//
330
//data pointer
331
// DPTR, DPH, DPL
332 120 simont
oc8051_dptr oc8051_dptr1(.clk(clk),
333
                         .rst(rst),
334
                         .addr(adr1),
335
                         .data_in(dat1),
336
                         .data2_in(dat2),
337
                         .wr(we),
338
                         .wr_bit(wr_bit_r),
339
                         .data_hi(dptr_hi),
340
                         .data_lo(dptr_lo),
341
                         .wr_sfr(wr_sfr));
342 75 simont
 
343 82 simont
 
344 75 simont
//
345
//program status word
346
// PSW
347 120 simont
oc8051_psw oc8051_psw1 (.clk(clk),
348
                        .rst(rst),
349
                        .wr_addr(adr1),
350
                        .data_in(dat1),
351
                        .wr(we),
352
                        .wr_bit(wr_bit_r),
353
                        .data_out(psw),
354
                        .p(p),
355
                        .cy_in(bit_in),
356
                        .ac_in(desAc),
357
                        .ov_in(desOv),
358
                        .set(psw_set),
359
                        .bank_sel(bank_sel));
360 75 simont
 
361
//
362
// ports
363
// P0, P1, P2, P3
364 120 simont
`ifdef OC8051_PORTS
365
  oc8051_ports oc8051_ports1(.clk(clk),
366
                           .rst(rst),
367
                           .bit_in(bit_in),
368
                           .data_in(dat1),
369
                           .wr(we),
370
                           .wr_bit(wr_bit_r),
371
                           .wr_addr(adr1),
372 75 simont
 
373 120 simont
                `ifdef OC8051_PORT0
374
                           .p0_out(p0_out),
375
                           .p0_in(p0_in),
376
                           .p0_data(p0_data),
377
                `endif
378
 
379
                `ifdef OC8051_PORT1
380
                           .p1_out(p1_out),
381
                           .p1_in(p1_in),
382
                           .p1_data(p1_data),
383
                `endif
384
 
385
                `ifdef OC8051_PORT2
386
                           .p2_out(p2_out),
387
                           .p2_in(p2_in),
388
                           .p2_data(p2_data),
389
                `endif
390
 
391
                `ifdef OC8051_PORT3
392
                           .p3_out(p3_out),
393
                           .p3_in(p3_in),
394
                           .p3_data(p3_data),
395
                `endif
396
 
397
                           .rmw(rmw));
398
`endif
399
 
400 75 simont
//
401
// serial interface
402
// SCON, SBUF
403 120 simont
`ifdef OC8051_UART
404
  oc8051_uart oc8051_uatr1 (.clk(clk),
405
                            .rst(rst),
406
                            .bit_in(bit_in),
407
                            .data_in(dat1),
408
                            .wr(we),
409
                            .wr_bit(wr_bit_r),
410
                            .wr_addr(adr1),
411
                            .rxd(rxd),
412
                            .txd(txd),
413
                // interrupt
414
                            .intr(uart_int),
415
                // baud rate sources
416
                            .brate2(brate2),
417
                            .t1_ow(tf1),
418
                            .pres_ow(pres_ow),
419
                            .rclk(rclk),
420
                            .tclk(tclk),
421
                //registers
422
                            .scon(scon),
423
                            .pcon(pcon),
424
                            .sbuf(sbuf));
425
`else
426
  assign uart_int = 1'b0;
427
`endif
428 75 simont
 
429
//
430
// interrupt control
431
// IP, IE, TCON
432 120 simont
oc8051_int oc8051_int1 (.clk(clk),
433
                        .rst(rst),
434
                        .wr_addr(adr1),
435
                        .bit_in(bit_in),
436
                        .ack(int_ack),
437
                        .data_in(dat1),
438
                        .wr(we),
439
                        .wr_bit(wr_bit_r),
440
                        .tf0(tf0),
441
                        .tf1(tf1),
442
                        .t2_int(tc2_int),
443
                        .tr0(tr0),
444
                        .tr1(tr1),
445
                        .ie0(int0),
446
                        .ie1(int1),
447
                        .uart_int(uart_int),
448
                        .reti(reti),
449
                        .intr(intr),
450
                        .int_vec(int_src),
451
                        .ie(ie),
452
                        .tcon(tcon),
453
                        .ip(ip));
454 75 simont
 
455 82 simont
 
456 75 simont
//
457
// timer/counter control
458
// TH0, TH1, TL0, TH1, TMOD
459 120 simont
`ifdef OC8051_TC01
460
  oc8051_tc oc8051_tc1(.clk(clk),
461
                       .rst(rst),
462
                       .wr_addr(adr1),
463
                       .data_in(dat1),
464
                       .wr(we),
465
                       .wr_bit(wr_bit_r),
466
                       .ie0(int0),
467
                       .ie1(int1),
468
                       .tr0(tr0),
469
                       .tr1(tr1),
470
                       .t0(t0),
471
                       .t1(t1),
472
                       .tf0(tf0),
473
                       .tf1(tf1),
474
                       .pres_ow(pres_ow),
475
                       .tmod(tmod),
476
                       .tl0(tl0),
477
                       .th0(th0),
478
                       .tl1(tl1),
479
                       .th1(th1));
480
`else
481
  assign tf0 = 1'b0;
482
  assign tf1 = 1'b0;
483
`endif
484 75 simont
 
485 82 simont
//
486
// timer/counter 2
487 116 simont
// TH2, TL2, RCAPL2L, RCAPL2H, T2CON
488 120 simont
`ifdef OC8051_TC2
489
  oc8051_tc2 oc8051_tc21(.clk(clk),
490
                         .rst(rst),
491
                         .wr_addr(adr1),
492
                         .data_in(dat1),
493
                         .wr(we),
494
                         .wr_bit(wr_bit_r),
495
                         .bit_in(bit_in),
496
                         .t2(t2),
497
                         .t2ex(t2ex),
498
                         .rclk(rclk),
499
                         .tclk(tclk),
500
                         .brate2(brate2),
501
                         .tc2_int(tc2_int),
502
                         .pres_ow(pres_ow),
503
                         .t2con(t2con),
504
                         .tl2(tl2),
505
                         .th2(th2),
506
                         .rcap2l(rcap2l),
507
                         .rcap2h(rcap2h));
508
`else
509
  assign tc2_int = 1'b0;
510
  assign rclk    = 1'b0;
511
  assign tclk    = 1'b0;
512
  assign brate2  = 1'b0;
513
`endif
514 75 simont
 
515 82 simont
 
516
 
517 75 simont
always @(posedge clk or posedge rst)
518
  if (rst) begin
519
    adr0_r <= #1 8'h00;
520
    ram_wr_sel_r <= #1 3'b000;
521 82 simont
    wr_bit_r <= #1 1'b0;
522 117 simont
//    wait_data <= #1 1'b0;
523 75 simont
  end else begin
524
    adr0_r <= #1 adr0;
525
    ram_wr_sel_r <= #1 ram_wr_sel;
526 82 simont
    wr_bit_r <= #1 wr_bit;
527 75 simont
  end
528
 
529
 
530
//
531 117 simont
//set output in case of address (byte)
532
always @(posedge clk or posedge rst)
533
begin
534
  if (rst) begin
535
    dat0 <= #1 8'h00;
536
    wait_data <= #1 1'b0;
537
  end else if ((wr_sfr==`OC8051_WRS_DPTR) & (adr0==`OC8051_SFR_DPTR_LO)) begin                          //write and read same address
538
    dat0 <= #1 dat1;
539
    wait_data <= #1 1'b0;
540
  end else if (
541 120 simont
      (((wr_sfr==`OC8051_WRS_ACC1) & (adr0==`OC8051_SFR_ACC)) |         //write to acc
542 117 simont
      ((wr_sfr==`OC8051_WRS_DPTR) & (adr0==`OC8051_SFR_DPTR_LO)) |      //write to dpl
543 120 simont
      (adr1[7] & (adr1==adr0) & we & !wr_bit_r)) & !wait_data) begin    //write and read same address
544 117 simont
    wait_data <= #1 1'b1;
545
 
546
  end else if (
547
      (((wr_sfr==`OC8051_WRS_ACC2) & (adr0==`OC8051_SFR_ACC)) |         //write to acc
548 118 simont
      ((wr_sfr==`OC8051_WRS_DPTR) & (adr0==`OC8051_SFR_DPTR_HI))        //write to dph
549 120 simont
      ) & !wait_data) begin
550 117 simont
    wait_data <= #1 1'b1;
551
 
552
  end else begin
553
    case (adr0)
554
      `OC8051_SFR_ACC:          dat0 <= #1 acc;
555
      `OC8051_SFR_PSW:          dat0 <= #1 psw;
556 120 simont
 
557
`ifdef OC8051_PORTS
558
  `ifdef OC8051_PORT0
559 117 simont
      `OC8051_SFR_P0:           dat0 <= #1 p0_data;
560 120 simont
  `endif
561
 
562
  `ifdef OC8051_PORT1
563 117 simont
      `OC8051_SFR_P1:           dat0 <= #1 p1_data;
564 120 simont
  `endif
565
 
566
  `ifdef OC8051_PORT2
567 117 simont
      `OC8051_SFR_P2:           dat0 <= #1 p2_data;
568 120 simont
  `endif
569
 
570
  `ifdef OC8051_PORT3
571 117 simont
      `OC8051_SFR_P3:           dat0 <= #1 p3_data;
572 120 simont
  `endif
573
`endif
574
 
575 117 simont
      `OC8051_SFR_SP:           dat0 <= #1 sp;
576
      `OC8051_SFR_B:            dat0 <= #1 b_reg;
577
      `OC8051_SFR_DPTR_HI:      dat0 <= #1 dptr_hi;
578
      `OC8051_SFR_DPTR_LO:      dat0 <= #1 dptr_lo;
579 120 simont
 
580
`ifdef OC8051_UART
581 117 simont
      `OC8051_SFR_SCON:         dat0 <= #1 scon;
582
      `OC8051_SFR_SBUF:         dat0 <= #1 sbuf;
583
      `OC8051_SFR_PCON:         dat0 <= #1 pcon;
584 120 simont
`endif
585
 
586
`ifdef OC8051_TC01
587 117 simont
      `OC8051_SFR_TH0:          dat0 <= #1 th0;
588
      `OC8051_SFR_TH1:          dat0 <= #1 th1;
589
      `OC8051_SFR_TL0:          dat0 <= #1 tl0;
590
      `OC8051_SFR_TL1:          dat0 <= #1 tl1;
591
      `OC8051_SFR_TMOD:         dat0 <= #1 tmod;
592 120 simont
`endif
593
 
594 117 simont
      `OC8051_SFR_IP:           dat0 <= #1 ip;
595
      `OC8051_SFR_IE:           dat0 <= #1 ie;
596
      `OC8051_SFR_TCON:         dat0 <= #1 tcon;
597 120 simont
 
598
`ifdef OC8051_TC2
599 117 simont
      `OC8051_SFR_RCAP2H:       dat0 <= #1 rcap2h;
600
      `OC8051_SFR_RCAP2L:       dat0 <= #1 rcap2l;
601
      `OC8051_SFR_TH2:          dat0 <= #1 th2;
602
      `OC8051_SFR_TL2:          dat0 <= #1 tl2;
603
      `OC8051_SFR_T2CON:        dat0 <= #1 t2con;
604 120 simont
`endif
605
 
606 117 simont
      default:                  dat0 <= #1 8'h00;
607
    endcase
608
    wait_data <= #1 1'b0;
609
  end
610
end
611
 
612
 
613
//
614
//set output in case of address (bit)
615
always @(posedge clk or posedge rst)
616
begin
617
  if (rst)
618
    bit_out <= #1 1'h0;
619
  else if (
620
          ((adr1[7:3]==adr0[7:3]) & (~&adr1[2:0]) &  we & !wr_bit_r) |
621 118 simont
          ((wr_sfr==`OC8051_WRS_ACC1) & (adr0[7:3]==`OC8051_SFR_B_ACC))         //write to acc
622 120 simont
          )
623 117 simont
 
624
    bit_out <= #1 dat1[adr0[2:0]];
625
  else if ((adr1==adr0) & we & wr_bit_r)
626
    bit_out <= #1 bit_in;
627
  else
628
    case (adr0[7:3])
629
      `OC8051_SFR_B_ACC:   bit_out <= #1 acc[adr0[2:0]];
630
      `OC8051_SFR_B_PSW:   bit_out <= #1 psw[adr0[2:0]];
631 120 simont
 
632
`ifdef OC8051_PORTS
633
  `ifdef OC8051_PORT0
634 117 simont
      `OC8051_SFR_B_P0:    bit_out <= #1 p0_data[adr0[2:0]];
635 120 simont
  `endif
636
 
637
  `ifdef OC8051_PORT1
638 117 simont
      `OC8051_SFR_B_P1:    bit_out <= #1 p1_data[adr0[2:0]];
639 120 simont
  `endif
640
 
641
  `ifdef OC8051_PORT2
642 117 simont
      `OC8051_SFR_B_P2:    bit_out <= #1 p2_data[adr0[2:0]];
643 120 simont
  `endif
644
 
645
  `ifdef OC8051_PORT3
646 117 simont
      `OC8051_SFR_B_P3:    bit_out <= #1 p3_data[adr0[2:0]];
647 120 simont
  `endif
648
`endif
649
 
650 117 simont
      `OC8051_SFR_B_B:     bit_out <= #1 b_reg[adr0[2:0]];
651
      `OC8051_SFR_B_IP:    bit_out <= #1 ip[adr0[2:0]];
652
      `OC8051_SFR_B_IE:    bit_out <= #1 ie[adr0[2:0]];
653
      `OC8051_SFR_B_TCON:  bit_out <= #1 tcon[adr0[2:0]];
654 120 simont
 
655
`ifdef OC8051_UART
656 117 simont
      `OC8051_SFR_B_SCON:  bit_out <= #1 scon[adr0[2:0]];
657 120 simont
`endif
658
 
659
`ifdef OC8051_TC2
660 117 simont
      `OC8051_SFR_B_T2CON: bit_out <= #1 t2con[adr0[2:0]];
661 120 simont
`endif
662
 
663 117 simont
      default:             bit_out <= #1 1'b0;
664
    endcase
665
end
666
 
667 120 simont
always @(posedge clk or posedge rst)
668
begin
669
  if (rst) begin
670
    prescaler <= #1 4'h0;
671
    pres_ow <= #1 1'b0;
672
  end else if (prescaler==4'b1011) begin
673
    prescaler <= #1 4'h0;
674
    pres_ow <= #1 1'b1;
675
  end else begin
676
    prescaler <= #1 prescaler + 4'h1;
677
    pres_ow <= #1 1'b0;
678
  end
679
end
680 117 simont
 
681 75 simont
endmodule

powered by: WebSVN 2.1.0

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