summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorfahim-oscad2016-04-04 16:59:25 +0530
committerfahim-oscad2016-04-04 16:59:25 +0530
commit705a0be005d9be0a3a81a4f58e4b5c92e586a4c9 (patch)
treeb94d6ecdbf95262b8da335aa7c650e3e2fc8607b
parent92860fe3ba762ff0a690f887319a7d95018b49c9 (diff)
parent66770d5e2c94cc299424daa67b8bfafcb4d9b8c1 (diff)
downloadeSim-705a0be005d9be0a3a81a4f58e4b5c92e586a4c9.tar.gz
eSim-705a0be005d9be0a3a81a4f58e4b5c92e586a4c9.tar.bz2
eSim-705a0be005d9be0a3a81a4f58e4b5c92e586a4c9.zip
Merged modification branch into release
-rw-r--r--Examples/BJT_CB_config/plot_data_i.txt2
-rw-r--r--Examples/BJT_CB_config/plot_data_v.txt4
-rw-r--r--Examples/BJT_amplifier/plot_data_i.txt2
-rw-r--r--Examples/BJT_amplifier/plot_data_v.txt6
-rw-r--r--src/browser/Welcome.py3
-rw-r--r--src/browser/pages/welcome.html16
-rw-r--r--src/configuration/Appconfig.py4
-rwxr-xr-xsrc/frontEnd/Application.py3
-rw-r--r--src/frontEnd/DockArea.py23
-rw-r--r--src/frontEnd/ProjectExplorer.py7
-rw-r--r--src/ngspiceSimulation/NgspiceWidget.py1
-rw-r--r--src/ngspiceSimulation/pythonPlotting.py15
-rw-r--r--src/projManagement/Worker.py3
13 files changed, 60 insertions, 29 deletions
diff --git a/Examples/BJT_CB_config/plot_data_i.txt b/Examples/BJT_CB_config/plot_data_i.txt
index 267823ff..687f1816 100644
--- a/Examples/BJT_CB_config/plot_data_i.txt
+++ b/Examples/BJT_CB_config/plot_data_i.txt
@@ -1,5 +1,5 @@
* /home/fossee/updatedexamples/bjt_cb_config/bjt_cb_config.cir
- DC transfer characteristic Thu Mar 3 18:30:45 2016
+ DC transfer characteristic Thu Mar 17 15:55:49 2016
--------------------------------------------------------------------------------
Index i-sweep v1#branch v_u_ic1#branch
--------------------------------------------------------------------------------
diff --git a/Examples/BJT_CB_config/plot_data_v.txt b/Examples/BJT_CB_config/plot_data_v.txt
index 0a211bb1..3176a023 100644
--- a/Examples/BJT_CB_config/plot_data_v.txt
+++ b/Examples/BJT_CB_config/plot_data_v.txt
@@ -1,5 +1,5 @@
* /home/fossee/updatedexamples/bjt_cb_config/bjt_cb_config.cir
- DC transfer characteristic Thu Mar 3 18:30:45 2016
+ DC transfer characteristic Thu Mar 17 15:55:49 2016
--------------------------------------------------------------------------------
Index i-sweep ie net-_q1-pad1_ net-_q1-pad3_
--------------------------------------------------------------------------------
@@ -2220,7 +2220,7 @@ Index i-sweep ie net-_q1-pad1_ net-_q1-pad3_
2106 5.000000e+00 -5.68795e+00 2.247493e-02 -6.87953e-01
* /home/fossee/updatedexamples/bjt_cb_config/bjt_cb_config.cir
- DC transfer characteristic Thu Mar 3 18:30:45 2016
+ DC transfer characteristic Thu Mar 17 15:55:49 2016
--------------------------------------------------------------------------------
Index i-sweep net-_r1-pad1_ vcb
--------------------------------------------------------------------------------
diff --git a/Examples/BJT_amplifier/plot_data_i.txt b/Examples/BJT_amplifier/plot_data_i.txt
index c3697448..c8335ced 100644
--- a/Examples/BJT_amplifier/plot_data_i.txt
+++ b/Examples/BJT_amplifier/plot_data_i.txt
@@ -1,5 +1,5 @@
* /home/fossee/esim-workspace/bjt_amplifier/bjt_amplifier.cir
- Transient Analysis Thu Mar 3 18:28:39 2016
+ Transient Analysis Thu Mar 17 16:00:09 2016
--------------------------------------------------------------------------------
Index time v1#branch v2#branch
--------------------------------------------------------------------------------
diff --git a/Examples/BJT_amplifier/plot_data_v.txt b/Examples/BJT_amplifier/plot_data_v.txt
index f299971e..4cc3eec6 100644
--- a/Examples/BJT_amplifier/plot_data_v.txt
+++ b/Examples/BJT_amplifier/plot_data_v.txt
@@ -1,5 +1,5 @@
* /home/fossee/esim-workspace/bjt_amplifier/bjt_amplifier.cir
- Transient Analysis Thu Mar 3 18:28:39 2016
+ Transient Analysis Thu Mar 17 16:00:09 2016
--------------------------------------------------------------------------------
Index time in net-_c1-pad1_ net-_c1-pad2_
--------------------------------------------------------------------------------
@@ -1064,7 +1064,7 @@ Index time in net-_c1-pad1_ net-_c1-pad2_
1007 1.000000e-02 -2.44929e-17 2.336157e-06 1.837271e+00
* /home/fossee/esim-workspace/bjt_amplifier/bjt_amplifier.cir
- Transient Analysis Thu Mar 3 18:28:39 2016
+ Transient Analysis Thu Mar 17 16:00:09 2016
--------------------------------------------------------------------------------
Index time net-_c2-pad2_ net-_c3-pad2_ net-_r2-pad1_
--------------------------------------------------------------------------------
@@ -2129,7 +2129,7 @@ Index time net-_c2-pad2_ net-_c3-pad2_ net-_r2-pad1_
1007 1.000000e-02 1.199900e+00 8.416406e+00 1.000000e+01
* /home/fossee/esim-workspace/bjt_amplifier/bjt_amplifier.cir
- Transient Analysis Thu Mar 3 18:28:39 2016
+ Transient Analysis Thu Mar 17 16:00:09 2016
--------------------------------------------------------------------------------
Index time out
--------------------------------------------------------------------------------
diff --git a/src/browser/Welcome.py b/src/browser/Welcome.py
index f9e3bbd7..0f50e153 100644
--- a/src/browser/Welcome.py
+++ b/src/browser/Welcome.py
@@ -12,7 +12,8 @@ class Welcome(QtGui.QWidget):
self.browser = QtGui.QTextBrowser()
self.browser.setSource(QtCore.QUrl("../browser/pages/welcome.html"))
self.browser.setOpenExternalLinks(True)
+ self.browser.setVerticalScrollBarPolicy(QtCore.Qt.ScrollBarAlwaysOff)
self.vlayout.addWidget(self.browser)
self.setLayout(self.vlayout)
- self.show() \ No newline at end of file
+ self.show()
diff --git a/src/browser/pages/welcome.html b/src/browser/pages/welcome.html
index 9343b8b0..2da1dc58 100644
--- a/src/browser/pages/welcome.html
+++ b/src/browser/pages/welcome.html
@@ -35,21 +35,21 @@ pre{
<head>
<body>
-
<h1>About eSim</h1>
+<center><img src="../../../images/logo.png" alt="eSim logo" height="100" width="100"></center>
+<br/>
<p>
-<b>eSim</b> is an open source EDA tool for circuit design, simulation, analysis and PCB design. It is an integrated tool built using open source software such as KiCad (<a href=http://www.kicad-pcb.org>http://www.kicad-pcb.org</a>) and Ngspice(<a href=http://ngspice.sourceforge.net>http://ngspice.sourceforge.net</a>).
-<br/>
-eSim source is released under <b>GNU General Public License V3.</b>
+<b>eSim</b> is an open source EDA tool for circuit design, simulation, analysis and PCB design. It is an integrated tool built using open source software such as KiCad (<a href=http://www.kicad-pcb.org>http://www.kicad-pcb.org</a>) and Ngspice(<a href=http://ngspice.sourceforge.net>http://ngspice.sourceforge.net</a>). eSim source is released under <b>GNU General Public License V3.</b>
</p>
<br/>
<p>
-eSim is developed by the <b>FOSSEE team at IIT Bombay</b>. To know more about eSim, please visit: <a href=http://esim.fossee.in>http://esim.fossee.in</a>.
+This tool is developed by the <b>FOSSEE team at IIT Bombay</b>. To know more about eSim, please visit: <a href=http://esim.fossee.in>http://esim.fossee.in</a>.
</p>
-<br />
+<br/>
<p>
-To discuss more about eSim please visits at <a href=http://esim.fossee.in>http://esim.fossee.in</a>
-
+For technical queries, please contact us through FOSSEE Forum: <a href=http://esim.fossee.in>http://esim.fossee.in</a>
+<br/>
+Write to us at: contact-esim@fossee.in
</p>
<br />
</body>
diff --git a/src/configuration/Appconfig.py b/src/configuration/Appconfig.py
index 72510174..3e4afad6 100644
--- a/src/configuration/Appconfig.py
+++ b/src/configuration/Appconfig.py
@@ -38,6 +38,8 @@ class Appconfig(QtGui.QWidget):
#Workspace detail
workspace_text = '''eSim stores your project in a folder called a eSim-Workspace. You can choose a different workspace folder to use for this session.'''
procThread_list = []
+ proc_dict={} #holds the pids of all external windows corresponds to the current project
+ dock_dict={} #holds all dockwidgets
dictPath = os.path.join(os.path.expanduser("~"), ".projectExplorer.txt")
noteArea = {}
try:
@@ -75,4 +77,4 @@ class Appconfig(QtGui.QWidget):
- \ No newline at end of file
+
diff --git a/src/frontEnd/Application.py b/src/frontEnd/Application.py
index 24e541c3..a3438591 100755
--- a/src/frontEnd/Application.py
+++ b/src/frontEnd/Application.py
@@ -187,6 +187,9 @@ class Application(QtGui.QMainWindow):
if current_project==None:
pass
else:
+ for pid in self.obj_appconfig.proc_dict[self.obj_appconfig.current_project['ProjectName']]:
+ os.kill(pid, 9)
+ self.obj_Mainview.obj_dockarea.closeDock()
self.obj_appconfig.current_project['ProjectName'] = None
self.systemTrayIcon.showMessage('Close', 'Current project '+os.path.basename(current_project)+' is Closed.')
diff --git a/src/frontEnd/DockArea.py b/src/frontEnd/DockArea.py
index 65296525..dcb48704 100644
--- a/src/frontEnd/DockArea.py
+++ b/src/frontEnd/DockArea.py
@@ -90,7 +90,8 @@ class DockArea(QtGui.QMainWindow):
")
"""
dock['Tips-'+str(count)].raise_()
-
+
+ self.obj_appconfig.dock_dict[self.obj_appconfig.current_project['ProjectName']].append(dock['Tips-'+str(count)])
count = count + 1
def plottingEditor(self):
@@ -124,7 +125,8 @@ class DockArea(QtGui.QMainWindow):
dock['Plotting-'+str(count)].setVisible(True)
dock['Plotting-'+str(count)].setFocus()
dock['Plotting-'+str(count)].raise_()
-
+
+ self.obj_appconfig.dock_dict[self.obj_appconfig.current_project['ProjectName']].append(dock['Plotting-'+str(count)])
count = count + 1
def ngspiceEditor(self,projDir):
@@ -160,7 +162,7 @@ class DockArea(QtGui.QMainWindow):
dock['NgSpice-'+str(count)].setVisible(True)
dock['NgSpice-'+str(count)].setFocus()
dock['NgSpice-'+str(count)].raise_()
-
+ self.obj_appconfig.dock_dict[self.obj_appconfig.current_project['ProjectName']].append(dock['NgSpice-'+str(count)])
count = count + 1
def modelEditor(self):
@@ -187,7 +189,8 @@ class DockArea(QtGui.QMainWindow):
dock['Model Editor-'+str(count)].setVisible(True)
dock['Model Editor-'+str(count)].setFocus()
dock['Model Editor-'+str(count)].raise_()
-
+
+ self.obj_appconfig.dock_dict[self.obj_appconfig.current_project['ProjectName']].append(dock['Model Editor-'+str(count)])
count = count + 1
def kicadToNgspiceEditor(self,clarg1,clarg2=None):
@@ -210,7 +213,8 @@ class DockArea(QtGui.QMainWindow):
dock['kicadToNgspice-'+str(count)].setVisible(True)
dock['kicadToNgspice-'+str(count)].setFocus()
dock['kicadToNgspice-'+str(count)].raise_()
-
+
+ self.obj_appconfig.dock_dict[self.obj_appconfig.current_project['ProjectName']].append(dock['kicadToNgspice-'+str(count)])
count = count + 1
@@ -238,7 +242,8 @@ class DockArea(QtGui.QMainWindow):
dock['Subcircuit-'+str(count)].setVisible(True)
dock['Subcircuit-'+str(count)].setFocus()
dock['Subcircuit-'+str(count)].raise_()
-
+
+ self.obj_appconfig.dock_dict[self.obj_appconfig.current_project['ProjectName']].append(dock['Subcircuit-'+str(count)])
count = count + 1
def usermanual(self):
@@ -266,4 +271,8 @@ class DockArea(QtGui.QMainWindow):
dock['User Manual-'+str(count)].setFocus()
dock['User Manual-'+str(count)].raise_()
- count = count + 1 \ No newline at end of file
+ count = count + 1
+
+ def closeDock (self):
+ for dockwidget in self.obj_appconfig.dock_dict[self.obj_appconfig.current_project['ProjectName']]:
+ dockwidget.close()
diff --git a/src/frontEnd/ProjectExplorer.py b/src/frontEnd/ProjectExplorer.py
index 6c96227a..146b6d0f 100644
--- a/src/frontEnd/ProjectExplorer.py
+++ b/src/frontEnd/ProjectExplorer.py
@@ -47,6 +47,8 @@ class ProjectExplorer(QtGui.QWidget):
parentnode = QtGui.QTreeWidgetItem(self.treewidget, [pathlist[-1], parents])
for files in children:
childnode = QtGui.QTreeWidgetItem(parentnode, [files, os.path.join(parents,files)])
+ self.obj_appconfig.proc_dict[self.obj_appconfig.current_project['ProjectName']] = []
+ self.oj_appconfig.dock_dict[self.obj_appconfig.current_project['ProjectName']] = []
def openMenu(self, position):
@@ -102,6 +104,9 @@ class ProjectExplorer(QtGui.QWidget):
self.textwindow.show()
else:
self.obj_appconfig.current_project["ProjectName"]= str(self.filePath)
+ self.obj_appconfig.proc_dict[self.obj_appconfig.current_project['ProjectName']] = []
+ if self.obj_appconfig.current_project['ProjectName'] not in self.obj_appconfig.dock_dict:
+ self.obj_appconfig.dock_dict[self.obj_appconfig.current_project['ProjectName']] = []
def enable_save(self):
self.save.setEnabled(True)
@@ -139,4 +144,4 @@ class ProjectExplorer(QtGui.QWidget):
childnode= QtGui.QTreeWidgetItem(parentnode, [files, os.path.join(self.filePath,files)])
self.obj_appconfig.project_explorer[self.filePath]= filelistnew
- json.dump(self.obj_appconfig.project_explorer, open(self.obj_appconfig.dictPath,'w')) \ No newline at end of file
+ json.dump(self.obj_appconfig.project_explorer, open(self.obj_appconfig.dictPath,'w'))
diff --git a/src/ngspiceSimulation/NgspiceWidget.py b/src/ngspiceSimulation/NgspiceWidget.py
index ee4dafe7..310cbe3c 100644
--- a/src/ngspiceSimulation/NgspiceWidget.py
+++ b/src/ngspiceSimulation/NgspiceWidget.py
@@ -24,6 +24,7 @@ class NgspiceWidget(QtGui.QWidget):
self.args = ['-hold','-e', self.command]
self.process.start('xterm', self.args)
self.obj_appconfig.process_obj.append(self.process)
+ self.obj_appconfig.proc_dict[self.obj_appconfig.current_project['ProjectName']].append(self.process.pid())
elif platform.system() == 'Windows':
tempdir= os.getcwd()
diff --git a/src/ngspiceSimulation/pythonPlotting.py b/src/ngspiceSimulation/pythonPlotting.py
index deb66c8a..1fbe3575 100644
--- a/src/ngspiceSimulation/pythonPlotting.py
+++ b/src/ngspiceSimulation/pythonPlotting.py
@@ -110,7 +110,7 @@ class plotWindow(QtGui.QMainWindow):
self.plotbtn = QtGui.QPushButton("Plot")
self.plotbtn.setToolTip('<b>Press</b> to Plot' )
self.multimeterbtn = QtGui.QPushButton("Multimeter")
- self.multimeterbtn.setToolTip('<b>Press</b> to get Multimeter' )
+ self.multimeterbtn.setToolTip('<b>RMS</b> value of the current and voltage is displayed' )
self.text = QtGui.QLineEdit()
self.funcLabel = QtGui.QLabel()
self.palette1 = QtGui.QPalette()
@@ -155,9 +155,9 @@ class plotWindow(QtGui.QMainWindow):
self.listNode.setText("<font color='indigo'>List of Nodes:</font>")
self.listBranch.setText("<font color='indigo'>List of Branches:</font>")
self.funcLabel.setText("<font color='indigo'>Function:</font>")
- self.funcName.setText("<font color='indigo'>Examples:</font>\
+ self.funcName.setText("<font color='indigo'>Standard functions</font>\
<br><br>Addition:<br>Subtraction:<br>Multiplication:<br>Division:<br>Comparison:")
- self.funcExample.setText("\n\nV(1) + V(2)\nV(1) - V(2)\nV(1) * V(2)\nV(1) / V(2)\nV(1) vs V(2)")
+ self.funcExample.setText("\n\nNode1 + Node2\nNode1 - Node2\nNode1 * Node2\nNode1 / Node2\nNode1 vs Node2")
#Connecting to plot and clear function
self.connect(self.clear,QtCore.SIGNAL('clicked()'),self.pushedClear)
@@ -429,12 +429,17 @@ class MultimeterWidgetClass(QtGui.QWidget):
QtGui.QWidget.__init__(self)
self.multimeter = QtGui.QWidget(self)
+<<<<<<< HEAD
if voltFlag:
self.node_branchLabel = QtGui.QLabel("Node")
self.rmsValue = QtGui.QLabel(str(rmsValue)+" Volts")
else:
self.node_branchLabel = QtGui.QLabel("Branch")
self.rmsValue = QtGui.QLabel(str(rmsValue)+" Amp")
+=======
+ self.node_branchLabel = QtGui.QLabel("Node/Branch")
+ self.rmsLabel = QtGui.QLabel("RMS Value (Volts/Amperes)")
+>>>>>>> modification
self.rmsLabel = QtGui.QLabel("RMS Value")
self.nodeBranchValue = QtGui.QLabel(str(node_branch))
@@ -447,7 +452,11 @@ class MultimeterWidgetClass(QtGui.QWidget):
self.layout.addWidget(self.rmsValue,1,1)
self.multimeter.setLayout(self.layout)
+<<<<<<< HEAD
self.setGeometry(loc_x,loc_y,200,100)
+=======
+ self.setGeometry(loc_x,loc_y,300,100)
+>>>>>>> modification
self.setWindowTitle("MultiMeter")
self.setWindowFlags(QtCore.Qt.WindowStaysOnTopHint)
self.show()
diff --git a/src/projManagement/Worker.py b/src/projManagement/Worker.py
index 9721f4a7..6befca65 100644
--- a/src/projManagement/Worker.py
+++ b/src/projManagement/Worker.py
@@ -39,7 +39,8 @@ class WorkerThread(QtCore.QThread):
procThread = Appconfig()
proc = subprocess.Popen(command.split())
procThread.procThread_list.append(proc)
+ procThread.proc_dict[procThread.current_project['ProjectName']].append(proc.pid)
- \ No newline at end of file
+