Class: OrigenTesters::IGXLBasedTester::Base::TimesetsBasic

Inherits:
Object
  • Object
show all
Includes:
Generator
Defined in:
lib/origen_testers/igxl_based_tester/base/timesets_basic.rb

Direct Known Subclasses

UltraFLEX::TimesetsBasic

Constant Summary collapse

OUTPUT_PREFIX =
'TSB'

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods included from Generator

#close, #collection, #collection=, #compiler, #current_dir, #dont_diff=, execute_source, #file_extension, #file_pipeline, #filename, #filename=, #identity_map, #import, #inhibit_output, #name, #on_close, original_reference_file, original_reference_file=, #output_file, #output_inhibited?, #platform, #reference_file, #render, #set_flow_description, #stats, #to_be_written?, #write_from_template, #write_to_file

Constructor Details

#initialize(options = {}) ⇒ TimesetsBasic

OUTPUT_POSTFIX = 'TS'


14
15
16
17
# File 'lib/origen_testers/igxl_based_tester/base/timesets_basic.rb', line 14

def initialize(options = {}) # :nodoc:
  @ts       = {}
  @ts_basic = options[:timeset_basic]
end

Instance Attribute Details

#tsObject

Returns the value of attribute ts.


7
8
9
# File 'lib/origen_testers/igxl_based_tester/base/timesets_basic.rb', line 7

def ts
  @ts
end

#ts_basicObject

Returns the value of attribute ts_basic.


9
10
11
# File 'lib/origen_testers/igxl_based_tester/base/timesets_basic.rb', line 9

def ts_basic
  @ts_basic
end

#ts_sheet_pinsObject

Returns the value of attribute ts_sheet_pins.


8
9
10
# File 'lib/origen_testers/igxl_based_tester/base/timesets_basic.rb', line 8

def ts_sheet_pins
  @ts_sheet_pins
end

Instance Method Details

#add(tsname, pin, esname, options = {}) ⇒ Object


19
20
21
22
23
24
25
26
# File 'lib/origen_testers/igxl_based_tester/base/timesets_basic.rb', line 19

def add(tsname, pin, esname, options = {})
  tsname = tsname.to_sym unless tsname.is_a? Symbol
  pin = pin.to_sym unless pin.is_a? Symbol
  esname = pin.to_sym unless esname.is_a? Symbol
  @ts.key?(tsname) ? @ts[tsname].add_edge(pin, esname) : @ts[tsname] = platform::Timeset.new(tsname, pin, esname, options)
  @ts_sheet_pins = options[:ts_sheet_pins] unless @ts_sheet_pins
  @ts[tsname]
end

#finalize(options = {}) ⇒ Object


28
29
# File 'lib/origen_testers/igxl_based_tester/base/timesets_basic.rb', line 28

def finalize(options = {})
end

#get_pin_objects(grp) ⇒ Object

Populate an array of pins based on the pin or pingroup


32
33
34
35
36
37
38
39
40
41
42
43
44
45
# File 'lib/origen_testers/igxl_based_tester/base/timesets_basic.rb', line 32

def get_pin_objects(grp)
  pins = []
  if Origen.top_level.pin(grp).is_a?(Origen::Pins::Pin) ||
     Origen.top_level.pin(grp).is_a?(Origen::Pins::FunctionProxy)
    pins << Origen.top_level.pin(grp)
  elsif Origen.top_level.pin(grp).is_a?(Origen::Pins::PinCollection)
    Origen.top_level.pin(grp).each do |pin|
      pins << pin
    end
  else
    Origen.log.error "Could not find pin class: #{grp}  #{Origen.top_level.pin(grp).class}"
  end
  pins
end