Migration from 7ML to 9ML

Discussion in 'Cadence' started by manell15, Oct 17, 2008.

  1. manell15

    manell15 Guest

    Hello
    I want to write a skill script that allows the migration from 7ML to
    9ML for a layout cellview. For that I have to duplicate the metal 5 to
    M6 and M7 and change the M6 and M7 to M8 et M9.
    Could you please help me? is there a function in skill that allows to
    create a metal as a copy of another metal in a cell?
    Thanks.
     
    manell15, Oct 17, 2008
    #1
  2. manell15

    gmc_99 Guest

    Hi

    you could use dbLayerOr which will copy the layer (OR it with
    nothing) . Also you may need to resize it depening on the DRC rules of
    the higher layers - dbLayerSize will up size. The bit of code below
    will do some basics - you'll need to work out what to do with vias
    pins etc.

    Also you'll need to run it on every block to replicate in that block

    LPP=list("M7" "drawing")
    cv=geGetEditCellView()
    ; get a list of objects on layer M7
    shlist = setof( shape cv~>shapes ((shape~>objType == "polygon" ||
    shape~>objType == "rect" || shape~>objType == "path") && (car(LPP) ==
    car(shape~>lpp))))
    foreach( sh shlist
    dbLayerOr(cv "M9" list(sh)) ; copy layer
    ;dbDeleteObject(sh) ; delete if necessary
    )

    cheers
    G
     
    gmc_99, Oct 21, 2008
    #2
  3. manell15

    Riad KACED Guest

    Hi G,

    I'm just catching up ...
    I went quickly through your code and I have few doubts:
    This catches most of the common used figures indeed. But you are still
    missing important things like labels and other less used figures like
    ellipse, donut ... (A complete list of the DFII figures is given in
    the DFII Skill manual).
    You don't need the foreach loop in the above code, you could just say:
    dbLayerOr(cv "M9" shlist)
    dbLayerOr shall take all the shapes in the list without explicitely
    looping with foreach.

    Anyway, this is my attempt (which somebody else could enhance as
    well :) ).
    I have used dbCopyFig myself. This fuction grabs all the types of
    figures, including the labels. dbLayerOr does not catch the labels as
    far I rememeber.
    ;
    procedure( rkCopyLayer(libName cellName viewName sourceLayer destLayer
    "ttttt")
    let((cv sourceLayerFigs destFig)
    cv=dbOpenCellViewByType(libName cellName viewName nil "a")
    sourceLayerFigs=setof(x cv~>shapes x~>layerName==sourceLayer)
    foreach(fig sourceLayerFigs
    destFig = dbCopyFig(fig cv list(0:0 "R0" 1.0))
    destFig~>layerName=destLayer
    ; dbDeleteObject(fig) if needed. Could be made as a procedure
    param.
    )
    dbSave(cv)
    dbClose(cv)
    t
    )
    )
    ;
    Example of Run:
    rkCopyLayer("myLib" "myCell" "layout" "M7" "M8")
    rkCopyLayer("myLib" "myCell" "layout" "M7" "M9")

    The second step for you is to look after the devices, vias and other
    constrains as G advices.

    Cheers,
    Riad,
     
    Riad KACED, Oct 26, 2008
    #3
  4. manell15

    Riad KACED Guest

    Hi G,

    I'm just catching up ...
    I went quickly through your code and I have few doubts:
    This catches most of the common used figures indeed. But you are still
    missing important things like labels and other less used figures like
    ellipse, donut ... (A complete list of the DFII figures is given in
    the DFII Skill manual).
    You don't need the forach loop in the above code, you could just say:
    dbLayerOr(cv "M9" shlist)
    dbLayerOr shall take all the shapes in the list without explicitely
    looping with foreach.

    Anyway, this is my attempt.
    I have used dbCopyFig myself. This fuction grabs all the types of
    figures, including the labels. dbLayerOr does not catch the labels as
    far I rememeber.
    ;
    procedure( rkCopyLayer(libName cellName viewName sourceLayer destLayer
    "ttttt")
    let((cv sourceLayerFigs destFig)
    cv=dbOpenCellViewByType(libName cellName viewName nil "a")
    sourceLayerFigs=setof(x cv~>shapes x~>layerName==sourceLayer)
    foreach(fig sourceLayerFigs
    destFig = dbCopyFig(fig cv list(0:0 "R0" 1.0))
    destFig~>layerName=destLayer
    ; dbDeleteObject(fig) if needed. Could be made as a procedure
    param.
    )
    dbSave(cv)
    dbClose(cv)
    t
    )
    )
    ;
    Example of Run:
    rkCopyLayer("myLib" "myCell" "layout" "M7" "M8")
    rkCopyLayer("myLib" "myCell" "layout" "M7" "M9")

    The second step for you is to look after the devices, vias and other
    constrains as G advices.
    Regards,
    Riad,
     
    Riad KACED, Oct 27, 2008
    #4
  5. manell15

    gmc_99 Guest

    Hi Riad,
    I always have doubts writting skill!
    your observations are correct - I was re-using a bit of code I'd
    written to do something else - so not optimal, after I posted I
    noticed the foreach wasn't necessary

    cheers
    G
     
    gmc_99, Oct 29, 2008
    #5
  6. manell15

    Riad KACED Guest

    Hi G,

    No worries, that's the benefit of having such a great place to share
    ideas and experiences.
    And BTW, I wouldn't show you my first skill codes, you would have a
    good laugh about it :)

    Cheers,
    Riad.
     
    Riad KACED, Oct 29, 2008
    #6
  7. manell15

    manell15 Guest

    Hello
    Thank you for your suggestions.
    I have used the dbCopyFig function and it works very well.

    Cheers,
    Manel.
     
    manell15, Nov 4, 2008
    #7
Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments (here). After that, you can post your question and our members will help you out.