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

Subversion Repositories vhld_tb

[/] [vhld_tb/] [trunk/] [examples/] [example1/] [vhdl/] [example_dut_tb_bhv.vhd] - Blame information for rev 17

Details | Compare with Previous | View Log

Line No. Rev Author Line
1 5 sckoarn
-- this file generated from template by ttb_gen
2
 
3
architecture bhv of example_dut_tb is
4
 
5
 
6
 
7
  signal tb_clk            : std_logic;
8
 
9
-------------------------------------------------------------------------
10
-- Component defintion
11
 
12
-------------------------------------------------------------------------------
13
-- USER Component instantiations
14
--for all: Arbitor      use entity tb_objects.arbitor(bhv);
15
 
16
 
17
  begin
18
 
19
-------------------------------------------------------------------------------
20
-- clock driver process
21
-- the main clock generator
22
clock_driver:
23
  process
24
  begin
25
    tb_clk <=  '0';
26
    wait for 5 ns;
27
    tb_clk <=  '1';
28
    wait for 5 ns;
29
  end process clock_driver;
30
 
31
 
32
  ex_clk_in  <=  tb_clk;
33
 
34
  --------------------------------------------------------------------------
35
  -- Read_file Process:
36
  --
37
  -- This process is the main process of the testbench.  This process reads
38
  -- the stumulus file, parses it, creates lists of records, then uses these
39
  -- lists to exicute user instructions.  There are two passes through the
40
  -- script.  Pass one reads in the stimulus text file, checks it, creates
41
  -- lists of valid instructions, valid list of variables and finialy a list
42
  -- of user instructions(the sequence).  The second pass through the file,
43
  -- records are drawn from the user instruction list, variables are converted
44
  -- to integers and put through the elsif structure for exicution.
45
  --------------------------------------------------------------------------
46
  Read_file: process
47
    variable current_line : text_line;  -- The current input line
48
    variable inst_list    : inst_def_ptr;  -- the instruction list
49
    variable defined_vars : var_field_ptr; -- defined variables
50
    variable inst_sequ    : stim_line_ptr; -- the instruction sequence
51 9 sckoarn
    variable file_list    : file_def_ptr;  -- pointer to the list of file names
52 17 sckoarn
    variable last_sequ_num: integer;
53
    variable last_sequ_ptr: stim_line_ptr;
54 5 sckoarn
 
55
    variable instruction  : text_field;   -- instruction field
56
    variable par1         : integer;      -- paramiter 1
57
    variable par2         : integer;      -- paramiter 2
58
    variable par3         : integer;      -- paramiter 3
59
    variable par4         : integer;      -- paramiter 4
60
    variable par5         : integer;      -- paramiter 5
61
    variable par6         : integer;      -- paramiter 6
62
    variable txt          : stm_text_ptr;
63
    variable nbase        : base;         -- the number base to use
64
    variable len          : integer;      -- length of the instruction field
65
    variable file_line    : integer;      -- Line number in the stimulus file
66
    variable file_name    : text_line;    -- the file name the line came from
67
    variable v_line       : integer := 0; -- sequence number
68
    variable stack        : stack_register; -- Call stack
69
    variable stack_ptr    : integer  := 0;  -- call stack pointer
70
    variable wh_stack     : stack_register; -- while stack
71
    variable wh_dpth      : integer := 0;   -- while depth
72
    variable wh_ptr       : integer  := 0;  -- while pointer
73
    variable loop_num         : integer := 0;
74
    variable curr_loop_count  : int_array := (others => 0);
75
    variable term_loop_count  : int_array := (others => 0);
76
    variable loop_line        : int_array := (others => 0);
77
 
78
    variable messages     : boolean  := TRUE;
79
    variable if_state     : boolean  := FALSE;
80
    variable wh_state     : boolean  := FALSE;
81
    variable wh_end       : boolean  := FALSE;
82
    variable rand         : std_logic_vector(31 downto 0);
83
    variable rand_back    : std_logic_vector(31 downto 0);
84
 
85
    variable temp_int     : integer;
86
    variable temp_index   : integer;
87
    variable temp_str     : text_field;
88
    variable valid        : integer;
89
    variable v_temp_vec1  : std_logic_vector(31 downto 0);
90
    variable v_temp_vec2  : std_logic_vector(31 downto 0);
91
 
92
    variable v_read_data  : std_logic_vector(31 downto 0);
93
    --------------------------------------------------------------------------
