Hi, I want to be able to generate pcells from tcl ...
# magic
a
Hi, I want to be able to generate pcells from tcl scripts. I'm already have the following proc
Copy code
proc insert_pcell { cellname params placement } {
    puts "Placing pcell $cellname"
    place $placement

    set default_params [eval sky130::sky130_fd_pr__${cellname}_defaults]

    sky130::sky130_fd_pr__${cellname}_draw [
        sky130::sky130_fd_pr__${cellname}_check [
            dict merge $default_params $params
        ]
    ]

    if {[expr 0 != [dict get $placement rot]]} {
        rotate [dict get $placement rot]
    }
    return $placement
}
This code generates the pcell, but it doesn't creates a cell for it. So I can't rotate it. I think there should be a lot of problems that I have not found. Which functions should I use to generate a pcell in the same way as the dialogs?
I think I should use the
magic::gencell
family of functions to do this, but I'm not sure how many dependencies should I solve before and after using this