• 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. PCB Design
  3. auto reference designator renaming problem

Stats

  • Locked Locked
  • Replies 1
  • Subscribers 164
  • Views 16021
  • Members are here 0
More Content
This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

auto reference designator renaming problem

shangwu
shangwu over 14 years ago

I used the auto renaming function in PCB Editor (v16.3) to change the reference designators, and also backward annotated to the schematic.  I noticed that all the capacitors (C) changed to resistors (R).  I must have forgotten to preserve the prefixes.   Does anyone know how to fix this?  What I can think of is going through all the capacitors in the schematic, manually change all the capacitors and forward annotate to the PCB Editor.  I was wondering if there’s any better method. 

Thanks.

  • Cancel
  • Mike Veal
    Mike Veal over 14 years ago
    I have three potential solutions for you, all of these are DE HDL actions. :

     1/

     Do you need to keep the numeric portion of the refdes?

     From the schematic, open the console window, and type:

    set nextgroup a

    find cap

    auto property a $location=c?

    wr

    You will need to change "cap" to whatever the name of your schematic symbol for a capacitor is. You can also put these four lines in a text file, file - fix_cap.scr for example. Make sure the file is in the same directory as your cds.lib and .cpm project files. Then in the console window, type :

    run fix_cap.scr

    This will run the script on every page of your schematic.

     2/

    Alternatively, use the following script to find only the broken reference designators. This will need to be done on a per page basis :

    set nextgroup a

    find cap

    include a properties

    find $location=R*

    find location=R*

    include b c

    exclude b a

    find cap

    include d properties

    exlcude d bodies

    exclude d b

    Group d should now contain just refdes starting R that are attached to properties. If you point this to a text editor with column mode editing (Crimson editor is good), changing the R back t a C should be easy.

    3/

    This is probably the simplest, but it will undo all of the naming work you did in the PCB tool.

     Go to your "packaged" directory.

    Find the files pstback.dat,  pstback.dat,1, pstback.dat,2 & pstback.dat,3.

    pstback.dat is the newest copy of your back annotation data. pstback.dat,1 the next newest and pstback.dat,3 the oldest.

     Open pstback.dat1 with a text editor, the format is nicely human readable. Find a cap and make sure it's C123 instead of R123. If it isn't, try pstback.dat,2 or 3.

    When you have found your file, rename pstback.dat as  pstback.dat_old.

    rename your file (pstback.dat,1 or 2 or 3) as pstback.dat.

    Go to DE HDL and in the console window, type

    backann path\pstback.dat

    Where path is the full path to the pstback.dat file. DE HDL will back annotate from your file, restoring all of your old refdes.

    I hope these work for you. I haven't tested them, this is from memory. So please back stuff up before trying and let me know if you get stuck. Obviously, once you've fixed the schem, you will need to export it from DE HDL and import it to Allegro to see the new-old-fixed refdes.
    • Cancel
    • Vote Up +1 Vote Down
    • Cancel
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.

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

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