Skip to content

SVG Animations

SVG Animation is the core visualization component of inSCADA. Each animation consists of an SVG file and creates real-time SCADA screens by binding to variable values.

Energy Monitoring Dashboard

Creating a SCADA screen consists of three steps:

The SVG screen is designed using any SVG editor. Inkscape (free, open source) is the recommended editor.

SVG Design with Inkscape

During design:

  • Freely create the visual layout of the screen — device symbols, text fields, buttons, indicators, charts
  • You don’t need to worry about SVG IDs — inSCADA automatically scans the entire SVG tree and makes every object selectable
  • Use standard SVG elements: <rect>, <circle>, <text>, <path>, <g>, <image>
  • You can create designs as complex as you like — layers, groups, gradients, filters

In Inkscape, set the page size under File → Document Properties:

SettingRecommended ValueDescription
Width1920 pxFull HD screen width
Height1080 pxFull HD screen height
UnitpxPixel unit
Scale1.01:1 scale
OrientationLandscapeSCADA screens are typically landscape

Upload the designed SVG file to the platform:

Menu: Development → Animations → Animation Dev

Animation Dev

Create a new animation or update the SVG content of an existing animation. Once the SVG file is uploaded, it is visualized on the screen.

After the SVG is uploaded, you bind animation behaviors to each object by clicking on objects with the mouse on the screen:

  1. Click on an object on the SVG with the mouse — the object is selected and highlighted
  2. Click the Element Editor (magic wand icon) button in the upper right
  3. The applicable animation types are automatically listed based on the selected object’s type
  4. Select and configure the desired animation type
  5. Save to save

Animation Element Editor

After these three steps, the SVG screen updates with live SCADA data when you run it in the Visualization screen.

Detailed information: Element Editor →

You can preview the animation live by clicking the rocket icon:

Preview Animation

You can edit the animation’s settings by clicking the pencil icon — Duration, Play Order, Main, Color, Alignment, access roles, and Pre/Post scripts:

Animation Configuration

Detailed information: Animation Configuration →

Each animation consists of three components:

Animation
├── SVG Content (the uploaded SVG file)
├── Animation Elements (behaviors bound to objects selected with the mouse)
│ ├── Element 1: temperature text → Temperature_C (Get)
│ ├── Element 2: motor indicator → MotorStatus (Color)
│ └── Element 3: valve group → ValvePosition (Rotate)
└── Animation Scripts (code that runs every scan cycle)
├── Pre-Animation Code
└── Post-Animation Code

An Animation Element is a behavior definition bound to an object selected with the mouse on the SVG. When you click on an object and open the Element Editor, the following fields are automatically filled or configured:

FieldDescription
DOM IDThe ID of the selected SVG object (automatically retrieved — no need to enter manually)
TypeAnimation type — appropriate types are automatically listed based on the object type
Expression TypeHow the value is calculated (Tag, Expression, Switch, etc.)
ExpressionValue expression (variable name, formula, or configuration)
PropsType-specific additional settings (each type presents its own visual form)
StatusActive/inactive

inSCADA supports 36 different animation types:

TypeDescriptionPage
GetDisplay variable value as textDetails →
ColorChange element color based on valueDetails →
BarBar height/width based on valueDetails →
OpacityOpacity based on valueDetails →
VisibilityShow/hide based on conditionDetails →
RotateRotation based on valueDetails →
MoveX/Y translation based on valueDetails →
ScaleScaling based on valueDetails →
BlinkBlinking based on conditionDetails →
PipePipe/line flow animationDetails →
TooltipHover information balloonDetails →
ImageChange image based on valueDetails →
AlarmIndicationDisplay alarm statusDetails →
TypeDescriptionPage
ChartChart componentDetails →
PeityInline sparkline mini chartDetails →
DatatableTable componentDetails →
TypeDescriptionPage
SetWrite value to variable (on click)Details →
SliderAdjust value with sliderDetails →
InputText/number inputDetails →
ButtonButton componentDetails →
ClickClick eventDetails →
MouseDown / MouseUp / MouseOverMouse eventsDetails →
TypeDescriptionPage
OpenNavigate to another animationDetails →
IframeEmbed external URLDetails →
MenuOpen menuDetails →
FaceplatePlace faceplate componentDetails →
TypeDescriptionPage
ScriptRun custom JavaScriptDetails →
FormScriptForm-based scriptDetails →
GetSymbolLoad symbol from Symbol libraryDetails →
AnimateTrigger CSS/SVG animationDetails →
AccessPermission-based visibilityDetails →
Three3D visualizationDetails →
QRCodeGenerationQR code generationDetails →
QRCodeScanQR code scanningDetails →

Determines how the value is calculated in each animation element:

TypeDescription
TagDirect variable name reference
ExpressionJavaScript formula
NumericConstant numeric value
TextConstant text value
SwitchConditional selection based on value
CollectionMultiple variable collection
SetValue write expression
AnimationAnother animation reference
UrlURL reference
AlarmAlarm status reference
FaceplateFaceplate reference
Animation PopupOpen popup animation
ButtonButton configuration
InSCADA ViewPlatform view reference
System PageSystem page reference
HtmlHTML content
Custom MenuCustom menu reference
Tetra ColorFour-color status display (alarm colors)

Pre and Post scripts can be attached to each animation. All code runs again every scan cycle:

Each cycle: Pre-Animation → Elements → Post-Animation → wait (duration ms) → repeat

For code that should run only once on first load, the __firstScan variable is used:

if (__firstScan) {
// Runs only in the first cycle
var logs = ins.getLoggedVariableValuesByPage(
['ActivePower_kW'],
ins.getDate(ins.now().getTime() - 3600000),
ins.now(), 0, 100
);
}
// Runs every cycle
var power = ins.getVariableValue("ActivePower_kW").value;
return power.toFixed(1);

Detailed information: Animation Configuration → Pre/Post Scripts