Photo of Dr. S. Salewski

Homepage of Stefan Salewski

Fixing Pin Number Position of gEDA Schematic Symbols

I had some schematics symbols which are generated with an old version of gEDA/tragesym symbol generator. Latest tragesym 0.14 generates a nicer, more symmetric position. But most old symbols are manually tuned, so new generation in not an option. So choices are: Leave the symbols as it is, change position manually, or change it with a script. I choose the later, so I wrote a plain Ruby script. It worked for my symbols, but it is not really tested and not written with too much care.

stefan@AMD64-X2 ~/Bash $ ./uglysym.rb 
      Plain Ruby script to fix the position of pinnumbers (of vertical and horizontal
      pins) of gschem symbols generated with old gEDA/tragesym symbol generator.
      Usage: ruby uglysym.rb MySym.sym (patterns like *.sym should work too)
      The fixed version is copied to ./tmp directory with same filename.
      Check this new version carefully by using diff, gsymcheck and gschem before
      replacing the original. The fixed version should look identical to output of
      tragesym 0.14 of gEDA 1.5.2.
      

Here is how it looks: Left side old original symbols, right side fixed ones. If you can not see the difference, then you do not need this script...

UglySym picture

It seems to work for symbols generated by djboxsym too -- clock input (pin 21) needs manual corrections:

boxsymtuning picture

Please use it only with VERY much care and test the results carefully. Of course you may modify the script. Currently it ignores all pins which are not exact 300 units (mil) long, because this is the pin-length of my tragesym generated symbols and I want that it ignores my manually generated 200 unit symbols (It's a constant PL = 300, you may change it). Here is the Ruby script: