System Variables

Movicon has a range of prefixed variables, dedicated to give the programmer the possibility to interact with the project and with the system, to facilitate information availability and managed commands by exploiting the logic.

 

The System Variables managed in Words contain a number in decimal format supplied or to be supplied to the system.

The ''strobe' bits are managed by using the logic state set at '1' for safe task synchronizing. When the strobe is 'from Movicon to Logic', the supervisor will set the strobe bit  to '1' and the logic , after having interpreted it, will return it to state '0'. When the strobe is 'from logic to Movicon', the logic should set the strobe bit to '1' and the supervisor, after having interpreted the request, will reset the  state  to '0'.

 

In a networking Server/Client architecture, the Server's  "_SysVar_" variable  cannot be connected directly to the Client.  If you need to have information about the local Server's  "_SysVar_" on the Client, you should use the Server project's IL General logic to transfer the value of the desired "_SysVar_" member to a new variable created in the same Server and exchanged in Networking on Client side.   

 

 

The System variables are grouped into a variable structure type. To use the System Variables you first need to insert the variable structure by using the 'Add a System Variable' command in the  "Project Explorer" window or by right mouse clicking on the 'Real Time DB' resource. By executing this command the structure prototype and the relative variable called "_SysVar_" will be inserted. Each member of the structure variable has a precise significance as described in the table below:

 

Variable Name

Refresh Time

Type

Description

SimSinDouble

-

Double

Simulation of sine of an angle varying from 0 to 360 degrees. The resulting value will range from -1 to +1 including decimals.

 

SimSinInt

-

Sign Byte

Simulation of sine of an angle varying from 0 to 360 degrees, The value is express in percentages as an integer and will range from 100 to +100.

 

SimCosDouble

-

Double

Simulation of cosine of an angle varying from 0 to 360 degrees.  The resulting value will range from -1 to +1 including decimals.

 

SimCosInt

-

Sign Byte

Simulation of cosine of an angle varying from 0 to 360 degrees. The value is expressed in percentages as an integer and will range from  100 to +100

 

SimRampDouble

-

Double

Simulation of a saw-tooth ramp with values ranging from -10 to +10 including decimals.

 

SimRampInt

-

Sign Word

Simulation of a saw-tooth ramp with values ranging from -10000 to +10000.

 

SimRandDouble

-

Double

Random number generation with values ranging from 0 to +32767.

 

SimRandInt

-

Sign Word

Random number generation with values ranging from 0 to +32767.

SimRandString

-

String

Random string Generation.

StrobeLocalTime

-

Bit

Command Strobe for carrying out changes to the system's time. Movicon executes the update and automatically returns the command to zero value.

 

ToggleBits

-

Byte

Each bit of this variable blinks with a different frequency:

Bit 00 = 125 ms Blinks

Bit 01 = 250 ms Blinks

Bit 02 = 500 ms Blinks

Bit 03 = 1 s Blinks

Bit 04 = 2.5 s Blinks

Bit 05 = 5 s Blinks

Bit 06 = 10 s Blinks

Bit 07 = not used

 

ActTimeSec

-

Byte

System Time: Seconds

 

ActTimeMin

-

Byte

System Time: Minutes

 

ActTimeHour

-

Byte

System Time: Hours

 

ActTimeDay

-

Byte

System Time: Day

 

ActTimeMonth

 

Byte

System Time: Month

 

ActTimeYear

 

Word

System Time: Year

 

ActTimeString

 

String

System Time in string value

 

ActDateString

 

String

System Date in string value

 

StrobeExitApp

 

Bit

setting this bit to true will control application exist and system shutdown.

StrobeYearLocalTime

 

Word

Year to be set in System's time (> 1980)

 

StrobeMonthLocalTime

 

Byte

Month to be set in system's time (1-12)

 

StrobeDayLocalTime

 

Byte

Day to be set in system's time (1-31)

 

StrobeHourLocalTime

 

Byte

Hour to be set in system's time (0-23)

 

StrobeMinuteLocalTime

 

Byte

Minutes to be set in system's time (0-59)

 

StrobeSecondLocalTime

 

Byte

