Sha256: 90bcb3a840371cf635e33ecac50f289b3e09b51c945575f5da733118270b75c7

Contents?: true

Size: 803 Bytes

Versions: 2

Compression:

Stored size: 803 Bytes

Contents

module <%= @namespace %>
  module Test
    # This is a dummy DUT class that should be used to test that your test module can
    # integrate into a top-level app
    class DUT
      include Origen::TopLevel

      def initialize(options = {})
        instantiate_pins(options)
        instantiate_sub_blocks(options)
      end

      def instantiate_pins(options)
        add_pin :tclk
        add_pin :tdi
        add_pin :tdo
        add_pin :tms
        add_pin :resetb
      end

      def instantiate_sub_blocks(options)
        sub_block :arm_debug, class_name: 'OrigenARMDebug::Driver', aps: { mem_ap: 0x0, mdmap: 0x0100_0000 }
        sub_block :<%= options[:sub_block_name] %>, class_name: '<%= @namespace %>::<%= options[:class_name] %>', base_address: 0x1000_0000
      end
    end
  end
end

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
origen_app_generators-0.3.1 templates/app_generators/test_engineering/test_block/lib/test/dut.rb
origen_app_generators-0.3.0 templates/app_generators/test_engineering/test_block/lib/test/dut.rb