Features, discussions, tips, tricks, questions, problems and feedback

Primitive and Basic Agent Types

Introduction
In Adroit, an Agent is a fundamental component that resides within the Agent Server. It serves as both a data storage unit and an intelligent entity capable of manipulating that data. Essentially, an Agent combines data with the necessary operations to work with and process it effectively. With this concept, Adroit ensures that Agents possess the intelligence required to handle and manipulate data efficiently.

In this article, we will focus on basic and primitive agent types. However, it is important to note that Adroit offers a wide range of advanced agents for you to utilize. While we will only cover the essentials here, you have a multitude of options available within Adroit to suit your specific needs and requirements.

Primitive
These agent types are considered primitive because they have limited functionality and value compared to Basic agents. They act as simple containers with only a single value. The primitive agent types include Boolean, Integer, Real, Text, and Frame. It’s essential to use Basic agent types instead to represent your process values, as primitive agent types cannot be alarmed, and their values are not scaled.

Boolean Agent:
A Boolean agent is specifically designed to store a Boolean value, which can be either 0 or 1. It serves as a dedicated container for representing true or false conditions within the Adroit system.

Integer Agent:
An Integer agent is specifically designed to hold integer numbers within the range of -2147483648 to +2147483647, utilizing 32 bits of memory. This agent type is ideal for storing whole numbers without any decimal places in the Adroit system.

Real Agent:
A Real agent is used to store double precision floating-point numbers in the Adroit system. It can hold numbers with decimal places, and utilizes 64 bits of memory to provide higher precision and a wider range of values.

Text Agent:
The Text Agent is one of the simplest types of Agents in Adroit. It stores a text string with a maximum length of 79 characters. The string can be defined at system start-up and updated as needed. Additionally, a text string can be set as a cold start value, which means it is used as the initial value when the system starts.

Frame Agent:
A Frame Agent in Adroit is capable of storing up to 32 indexed strings. The value field of this Agent is set to the string that corresponds to the current index value. This allows for efficient management and organization of multiple strings within a single agent, making it easier to access the desired string based on the assigned index value.

Basic
These agent types serve as the foundation for a system and handle the gathering, processing, and management of data from the physical external world. They include Analog, Counter, Date, Digital, Expression, Marshal, Multistate, String, String List, and Timer.

Analog Agent:
An Analog Agent stores a scaled floating-point value with user-defined scaling parameters. It checks this scaled value against alarm settings for low-low, low, high, high-high, and rate-of-change limits. If any of these alarm limits are exceeded, the Agent sets the corresponding bits in its status word. The user can also configure settings for square root extraction, alarm deadband, and cold-start initialization. Additionally, Analog Agents provide a change monitoring feature that logs events and sets the Changed status bit when the value slots change.

Example:
image

Counter Agent:
A Counter Agent is a basic tool that can calculate and track time spent on and off, count the number of on and off events, and calculate the total on and off time. It receives data from Boolean slots of other Agents. Each of these values can be individually alarmed, allowing you to generate events based on specific conditions. For example, you can trigger an event when a motor starts more times than a required threshold.

Date Agent:
The Date Agent is responsible for storing time and date information, which is broken down into separate components for the date and time. It serves as a dedicated container for managing and manipulating chronological data within the Adroit system.

Digital Agent:
A Digital Agent stores a digital value (ON/OFF) and includes text descriptions for each state. It offers value inversion, cold-start initialization, alarm checking, and a pulsed output option. When the pulsed output is enabled, the Agent remains ON for a configurable delay. The pulsed output is applied to the scaled value, so inverting the value will invert the effect of the pulsed output. Digital Agents also provide a change monitoring feature, logging events and setting the Changed status bit when the value slots change.

Example:
image

Expression Agent:
The Expression Agent is a versatile tool for creating user-defined calculations within the Adroit system. It offers various applications, including constructing control strategies, enabling/disabling alarming, implementing logging thresholds, creating animations, and simulating plant behavior. Each Expression Agent can have up to 20 input variables, sourced from other Agents or front-end devices. Multiple Expression Agents can be interconnected for more complex calculations. The expression slot holds the mathematical expression to be evaluated, following ANSI-C syntax with support for nested sub-expressions, conditional operators, mathematical functions, and more. Using generic variable input names (V1, V2, etc.) allows reusability of Expression Agents across different contexts without modifying the expression itself. The evaluation of expressions can be continuous or triggered by a pulse signal, allowing periodic evaluation by connecting the trigger input to other changing data. By connecting the trigger input to a shared input among multiple expressions, the group of expressions can be constrained to evaluate only when data is valid or meets specific conditions.

Example:
image

Marshal Agent:
The Marshal Agent in Adroit is designed to replace the marshalling function of the Multistate Agent. It gathers discreet binary data from its 16-bit raw value or value slot. Unlike the Multistate Agent, each individual bit in the Marshal Agent has the full functionality of a digital Agent. This offers enhanced capabilities, such as alarming, pulsing, naming, and defining the states of each bit (on/off, open/closed, etc.). The status bit header slots of the Marshal Agent only reflect the ON state. However, the alarming subsystem has been expanded to allow alarming for both ON and OFF states. Additionally, the relationship between the raw value and value can be reversed (mirrored). To address the properties of each bit in the Marshal Agent, you can use the following convention, for example: MarshalAgentName.BitName.slot (e.g., MSH1.Switch.Value) to refer to the Value slot of the Switch bit inside the MSH1 Marshal Agent.

Multistate Agent:
The Multistate Agent is a valuable tool for simplifying configuration and improving performance in installations with numerous drive or group controls. It enables the specification of operating and control sequences for drives by defining discrete states using a truth or logic table.This Agent can be utilized to implement custom digital controllers or display the status of motors through dynamic changes in background color, text content, and color during different state transitions of the drive group. It also allows for the implementation of prioritized alarming strategies, enhancing the overall control and monitoring capabilities of the system.

String Agent:
The String Agent serves as a storage space for text, offering a maximum capacity of 79 characters. It allows for the retrieval and management of textual information within the Adroit system.

StringList Agent:
The StringList Agent offers an expanded range of capabilities compared to the Frame Agent. It enables the storage of multiple character strings with varying lengths. These strings are indexed, and the current string indicated by the index is duplicated in the value field. One common use of the StringList Agent is mapping numeric values from a PLC to corresponding text descriptions. For instance, if a PLC value is set to 2, the Agent will display “Starting” on the Operator screen. This simplifies the implementation of this feature within an Adroit system, making it straightforward to associate numeric states with meaningful text representations.

Timer Agent:
The Timer Agent simplifies common timing operations, which were previously done using expressions, recipes, and scripts. It includes a Boolean output slot that can be enabled (TRUE) or disabled (FALSE) based on the agent’s mode. This slot can be used to activate or deactivate other agents according to the timer’s status. While the Timer Agent lacks a cold-start value, it supports real-time catch-up when transitioning from a master server to a standby server. All timing operations, except the Pulse generator, can be automatically reset if needed.

The Timer Agent can be configured for three timing modes:

  1. On timer: Enables the value slot for a specified period, acting similar to a pulsed digital.
  2. On delay timer: Delays the enabling of the value slot until a specified delay period has passed.
  3. Pulse generator: Generates square wave pulses by enabling the value slot for the duration of the pulse width, then disabling it for the delay period. The generated pulse period is the sum of the delay and pulse width times.

The Timer Agent’s status bits indicate whether the timer is running or expired. Note that the agent’s value slot and operational status are separate, and the timer may not be off when its value is FALSE.

Example:
image

More information: Agent Types and Scanning

1 Like