origen_testers 0.51.3 → 0.51.5
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/config/version.rb +1 -1
- data/lib/origen_testers/decompiler/nodes.rb +1 -1
- data/lib/origen_testers/igxl_based_tester/decompiler/atp.rb +2 -0
- data/lib/origen_testers/igxl_based_tester/decompiler.rb +1 -1
- data/lib/origen_testers/stil_based_tester/base.rb +111 -33
- data/templates/origen_guides/pattern/stil.md.erb +17 -0
- metadata +3 -3
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: a180bdac7bac206de7e54920fe663e70d1a2385d719a4a2ee134168856926142
|
4
|
+
data.tar.gz: 1882b6db742cdcb8f4a05a2a5f2d14c8bf0edcbee5e2ad65cff473a4a0ebefb7
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 1dc6ab272a3770ee8351f0b1fad2d17cc41fa1a0abf5fe3df4f0d7caba4aea82551fe2719dae4bb676c2080af4c0327e12d2682afd288db50f5f9bbad44a392e
|
7
|
+
data.tar.gz: 1be16fa7b79f24afeb21d59713c66134917922d19a4534e611bc9a153cdf10911e3a96c9a066928a30db3850ee26084dd9655065d388f5bcdf9102f00cef778c
|
data/config/version.rb
CHANGED
@@ -33,6 +33,8 @@ module OrigenTesters
|
|
33
33
|
imports[val.gsub(';', '')] = type
|
34
34
|
elsif l.strip.empty?
|
35
35
|
# Just whitespace. Ignore this, but don't throw an error
|
36
|
+
elsif !(l =~ Regexp.new(/vector/)).nil?
|
37
|
+
# line break between vector keyword and pinlist, ignore
|
36
38
|
else
|
37
39
|
Origen.app!.fail!("Unable to parse pattern frontmatter, at line: #{i}")
|
38
40
|
end
|
@@ -15,6 +15,7 @@ module OrigenTesters
|
|
15
15
|
@min_repeat_loop = 2
|
16
16
|
@pat_extension = 'stil'
|
17
17
|
@compress = true
|
18
|
+
@use_timing_equations = options[:use_timing_equations]
|
18
19
|
|
19
20
|
# @support_repeat_previous = true
|
20
21
|
@match_entries = 10
|
@@ -30,6 +31,32 @@ module OrigenTesters
|
|
30
31
|
true
|
31
32
|
end
|
32
33
|
|
34
|
+
# returns the orderd pins with groups decomposed into individual pins
|
35
|
+
def flattened_ordered_pins
|
36
|
+
if @flattened_ordered_pins.nil?
|
37
|
+
@flattened_ordered_pins = []
|
38
|
+
ordered_pins.each do |p|
|
39
|
+
if p.is_a?(Origen::Pins::PinCollection)
|
40
|
+
p.each { |ip| @flattened_ordered_pins << ip }
|
41
|
+
else
|
42
|
+
@flattened_ordered_pins << p
|
43
|
+
end
|
44
|
+
end
|
45
|
+
end
|
46
|
+
@flattened_ordered_pins
|
47
|
+
end
|
48
|
+
|
49
|
+
def output_group_definition(grp, grp_name)
|
50
|
+
line = "\"#{grp_name}\" = '"
|
51
|
+
grp.each_with_index do |pin, i|
|
52
|
+
unless i == 0
|
53
|
+
line << '+'
|
54
|
+
end
|
55
|
+
line << pin.name.to_s
|
56
|
+
end
|
57
|
+
microcode " #{line}';"
|
58
|
+
end
|
59
|
+
|
33
60
|
# An internal method called by Origen to create the pattern header
|
34
61
|
def pattern_header(options = {})
|
35
62
|
options = {
|
@@ -42,7 +69,7 @@ module OrigenTesters
|
|
42
69
|
|
43
70
|
microcode ''
|
44
71
|
microcode 'Signals {'
|
45
|
-
|
72
|
+
flattened_ordered_pins.each do |pin|
|
46
73
|
line = ''
|
47
74
|
line << "#{pin.name} "
|
48
75
|
if pin.direction == :input
|
@@ -58,22 +85,38 @@ module OrigenTesters
|
|
58
85
|
|
59
86
|
microcode ''
|
60
87
|
microcode 'SignalGroups {'
|
61
|
-
|
62
|
-
ordered_pins.
|
63
|
-
|
64
|
-
line << '+'
|
65
|
-
end
|
66
|
-
line << pin.name.to_s
|
88
|
+
# output pin group definitions used in this pattern
|
89
|
+
ordered_pins.each do |p|
|
90
|
+
output_group_definition(p, p.name.to_s) if p.is_a?(Origen::Pins::PinCollection)
|
67
91
|
end
|
68
|
-
|
92
|
+
|
93
|
+
# output the all pin group
|
94
|
+
output_group_definition(flattened_ordered_pins, "#{ordered_pins_name || 'ALL'}")
|
69
95
|
microcode '}'
|
70
96
|
|
97
|
+
# output the period category specs
|
98
|
+
if @use_timing_equations
|
99
|
+
microcode ''
|
100
|
+
microcode 'Spec {'
|
101
|
+
microcode " Category c_#{@pattern_name} {"
|
102
|
+
(@wavesets || []).each_with_index do |w, i|
|
103
|
+
microcode " period_#{w[:name]} = '#{w[:period]}ns';"
|
104
|
+
end
|
105
|
+
microcode ' }'
|
106
|
+
microcode '}'
|
107
|
+
end
|
108
|
+
|
71
109
|
microcode ''
|
72
110
|
microcode "Timing t_#{@pattern_name} {"
|
73
111
|
(@wavesets || []).each_with_index do |w, i|
|
74
112
|
microcode '' if i != 0
|
75
113
|
microcode " WaveformTable Waveset#{i + 1} {"
|
76
|
-
|
114
|
+
period_var = "period_#{w[:name]}"
|
115
|
+
if @use_timing_equations
|
116
|
+
microcode " Period '#{period_var}';"
|
117
|
+
else
|
118
|
+
microcode " Period '#{w[:period]}ns';"
|
119
|
+
end
|
77
120
|
microcode ' Waveforms {'
|
78
121
|
w[:lines].each do |line|
|
79
122
|
microcode " #{line}"
|
@@ -90,6 +133,7 @@ module OrigenTesters
|
|
90
133
|
|
91
134
|
microcode ''
|
92
135
|
microcode "PatternExec e_#{@pattern_name} {"
|
136
|
+
microcode " Category c_#{@pattern_name};" if @use_timing_equations
|
93
137
|
microcode " Timing t_#{@pattern_name};"
|
94
138
|
microcode " PatternBurst b_#{@pattern_name};"
|
95
139
|
microcode '}'
|
@@ -106,6 +150,27 @@ module OrigenTesters
|
|
106
150
|
end
|
107
151
|
|
108
152
|
def set_timeset(t, period_in_ns = nil)
|
153
|
+
# check for period size override from the app if performing convert command
|
154
|
+
if Origen.current_command == 'convert'
|
155
|
+
listeners = Origen.listeners_for(:convert_command_set_period_in_ns)
|
156
|
+
if listeners.empty?
|
157
|
+
unless @call_back_message_displayed
|
158
|
+
Origen.log.warn 'STIL output is generated using "origen convert" with no timeset period callback method defined. Default period size will be used.'
|
159
|
+
Origen.log.info 'stil tester implements a callback for setting the timeset period size when converting a pattern to stil format'
|
160
|
+
Origen.log.info 'to use the callback feature add the following define to your app in config/application.rb'
|
161
|
+
Origen.log.info ' def convert_command_set_period_in_ns(timeset_name)'
|
162
|
+
Origen.log.info ' return 25 if timeset_name == "timeset0"'
|
163
|
+
Origen.log.info ' return 30 if timeset_name == "timeset1"'
|
164
|
+
Origen.log.info ' 40'
|
165
|
+
Origen.log.info ' end'
|
166
|
+
@call_back_message_displayed = true
|
167
|
+
end
|
168
|
+
else
|
169
|
+
listeners.each do |listener|
|
170
|
+
period_in_ns = listener.convert_command_set_period_in_ns(t)
|
171
|
+
end
|
172
|
+
end
|
173
|
+
end
|
109
174
|
super
|
110
175
|
if pattern_only
|
111
176
|
# Why does D10 not include this?
|
@@ -115,25 +180,32 @@ module OrigenTesters
|
|
115
180
|
wave_number = nil
|
116
181
|
@wavesets.each_with_index do |w, i|
|
117
182
|
if w[:name] == timeset.name && w[:period] = timeset.period_in_ns
|
118
|
-
wave_number = i
|
183
|
+
wave_number = i + 1 # bug fix wave numbers are 1 more than their index #
|
119
184
|
end
|
120
185
|
end
|
121
186
|
unless wave_number
|
122
187
|
lines = []
|
123
|
-
|
188
|
+
period_var = "period_#{timeset.name}"
|
189
|
+
flattened_ordered_pins.each do |pin|
|
124
190
|
if pin.direction == :input || pin.direction == :io
|
125
191
|
line = "#{pin.name} { 01 { "
|
126
192
|
wave = pin.drive_wave if tester.timeset.dut_timeset
|
127
|
-
|
128
|
-
|
129
|
-
|
130
|
-
|
131
|
-
|
132
|
-
|
133
|
-
|
134
|
-
|
193
|
+
if wave
|
194
|
+
(@use_timing_equations ? wave.events : wave.evaluated_events).each do |t, v|
|
195
|
+
if @use_timing_equations
|
196
|
+
line << "'#{t.to_s.gsub('period', period_var)}' "
|
197
|
+
else
|
198
|
+
line << "'#{t}ns' "
|
199
|
+
end
|
200
|
+
if v == 0
|
201
|
+
line << 'D'
|
202
|
+
elsif v == 1
|
203
|
+
line << 'U'
|
204
|
+
else
|
205
|
+
line << 'D/U'
|
206
|
+
end
|
207
|
+
line << '; '
|
135
208
|
end
|
136
|
-
line << '; '
|
137
209
|
end
|
138
210
|
line << '}}'
|
139
211
|
lines << line
|
@@ -141,20 +213,26 @@ module OrigenTesters
|
|
141
213
|
if pin.direction == :output || pin.direction == :io
|
142
214
|
line = "#{pin.name} { LHX { "
|
143
215
|
wave = pin.compare_wave if tester.timeset.dut_timeset
|
144
|
-
|
145
|
-
|
146
|
-
|
147
|
-
|
148
|
-
|
149
|
-
|
150
|
-
|
151
|
-
|
152
|
-
|
153
|
-
|
154
|
-
|
155
|
-
|
216
|
+
if wave
|
217
|
+
(@use_timing_equations ? wave.events : wave.evaluated_events).each_with_index do |tv, i|
|
218
|
+
t, v = *tv
|
219
|
+
if i == 0 && t != 0
|
220
|
+
line << "'0ns' X; "
|
221
|
+
end
|
222
|
+
if @use_timing_equations
|
223
|
+
line << "'#{t.to_s.gsub('period', period_var)}' "
|
224
|
+
else
|
225
|
+
line << "'#{t}ns' "
|
226
|
+
end
|
227
|
+
if v == 0
|
228
|
+
line << 'L'
|
229
|
+
elsif v == 0
|
230
|
+
line << 'H'
|
231
|
+
else
|
232
|
+
line << 'L/H/X'
|
233
|
+
end
|
234
|
+
line << '; '
|
156
235
|
end
|
157
|
-
line << '; '
|
158
236
|
end
|
159
237
|
line << '}}'
|
160
238
|
lines << line
|
@@ -17,6 +17,23 @@ If the timeset waveforms used by the pattern are
|
|
17
17
|
[fully defined within your Origen application](<%= path "guides/pattern/timing/#Defining_Timesets" %>)
|
18
18
|
then that information will also be represented within the generated STIL pattern.
|
19
19
|
|
20
|
+
Optionally the defined timing can be represented in equation form by setting up your environment as follows:
|
21
|
+
|
22
|
+
~~~ruby
|
23
|
+
OrigenTesters::STIL.new use_timing_equations: true
|
24
|
+
~~~
|
25
|
+
|
26
|
+
If your application is used to convert patterns from another format into STIL format you can add
|
27
|
+
a callback function to config/application.rb to set appropriate period sizes as follows:
|
28
|
+
|
29
|
+
~~~ruby
|
30
|
+
def convert_command_set_period_in_ns(timeset_name)
|
31
|
+
return 25 if timeset_name == "timeset0"
|
32
|
+
return 30 if timeset_name == "timeset1"
|
33
|
+
40
|
34
|
+
end
|
35
|
+
~~~
|
36
|
+
|
20
37
|
A pattern containing a `Pattern { }` block only - i.e. only vectors and without the `Signals { }`,
|
21
38
|
`Timing { }` and other frontmatter blocks - can be generated by setting up your environment as follows:
|
22
39
|
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: origen_testers
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.51.
|
4
|
+
version: 0.51.5
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Stephen McGinty
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2024-04-11 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: origen
|
@@ -601,7 +601,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
601
601
|
- !ruby/object:Gem::Version
|
602
602
|
version: '0'
|
603
603
|
requirements: []
|
604
|
-
rubygems_version: 3.
|
604
|
+
rubygems_version: 3.1.6
|
605
605
|
signing_key:
|
606
606
|
specification_version: 4
|
607
607
|
summary: This plugin provides Origen tester models to drive ATE type testers like
|