Go to documentation repository
The DoReact method generates actions for the reactions of the system objects. It The method sends the action reaction to the specified object. The action reaction is transferred directly to the kernel where on which the object belongsis registered, and not to the whole entire system. The action In the DoReact method, the reaction is specified using by the MsgObject object.
Method call syntaxSyntax for method invocation:
| Code Block | ||
|---|---|---|
| ||
function DoReact(msgevent : MsgObject) |
Method arguments:
...
...
...
...
| Info | ||
|---|---|---|
| ||
Two types of system messages are available in the Axxon PSIM system: events and actionsreactions. The events usually contain some information and are used as notifications sent to all Axxon PSIM kernels connected to each other during the system setup architecture configuration. The actions reactions are the control commands sent to specific objects. An action A reaction is transmitted only to the kernel where on which the related required object belongsis registered, and not to the whole entire system.The The DoReactStr and DoReact methods are used to generate actionsreactions. The NotifyEventStr and NotifyEvent methods are used to generate events. |
Usage examples
ProblemExample. When Relay relay 1 closes, close Relays relays 2 and 3. When Relay relay 1 opens, open Relay relay 2.
| Code Block | ||
|---|---|---|
| ||
if (Event.SourceType == "GRELE" && Event.SourceId == "1")
{
var msgevent = Event.Clone();
if(Event.Action == "ON")
{
msgevent.SourceId = "2";
DoReact(msgevent);
msgevent.SourceId = "3";
DoReact(msgevent);
}
if(Event.Action == "OFF")
{
msgevent.SourceId = "2";
DoReact(msgevent);
}
} |