Hi, I would like to use the CCCS element in my analog simulations, but whenever I add such an element, the simulation fails with error messages that do not quite make sense.
I have reduced my simulation to the following netlist:
simulator lang=spectreglobal 0include "$ADE_UTILS_BIN/spectre_gnd_vss.scs"simulatorOptions options psfversion="1.4.0" reltol=1e-3 vabstol=1e-6 \ iabstol=1e-12 temp=27 tnom=27 scalem=1.0 scale=1.0 gmin=1e-12 rforce=1 \ maxnotes=5 maxwarns=5 digits=5 cols=80 pivrel=1e-3 useterms=name ac ac start=1e9 stop=1e11 lin=50 annotate=status modelParameter info what=models where=rawfileelement info what=inst where=rawfileoutputParameter info what=output where=rawfiledesignParamVals info what=parameters where=rawfileprimitives info what=primitives where=rawfilesubckts info what=subckts where=rawfilesave vmaster vslave saveOptions options save=selected useprobes=yes
rslave (vslave 0) resistor r=1Krmaster (vmaster 0) resistor r=1Kimaster (vmaster 0) isource dc=1m mag=1m type=dcislave (vslave 0) cccs gain=0.1 probe=imaster port=1
When I try to run this using the command "spectre netlist.scs" I get:
*******************************************AC Analysis `ac': freq = (1 GHz -> 100 GHz)*******************************************
Error found by spectre during AC analysis `ac'. ERROR (CMI-2239): islave: Controlled source is using `imaster' as controlling element, which is not available. The controlling element might have been removed because it is dangling. Ensure that `imaster' is available and rerun the simulation.
Opening the PSF file netlist.raw/ac.ac ...
Internal error found in spectre at freq = 1 GHz during AC analysis `ac'. FATAL (CMI-2010): Assertion failed in file `cccs.c' at line 3384. Encountered a critical error during simulation. Run `mmsimpack' (see mmsimpack -h for detailed usage information) to package the netlist and log files as a compressed tar file. Then, contact your Cadence representative or submit a service request via Cadence Online Support, including the tar file and any other information that could help identify the problem. FATAL (SPECTRE-18): Segmentation fault. Encountered a critical error during simulation. Run `mmsimpack' (see mmsimpack -h for detailed usage information) to package the netlist and log files as a compressed tar file. Then, contact your Cadence representative or submit a service request via Cadence Online Support, including the tar file and any other information that could help identify the problem.
What is going on? Am I instantiating the CCCS improperly or is there a software bug? I am using Spectre version 220.127.116.111. Thanks
Looks like a bug to me. I tried a few changes of which component is used as the probe - I can't work out what is causing it to fail (I tried changing the probe to the resistor, or to an iprobe in series with the current source and resistor, to no avail). I filed CCR 2446749 for this, but it would be best if you contacted customer support (referencing that CCR) so that we can create a duplicate for you (with appropriate severity) so that fixing this can be prioritised.
The error message is not great (it was "fixed" during SPECTRE19.1 to try to make it clearer, but I think it may have had the opposite effect in some cases!). Essentially you can't use a current source as the controlling element of a cccs. It has to be a vsource or iprobe, and then it only seems to work with port=0 (or the port parameter missed). So I'm trying to find out precisely what is and isn't allowed and get a) the crash fixed, b) the error message clarified, and c) the meaning of the port parameter more clearly defined.
// Titlerslave (vslave 0) resistor r=1Krmaster (vmaster2 0) resistor r=1Kimaster (vmaster1 0) isource dc=1m mag=1m type=dciprb (vmaster1 vmaster2) iprobeislave (vslave 0) cccs gain=0.1 probe=iprb port=0 ac ac start=1e9 stop=1e11 lin=50 annotate=status
Yes it does. Thank you!