summaryrefslogtreecommitdiff
path: root/src/kicadtoNgspice/Convert.py
diff options
context:
space:
mode:
authorRahul P2022-08-25 03:50:54 +0530
committerGitHub2022-08-25 03:50:54 +0530
commit2dbc0fbd2c125c8e1d879d623c3967cea79d1cbe (patch)
tree5ef2a7fc94276eddf875601b4a710125d5215989 /src/kicadtoNgspice/Convert.py
parent49efba6b6844f0c90f48159dfcdab84804e3df02 (diff)
parent1962e47945175dc2e033eaaa20e7f0571e125c88 (diff)
downloadeSim-2dbc0fbd2c125c8e1d879d623c3967cea79d1cbe.tar.gz
eSim-2dbc0fbd2c125c8e1d879d623c3967cea79d1cbe.tar.bz2
eSim-2dbc0fbd2c125c8e1d879d623c3967cea79d1cbe.zip
Merge pull request #215 from Eyantra698Sumanto/master
Parser for Sky130_fd_pr
Diffstat (limited to 'src/kicadtoNgspice/Convert.py')
-rwxr-xr-x[-rw-r--r--]src/kicadtoNgspice/Convert.py17
1 files changed, 17 insertions, 0 deletions
diff --git a/src/kicadtoNgspice/Convert.py b/src/kicadtoNgspice/Convert.py
index 24449a3b..9aec6cce 100644..100755
--- a/src/kicadtoNgspice/Convert.py
+++ b/src/kicadtoNgspice/Convert.py
@@ -525,6 +525,7 @@ class Convert:
# print("Library Path :", libpath)
# Copying library from devicemodelLibrary to Project Path
# Special case for MOSFET
+ print(eachline[0:5])
if eachline[0] == 'm':
# For mosfet library name come along with MOSFET
# dimension information
@@ -547,6 +548,22 @@ class Convert:
src = os.path.join(src_path, src_lib)
dst = projpath
shutil.copy2(src, dst)
+
+ elif eachline[0:6] == 'scmode':
+ tempStr = completeLibPath.split(':')
+ print(tempStr)
+ includeLine.append(
+ ".lib \"" + tempStr[0] + "\" " + tempStr[1])
+ deviceLine[index] = ''
+ # words.append(completeLibPath)
+ # deviceLine[index] = words
+
+ elif eachline[0:2] == 'sc' and eachline[0:6] != 'scmode':
+ temp_str = words[0].replace('sc', 'xsc')
+ words[0] = temp_str
+ words.append(completeLibPath)
+ deviceLine[index] = words
+
else:
# Replace last word with library name
# words[-1] = libname.split('.')[0]