(line, name, cirType)
| 291 | _CIRCUITS[name].title = title |
| 292 | |
| 293 | def _createSubCKT(line, name, cirType): |
| 294 | global _CIRCUITS, _USERCIRCUITS, _SLiCAPCIRCUITS |
| 295 | nodes = [] |
| 296 | params = {} |
| 297 | errors = 0 |
| 298 | for i in range(2, len(line)): |
| 299 | if line[i].type in _NODES: |
| 300 | nodes.append(line[i].value) |
| 301 | elif line[i].type == "PARDEF": |
| 302 | parName, parValue = line[i].value |
| 303 | params[parName] = parValue |
| 304 | else: |
| 305 | _printError("Error: Unexpected input.", line[i]) |
| 306 | errors += 1 |
| 307 | subCKT = circuit() |
| 308 | subCKT.title = name |
| 309 | subCKT.nodes = nodes |
| 310 | subCKT.params = params |
| 311 | subCKT.errors += errors |
| 312 | _saveCircuit(subCKT, name, cirType) |
| 313 | |
| 314 | def _addErrors(name, cirType, n): |
| 315 | global _CIRCUITS, _USERCIRCUITS, _SLiCAPCIRCUITS |
no test coverage detected