Seconds to be set in system's time (0-59)

 

CommDriverStatus

 

Bit

Driver communication status.  The '0' value means there are  no current  communication errors.

 

ControlKeyDown

 

Bit

CTRL key pressed

 

AltKeyDown

 

Bit

ALT  key pressed

 

ShiftKeyDown

 

Bit

SHIFT  key pressed

 

LastKeyPressed

 

Word

Code of the last  key pressed

 

ActiveScreen

 

Word

The ID of the currently active screen is set in this variable.  In order to use this variable correctly you need to associate each Screen with that different ID.

 

NumberNotAckAlarms

 

Word

Number of alarms still active but not yet acknowledged.

 

AlarmsActive

 

Word

Number of active alarms. Alarms which are still active, in the ON condition, are considered whether already acknowledge or still to be acknowledged.

 

NumActiveAlarms

 

Win32/64:

refreshes once a second

WinCE: refreshed once a second

Word

 

Number of current active alarms. This variable reports the number of ON and OFF alarms currently in the system.  It is the same number of alarms displayed in the Alarm window as well.

NumActiveAlarmsON

 

Word

Number of active alarms with ON status.

NumActiveAlarmsOFF

 

Word

Number of active alarms with OFF status, which corresponds to  "NumActiveAlarms - NumActiveAlarmsON".

NumActiveSubscribedAlarms

Win32/64: refreshes once a second

WinCE: refreshed once a second

Word

Description: Represents the number of "entities" subscribed to receiving notifications when alarms change statuses. Entities which can currently subscribe are:

 

  • Alarm Window

  • Network Client

  • Secondary Server Project

  • OPC Server

  • Child Project

AlarmsSoundState

 

Bit

Variable that shows the Alarm's sound status based on the user logged on.  This variable can also be set for activating/deactivating the sound from logic.

 

MouseMove

 

Bit

This variable when set at true indicates that the Mouse is moving.

This is not managed In Windows CE as touch panel devices do not have the mouse.

 

OutputAckAlarms

 

Bit

This variable is set at True by Movicon when alarms are acknowledged with the button in the alarm window. The programmer must reset the variable to false.

 

OutputResetAlarms

 

Bit

This variable is set at true by Movicon when alarms are reset with the button in the alarm window. The programmer must reset the variable to false.

 

IMDBLocalMemoryUsed

 

DWORD

Returns the size (in bytes) of memory being used by the InMemoryDB engine in the local process area.  This value is updated every minute.

IMDBSharedMemoryUsed

 

DWORD

Returns the size (in bytes) of the memory being used by the InMemoryDB engine in shared process areas.  This value is updated every minute.

IMDBLocalMemoryReserved

 

DWORD

Returns the size (in bytes) of reserved memory area that the  InMemoryDB manager can use in the local process area.  This value is updated every minute.

IMDBSharedMemoryReserved

 

DWORD

Returns size  (in bytes) reserved memory area that the InMemoryDB manager can use in the shared process area.  This value is updated every minute.

InputAckAlarms

 

Bit

This variable acknowledges alarms when set at true. After the command has been executed Movicon will reset the variable to false. Acknowledges only those alarms with have option requesting user to enter comment.

 

InputResetAlarms

 

Bit

This variable resets alarms when set at true. After the command has been executed Movicon will reset the variable to false.

 

ActiveUserName

 

String

This variable contains the name of the active user. Its value will be nothing when no users are logged on. In the case of a Network Client-Server configuration, the "ActiveUserName" variable always returns the name of the user logged in on the Server side. In order to know the Project User logged on Client side it is necessary to use the "SynopticCmdTarget" VBA function named "GetActiveUserObject"

ActivePassLevel

 

Sign Word

This variable contains the active user's password level. Its value will be -1 when no user is logged on.

 

ActiveMaskLevel

 

Signed DWord

This variable contains the active user's access level. Its value will be -1 when no user is logged on.

 

NumActiveUsers

Win32/64: refreshes once a second

WinCE: refreshed once a second

Word

Indicates the how many users are logged on or connected to the project.  This total includes all logged on user plus those users connected via WebClient.

 

