ERROR!

This web site requires Java Script.
You must enable Java Script on
your browser to navigate this site.

 

 

 

 

 

 

 

 

 

 

 

 

 

 

Event Counter

An Event Counter is a Screen Object which can be used to keep a running count of various occurrences while the main run-time loop is executing. An occurrence can be the reception of a specific command from a DAQ Module, one or more steps in an ongoing Script, a Conditional statement which evaluates to TRUE, etc. The Event Counter can be run in stand-alone mode using its "Conditionals" section, or operated on by other objects. The value of the Event Counter can also be used to trigger other actions within ModCom.

Once an Event Counter is placed on the screen it can be selected by clicking on it with the left mouse button. To move the object, place the cursor over it, hold down the left mouse button and drag the object to the desired position. Resize handles are provided to allow adjustment of the overall size by dragging on them with the mouse in a similar fashion.

To set the properties of an Event Counter, right-click on the object or select "Properties" in the <Edit> menu while the Event Counter is selected. The following is a summery of the user defined attributes in the Properties dialog box.

Properties Dialog Box:

Screen Text:

Title: Type in the text that will appear to the left of the data field.

Size: Selects the font size used for the text characters in the Event Counter. Making changes to this attribute will also change the overall size of the Event Counter respectively.

Color: Selects the font color used for text in the title field.

Title Width: Selects the width of the title field. Note, dragging the resize handles will change the width of the data field only.

Configuration:

Object ID Label: Type in a label that will be used for identification by other objects within ModCom when sending instructions to the Event Counter, using the displayed reading as a variable in another object's function, or when evaluating Conditional statements specific to the Event Counter's value.

Reset Value: Type in the value that the counter will be set to at start-up and at any time an object within ModCom instructs the Event Counter to reset.

Reset when start/stop run loop: Check this box if wishing the Event Counter to reset when starting or stopping the main run-time loop. If unchecked, the Event Counter will hold its value between run sessions and ask the operator to save changes upon exit.

Show manual edit buttons: Check this box to show the manual edit buttons to the right of the data field. When the main run-time loop is executing, clicking on the top button with the left mouse button will increment the counter, bottom button will decrement the counter, and the center button will reset the counter. Uncheck this box to prohibit manual editing of count value.

Conditionals:

Increment if a DAQ Module sends this: Type in the data string and/or variable which, upon reception from a DAQ Module, will cause the counter to increment. If wishing to increment the counter with the reception of many different data strings, set up Conditional statements in the <Run-Loop> menu to act on each. Note, any data which is received in direct response to a command transmitted by another object within ModCom, will not increment this counter unless the transmitting object has the word "Conditionals" typed into its box called "Send the response to this Screen Object".

Decrement if a DAQ Module sends this: Type in the data string and/or variable which, upon reception from a DAQ Module, will cause the counter to decrement. If wishing to decrement the counter with the reception of many different data strings, set up Conditional statements in the <Run-Loop> menu to act on each. Note, any data which is received in direct response to a command transmitted by another object within ModCom, will not decrement this counter unless the transmitting object has the word "Conditionals" typed into its box called "Send the response to this Screen Object".

Reset if a DAQ Module sends this: Type in the data string and/or variable which, upon reception from a DAQ Module, will cause the counter to reset. If wishing to reset the counter with the reception of many different data strings, set up Conditional statements in the <Run-Loop> menu to act on each. Note, any data which is received in direct response to a command transmitted by another object within ModCom, will not reset this counter unless the transmitting object has the word "Conditionals" typed into its box called "Send the response to this Screen Object".