blob: b414e8bdbfac6b2bf5b5e325142b2eba6268c834 [file] [log] [blame]
Mohamed Kassem7a3f4782020-10-27 12:31:18 -07001#!/bin/bash
agorararmard6c766a82020-12-10 18:13:12 +02002# SPDX-FileCopyrightText: 2020 Efabless Corporation
agorararmarde5780bf2020-12-09 21:27:56 +00003#
4# Licensed under the Apache License, Version 2.0 (the "License");
5# you may not use this file except in compliance with the License.
6# You may obtain a copy of the License at
7#
8# http://www.apache.org/licenses/LICENSE-2.0
9#
10# Unless required by applicable law or agreed to in writing, software
11# distributed under the License is distributed on an "AS IS" BASIS,
12# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13# See the License for the specific language governing permissions and
14# limitations under the License.
agorararmardafa96ea2020-12-09 23:37:31 +020015# SPDX-License-Identifier: Apache-2.0
agorararmarde5780bf2020-12-09 21:27:56 +000016
Mohamed Kassem7a3f4782020-10-27 12:31:18 -070017
18export MAGTYPE=maglef ;
19export BASE=/home/mk/zooz/ ;
20export PDKPATH=$BASE/pdks/ef-skywater-s8/EFS8A ;
21
22magic -dnull -noconsole -rcfile $PDKPATH/libs.tech/magic/current/EFS8A.magicrc <<EOF
23gds polygon subcell true
24gds warning default
25gds read $1.gds
26load $1.mag
27save $1.mag
28writeall force
29select top cell
30extract style ngspice(si)
31extract
32ext2spice hierarchy on
33ext2spice format ngspice
34ext2spice cthresh infinite
35ext2spice rthresh infinite
36ext2spice renumber off
37ext2spice scale off
38ext2spice blackbox on
39ext2spice subcircuit top auto
40ext2spice global off
41ext2spice $1.ext
42quit -noprompt
43EOF