Class: Origen::Tester::CommandBasedTester
- Inherits:
-
Object
- Object
- Origen::Tester::CommandBasedTester
- Includes:
- Origen::Tester
- Defined in:
- lib/origen/tester/command_based_tester.rb
Overview
A base class that can be used to model command-based, rather than vector-based testers.
Instance Method Summary (collapse)
-
- (Object) call_subroutine(sub)
Concept of a subroutine not supported, print out an error to the output file to alert the user that execution has hit code that is not compatible with a command based tester.
-
- (Object) cycle(*_args)
Concept of a cycle not supported, print out an error to the output file to alert the user that execution has hit code that is not compatible with a command based tester.
-
- (Object) direct_write(str)
(also: #dw)
Write a string directly to the output file without being processed or modified in any way.
- - (Object) format_vector(vec)
-
- (CommandBasedTester) initialize
constructor
A new instance of CommandBasedTester.
-
- (Object) loop(_name = nil, number_of_loops)
(also: #loop_vector)
Loop the content embedded in the supplied block.
Constructor Details
- (CommandBasedTester) initialize
Returns a new instance of CommandBasedTester
8 9 10 |
# File 'lib/origen/tester/command_based_tester.rb', line 8 def initialize @vector_based = false end |
Instance Method Details
- (Object) call_subroutine(sub)
Concept of a subroutine not supported, print out an error to the output file to alert the user that execution has hit code that is not compatible with a command based tester.
29 30 31 |
# File 'lib/origen/tester/command_based_tester.rb', line 29 def call_subroutine(sub) microcode "Call_subroutine called to #{sub}" end |
- (Object) cycle(*_args)
Concept of a cycle not supported, print out an error to the output file to alert the user that execution has hit code that is not compatible with a command based tester.
22 23 24 |
# File 'lib/origen/tester/command_based_tester.rb', line 22 def cycle(*_args) microcode '*** Cycle called ***' end |
- (Object) direct_write(str) Also known as: dw
Write a string directly to the output file without being processed or modified in any way
14 15 16 |
# File 'lib/origen/tester/command_based_tester.rb', line 14 def direct_write(str) microcode str end |
- (Object) format_vector(vec)
33 34 35 |
# File 'lib/origen/tester/command_based_tester.rb', line 33 def format_vector(vec) vec.microcode end |
- (Object) loop(_name = nil, number_of_loops) Also known as: loop_vector
Loop the content embedded in the supplied block
38 39 40 41 42 |
# File 'lib/origen/tester/command_based_tester.rb', line 38 def loop(_name = nil, number_of_loops) number_of_loops.times do yield end end |