LastAlarmText

 

String

In this variable are shown all the active alarm of the project with a scroll of three seconds. The scroll will be executed following the activation time of the alarms, from the oldest one to the newest one. The scroll will be executed only for the alarms with a status "ON" and not yet acknowledged.

DispatchingQueueCount

 

Word

Shows the number of messages that the dispatcher has not yet notified.  Seeing as the dispatcher can manage message notifications with programmed delay times and  depending on the alarm severity, this new counter takes into consideration those messages that are waiting in queue to be sent by the dispatcher and therefore pending and makes them persistent using the "ADPending.xml" file saved in the project's DATA folder.

StrobeLoadScreen

 

Bit

The screen indicated by the _SysVar_:ScreenToLoad  variable is loaded on strobe event when not at zero.  Once the screen is loaded, Movicon will zero the_SysVar_:StrobeLoadScreen automatically.

 

ScreenToLoad

 

Word

Indices which is the ID of the screen to be opened when the  StrobeLoadScreen command is given. Each screen can in fact be identified by a ID in their General properties. You can also open child project screens providing that they have a different ID from all the other Child and Parent projects, otherwise all those with the same ID will open. You can use the Parent project's system variable with or without the <..\> prefix in the child project.

 

HostType

Win32/64: refreshes at  startup

WinCE: refreshes at startup

String

Contains the PC's network name.  Updates at project StartUp.

 

HostIP

Win32/64: refreshes once a minute

WinCE: refreshes once a minute

String

Contains the computer's IP address.  Updates every minute.

 

PlatformVerMajor

Win32/64: refreshes at startup

WinCE: refreshes at startup

Word

Identifies the Movicon  Major version (ie. PlatformVerMajor = 11 in the Movicon 11.0.1008). Updates at project StartUp.

 

PlatformVerMinor

Win32/64: refreshes at startup

WinCE: refreshes at startup

Word

Identifies the Movicon minor version (ie. PlatformVerMinor = 0 in the Movicon  11.0.1008 ). Updates at project StartUp.

 

PlatformVerBuild

Win32/64: refreshes at startup

WinCE: refreshes at startup

Word

Identifies the Movicon Build number (ie.  PlatformVerBuild = 1008in the 11.0.1008 version). Updates at project StartUp.

 

PlatformType

Win32/64: refreshes at startup

WinCE: refreshes at startup

String

Contains the name of the platform on which the project runs. This may be  "MOVICON", "MOVCE", "POWERHMI", etc..

 

ProjectRunningInDemo

 

BIT

Gets set  to  "true" when the project goes into demo mode.  Returns to "false" when the project returns back from demo mode.  Can be  used to give notification of project going into demo mode so that it can be intervened before closing, being after 120 minutes.    

 

StartupTime

Win32/64: refreshes at startup

WinCE: refreshes at startup

String

Contains the date and time of the project startup. Updates at project StartUp.

 

CPUNameString

Win32: refreshes at startup

String

Contains the name of the CPU (ie. Intel(R) Pentium(R) 4 CPU 3.00GHz). Updates at project StartUp (not available in the  WinCE platform).

 

 

CPUVendorIdentifier

Win32: refreshes at startup

 

String

Contains the name of the CPU vendors  (ie. GenuineIntel). Updates at project StartUp (not available in the  WinCE platform).

 

 

CPUIdentifier

Win32: refreshes at startup

String

Contains the CPU version, family, model, step (ie.  x86 Family 15 Model 3 Stepping 3).  Updates at project StartUp (not available in the  WinCE platform).

 

 

CPUSpeed

Win32: refreshes at startup

String

Indicates the CPU's speed (ie. 2993). Updates at project StartUp (not available in the  WinCE platform).

 

 

CPUProcessorType

 

Word

Report the identification code of the microprocessor installed on the device in which the project is running.  

The value is retrieved at project startup.

 

PROCESSOR_INTEL_386    386

PROCESSOR_INTEL_486    486

PROCESSOR_INTEL_PENTIUM 586

PROCESSOR_INTEL_IA64    2200

PROCESSOR_AMD_X8664    8664

PROCESSOR_MIPS_R4000    4000

PROCESSOR_ALPHA_21064  21064

PROCESSOR_PPC_601      601

PROCESSOR_PPC_603      603

PROCESSOR_PPC_604      604

PROCESSOR_PPC_620      620

PROCESSOR_HITACHI_SH3  10003

PROCESSOR_HITACHI_SH3E  10004

PROCESSOR_HITACHI_SH4  10005

PROCESSOR_MOTOROLA_821  821

PROCESSOR_SHx_SH3      103

PROCESSOR_SHx_SH4      104

PROCESSOR_STRONGARM    2577

PROCESSOR_ARM720        1824

PROCESSOR_ARM820        2080

PROCESSOR_ARM920        2336

PROCESSOR_ARM_7TDMI    70001

WinMajor

Win32:  refreshes at startup

String

Indicates  Windows' Major version number (ie. 5).Updates at project StartUp (not available in the  WinCE platform).

 

 

WinMinor

Win32:  refreshes at startup

String

Indicates Windows' Minor version number (ie. 1).Updates at project StartUp (not available in the  WinCE platform).

 

BuildNumber

Win32:  refreshes at startup

String

Indicates the Windows build  (ie. 2600). Updates at project StartUp

 (not available in the  WinCE platform).

 

ServicePack

Win32:  refreshes at startup

String

Indicates the Windows Service Pack version number (is. 2). Updates at project StartUp (not available in the  WinCE platform).

 

OSType

Win32:  refreshes at startup

String

Indicates which Operating System  edition type . Updates at project StartUp (not available in the  WinCE platform).

 

TimeZoneBias

Win32/64:  refreshes once a minute

WinCE:  refreshes once a minute

String

Indicates the local time zone in minutes considering the daylight saving time (not available in the  WinCE platform).

 

IntColumnSep

Win32/64:  refreshes once a minute

WinCE:  refreshes once a minute

String

Indicates the decimal separator character for Numbers set in the OS's International Options.

 

IntTimeSep

Win32/64:  refreshes once a minute

WinCE:  refreshes once a minute

String

Indicates the separator character for the time set in the OS's International Options.

 

IntDateSep

Win32/64:  refreshes once a minute

WinCE:  refreshes once a minute

String

Indicates the separator character of the data set in the OS's International Options.

 

ShortDateFmt

Win32/64:  refreshes once a minute

WinCE:  refreshes once a minute

String

Indicates the short date format to display the date set in the OS's International Options.

 

TimeFmt

Win32/64:  refreshes once a minute

WinCE:  refreshes once a minute

String

Indicates the time format to be display the date set in the OS's International Options date settings.

 

WorkingDir

Win32: refreshes once a minute

String

Contains the directory's current set value (not available in the  WinCE platform).

 

 

LoginUserName

Win32: refreshes once a minute

String

Contains the name of the user currently logged in the OS  (not available in the  WinCE platform).

 

IsUserAdmin

Win32: refreshes once a minute

String

Indicates if the actual user logged on the Operating System is the system administrator with the value "1". (not available in the  WinCE platform).

NumExpressions

Win32/64: refreshes once a second

WinCE: refreshed once a second

Word

Number of expressions executed.

 

NumHTTPClient

Win32/64: refreshes once a second

WinCE: refreshed once a second

Word

Number of  HTTP  Clients connected to project.

 

NumHTTPOutgoingMessages

Win32/64: refreshes once a second

WinCE: refreshed once a second

Word

Number of outgoing  HTTP messages from project.

 

NumLoadedAcceleratorRes

Win32/64: refreshes once a second

WinCE: refreshed once a second

Word

Number of Accelerator resources loaded in memory.

 

NumLoadedMenuRes

Win32/64: refreshes once a second

WinCE: refreshed once a second

Word

Number of Menu resources loaded in memory.

 

NumLoadedScreenRes

Win32/64: refreshes once a second

WinCE: refreshed once a second

Word

Number of Screen resources loaded in memory.

 

NumLoadedScriptRes

Win32/64: refreshes once a second

WinCE: refreshed once a second

Word

Number of Basic Scrip resources loaded in memory.

 

