3 # tango to PCB netlist converter
4 # usage: tgo2pcb input > output
6 # Copyright 1998, Ingo Cyliax, Derivation Systems, Inc.
7 # Email: cyliax@derivation.com
13 # read a tango netlist and extract the essentials we need, this
14 # has been tested with OrCad's tango netlister
28 if { $n == -1 } { break }
31 set ch
[string index
$line 0]
49 if { $ch != "(" && $lch == "(" && $ln == "1"} {
52 if { $ch != "(" && $lch == "(" && $ln != "1"} {
53 set xx
[split $line ,]
54 set pin
[lindex $xx 1]
55 set ref
[lindex $xx 0]
56 if { $cnvt($pin) != "" } {
59 lappend nets
($net) "$ref-$pin"
66 # write out a PCB netlist
70 foreach i
[array names nets
] {
71 if { $nets($i) != "" } {
78 # pins 1-99 convert to 1-99, all input pins are converted in this array
81 for { set i
1 } { $i <= 99 } { incr i
} {
87 # read the input file and convert to internal netlist
89 rdtgo
[lindex $argv 0]
92 # convert and write to output