정진형학부생
12/29/2023, 3:37 PMAmro Tork
12/29/2023, 6:18 PMAmro Tork
12/29/2023, 6:18 PMAmro Tork
12/29/2023, 6:21 PM.save v(vctrl) v(UP) v(DN) v(REF) v(FB) v(vp) i(Vt)
Amro Tork
12/29/2023, 6:21 PMAmro Tork
12/29/2023, 6:22 PMAmro Tork
12/29/2023, 6:23 PM정진형학부생
12/30/2023, 12:42 AMStefan Schippers
12/30/2023, 9:50 AM17.5.100 Wrnodev: Write node voltage values to a file (.ic=xx format)
this command saves all the voltages, you can then include this file for another simulation with a .tran instruction that has the uic
option (Use Initial Conditions). If your circuit is sufficiently "digital" such that the state of all voltages is sufficient to define the circuit state you will be able to restart the transient simulation. A good advice is to use wrnodev
when the circuit is not in the middle of a voltage transition, so stay away from clock edges or any other switching event when saving the circuit state.
keep in mind that restarting the simulation this way the time for the next simulation starts from 0 so you probably need to adjust voltage / current source stimuli if they depend on time.Stefan Schippers
12/30/2023, 12:17 PMsolar_panel.raw
, second section in `solar_panel2.raw`:
Keep in mind however that this will just split the output raw files but does not solve the memory issue. If simulation data does not fit in memory using interactive ngspice simulation this will not work.Stefan Schippers
12/30/2023, 12:18 PM.option savecurrents
.control
save all
stop when time=0.3m
tran .05u 1m uic
write solar_panel.raw
resume
let cut-tstart = 0.3m
let cut-end = 1m
cutout
write solar_panel2.raw
quit 0
.endc
정진형학부생
01/01/2024, 2:03 PM정진형학부생
01/01/2024, 2:04 PMStefan Schippers
01/01/2024, 2:28 PMxschem raw_read $netlist_dir/circuit_name.raw tran 10u 20u
In the example above 10u and 20u is the interval to load. (10u included, 20u excluded, 10u <= t < 20u).
If you may set an interval small enough such that the raw portion fits in xschem memory.
This is very new in xschem, you need to rebuild the program from github sources.정진형학부생
01/01/2024, 3:18 PM정진형학부생
01/07/2024, 1:35 AMStefan Schippers
01/08/2024, 2:59 PM.tran
command has optional parameters tstart and tmax:
.tran tstep tstop tstart tmax
, tstart is defaulted to 0 if unspecified.
If you specify a value for it the raw file is recorded from that point.
.tran 10p 201n 199nn 10p
will save simulation from 199ns to 201ns only.
The last 10p
ensures a maximum timestep of 10ps, even if numerical solution could use bigger time steps (in case for example if a steady circuit).