NumLocalClient

Win32/64: refreshes once a second

WinCE: refreshed once a second

Word

Number of Local Clients connected to project.

 

NumLocalOutgoingMessages

Win32/64: refreshes once a second

WinCE: refreshed once a second

Word

Number of outgoing local messages from project.

 

NumTCPClient

Win32/64: refreshes once a second

WinCE: refreshed once a second

Word

Number of TCP Client connected to project.

 

NumTCPOutgoingMessages

Win32/64: refreshes once a second

WinCE: refreshed once a second

Word

Number of outgpoing TCP messages from project.

 

NumUDPClient

Win32/64: refreshes once a second

WinCE: refreshed once a second

Word

Number of UDP Clients connected to project.

 

NumUDPOutgoingMessages

Win32/64: refreshes once a second

WinCE: refreshed once a second

Word

Number of outgoing UDP messaged from project.

 

NumWebClientConnected

Win32/64: refreshes once a second

WinCE: refreshed once a second

Word

Number of WebClients connected to project.

 

OPCServerNumClients

Win32/64: refreshes once a second

Word

Number of OPC Clients connected to the Movicon OPC Server . di Client OPC connessi al Server OPC Movicon  (not available in the  WinCE platform).

PendingDLREntries

Win32/64: refreshes once a second

WinCE: refreshed once a second

Word

Number of  DataLogger/Recipe entries still to unload on file.

 

PendingLogEntries

Win32/64: refreshes once a second

WinCE: refreshed once a second

Word

Number of Historical Log entries still to unload on file.

 

PendingTraceEntries

Win32/64: refreshes once a second

WinCE: refreshed once a second

Word

Number of Variable  DB Trace entries still to unload on file.

 

MemoryLoad

Win32/64:  refreshes once a minute

WinCE:  refreshes once a minute

Word

Indicates the percentage of  allocated RAM.

 

MemoryTotalPhys

Win32/64:  refreshes once a minute

WinCE:  refreshes once a minute

Double

Indicates the  total  of physical RAM  in the system  (in Bytes).

 

MemoryAvailPhys

Win32/64:  refreshes once a minute

WinCE:  refreshes once a minute

Double

Indicates the quantity of physical  RAM available in the process  (in Bytes).

 

MemoryTotalPageFile

Win32/64:  refreshes once a minute

WinCE:  refreshes once a minute

Double

Indicates the maximum memory limit that can be allocated in the system  (in Bytes).

 

MemoryAvailPageFile

Win32/64:  refreshes once a minute

WinCE:  refreshes once a minute

Double

Indicates how much available  memory not yet allocated in the system (in Bytes). The difference between  MemoryTotalPageFile and MemoryAvailPageFile is the memory allocated in the system.

 

MemoryTotalVirtual

Win32/64:  refreshes once a minute

WinCE:  refreshes once a minute

Double

Indicates the total virtual memory available in the system  (in Bytes).

 

MemoryAvailVirtual

Win32/64:  refreshes once a minute

WinCE:  refreshes once a minute

Double

Indicates the amount of virtual memory not yet used in the system  (in Bytes).

 

FreeSpaceAlarmPath

Win32/64:  refreshes once a minute

WinCE:  refreshes once a minute

Double

Indicates available space in KBytes on the disk containing the project's Alarms folder set in the "Project Paths" settings  properties.

 

FreeSpaceResourcePath

Win32/64:  refreshes once a minute

WinCE:  refreshes once a minute

Double

Indicates the space available in bytes on the disk containing the project's resource folder set in the  "Project Paths" settings  properties.

 

FreeSpaceImagePath

Win32/64:  refreshes once a minute

WinCE:  refreshes once a minute

Double

Indicates the space available in KByteson on the disk containing the project's Images file set in the  "Project Paths" settings   properties.

 

FreeSpaceLogPath

Win32/64:  refreshes once a minute

WinCE:  refreshes once a minute

Double

Indicates the space available in  KBytes on the disk containing the projects Logs folder set in the  "Project Paths" settings   properties.

 

FreeSpaceDLRPath

Win32/64:  refreshes once a minute

