If I use “Library File” in the symbol properties of a Ø-Device to choose a DLL file, it will not work.
The reason: The simulator does not accept module names with a “.dll” extension, but the GUI will give it the full file path with the extension. I have to manually delete the “.dll” from the file path to make it work. The solution would be either to let the simulator (qspice64.exe/qspice80.exe) accept module names with “.dll” extension, or cut off the “.dll” by the GUI, before it calls the simulator.
Another problem: A DLL file path with spaces only works if I manually surround the path with quotation marks. The GUI should automatically do this.
Please check out the video on using .dlls. The module name and .dll can not have spaces in any more than C++ and Verilog module names may. I think the software is correct on all this.
A module file path can have spaces if you manually put quotation marks around it (in the “Load Library” text field). I’ve just tested it. It works. It will also appear with quotation marks in the netlist if you generate one.
The problem is not that it cannot have spaces, the problem is, when I use the GUI and the “Load Library” field (i.e. clicking on the “dot dot dot” symbol of it, so that a file chooser menu opens to choose the path), it will not automatically surround it by quotation marks, and will not remove the “.dll” from the path. I have to do that manually. That’s not a problem if I create the whole netlist manually, of course. It’s a GUI problem.
The software is correct here.
I should have pointed out that “Library File” is the incorrect attribute to use for a .DLL. “Library File” is for a netlist to be included in the netlist, not a .DLL. The Ø-Device syntax is quite special. The first token of the first attribute is used to both compute the name of the .DLL and the function to call in the .DLL.
The module filename can not have a space it it since (i) it is the the name of the C++ function or Verilog module and (ii) there can be additional instances parameters so the GUI can’t really know what to quote even if a space were allowed in a C++/Verilog function/module name. But the module can be in a directory that has spaces in it.
Please watch the video in the Help Section F.A.Q.=>How-To Videos.
I wasn’t talking about the “Library File” from the “.lib” command used in netlists.
I was talking about the “Library File” from the Symbol Properties window for Ø-Device blocks, see this picture:
Any symbol can include a library file. Usually because that file is needed by that symbol, but I’m seeing people hook things up different. As they wish.
The Ø-device computes the function name and file name of the .DLL from the 1st attribute of the symbol(after the instance name). The “Library File” field is not used for that and will normally be blank, unless you want to interject some other file in the netlist when you use the block. It is correct that that field is blank as the example shows.
The function name to call in the .DLL cannot have a space in it. Besides, it’d get confusing with and follow on parameters passed to the function from the instance or circuit-level instance parameter.
Just do it like in video, or like in the example you’re quoting, and it will all work.