79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
|
# File 'lib/tdl/class_hdl/hdl_always_ff.rb', line 79
def instance
str = []
pose_str = edge_instance('posedge',@posedges)
nege_str = edge_instance('negedge',@negedges)
pose_str.concat nege_str
str.push "always_ff@(#{pose_str.join(",")}) begin "
opertor_chains.each do |op|
unless op.is_a? OpertorChain
str.push op.instance(:always_ff).gsub(/^./){ |m| " #{m}"}
else
unless op.slaver
rel_str = ClassHDL.compact_op_ch(op.instance(:always_ff,belong_to_module))
str.push " #{rel_str};"
end
end
end
str.push "end\n"
str.join("\n")
end
|