• Skip to main content
  • Skip to search
  • Skip to footer
Cadence Home
  • This search text may be transcribed, used, stored, or accessed by our third-party service providers per our Cookie Policy and Privacy Policy.

  1. Community Forums
  2. Allegro X Scripting - Skill
  3. Copy Paste via SKILL from one board to another

Stats

  • Replies 2
  • Subscribers 19
  • Views 11337
  • Members are here 0
More Content

Copy Paste via SKILL from one board to another

Andak
Andak over 6 years ago

Hello Cadencers,

I'm trying to figure out a way to implement a copy-paste like function from two different boards without using the export/import subdrawing FROM the menus. Just not an option when you do that 20 times per minute and you need to copy via by via.

It only needs to be able to transfer basic features like vias, clines and shapes.

I'm thinking of a way that uses a temp file as a data transport path between the 2 boards. I have some ideas but I was wondering what you guys think about it.

Thus I have a few questions:

1. did anyone succeed in implementing such a feature so far? Can you share the experience?

2. Is there a way to export a clip file without calling import/export via scripts inside the SKILL (I'm looking for an axlFunction which I could not identify so far)? Otherwise I'll end up calling the export under a given name file subdrawing with (0 0) origin in 1st boad and import that particular file in the other board. Doesn't seem to be the best way.

Thanks,

Catalin

  • Cancel
  • Sign in to reply
Parents
  • B Bruekers
    B Bruekers over 6 years ago

    There are two other ways to do this:

    1) open the 'source' design and extract all information and store it in memory. With this data you can re-create those items in the destination board. Obviously this only works within the same Allegro session.

    Since you cannot use/store the dbId's you need to come up with your own data structures.

    For example for vias you need to transfer padstack(name), location, net, properties.  For sure there are other items to consider.

    For (c)lines you can use axlPath structures to store the data into memory. You can then simply call a path create function in the desitination board.

    I've used this mechanism in a tool that can place a board (boundaries, holes, outline etc) in another board.

    Some starting code to work from:
    defun( copy_boundary ()
        let( (brd_current placebound)
            brd_from = "test.brd"
            brd_current     = axlGetDrawingName()
            when(axlOpenDesignForBatch(brd_from "wf")
                ;only want to keep polygons, shape dbid will become invalid after switching design
                ;axlPolyFromDB returns always a list. Using mapcar('car  to make flat list
                placebound = mapcar('car mapcar('axlPolyFromDB axlDBGetShapes("PACKAGE GEOMETRY/PLACE_BOUND_TOP")))
                axlOpenDesignForBatch(brd_current "wf")
            )

            foreach(poly placebound   axlDBCreateShape(poly t "PACKAGE GEOMETRY/PLACE_BOUND_TOP" nil nil))
            )
    )

    2) use axlDBCreateModuleDef().  With this you can create a complete 'module' which you can save and 'place' in the destination design with axlDBCreateModuleInstance().

    The allegro clip file is in fact a skill file, so you can use a load("test.clp")  to import the clip drawing...

    Bram

    • Cancel
    • Vote Up 0 Vote Down
    • Sign in to reply
    • Cancel
Reply
  • B Bruekers
    B Bruekers over 6 years ago

    There are two other ways to do this:

    1) open the 'source' design and extract all information and store it in memory. With this data you can re-create those items in the destination board. Obviously this only works within the same Allegro session.

    Since you cannot use/store the dbId's you need to come up with your own data structures.

    For example for vias you need to transfer padstack(name), location, net, properties.  For sure there are other items to consider.

    For (c)lines you can use axlPath structures to store the data into memory. You can then simply call a path create function in the desitination board.

    I've used this mechanism in a tool that can place a board (boundaries, holes, outline etc) in another board.

    Some starting code to work from:
    defun( copy_boundary ()
        let( (brd_current placebound)
            brd_from = "test.brd"
            brd_current     = axlGetDrawingName()
            when(axlOpenDesignForBatch(brd_from "wf")
                ;only want to keep polygons, shape dbid will become invalid after switching design
                ;axlPolyFromDB returns always a list. Using mapcar('car  to make flat list
                placebound = mapcar('car mapcar('axlPolyFromDB axlDBGetShapes("PACKAGE GEOMETRY/PLACE_BOUND_TOP")))
                axlOpenDesignForBatch(brd_current "wf")
            )

            foreach(poly placebound   axlDBCreateShape(poly t "PACKAGE GEOMETRY/PLACE_BOUND_TOP" nil nil))
            )
    )

    2) use axlDBCreateModuleDef().  With this you can create a complete 'module' which you can save and 'place' in the destination design with axlDBCreateModuleInstance().

    The allegro clip file is in fact a skill file, so you can use a load("test.clp")  to import the clip drawing...

    Bram

    • Cancel
    • Vote Up 0 Vote Down
    • Sign in to reply
    • Cancel
Children
No Data
Cadence Guidelines

Community Guidelines

The Cadence Design Communities support Cadence users and technologists interacting to exchange ideas, news, technical information, and best practices to solve problems and get the most from Cadence technology. The community is open to everyone, and to provide the most value, we require participants to follow our Community Guidelines that facilitate a quality exchange of ideas and information. By accessing, contributing, using or downloading any materials from the site, you agree to be bound by the full Community Guidelines.

© 2025 Cadence Design Systems, Inc. All Rights Reserved.

  • Terms of Use
  • Privacy
  • Cookie Policy
  • US Trademarks
  • Do Not Sell or Share My Personal Information