https://open-source-silicon.dev logo
Title
d

Deni Alves

03/24/2023, 5:13 PM
@Tim Edwards @Stefan Schippers Anyone tried to enable osdi on google colab ngpsice? I'm installing ngspice using "https://conda.anaconda.org/litex-hub/linux-64" repository, a pre-built configuration of it, so I can't activate the "--enable-osdi" to compile with it. By default, ngspice come with it disabled,
s

Stefan Schippers

03/25/2023, 12:03 AM
I build ngspice from sources and run the configure script as:
../configure --with-x --enable-xspice --disable-debug --enable-cider --with-readline=yes --enable-openmp --enable-osdi --prefix=/home/schippes
so you see I enable osdi with
--enable-osdi
g

Gabriel Maranhão

03/25/2023, 5:33 PM
My colleague @Deni Alves and I successfully compiled and executed ngspice in Google Colab following your guidance. However, we encountered issues when attempting to simulate circuits with OSDI models. This could potentially stem from differences in OS architectures between Colab and the system where the .osdi file was generated (with openvaf), but we cannot confirm this. Upon running the existing example netlist found in ngspice's examples\osdi\bsimbulk-local folders, on a Google Colab environment we encountered the following issue:
_*Error opening osdi lib "./osdi_libs/BSIMBULK107.osdi": ./osdi_libs/BSIMBULK107.osdi: invalid ELF header*_
_*Error: Library osdi_libs/BSIMBULK107.osdi couldn't be loaded!*_
Notably, the same file functions properly in a Windows environment.
s

Stefan Schippers

03/25/2023, 10:17 PM
I think you must install the openvaf compiler for the specific machine and compile the verilog-A model to get the osdi lib, this must be done on the same machine where you want to run simulations.
g

Gabriel Maranhão

03/27/2023, 4:06 AM
I thought it wouldn't work to install openvaf on an ubuntu system (google colab) but it worked, it generated the ".osdi" and we were able to run the veriloga models in ngspice inside google colab. Thanks!