WinCE:  refreshes once a minute

Double

Indicates the space available in KBytes on the disk containing the project's Data Logger/Recipe folder set in the  "Project Paths" settings  properties.

 

FreeSpaceNetworkUserPath

Win32/64:  refreshes once a minute

WinCE:  refreshes once a minute

Double

Indicates the space available in KBytes on the disk containing the project's Networking log folder set in the  "Project Paths" settings  properties.

 

FreeSpaceDataUserPath

Win32/64:  refreshes once a minute

WinCE:  refreshes once a minute

Double

Indicates the space available in KBytes on the disk containing the project's Data folder set in the  "Project Paths" settings  properties.

 

ILLogicCycleTime

Win32/64: refreshes once a second

WinCE: refreshed once a second

Word

The project's IL logic cycle time.

 

PeekInUseByte

Win32/64: refreshes once a second

WinCE: refreshed once a second

Word

retrieved peak of bytes in use during project run.

 

ProjectRunning

Win32/64: refreshes once a second

WinCE: refreshed once a second

Bit

Indicates whether project is running.  The "True" value means that the project is being  Run.

 

TotalInUseByte

Win32/64: refreshes once a second

WinCE: refreshed once a second

Word

Total number of Bytes currently in use in the project.

 

NumInUseVar

Win32/64: refreshes once a second

WinCE: refreshed once a second

Word

Indicates the number of variables which have gone into use but are still pending because Movicon has not yes processed them. This value changes from zero to a different value  when the variables go into the "In Use" from the "Not in Use" status, or vice-versa when switching over from  "In Use" status to the "Not In Use" status,  usually at project startup or page change. Once all the variables have been processed this value returns to the zero value.  When the project does not have a high number of variables, this value will stay with a different value from zero for a very short time and therefore not always retrievable.

 

NumDynVar

Win32/64: refreshes once a second

WinCE: refreshed once a second

Word

Number of variables created dynamically for objects set with a dynamic link in  their "Variable" property.

 

SRActiveShortcut

 

String

Speech Recognition: contains the path and name of the Shortcut resource currently active in the project.  (ie. C:\ProjectName\Resources\ProjectName\Shortcut1.movacc). If the   active Shortcut has not been enabled with the Speech Recognition functions, the variable will be an empty string.

 

SRLastUnderstood

 

String

Speech Recognition: contains the last word or phrase understood by the system.

 

SRListening

 

Bit

Speech Recognition: when the value is "True", this means that the Speech Recognition functions have been enabled.

 

SRIsActive

 

Bit

Speech Recognition: when the value is "True", means that the system is active and listening.

 

LicenseCode

 

String

This variable contains the license code based on the product installed, Movicon or MoviconCE. To be more exact:

 

  • Movicon: this variable returns the  serial number if a hardware license (SGLock or Eutron) and returns the  "Site Code" when a software license  (CryptKey)

  • Movicon CE: this variable returns the  "Site Code"

  •  

In cases where device is without license, the  LicenseCode variable will display an empty string.

StrobeEmptyDispatcher

 

bit

 

This variable is used for emptying the queue of messages still not sent by the Alarm Dispatcher so that they don't get sent.  Setting this variable to "1" will delete the queued messages, after which the variable will be reset to "0" by Movicon.

The deletion of messages in queue does not delete messages that are already  in progress in the Dispatcher and not yet  sent  when the empty dispatcher function is activated.

 

HisLogODBCStatus

Bit

 

This variable reveals the status of the Historical Log's ODBC connection. The "0" or "False" value indicates that the ODBC connection is working correctly, while the "1" or "True" indicates that there is an error with the connection.

 

TraceODBCStatus

Bit

 

This variable reveals the status of the Variable Trace's  ODBC connection. The "0" or "False" value indicates that the ODBC connection is working correctly, while the "1" or "True" indicates that there is an error with the connection.

 

RealTimeODBCStatus

Bit

 

This variable reveals the status of the variables'  Realtime I/O Link's ODBC connection. The "0" or "False" value indicates that the ODBC connection is working correctly, while the "1" or "True" indicates that there is an error with the connection.

 

 

See Also