summaryrefslogtreecommitdiff
path: root/src/kicadtoNgspice
diff options
context:
space:
mode:
authorFahim2015-03-25 18:06:41 +0530
committerFahim2015-03-25 18:06:41 +0530
commitd25fa222ec4481e30b82d69e6905792aa5beb843 (patch)
tree7228e81e9623c1c9989fb25b8b65d5d3331b7ed7 /src/kicadtoNgspice
parentc476edcbb0f8c15fad287fe13984adf79ee11e8c (diff)
parentb1a89a8ff9efd4b8f567ad92420ee32768b18c5d (diff)
downloadeSim-d25fa222ec4481e30b82d69e6905792aa5beb843.tar.gz
eSim-d25fa222ec4481e30b82d69e6905792aa5beb843.tar.bz2
eSim-d25fa222ec4481e30b82d69e6905792aa5beb843.zip
Merge pull request #2 from komalsheth236/master
Subject: Analysis inserter
Diffstat (limited to 'src/kicadtoNgspice')
-rw-r--r--src/kicadtoNgspice/Analysis.py76
1 files changed, 71 insertions, 5 deletions
diff --git a/src/kicadtoNgspice/Analysis.py b/src/kicadtoNgspice/Analysis.py
index 61af84b5..4ab5291b 100644
--- a/src/kicadtoNgspice/Analysis.py
+++ b/src/kicadtoNgspice/Analysis.py
@@ -1,5 +1,7 @@
from PyQt4 import QtGui,QtCore
+from numpy import partition
+from PyQt4.Qt import QRect
#import GroupBox
class Analysis(QtGui.QWidget):
@@ -160,14 +162,78 @@ class Analysis(QtGui.QWidget):
self.dcbox = QtGui.QGroupBox()
self.dcbox.setTitle("DC Analysis")
self.dcgrid = QtGui.QGridLayout()
-
- self.btn3 = QtGui.QRadioButton("Radio button 3")
- self.btn4 = QtGui.QRadioButton("Radio button 4")
- self.dcgrid.addWidget(self.btn3,0,0)
- self.dcgrid.addWidget(self.btn4,0,1)
+ #self.dcgrid.setGeometry(self, QRect)
+ #self.partition= QtGui.QHBoxLayout()
+ #self.dcgrid.addWidget(partition,0,0)
+ #self.dcgrid.setHorizontalSpacing(60)
+
+ #self.btn3 = QtGui.QRadioButton("Radio button 3")
+ #self.simulation_button = QtGui.QPushButton("Add Simulation Data")
+ #self.dcgrid.addWidget(self.btn3,0,0)
+ #self.dcgrid.addWidget(self.btn4,0,1)
self.dcbox.setDisabled(True)
self.dcbox.setLayout(self.dcgrid)
+ self.source_name= QtGui.QLabel('Enter Source Name',self)
+ self.source_name.setMaximumWidth(150)
+ self.start= QtGui.QLabel('Start', self)
+ self.start.setMaximumWidth(150)
+ self.increment=QtGui.QLabel('Increment',self)
+ self.increment.setMaximumWidth(150)
+ self.stop=QtGui.QLabel('Stop',self)
+ self.stop.setMaximumWidth(150)
+ self.start_spin= QtGui.QSpinBox()
+ self.increment_spin= QtGui.QSpinBox()
+ self.stop_spin= QtGui.QSpinBox()
+ self.inputbox=QtGui.QLineEdit(self)
+ self.inputbox.setMaximumWidth(200)
+ self.check=QtGui.QCheckBox('Operating Point Analysis',self)
+
+ self.start_combo=QtGui.QComboBox(self)
+ self.start_combo.setMaximumWidth(150)
+ self.start_combo.addItem('volts or Amperes')
+ self.start_combo.addItem('mV or mA')
+ self.start_combo.addItem('uV or uA')
+ self.start_combo.addItem("nV or nA")
+ self.start_combo.addItem("pV or pA")
+
+ self.increment_combo=QtGui.QComboBox(self)
+ self.increment_combo.setMaximumWidth(150)
+ self.increment_combo.addItem("volts or Amperes")
+ self.increment_combo.addItem("mV or mA")
+ self.increment_combo.addItem("uV or uA")
+ self.increment_combo.addItem("nV or nA")
+ self.increment_combo.addItem("pV or pA")
+
+ self.stop_combo=QtGui.QComboBox(self)
+ self.stop_combo.setMaximumWidth(150)
+ self.stop_combo.addItem("volts or Amperes")
+ self.stop_combo.addItem("mV or mA")
+ self.stop_combo.addItem("uV or uA")
+ self.stop_combo.addItem("nV or nA")
+ self.stop_combo.addItem("pV or pA")
+
+ self.dcgrid.addWidget(self.source_name,1,0)
+ self.dcgrid.addWidget(self.inputbox,1,1)
+
+ self.dcgrid.addWidget(self.start,2,0)
+ self.dcgrid.addWidget(self.start_spin,2,1)
+ self.dcgrid.addWidget(self.start_combo,2,2)
+
+ self.dcgrid.addWidget(self.increment,3,0)
+ self.dcgrid.addWidget(self.increment_spin,3,1)
+ self.dcgrid.addWidget(self.increment_combo,3,2)
+
+ self.dcgrid.addWidget(self.stop,4,0)
+ self.dcgrid.addWidget(self.stop_spin,4,1)
+ self.dcgrid.addWidget(self.stop_combo,4,2)
+
+ self.dcgrid.addWidget(self.check,5,1,5,2)
+ #self.dcgrid.addWidget(self.simulation_button,6,1,6,2)'''
+
+
+
+
#CSS
self.dcbox.setStyleSheet(" \
QGroupBox { border: 1px solid gray; border-radius: 9px; margin-top: 0.5em; } \