def __init__(self, parent, title): wx.Frame.__init__(self, parent, title=title) bb = Breadboard() a = OpAmp() c = Resistor(50) print bb.putComponent(c, 28, 10, 8, 4) print bb.putComponent(a, 8, 7) BreadboardPanel(self, bb) self.Fit() self.Show()
if __name__ == '__main__': #Yay for debugging!! bb = Breadboard() source = InputDevice(.01,'DC') p = OpAmp() W1 = Wire() W2 = Wire() W3 = Wire() W4 = Wire() C = Capacitor(.01) print bb.putComponent(p,3,10) print bb.putComponent(source,5,12) print bb.putComponent(W1,4,14,4,17) print bb.putComponent(W2,6,14,6,17) print bb.putComponent(W3,4,6,4,0) print bb.putComponent(W4,5,6,7,17) print bb.putComponent(C,5,14,3,16) b = B2Spice(bb) print b.nodeList print b.buildNetList('tran',scopedNode=25,tstep = .001,ttotal=1) print b.netList print b.nodePlotDict