System and Driver Events

Events are notifications sent by ATEasy to indicate that a specific occurrence has taken place. These events can be tied to predefined procedures which will execute when they receive a specific event signal.

Events are found as a submodule in both the System and the Driver. You can add code to Events by double-clicking on the Events submodule in the Workspace view for the System or Driver, and then selecting an event from the pulldown menu in the client area.

Events in System and Driver

Events Pulldown

As an examination of the charts below will show, System events and Driver events are identical, except that the System has two additional events, OnInitSystem and OnEndSystem.

System Events

System OnInit() events are called before the Init events for the Program and Driver. System OnEnd() events take place after the OnEnd() events for the Program and Driver.

 

Event

Description

OnInit()

Occurs when the application is initialized. This is the first event in the life of the application.

OnInitSystem()

Occurs when the system is initialized and after the drivers are initialized.

OnInitProgram ()

Occurs when a program is about to run.

OnInitTask()

Occurs before a program task is executed.

OnInitTest()

Occurs before a program test is executed.

OnEndTest()

Occurs after a program test is executed.

OnEndTask()

Occurs after a program task is executed.

OnEndProgram()

Occurs when a program has ended.

OnEndSystem()

Occurs when the application has ended and before drivers have ended.

OnEnd()

Occurs when the application has ended. This is the last event in the life of the application.

OnReset()

Occurs when the application is reset.

OnAbort()

Occurs when the application is aborted.

OnError()

Occurs when an error occurs in the application.

 Driver Events

Driver events are called for each Driver in the System in the order in which the Drivers were inserted. They provide a way for the Driver to respond to changes in the way the application is run.

 

Event

Description

OnInit()

Occurs when the Driver is initialized. After the System is initialized, the OnInit() event takes place for all Drivers.

OnInitProgram()

Occurs when a program is about to run

OnInitTask()

Occurs before a program task is executed.

OnInitTest()

Occurs before a program test is executed.

OnEndTask()

Occurs after a program task is executed.

OnEndTest()

Occurs after a program test is executed.

OnEndProgram()

Occurs when a program is ended.

OnEnd()

Occurs when the application is ended.

OnAbort()

Occurs when the application is aborted.

OnError()

Occurs when an error occurs in the application

OnReset()

Occurs when the application is reset.

See Also:

Module Events