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

Subversion Repositories socgen

[/] [socgen/] [trunk/] [Projects/] [opencores.org/] [wishbone/] [ip/] [wb_uart16550/] [sim/] [icarus/] [bus16_lit_default/] [test_define] - Blame information for rev 131

Details | Compare with Previous | View Log

Line No. Rev Author Line
1 131 jt_eaton
`include  "../../testbenches/elab/wb_uart16550_bus16_lit_tb/sw/wb.v"
2
 
3
reg [31:0] d;
4
 
5
 
6
 
7
initial
8
 begin
9
 $display("              ");
10
 $display("          ===================================================");
11
 $display("%t  Test Start",$realtime  );
12
 $display("          ===================================================");
13
 $display("              ");
14
 test.cg.next(1);
15
 test.cts_pad_R  <= 1'b0;
16
 test.dcd_pad_R  <= 1'b0;
17
 test.dsr_pad_R  <= 1'b0;
18
 test.ri_pad_R   <= 1'b0;
19
 test.cg.next(8);
20
 
21
 $display("%t    out of reset  ",$realtime  );
22
 test.cg.next(88);
23
 
24
fork
25
begin
26
          test.i_wb_master.wb_write(fc_reg,2'h1,16'h00c7 );
27
          test.cg.next(20);
28
          test.i_wb_master.wb_write(ie_reg,2'h2,16'h0000 );
29
          test.cg.next(20);
30
          test.i_wb_master.wb_write(lc_reg,2'h2,16'h0300 );
31
          test.cg.next(20);
32
          test.i_wb_master.wb_write(lc_reg,2'h2,16'h8300 );
33
          test.cg.next(20);
34
          test.i_wb_master.wb_cmp(tr_reg,2'h3,16'h1234   );
35
          test.cg.next(20);
36
          test.i_wb_master.wb_write(tr_reg,2'h3,16'h000d );
37
          test.cg.next(20);
38
          test.i_wb_master.wb_cmp(tr_reg,2'h3,16'h000d );
39
          test.cg.next(20);
40
          test.i_wb_master.wb_write(lc_reg,2'h2,16'h0300 );
41
          test.cg.next(20);
42
          test.i_wb_master.wb_write(tr_reg,2'h1,16'h0048 );
43
          test.i_wb_master.wb_read(ls_reg,d );
44
          test.cg.next(10000);
45
          test.i_wb_master.wb_write(tr_reg,2'h1,16'h0065 );
46
          test.cg.next(10000);
47
          test.i_wb_master.wb_write(tr_reg,2'h1,16'h006c );
48
          test.cg.next(10000);
49
          test.i_wb_master.wb_write(tr_reg,2'h1,16'h006c );
50
          test.cg.next(10000);
51
          test.i_wb_master.wb_write(tr_reg,2'h1,16'h006f );
52
          test.cg.next(50000);
53
          test.i_wb_master.wb_cmp(tr_reg,2'h1,16'h0034 );
54
          test.cg.next(50);
55
          test.i_wb_master.wb_cmp(ie_reg,2'h2,16'h0000 );
56
          test.cg.next(50);
57
          test.i_wb_master.wb_cmp(ii_reg,2'h1,16'h00c1 );
58
          test.cg.next(50);
59
          test.i_wb_master.wb_cmp(lc_reg,2'h2,16'h0300 );
60
          test.cg.next(50);
61
          test.i_wb_master.wb_cmp(mc_reg,2'h1,16'h0000 );
62
          test.cg.next(50);
63
          test.i_wb_master.wb_cmp(ls_reg,2'h2,16'h6100 );
64
          test.cg.next(50);
65
          test.i_wb_master.wb_cmp(ms_reg,2'h1,16'h0000 );
66
          test.cg.next(50);
67
          test.i_wb_master.wb_cmp(sr_reg,2'h2,16'h0000 );
68
          test.cg.next(500);
69
          test.i_wb_master.wb_cmp(tr_reg,2'h1,16'h0043 );
70
          test.cg.next(500);
71
          test.i_wb_master.wb_cmp(tr_reg,2'h1,16'h0056 );
72
          test.cg.next(500);
73
          test.i_wb_master.wb_cmp(debug_0_reg,2'h3,16'h1060 );
74
          test.cg.next(500);
75
          test.i_wb_master.wb_cmp(debug_0_reg+2,2'h3,16'h0003 );
76
          test.cg.next(500);
77
 
78
 
79
 
80
end
81
 
82
 
83
 
84
 
85
 
86
 
87
 
88
 
89
 begin
90
 test.uart_model.rx_parity_enable  = 1'b0;
91
 test.uart_model.txd_parity_enable = 1'b0;
92
 test.uart_model.rx_parity         = 1'b1;
93
 test.uart_model.txd_parity        = 1'b1;
94
 test.cg.next(10);
95
 test.uart_model.rcv_byte(8'h48);
96
 test.uart_model.send_byte(8'h34);
97
 test.cg.next(10);
98
 test.uart_model.rcv_byte(8'h65);
99
 test.cg.next(10);
100
 test.uart_model.rcv_byte(8'h6c);
101
 test.cg.next(10);
102
 test.uart_model.rcv_byte(8'h6c);
103
 test.cg.next(10);
104
 test.uart_model.rcv_byte(8'h6f);
105
 test.cg.next(10);
106
 test.uart_model.send_byte(8'h43);
107
 test.cg.next(10);
108
 test.uart_model.send_byte(8'h56);
109
 
110
 
111
 end
112
 join
113
 test.cg.exit;
114
end
115
 
116
 
117
 
118
 
119
 
120
 
121
 
122
 
123
 

powered by: WebSVN 2.1.0

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