2 # Copyright 2011 by Bdale Garbee <bdale@gag.com>. GPLv2
4 # Program to emit PCB footprint for a 16 pin
5 # Tyco/AMP Micro-MaTch vertical through-hole female connectors
6 # overlaid with a 10-pin
7 # Tyco Electronics Buchanan 2.54mm pitch terminal blocks
10 # dimensions in mm from C_215079_v.pdf datasheet
11 #PinDiam = 1.15 # screw terminals
12 PinDiam = 0.8 # micromatch
26 # we're going to use the 1/100 of a mil fundamental unit form
28 return int( mm / 25.4 * 1000.0 * 100.0 + 0.5 )
35 print '# author: Bdale Garbee'
36 print '# email: bdale@gag.com'
37 print '# dist-license: GPL 2'
38 print '# use-license: unlimited'
40 print 'Element[0x0 "tphybrid" "" "" 0 0 0 0 0 100 0x0]'
42 for col in range ((pins+1)/2):
48 pinnum = (col * 2) + row + 1
55 mm2mils100((pinnum-1)*PinSpacing), \
56 mm2mils100(spacing), \
57 mm2mils100(PinDiam*2), \
59 mm2mils100(PinDiam*2)+1000, \
60 mm2mils100(PinDiam), \
61 '"pin%i"' % pinnum, '"%i"' % pinnum, Flags, ']'
64 mm2mils100((-2)*PinSpacing), \
65 mm2mils100(RowSpacing), \
66 mm2mils100(PinDiam*2), \
68 mm2mils100(PinDiam*2)+1000, \
69 mm2mils100(PinDiam), \
70 '"pin18"' , '"18"', Flags, ']'
72 # add a hole for the index pin. plated to save non-plated-hole extra fab cost.
75 mm2mils100(RowSpacing-MntY), \
76 mm2mils100(MntDiam)+1400, \
78 mm2mils100(MntDiam)+1400+600, \
79 mm2mils100(MntDiam), \
80 '"mnt" "0"', '0x0001', ']'
82 # pins-2 accounts for the extra pin used by screw terminal overlay
83 BoxX = (pins - 2) * PinSpacing + BoxXbase
86 # re-compute X1 after computing X2 to account for screw terminal overlay
87 BoxX1 = -2*PinSpacing - BoxEnd
88 BoxY1 = -(BoxY - RowSpacing)/2
91 print ' ElementLine[', \
98 print ' ElementLine[', \
105 print ' ElementLine[', \
112 print ' ElementLine[', \