connect_pg_net -automatic
remove_terminals [get_terminal -filter "shape.layer_name == LB" ]
remove_shapes [get_shapes -filter "layer_name == LB" ]
foreach_in_collection j_obj [get_cells -hier -filter "ref_name =~ *phy*" ] {
puts "#### \n This is [get_attr $j_obj full_name ] \n####\n"
foreach_in_collection j_obj2 [get_pins -of $j_obj -filter {layer_name =~ *LB* || layer_name =="G1 G2 LB" } ] {
puts "#### \n This is [get_attr $j_obj2 full_name ] \n####\n"
set j_net_name [get_object_name [get_nets -segment -of [get_pins $j_obj2 ] -top_net_of_hierarchical_group ] ]
foreach_in_collection j_obj3 [get_shapes -of_object $j_obj2 -filter "layer.name==LB" ] {
set j_bbox [get_attr $j_obj3 bbox ]
set llx [lindex [lindex $j_bbox 0 ] 0 ]
set lly [lindex [lindex $j_bbox 0 ] 1 ]
set rtx [lindex [lindex $j_bbox 1 ] 0 ]
set rty [lindex [lindex $j_bbox 1 ] 1 ]
puts "llx $llx lly $lly rtx $rtx rty $rty"
if { [expr int(abs($rtx - $llx)) ] == 71 && [expr int(abs($rty - $lly)) ] == 71 } {
set center_x [expr ($llx + $rtx)/2 ]
set center_y [expr ($lly + $rty)/2 ]
set llx_s [expr $center_x - 10 ]
set lly_s [expr $center_y - 10 ]
set rtx_s [expr $center_x + 10 ]
set rty_s [expr $center_y + 10 ]
puts "create_terminal -of \[create_shape -shape_type rect -shape_use rdl -layer LB -net $j_net_name -boundary \{ \{ $llx_s $lly_s \} \{ $rtx_s $rty_s \} \} \]"
eval "create_terminal -of \[create_shape -shape_type rect -shape_use rdl -layer LB -net $j_net_name -boundary \{ \{ $llx_s $lly_s \} \{ $rtx_s $rty_s \} \} \]"
}
}
}
}
|