94
    --  Area for Procedures which may be usefull to more than one instruction.
95
    --    By coding here commonly used  code sections ...
96
    --    you know the benifits.
97
    ---------------------------------------------------------------------
98
    -----------------------------------------------------------------
99
    -- This procedure writes to the arbitor model access port
100
--    procedure arb_write(add: in integer; .....
101
--    end arb_write;
102
 
103
 
104
  begin  -- process Read_file
105
 
106
    ex_reset_n <=  '1';
107
--    ex_clk_in  <=  '0';
108
    stm_add    <=  (others => 'Z');
109
    stm_dat    <=  (others => 'Z');
110
    stm_rwn    <=  '1';
111
    stm_req_n  <=  '1';
112
 
113
    -----------------------------------------------------------------------
114
    --           Stimulus file instruction definition
115
    --  This is where the instructions used in the stimulus file are defined.
116
    --  Syntax is
117
    --     define_instruction(inst_def_ptr, instruction, paramiters)
118
    --           inst_def_ptr: is a record pointer defined in tb_pkg_header
119
    --           instruction:  the text instruction name  ie. "DEFINE_VAR"
120
    --           paramiters:   the number of fields or paramiters passed
121
    --
122
    --  Some basic instruction are created here, the user should create new
123
    --  instructions below the standard ones.
124
    ------------------------------------------------------------------------
125
    define_instruction(inst_list, "DEFINE_VAR", 2);  -- Define a Variable
126
    define_instruction(inst_list, "EQU_VAR", 2);
127
    define_instruction(inst_list, "ADD_VAR", 2);
128
    define_instruction(inst_list, "SUB_VAR", 2);
129
    define_instruction(inst_list, "CALL", 1);
130
    define_instruction(inst_list, "RETURN_CALL", 0);
131
    define_instruction(inst_list, "JUMP", 1);
132
    define_instruction(inst_list, "LOOP", 1);
133
    define_instruction(inst_list, "END_LOOP", 0);
134
    define_instruction(inst_list, "IF", 3);
135
    define_instruction(inst_list, "ELSE", 0);
136 9 sckoarn
    define_instruction(inst_list, "ELSEIF", 3);
137 5 sckoarn
    define_instruction(inst_list, "END_IF", 0);
138
    define_instruction(inst_list, "WHILE", 3);
139
    define_instruction(inst_list, "END_WHILE", 0);
140
    define_instruction(inst_list, "MESSAGES_OFF", 0);
141
    define_instruction(inst_list, "MESSAGES_ON", 0);
142
    define_instruction(inst_list, "ABORT", 0);       -- Error exit from sim
143
    define_instruction(inst_list, "FINISH", 0);      -- Normal exit from sim
144
    define_instruction(inst_list, "INCLUDE", 1);  -- Define a Variable
145
 
146
    --  User defined instructions
147
    define_instruction(inst_list, "RESET_SYS", 0);
148
    define_instruction(inst_list, "READ_PINS", 1);
149
    define_instruction(inst_list, "WRITE_DUT", 2);
150
    define_instruction(inst_list, "VERIFY", 1);
151
 
152
 
153
    ------------------------------------------------------------------------
154
    -- Read, test, and load the stimulus file
155 9 sckoarn
    read_instruction_file(stimulus_file, inst_list, defined_vars, inst_sequ,
156
                          file_list);
157 17 sckoarn
 
158
    -- initialize last info
159
    last_sequ_num  := 0;
160
    last_sequ_ptr  := inst_sequ;
161 5 sckoarn
 
162
------------------------------------------------------------------------
163
-- Using the Instruction record list, get the instruction and implement
164
-- it as per the statements in the elsif tree.
165
  while(v_line < inst_sequ.num_of_lines) loop
166
    v_line := v_line + 1;
167 9 sckoarn
    access_inst_sequ(inst_sequ, defined_vars, file_list, v_line, instruction,
168 17 sckoarn
         par1, par2, par3, par4, par5, par6, txt, len, file_name, file_line,
169
         last_sequ_num, last_sequ_ptr);
170 5 sckoarn
 
171
--------------------------------------------------------------------------
172
    if(instruction(1 to len) = "DEFINE_VAR") then
173
      null;  -- This instruction was implemented while reading the file
174
 
175
--------------------------------------------------------------------------
176
    elsif(instruction(1 to len) = "INCLUDE") then
177
      null;  -- This instruction was implemented while reading the file
178
 
179
--------------------------------------------------------------------------
180
    elsif(instruction(1 to len) = "ABORT") then
181
      assert (false)
182
        report "The test has aborted due to an error!!"
183
      severity failure;
184
 
185
--------------------------------------------------------------------------
186
    elsif(instruction(1 to len) = "FINISH") then
187
      assert (false)
188
        report "Test Finished with NO errors!!"
189
      severity failure;
190
 
191
--------------------------------------------------------------------------
192
    elsif(instruction(1 to len) = "EQU_VAR") then
193
      update_variable(defined_vars, par1, par2, valid);
194
 
195
--------------------------------------------------------------------------
196
    elsif(instruction(1 to len) = "ADD_VAR") then
197
      index_variable(defined_vars, par1, temp_int, valid);
198
      if(valid /= 0) then
199
        temp_int  :=  temp_int + par2;
200
        update_variable(defined_vars, par1, temp_int, valid);
201
      else
202
        assert (false)
203
          report "ADD_VAR Error: Not a valid Variable??"
204
        severity failure;
205
      end if;
206
 
207
--------------------------------------------------------------------------
208
    elsif(instruction(1 to len) = "SUB_VAR") then
209
      index_variable(defined_vars, par1, temp_int, valid);
210
      if(valid /= 0) then
211
        temp_int  :=  temp_int - par2;
212
        update_variable(defined_vars, par1, temp_int, valid);
213
      else
214
        assert (false)
215
          report "SUB_VAR Error: Not a valid Variable??"
216
        severity failure;
217
      end if;
218
 
219
--------------------------------------------------------------------------
220
    elsif(instruction(1 to len) = "CALL") then
221
      if(stack_ptr >= 7) then
222
        assert (false)
223
          report "Call Error: Stack over run, calls to deeply nested!!"
224
        severity failure;
225
      end if;
226
      stack(stack_ptr)  :=  v_line;
227
      stack_ptr  :=  stack_ptr + 1;
228
      v_line       :=  par1 - 1;
229
 
230
--------------------------------------------------------------------------
231
    elsif(instruction(1 to len) = "RETURN_CALL") then
232
      if(stack_ptr <= 0) then
233
        assert (false)
234
          report "Call Error: Stack under run??"
235
        severity failure;
236
      end if;
237
      stack_ptr  :=  stack_ptr - 1;
238
      v_line  :=  stack(stack_ptr);
239
 
240
--------------------------------------------------------------------------
241
    elsif(instruction(1 to len) = "JUMP") then
242
      v_line    :=  par1 - 1;
243
      wh_state  :=  false;
244
      wh_stack  := (others => 0);
245
      wh_dpth   := 0;
246
      wh_ptr    := 0;
247
      stack     := (others => 0);
248
      stack_ptr := 0;
249
 
250
--------------------------------------------------------------------------------
251
     elsif (instruction(1 to len) = "LOOP") then
252
        loop_num := loop_num + 1;
253
        loop_line(loop_num) := v_line;
254
        curr_loop_count(loop_num) := 0;
255
        term_loop_count(loop_num) := par1;
256
        assert (messages)
257
          report LF & "Executing LOOP Command" &
258
                 LF & "  Nested Loop:" & HT & integer'image(loop_num) &
259
                 LF & "  Loop Length:" & HT & integer'image(par1)
260
          severity note;
261
 
262
--------------------------------------------------------------------------------
263
     elsif (instruction(1 to len) = "END_LOOP") then
264
        curr_loop_count(loop_num) := curr_loop_count(loop_num) + 1;
265
        if (curr_loop_count(loop_num) = term_loop_count(loop_num)) then
266
          loop_num := loop_num - 1;
267
        else
268
          v_line := loop_line(loop_num);
269
        end if;
270
 
271
--------------------------------------------------------------------------------
272
     elsif (instruction(1 to len) = "IF") then
273
       if_state  :=  false;
274
       case par2 is
275
         when 0 => if(par1 = par3) then if_state  :=  true; end if;
276
         when 1 => if(par1 > par3) then if_state  :=  true; end if;
277
         when 2 => if(par1 < par3) then if_state  :=  true; end if;
278
         when 3 => if(par1 /= par3) then if_state :=  true; end if;
279
         when 4 => if(par1 >= par3) then if_state :=  true; end if;
280
         when 5 => if(par1 <= par3) then if_state :=  true; end if;
281
         when others =>
282
           assert (false)
283
             report LF & "ERROR:  IF instruction got an unexpected value" &
284
                 LF & "  in parameter 2!" & LF &
285
                  "Found on line " & (ew_to_str(file_line,dec)) & " in file " & file_name
286
             severity failure;
287
       end case;
288
 
289
       if(if_state = false) then
290
         v_line := v_line + 1;
291 17 sckoarn
         access_inst_sequ(inst_sequ, defined_vars, file_list, v_line, instruction,
292
             par1, par2, par3, par4, par5, par6, txt, len, file_name, file_line,
293
             last_sequ_num, last_sequ_ptr);
294 5 sckoarn
         while(instruction(1 to len) /= "ELSE" and
295
               instruction(1 to len) /= "ELSEIF" and
296
               instruction(1 to len) /= "END_IF") loop
297
           if(v_line < inst_sequ.num_of_lines) then
298
             v_line := v_line + 1;
299 17 sckoarn
             access_inst_sequ(inst_sequ, defined_vars, file_list, v_line, instruction,
300
                 par1, par2, par3, par4, par5, par6, txt, len, file_name, file_line,
301
                 last_sequ_num, last_sequ_ptr);
302 5 sckoarn
           else
303
             assert (false)
304
              report LF & "ERROR:  IF instruction unable to find terminating" &
305
                     LF & "    ELSE, ELSEIF or END_IF statement."
306
              severity failure;
307
           end if;
308
         end loop;
309
         v_line := v_line - 1;  -- re-align so it will be operated on.
310
       end if;
311
 
312
--------------------------------------------------------------------------------
313
     elsif (instruction(1 to len) = "ELSEIF") then
314
       if(if_state = true) then  -- if the if_state is true then skip to the end
315
         v_line := v_line + 1;
316 17 sckoarn
         access_inst_sequ(inst_sequ, defined_vars, file_list, v_line, instruction,
317
             par1, par2, par3, par4, par5, par6, txt, len, file_name, file_line,
318
             last_sequ_num, last_sequ_ptr);
319 5 sckoarn
         while(instruction(1 to len) /= "END_IF") loop
320
           if(v_line < inst_sequ.num_of_lines) then
321
             v_line := v_line + 1;
322 17 sckoarn
             access_inst_sequ(inst_sequ, defined_vars, file_list, v_line, instruction,
323
                 par1, par2, par3, par4, par5, par6, txt, len, file_name, file_line,
324
                 last_sequ_num, last_sequ_ptr);
325 5 sckoarn
           else
326
             assert (false)
327
              report LF & "ERROR:  IF instruction unable to find terminating" &
328
                     LF & "    ELSE, ELSEIF or END_IF statement."
329
              severity failure;
330
           end if;
331
         end loop;
332
         v_line := v_line - 1;  -- re-align so it will be operated on.
333
 
334
       else
335
         case par2 is
336
           when 0 => if(par1 = par3) then if_state  :=  true; end if;
337
           when 1 => if(par1 > par3) then if_state  :=  true; end if;
338
           when 2 => if(par1 < par3) then if_state  :=  true; end if;
339
           when 3 => if(par1 /= par3) then if_state :=  true; end if;
340
           when 4 => if(par1 >= par3) then if_state :=  true; end if;
341
           when 5 => if(par1 <= par3) then if_state :=  true; end if;
342
           when others =>
343
             assert (false)
344
               report LF & "ERROR:  ELSEIF instruction got an unexpected value" &
345
                   LF & "  in parameter 2!" & LF &
346
                    "Found on line " & (ew_to_str(file_line,dec)) & " in file " & file_name
347
               severity failure;
348
         end case;
349
 
350
         if(if_state = false) then
351
           v_line := v_line + 1;
352 17 sckoarn
           access_inst_sequ(inst_sequ, defined_vars, file_list, v_line, instruction,
353
               par1, par2, par3, par4, par5, par6, txt, len, file_name, file_line,
354
               last_sequ_num, last_sequ_ptr);
355 5 sckoarn
           while(instruction(1 to len) /= "ELSE" and
356
                 instruction(1 to len) /= "ELSEIF" and
357
                 instruction(1 to len) /= "END_IF") loop
358
             if(v_line < inst_sequ.num_of_lines) then
359
               v_line := v_line + 1;
360 17 sckoarn
               access_inst_sequ(inst_sequ, defined_vars, file_list, v_line, instruction,
361
                   par1, par2, par3, par4, par5, par6, txt, len, file_name, file_line,
362
                   last_sequ_num, last_sequ_ptr);
363 5 sckoarn
             else
364
               assert (false)
365
                report LF & "ERROR:  ELSEIF instruction unable to find terminating" &
366
                       LF & "    ELSE, ELSEIF or END_IF statement."
367
                severity failure;
368
             end if;
369
           end loop;
370
           v_line := v_line - 1;  -- re-align so it will be operated on.
371
         end if;
372
       end if;
373
 
374
--------------------------------------------------------------------------------
375
     elsif (instruction(1 to len) = "ELSE") then
376
       if(if_state = true) then  -- if the if_state is true then skip the else
377
         v_line := v_line + 1;
378 17 sckoarn
         access_inst_sequ(inst_sequ, defined_vars, file_list, v_line, instruction,
379
             par1, par2, par3, par4, par5, par6, txt, len, file_name, file_line,
380
             last_sequ_num, last_sequ_ptr);
381 5 sckoarn
         while(instruction(1 to len) /= "END_IF") loop
382
           if(v_line < inst_sequ.num_of_lines) then
383
             v_line := v_line + 1;
384 17 sckoarn
             access_inst_sequ(inst_sequ, defined_vars, file_list, v_line, instruction,
385
                 par1, par2, par3, par4, par5, par6, txt, len, file_name, file_line,
386
                 last_sequ_num, last_sequ_ptr);
387 5 sckoarn
           else
388
             assert (false)
389
              report LF & "ERROR:  IF instruction unable to find terminating" &
390
                     LF & "    ELSE, ELSEIF or END_IF statement."
391
              severity failure;
392
           end if;
393
         end loop;
394
         v_line := v_line - 1;  -- re-align so it will be operated on.
395
       end if;
396
 
397
--------------------------------------------------------------------------------
398
     elsif (instruction(1 to len) = "END_IF") then
399
       null;  -- instruction is a place holder for finding the end of IF.
400
 
401
--------------------------------------------------------------------------------
402
     elsif (instruction(1 to len) = "WHILE") then
403
       wh_state  :=  false;
404
       case par2 is
405
         when 0 => if(par1 = par3) then if_state  :=  true; end if;
406
         when 1 => if(par1 > par3) then if_state  :=  true; end if;
407
         when 2 => if(par1 < par3) then if_state  :=  true; end if;
408
         when 3 => if(par1 /= par3) then if_state :=  true; end if;
409
         when 4 => if(par1 >= par3) then if_state :=  true; end if;
410
         when 5 => if(par1 <= par3) then if_state :=  true; end if;
411
         when others =>
412
           assert (false)
413
             report LF & "ERROR:  WHILE instruction got an unexpected value" &
414
                 LF & "  in parameter 2!" & LF &
415
                  "Found on line " & (ew_to_str(file_line,dec)) & " in file " & file_name
416
             severity failure;
417
       end case;
418
 
419
       if(wh_state = true) then
420
         wh_stack(wh_ptr) :=  v_line;
421
         wh_ptr  := wh_ptr + 1;
422
       else
423
         wh_end := false;
424
         while(wh_end /= true) loop
425
           if(v_line < inst_sequ.num_of_lines) then
426
             v_line := v_line + 1;
427 17 sckoarn
             access_inst_sequ(inst_sequ, defined_vars, file_list, v_line, instruction,
428
                 par1, par2, par3, par4, par5, par6, txt, len, file_name, file_line,
429
                 last_sequ_num, last_sequ_ptr);
430 5 sckoarn
           else
431
             assert (false)
432
               report LF & "ERROR:  WHILE instruction unable to find terminating" &
433
                      LF & "    END_WHILE statement."
434
             severity failure;
435
           end if;
436
 
437
           -- if is a while need to escape it
438
           if(instruction(1 to len) = "WHILE") then
439
             wh_dpth := wh_dpth + 1;
440
           -- if is the end_while we are looking for
441
           elsif(instruction(1 to len) = "END_WHILE") then
442
             if(wh_dpth = 0) then
443
               wh_end := true;
444
             else
445
               wh_dpth := wh_dpth - 1;
446
             end if;
447
           end if;
448
         end loop;
449
       end if;
450
 
451
--------------------------------------------------------------------------------
452
     elsif (instruction(1 to len) = "END_WHILE") then
453
       if(wh_ptr > 0) then
454
         v_line  :=  wh_stack(wh_ptr - 1) - 1;
455
         wh_ptr  := wh_ptr - 1;
456
       end if;
457
 
458
--------------------------------------------------------------------------------
459
     elsif (instruction(1 to len) = "MESSAGES_OFF") then
460
       messages  := TRUE;
461
--------------------------------------------------------------------------------
462
     elsif (instruction(1 to len) = "MESSAGES_ON") then
463
       messages  := FALSE;
464
 
465
 
466
--------------------------------------------------------------------------------
467
--------------------------------------------------------------------------------
468
--  USER Istruction area.  Add all user instructions below this
469
--------------------------------------------------------------------------------
470
--------------------------------------------------------------------------------
471
    elsif (instruction(1 to len) = "RESET_SYS") then
472
      wait until tb_clk'event and tb_clk = '1';
473
      EX_RESET_N  <=  '0';
474
      wait until tb_clk'event and tb_clk = '1';
475
      wait until tb_clk'event and tb_clk = '1';
476
      EX_RESET_N  <=  '1';
477
      wait for 0 ns;
478
 
479
--------------------------------------------------------------------------------
480
--  READ_PINS
481
--    read one of the two output interfaces on the dut, put value in read_data
482
--  par1  0  read port1
483
--        1  read port2
484
    elsif (instruction(1 to len) = "READ_PINS") then
485
      if(par1 = 0) then
486
        v_read_data :=  EX_DATA1;
487
      elsif(par1 = 1) then
488
        v_read_data :=  EX_DATA2;
489
      else
490
        assert (false)
491
          report LF & "Out of range message" & LF
492
        severity error;
493
      end if;
494
 
495
--------------------------------------------------------------------------------
496
--  VERIFY
497
--    par1  Data to compare
498
    elsif (instruction(1 to len) = "VERIFY") then
499
      v_temp_vec1  :=   std_logic_vector(conv_unsigned(par1, 32));
500
   --   if (sim_halt = '1') then
501
        assert (v_temp_vec1 = v_read_data)
502
          report "VERIFY instruction found missmatch!" & LF &
503
                 "Expected data = " & to_hstring(v_temp_vec1) & LF &
504
                 "Read   data     = " & to_hstring(v_read_data) & LF &
505
                 "Found on line " & (integer'image(file_line)) & " in file " & file_name
506
          severity failure;
507
 
508
   --   else
509
   --     assert (v_temp_vec1 = v_read_data)
510
   --       report "VERIFY instruction found missmatch!" & LF &
511
   --              "Expected data = " & to_hstring(v_temp_vec1) & LF &
512
   --              "Read   data     = " & to_hstring(v_read_data) & LF &
513
   --              "Found on line " & (integer'image(file_line)) & " in file " & file_name
514
   --       severity error;
515
   --   end if;
516
 
517
--------------------------------------------------------------------------------
518
--  PCI_WRITE
519
--    par1  address
520
--    par2  data
521
--  This instruction I use for accessing models.  which is the interface
522
--   on the example dut.  I use that interface as a stimulus access port.
523
    elsif (instruction(1 to len) = "WRITE_DUT") then
524
      stm_add    <=  std_logic_vector(conv_unsigned(par1,32));
525
      stm_dat    <=  std_logic_vector(conv_unsigned(par2,32));
526
      stm_req_n  <=  '0';
527
      stm_rwn    <=  '0';
528
      wait until stm_ack_n'event and stm_ack_n = '0';
529
      stm_req_n  <=  '1';
530
      wait until stm_ack_n'event and stm_ack_n = '1';
531
      stm_add   <=  (others => 'Z');
532
      stm_dat   <=  (others => 'Z');
533
      stm_rwn   <=  '1';
534
      wait for 0 ns;
535
 
536
 
537
--------------------------------------------------------------------------------
538
--  USER Istruction area.  Add all user instructions above this
539
--------------------------------------------------------------------------------
540
    --------------------------------------------------------------------------
541
    -- catch those little mistakes
542
    else
543
      assert (false)
544
        report LF & "ERROR:  Seems the command " & instruction(1 to len) & " was defined" & LF &
545
                    "but not found in the elsif chain, please check the spelling."
546
        severity failure;
547
    end if;  -- else if structure end
548
    txt_print_wvar(defined_vars, txt, hex);
549
  end loop;  -- Main Loop end
550
 
551
  assert (false)
552
    report LF & "The end of the simulation! It was not terminated as expected." & LF
553
  severity failure;
554
 
555
  end process Read_file;
556
 
557
 
558
end bhv;
559
 

powered by: WebSVN 2.1.0

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