diff options
author | Fahim | 2015-10-21 16:58:26 +0530 |
---|---|---|
committer | Fahim | 2015-10-21 16:58:26 +0530 |
commit | e383c8b9dd13465dc8b7cad2586e1db829845ff8 (patch) | |
tree | 23afc79435b39a7d1f7b65df6f13aef1153cb00f /src/ngspicetoModelica | |
parent | 506936250356ec10422933e04257c00facd77159 (diff) | |
download | eSim-e383c8b9dd13465dc8b7cad2586e1db829845ff8.tar.gz eSim-e383c8b9dd13465dc8b7cad2586e1db829845ff8.tar.bz2 eSim-e383c8b9dd13465dc8b7cad2586e1db829845ff8.zip |
Subject: OpenModelica- Added comma in parameter line
Description: OpenModelica- Added comma in parameter line to separate
each parameter with comma
Diffstat (limited to 'src/ngspicetoModelica')
-rw-r--r-- | src/ngspicetoModelica/NgspicetoModelica.py | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/src/ngspicetoModelica/NgspicetoModelica.py b/src/ngspicetoModelica/NgspicetoModelica.py index 3cb7a8a6..3b1752d3 100644 --- a/src/ngspicetoModelica/NgspicetoModelica.py +++ b/src/ngspicetoModelica/NgspicetoModelica.py @@ -117,9 +117,15 @@ class NgMoConverter: modelicaParam = [] for eachline in paramInfo: eachline = eachline.split('.param') - stat = 'parameter Real ' + eachline[1] + ';' + #Include ',' in between parameter + #Removing leading and trailing space + line = eachline[1].strip() + line = line.split() + final_line = ','.join(line) + stat = 'parameter Real ' + final_line + ';' stat = stat.translate(maketrans('{}', ' ')) modelicaParam.append(stat) + print "Modelica Parameter----------->",modelicaParam return modelicaParam |