Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Verilog symbol generation for single Verilog file containing both nMOS and pMOS #377

Closed
tomhajjar opened this issue Nov 22, 2023 · 6 comments
Labels

Comments

@tomhajjar
Copy link

Issue #365 left out the steps for generating both nMOS and pMOS models and symbols when the Verilog file contains both.

Old example in Qucs 0.0.19 used separate ekv26nMOS.va and ekv26pMOS.va files. What is the procedure for ekv26.va?

Attached is the old Qucs project minus the old va files which don't work under OpenVAF.

Verilog-A_EKV_2v6_prj.zip

@ra3xdh
Copy link
Owner

ra3xdh commented Nov 22, 2023

There is no solution for this issue using the existing procedure for Verilog-A devices. I am planning to add new Verilog-A device that will act like SPICE file device and will not require the JSON files. But don't expect this feature to be implemented in the near future because of low demand and high time effort.

You can use the following workaround.

  • Compile the VA file from CLI outside Qucs-S using OpenVAF
  • Specify the OSDI path using the spiceinit script.
  • Put .MODEL on schematic
  • Put the SPICE generic (Z) device referencing letter N and specify the proper model name for it

@tomhajjar
Copy link
Author

The file usually has a flag of 0/1 or 1/-1 that determines n or p. One could add a line that sets the flag and create two files.

@ra3xdh
Copy link
Owner

ra3xdh commented Nov 25, 2023

It is not possible to attach two JSON *.sym files to one *.va file using the existing workflow. Wait until the Verilog-A devices will be rewritten without need to use JSON or use the workaround. I don't promise a quick fix for this.

@tomhajjar
Copy link
Author

One could create two files and add a line that sets the flag.

I don't use Verilog myself...

@dwarning
Copy link

@ra3xdh : Don't know your concept. But at the moment it is a bit cumbersome that each instance get his own model fixed burned in the netlist. This prevent to include library files with .model cards for each device construction and type. This concept can sufficient for usual rf circuits but not for analog and mixed-signal circuits.
Another topic is the separation of instance and model parameter. The latest release of CMC VA models make more and more this distinction, whenever unfortunately some models allow double usage - model and device parameter. I think it should considered to take care for that in the future.

@ra3xdh
Copy link
Owner

ra3xdh commented Nov 27, 2023

The issue is not resolvable using the current way of Verilog-A devices support using the JSON files. Use the proposed workaround with SPICE generic device and modelcard. The situation will improve after implementation of #343 Don't expect a quick fix here. Closing for now.

@ra3xdh ra3xdh closed this as completed Nov 27, 2023
@ra3xdh ra3xdh added the wontfix label Nov 27, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants