2025-05-21 15:53:01 +02:00
|
|
|
SEE (single event effects) generator
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
NAME_TABLE:
|
|
|
|
|
|
|
|
|
|
C_Function_Name: cm_seegen
|
|
|
|
|
Spice_Model_Name: seegen
|
|
|
|
|
Description: "single event effect generator"
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
PORT_TABLE:
|
|
|
|
|
|
|
|
|
|
Port_Name: ctrl out
|
|
|
|
|
Description: "control input" "output"
|
|
|
|
|
Direction: in out
|
|
|
|
|
Default_Type: v i
|
|
|
|
|
Allowed_Types: [v,vd,i,id] [i,id]
|
|
|
|
|
Vector: no yes
|
|
|
|
|
Vector_Bounds: - [1 -]
|
|
|
|
|
Null_Allowed: yes no
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
PARAMETER_TABLE:
|
|
|
|
|
|
|
|
|
|
Parameter_Name: talpha tbeta
|
|
|
|
|
Description: "alpha" "beta"
|
|
|
|
|
Data_Type: real real
|
|
|
|
|
Default_Value: 500e-12 20e-12
|
|
|
|
|
Limits: - -
|
|
|
|
|
Vector: no no
|
|
|
|
|
Vector_Bounds: - -
|
|
|
|
|
Null_Allowed: yes yes
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
PARAMETER_TABLE:
|
|
|
|
|
|
|
|
|
|
Parameter_Name: tdelay inull
|
|
|
|
|
Description: "pulse delay" "max current"
|
|
|
|
|
Data_Type: real real
|
|
|
|
|
Default_Value: 0 200e-6
|
|
|
|
|
Limits: - -
|
|
|
|
|
Vector: no no
|
|
|
|
|
Vector_Bounds: - -
|
|
|
|
|
Null_Allowed: yes yes
|
|
|
|
|
|
2025-05-27 13:34:23 +02:00
|
|
|
|
2025-05-21 15:53:01 +02:00
|
|
|
PARAMETER_TABLE:
|
|
|
|
|
|
|
|
|
|
Parameter_Name: tperiod ctrlthres
|
|
|
|
|
Description: "pulse repetition" "control voltage threshold"
|
|
|
|
|
Data_Type: real real
|
|
|
|
|
Default_Value: 0 0.5
|
|
|
|
|
Limits: - -
|
|
|
|
|
Vector: no no
|
|
|
|
|
Vector_Bounds: - -
|
|
|
|
|
Null_Allowed: yes yes
|
|
|
|
|
|
2025-05-27 13:34:23 +02:00
|
|
|
|
|
|
|
|
PARAMETER_TABLE:
|
|
|
|
|
|
|
|
|
|
Parameter_Name: perlim
|
|
|
|
|
Description: "pulse repetition limited"
|
|
|
|
|
Data_Type: boolean
|
|
|
|
|
Default_Value: TRUE
|
|
|
|
|
Limits: -
|
|
|
|
|
Vector: no
|
|
|
|
|
Vector_Bounds: -
|
|
|
|
|
Null_Allowed: yes
|
|
|
|
|
|
|
|
|
|
|
2025-05-21 15:53:01 +02:00
|
|
|
STATIC_VAR_TABLE:
|
|
|
|
|
|
|
|
|
|
Static_Var_Name: last_t_value
|
|
|
|
|
Data_Type: pointer
|
|
|
|
|
Vector: no
|
|
|
|
|
Description: "next pulse start time"
|
|
|
|
|
|
|
|
|
|
STATIC_VAR_TABLE:
|
|
|
|
|
|
|
|
|
|
Static_Var_Name: pulse_number
|
|
|
|
|
Data_Type: pointer
|
|
|
|
|
Vector: no
|
|
|
|
|
Description: "number of pulse"
|
|
|
|
|
|
|
|
|
|
STATIC_VAR_TABLE:
|
|
|
|
|
|
|
|
|
|
Static_Var_Name: last_ctrl
|
|
|
|
|
Data_Type: pointer
|
|
|
|
|
Vector: no
|
|
|
|
|
Description: "last control value"
|
|
|
|
|
|
|
|
|
|
Description
|
|
|
|
|
This code model generates "double exponentially" formed current pulses according to
|
|
|
|
|
i(t) = inull * (exp(-(t-tdelay)/talpha) - (exp(-(t-tdelay)/tbeta) for t > tdelay
|
|
|
|
|
i(t) = 0 for t < tdelay
|
|
|
|
|
Minimum is one pulse output (a node pair, or a single node with the other grounded).
|
|
|
|
|
Several output node pairs may be defined per code model instance. Parameter tperiod
|
2025-05-27 13:34:23 +02:00
|
|
|
may then be used to create pulses in sequence. Per default only one sequence is running.
|
|
|
|
|
Parameter perlim, set to FALSE, allows running and repeating the sequence until
|
|
|
|
|
the end of the simulation. The first pulse is issued in the first
|
|
|
|
|
node pair of the node list in the vector [], the second (after time tperiod has elapsed),
|
|
|
|
|
is injected by the second node (pair) of the list and so on. When the sequence is repeated,
|
|
|
|
|
again the output starts pulsing at port (node pair) number 1.
|
|
|
|
|
The control input ctrl (voltage or current) may be used
|
2025-05-21 15:53:01 +02:00
|
|
|
to start or repeat the whole sequence, depending on the circuit status. A rising voltage
|
|
|
|
|
at ctrl, when crossing the threshold given by ctrlthres, will initiate the sequence (including
|
|
|
|
|
tdelay and tperiod).
|
|
|
|
|
|
2025-05-27 13:56:46 +02:00
|
|
|
This model will work in transient analysis. The time step TSEP should be chosen to be not
|
|
|
|
|
larger than than tbeta.
|
2025-05-21 15:53:01 +02:00
|
|
|
|
|
|
|
|
Example ngspice usage (with control)
|
|
|
|
|
|
|
|
|
|
aseegen1 ctrl [%id(n1 m1) %id(n2 m2) %id(n1 m1) %id(n2 m2)] seemod1
|
|
|
|
|
.model seemod1 seegen (tdelay = 8n tperiod=25n)
|
|
|
|
|
|
|
|
|
|
Example ngspice usage (without control, parameters as offered by default)
|
|
|
|
|
|
|
|
|
|
aseegen2 NULL [%id(n1 m1) %id(n5 n6) %id(n6 n7) %i(isingle) ] seemod2
|
2025-05-27 13:34:23 +02:00
|
|
|
.model seemod2 seegen (tdelay = 0 tperiod=0 ctrlthres=0.5 inull=200u talpha=500p tbeta=20p perlim=FALSE)
|