Home > Community > Forums > PCB SKILL > Skill code to move component

Email

* Required Fields

Recipients email * (separate multiple addresses with commas)

Your name *

Your email *

Message *

Contact Us

* Required Fields
First Name *

Last Name *

Email *

Company / Institution *

Comments: *

 Skill code to move component 

Last post Fri, Jun 29 2012 10:24 AM by Mstrghettorigg. 34 replies.
Started by archive 29 Mar 2006 03:07 AM. Topic has 34 replies and 14773 views
Page 2 of 3 (35 items) < Previous 1 2 3 Next >
Sort Posts:
  • Mon, Dec 29 2008 12:33 AM

    • satya12
    • Top 500 Contributor
    • Joined on Mon, Dec 29 2008
    • Bangalore, Karnataka
    • Posts 23
    • Points 640
    Re: RE: Skill code to move component Reply

    Could you attach zip format file.

    • Post Points: 5
  • Wed, Sep 22 2010 10:18 AM

    • rahays
    • Not Ranked
    • Joined on Mon, Jul 28 2008
    • Posts 7
    • Points 110
    Re: RE: Skill code to move component Reply

    Dave,

    When I try to use the moveByRefDes.il program I get the following error in Allegro:

    E- *Error* moveByRefdes: too few arguments (1 expected, 0 given) - nil

     What does that mean? Do you have a latest .il program? I am trying to move by coordinates, rotation, mirror within one screen.

    Thanks,

     Bob Hays

    • Post Points: 5
  • Wed, Sep 22 2010 10:18 AM

    • rahays
    • Not Ranked
    • Joined on Mon, Jul 28 2008
    • Posts 7
    • Points 110
    Re: RE: Skill code to move component Reply

    Dave,

    When I try to use the moveByRefDes.il program I get the following error in Allegro:

    E- *Error* moveByRefdes: too few arguments (1 expected, 0 given) - nil

     What does that mean? Do you have a latest .il program? I am trying to move by coordinates, rotation, mirror within one screen.

    Thanks,

     Bob Hays

    bob.hays@coachcomm.com

    • Post Points: 20
  • Wed, Sep 22 2010 1:24 PM

    • eDave
    • Top 10 Contributor
    • Joined on Sun, Jul 13 2008
    • Christchurch, 00-NZ
    • Posts 744
    • Points 16,130
    Re: RE: Skill code to move component Reply

    Hi Bob,

    Type "moveByRefdes [refdes]" on the command line. Where [refdes] is the symbol you want to move.

    eg

    moveByRefdes IC101

    Newer code is attached.

    Cheers,

    Dave

    Dave Elder, Tait Communications
    • Post Points: 35
  • Wed, Sep 22 2010 1:49 PM

    • rahays
    • Not Ranked
    • Joined on Mon, Jul 28 2008
    • Posts 7
    • Points 110
    Re: RE: Skill code to move component Reply

    Thanks, Dave - that does work. I had it as a custom menu item which gave me the error when I tried to activate the code from the menu.

    What I am looking for is the ability to move any component by coordinates, rotation, and mirror/not mirrored, kind of like a properties info window. I have many components to move from a list of location coordinates.

    Do you know where I can find code like that? I have looked without success.

     Thanks,

     Bob Hays

    PCB layout engineer

    Coachcomm, LLC

    Auburn, AL 36830

    bob.hays@coachcomm.com

    PCB

    • Post Points: 20
  • Wed, Sep 22 2010 2:23 PM

    • eDave
    • Top 10 Contributor
    • Joined on Sun, Jul 13 2008
    • Christchurch, 00-NZ
    • Posts 744
    • Points 16,130
    Re: RE: Skill code to move component Reply

    Hi Bob,

    I'm not aware of any specific code to do that. The closest code I have is my tool to import an IDF interface from Pro-Engineer. (The Cadence interface isn't yet good enough for our purposes).

    This requirement is fairly standard Skill stuff. It should be relatively easy to write code to read a file containing a list of parts and their new locations and move them accordingly. You could adapt the moveByRefdes code quite easily.

    Regards,

    Dave

    Dave Elder, Tait Communications
    • Post Points: 5
  • Wed, Nov 9 2011 9:15 AM

    • Quarkdog1
    • Top 500 Contributor
    • Joined on Thu, Nov 3 2011
    • Posts 19
    • Points 245
    Re: RE: Skill code to move component Reply

    Hi Dave,  totally brand new to Cadence and thus have big learning curve with all this.  Is it possible to to tell me how I can alter the code so it exits the function after placing the component down.  I will have more time to learn skill later, but now have a rush board to do.

    Thanks

    Mark

    • Post Points: 20
  • Wed, Nov 9 2011 11:50 AM

    • eDave
    • Top 10 Contributor
    • Joined on Sun, Jul 13 2008
    • Christchurch, 00-NZ
    • Posts 744
    • Points 16,130
    Re: RE: Skill code to move component Reply
    Hi Mark, See attached. Cheers, Dave
    Dave Elder, Tait Communications
    • Post Points: 20
  • Wed, Nov 9 2011 12:46 PM

    • Quarkdog1
    • Top 500 Contributor
    • Joined on Thu, Nov 3 2011
    • Posts 19
    • Points 245
    Re: RE: Skill code to move component Reply

    omg what service :)     I am using as we speak to locate my parts.  The popup box is wicked. 

    :) Mark

    • Post Points: 5
  • Wed, Nov 9 2011 1:43 PM

    • Quarkdog1
    • Top 500 Contributor
    • Joined on Thu, Nov 3 2011
    • Posts 19
    • Points 245
    Re: RE: Skill code to move component Reply

    Hi Dave,  little bug in the code can be fixed with adding "_" to the _axlSetDynamicsMirror(MBRD_dMir) and _axlSetDynamicsRotation(MBRD_dAng) in the sub functions.  Allows rotation and mirror to work while moving the part. 

    • Post Points: 20
  • Wed, Nov 9 2011 2:09 PM

    • eDave
    • Top 10 Contributor
    • Joined on Sun, Jul 13 2008
    • Christchurch, 00-NZ
    • Posts 744
    • Points 16,130
    Re: RE: Skill code to move component Reply
    Yep. This would imply that you are on 16.2 or lower?
    Dave Elder, Tait Communications
    • Post Points: 20
  • Thu, May 10 2012 1:00 PM

    • Quarkdog1
    • Top 500 Contributor
    • Joined on Thu, Nov 3 2011
    • Posts 19
    • Points 245
    Re: RE: Skill code to move component Reply

    Hi Dave,  I just started using the "find_cmp.il" to me out but  the moveByRefdes command somehow alters the "designator case".  The find_cmp will work with "c1" designator but after I use the moveByRefdes, then I need to use "C1".  moveByRefdes will toggle it back to "c1" after the next use.  Any ideas what might be causing this?

     Thanks a bunch in advance.

    • Post Points: 20
  • Thu, May 10 2012 2:15 PM

    • eDave
    • Top 10 Contributor
    • Joined on Sun, Jul 13 2008
    • Christchurch, 00-NZ
    • Posts 744
    • Points 16,130
    Re: RE: Skill code to move component Reply

    I'll publish some improved code shortly but,in the meantime, add the following line:

    refdes = sym ->name

    below the line :

    sym = car(axlSelectByName("SYMBOL", refdes))

    My designs don't contain lower case reference designators so I had overlooked the possibility of their use. 

    Dave Elder, Tait Communications
    • Post Points: 20
  • Thu, May 10 2012 2:26 PM

    • eDave
    • Top 10 Contributor
    • Joined on Sun, Jul 13 2008
    • Christchurch, 00-NZ
    • Posts 744
    • Points 16,130
    Re: RE: Skill code to move component Reply

    Oops, Of course that command should be:

    refdes = sym ->refdes 

    Dave Elder, Tait Communications
    • Post Points: 5
  • Thu, May 10 2012 2:35 PM

    • Quarkdog1
    • Top 500 Contributor
    • Joined on Thu, Nov 3 2011
    • Posts 19
    • Points 245
    Re: RE: Skill code to move component Reply
    The code change below caused an issue ( part disappeared )

    W- *WARNING* (axlDBCreateSymbol): Refdes not found - "ID004D"

    :(
    Mark
    • Post Points: 20
Page 2 of 3 (35 items) < Previous 1 2 3 Next >
Sort Posts:
Started by archive at 29 Mar 2006 03:07 AM. Topic has 34 replies.