Sha256: 970300594a8ac7b71b00d6ed39374802b3093dfb6189b477539d5c8b04a1cc91

Contents?: true

Size: 858 Bytes

Versions: 18

Compression:

Stored size: 858 Bytes

Contents

module Origen
  module Tester
    class JLink < CommandBasedTester
      def initialize
        super
        # The minimum time unit is 1ms
        set_timeset('default', 1_000_000)
        @pat_extension = 'jlk'
        @comment_char = '//'
      end

      def delay(cycles)
        microcode "Sleep #{cycles_to_ms(cycles)}"
      end

      def write_byte(address, data)
        microcode "w1 0x#{address.to_s(16).upcase}, 0x#{data.to_s(16).upcase}"
      end

      def write_word(address, data)
        microcode "w2 0x#{address.to_s(16).upcase}, 0x#{data.to_s(16).upcase}"
      end

      def write_longword(address, data)
        microcode "w4 0x#{address.to_s(16).upcase}, 0x#{data.to_s(16).upcase}"
      end

      def read(address, number_of_regs = 1)
        microcode "mem 0x#{address.to_s(16)}, #{number_of_regs}"
      end
    end
  end
end

Version data entries

18 entries across 18 versions & 1 rubygems

Version Path
origen-0.2.6 lib/origen/tester/jlink/jlink.rb
origen-0.2.5 lib/origen/tester/jlink/jlink.rb
origen-0.2.4 lib/origen/tester/jlink/jlink.rb
origen-0.2.3 lib/origen/tester/jlink/jlink.rb
origen-0.2.2 lib/origen/tester/jlink/jlink.rb
origen-0.2.1 lib/origen/tester/jlink/jlink.rb
origen-0.2.0 lib/origen/tester/jlink/jlink.rb
origen-0.1.3 lib/origen/tester/jlink/jlink.rb
origen-0.1.2 lib/origen/tester/jlink/jlink.rb
origen-0.1.1 lib/origen/tester/jlink/jlink.rb
origen-0.1.0 lib/origen/tester/jlink/jlink.rb
origen-0.0.9 lib/origen/tester/jlink/jlink.rb
origen-0.0.8 lib/origen/tester/jlink/jlink.rb
origen-0.0.6 lib/origen/tester/jlink/jlink.rb
origen-0.0.5 lib/origen/tester/jlink/jlink.rb
origen-0.0.4 lib/origen/tester/jlink/jlink.rb
origen-0.0.3 lib/origen/tester/jlink/jlink.rb
origen-0.0.2 lib/origen/tester/jlink/jlink.rb