EvtParam attributesPowerFactory Parameter Event

Every attribute of the PowerFactory Parameter Event (EvtParam): 17 event parameters, with units and meaning. Copy a name into GetAttribute or SetAttribute.

What EvtParam is

A parameter event: it sets any input parameter of an element (a setpoint, a gain) to a new value at a set time of a simulation.

Class
EvtParam, event class
PowerFactory name
Parameter Event
Attributes
17 event parameters

Most used EvtParam attributes

AttributeUnitDescriptionWhere
p_target·Elementevent data
timesExecution time (absolute)event data
variable·Name of Variableparameter nameevent data
value·New Valuenew value, as textevent data

Read and write EvtParam in Python

import powerfactory

app = powerfactory.GetApplication()          # GetApplicationExt() from outside PowerFactory

inc = app.GetFromStudyCase("ComInc")
events = inc.GetAttribute("p_event")          # the event list the simulation reads
gen = app.GetCalcRelevantObjects("*.ElmSym")[0]
ev = events.CreateObject("EvtParam", "My parameter event")
ev.SetAttribute("p_target", gen)
app.SetAttributeModeInternal(1)               # write the time in seconds, whatever unit the project shows
ev.SetAttribute("time", 1.0)
app.SetAttributeModeInternal(0)
ev.SetAttribute("variable", "pgini")          # the input parameter to change
ev.SetAttribute("value", "120")               # its new value, written as text
  • Times are written in the unit the project shows (some show milliseconds); SetAttributeModeInternal(1) makes it seconds. A fault is cleared by a second EvtShc with i_shc 4: i_clearShc does not clear it in an RMS or EMT run.

EvtParam event parameters

Set these on the event before the simulation runs. Names are typed without the e: shown in variable lists.

AttributeUnitDescription
variable·Name of Variable
value·New Value
outserv·Out of Service
mtimeminExecution time (absolute, in minutes)
hrtimehExecution time (absolute, in hours)
i_sysmat·Recompute system matrix
eventHandling·Event handling
timesExecution time (absolute)
tDateTime·Execution Time
p_target·ElementObject: Elm*,Rel*,Sta*,SetSelect
p_from·Event defined byObject: Elm*,Rel*,Sta*
dtimesExecution time (relative to now)
tactsNow (current simulation time)
dmtimeminExecution time (relative to now, in minutes)
mtactminNow (current simulation time, in minutes)
dhrtimehExecution time (relative to now, in hours)
hrtacthNow (current simulation time, in hours)

Related

← EvtOutage Outage Event · EvtShc Short-Circuit Event →