browser-based HMI and SCADA software
Configuration & Engineering Manual
Chapter 28. WebAccess Node-RED
WEBACCESS HMI AND SCADA SOFTWARE
Configuration & Engineering Manual
WebAccess Engineering Manual Contents
TABLE OF CONTENTS
28. WebAccess Node-RED 28-1
28.1 Introduction for WebAccess Node-RED.................................... 28-1
28.2 Functionalities and Features ...................................................... 28-1
28.2.1 WebAccess _IO .................................................................... 28-2
28.2.2 WebAccess_Dashboard ....................................................... 28-2
28.2.3 WebAccess _Logic ............................................................... 28-2
28.2.4 WebAccess _Math ................................................................ 28-2
28.2.5 WebAccess_Conversion ....................................................... 28-3
28.3 Execution...................................................................................... 28-3
28.3.1 Getting Started ...................................................................... 28-3
28.3.2 Editing the wiring message ................................................... 28-4
28.3.3 Workspace Management ...................................................... 28-6
28.4 WebAccess I/O Nodes................................................................. 28-8
28.4.1 GetProjectList Node .............................................................. 28-8
28.4.2 GetScadaList Node ............................................................... 28-9
28.4.3 GetTagList Node ................................................................. 28-10
28.4.4 GetTagValue Node ............................................................. 28-11
28.4.5 SetTagValue Node.............................................................. 28-13
28.5 WebAccess Dashboard Nodes ................................................ 28-15
28.5.1 BuildinWidget Node and Dashboard Node ......................... 28-17
28.5.2 CustomWidget Node and Dashboard Node ....................... 28-21
28.5.3 waGroupAid Node............................................................... 28-25
28.6 WebAccess Logic Nodes .......................................................... 28-26
28.6.1 And Node ............................................................................ 28-26
28.6.2 Or Node .............................................................................. 28-27
28.6.3 Not Node ............................................................................. 28-28
28.6.4 Equal Node ......................................................................... 28-29
28.6.5 Not Equal Node................................................................... 28-30
28.6.6 XOR-Gate Node.................................................................. 28-31
28.6.7 NAND-Gate Node ............................................................... 28-32
28.6.8 Less Than Node.................................................................. 28-33
28.6.9 Greater Than Node ............................................................. 28-34
28.6.10 Greater or Equal Node ...................................................... 28-36
28.6.11 Less Or Equal Node .......................................................... 28-37
28.6.12 NOR-Gate Node ................................................................ 28-39
28.6.13 Compare Node .................................................................. 28-39
28.7 WebAccess Math Nodes ........................................................... 28-41
28.7.1 ADD Node ........................................................................... 28-42
28.7.2 SUB Node ........................................................................... 28-43
28.7.3 MUL Node ........................................................................... 28-44
28.7.4 DIV Node ............................................................................ 28-45
28.7.5 SQRT Node ........................................................................ 28-46
28.7.6 MAX Node ........................................................................... 28-47
28.7.7 MIN Node ............................................................................ 28-48
28.7.8 EXP Node ........................................................................... 28-49
28.7.9 LOG Node ........................................................................... 28-50
28.7.10 LN Node ............................................................................. 28-51
28.7.11 ABS Node .......................................................................... 28-52
28.7.12 SIN Node ........................................................................... 28-53
page 2
WebAccess Engineering Manual Contents
28.7.13 COS Node ......................................................................... 28-54
28.7.14 TAN Node .......................................................................... 28-55
28.7.15 FilterTagValue Node .......................................................... 28-56
28.8 WebAccess Conversion Node ................................................. 28-57
28.8.1 Convert Integer to Boolean ................................................. 28-57
28.8.2 Convert Integer to String ..................................................... 28-58
28.8.3 Convert Boolean to Integer ................................................. 28-59
28.8.4 Convert Boolean to String ................................................... 28-61
28.8.5 Convert Float to String ........................................................ 28-62
28.8.6 Convert Float to Boolean .................................................... 28-63
28.8.7 Convert Float to Integer ...................................................... 28-64
28.9 Reference ................................................................................... 28-65
page 3
WebAccess Engineering Manual 28. WebAccess Node-RED
28. WebAccess Node-RED
28.1 Introduction for WebAccess Node-RED
WebAccess Node-RED is an integrated Internet of Things (IoT) platform based
on WebAccess and Node-RED. Node-RED provides the different type of nodes
including input nodes, output nodes, basic function nodes, social nodes, file
nodes, advance nodes, and so on. Input nodes allow user to import messages or
set the node properties into a work flow, and output nodes allow user to export
the message in the work flow. Basic function nodes provide the configurable
setting for user to create the adaptive function. User can communicate with
social network by using the social nodes. Users can read the specified file and
sends the content by using the file nodes. WebAccess is a web browser-based
software package for viewing and controlling automation equipment, and
Node-RED is a visual tool for wiring the IoT. WebAccess Node-RED takes full
advantage of WebAccess and Node-RED, providing functional nodes that
retrieve tag information from WebAccess (e.g., value, quality) with a flow editor
that can wire together flows using function nodes in the palette. Using the
WebAccess Dashboard, the WebAccess nodes’ tag values can be displayed to
users in real-time with dynamically updated graphics.
Note - The detail description of Node-RED is on the Node-RED official website
(see Node-RED manual).
28.2 Functionalities and Features
WebAccess Node-RED provides both the basic Node-RED function (Node-RED
v0.11.1) and an extended function that supports WebAccess. This manual
introduces the integrated function for WebAccess, and this Guide provides
generalized explanations for using the function node, configuring
communications, and building graphics and web deployment for WebAccess
applications. WebAccess Node-RED is consisted of 38 WebAccess function nodes
can support the following functionalities:
Types Quantity
WebAccess _IO 5
WebAccess_Dashboard 4
WebAccess _Logic 13
WebAccess _Math 15
WebAccess_Conversion 1
WebAccess Node-RED 38
WebAccess Engineering Manual 28. WebAccess Node-RED
28.2.1 WebAccess _IO
Description: Get the information such as project lists, SCADA lists, and tag value
from WebAccess.
The function nodes:
(1) GetProjectList node
(2) GetScadaList node
(3) GetTagList node
(4) GetTagValue node
(5) SetTagValue nodes
28.2.2 WebAccess_Dashboard
Description: User can use the WebAccess_Dashboard node to create the
widget/dashboard format, and import the configured format to the WebAccess
Dashboard.
The function nodes:
(1) BuildinWidget node (input node)
(2) CustomWidget node (input node)
(3) Dashboard node (output node)
(4) WaGroupAid node
28.2.3 WebAccess _Logic
Description: General logical computation.
The function nodes:
(1) AND node
(2) OR node
(3) NOT node
(4) NAND node
(5) NOR node
(6) XOR node
(7) Equal node
(8) NotEqual node
(9) LessThan node
(10) LessThanOrEqual node
(11) GreaterThan node
(12) GreaterThanOrEqual node
(13) Compare node
28.2.4 WebAccess _Math
Description: General mathematical computation.
The function nodes:
WebAccess Engineering Manual 28. WebAccess Node-RED
(1) ADD node
(2) SUB node
(3) MUL node
(4) DIV node
(5) EXP node
(6) SQRT node
(7) MAX node
(8) MIN node
(9) LOG node
(10) LN node
(11) ABS node
(12) SIN node
(13) COS node
(14) TAN node
(15) FilterTagValue node
28.2.5 WebAccess_Conversion
Description: Data type conversion including:
Integer to Float
Float to Boolean
Float to Integer
Boolean to Integer
Integer to Boolean
The function node:
(1) Conversion node
28.3 Execution
In this chapter, we introduce the functional node of WebAccess Node-RED. This
Guide describes the functionalities, including WebAccess I/O, WebAccess
Dashboard, WebAccess Logic, WebAccess Math, and WebAccess Conversion.
28.3.1 Getting Started
WebAccess Project Manager is used to manage web-based projects, and the
WebAccess Node-RED link is found in the projects lists. Using WebAccess
Project Manager, users can access WebAccess Node-RED to configure a project
flow.
WebAccess Engineering Manual 28. WebAccess Node-RED
The above figure shows the default workspace of WebAccess Node-RED. On the
left side of the window is the nodes list, which displays icons of nodes that can
be added to the project flow. These icons can be dragged to Workspace, and two
nodes can be wired together by dragging from the output port of one node to
the input port of the other node. Double-clicking on the function node brings up
the edit dialog, which allows users to pass a message through the JavaScript
function. The project flow can be uploaded to the server by clicking the Deploy
button. On the right side of the window is the information and debug tabs. The
properties and a description of the nodes are displayed on the information tab,
and debugging results are displayed on the debug tab. User information is
displayed on the top-right side of the window, and the current WebAccess
project information is shown on the top-left side of the window.
28.3.2 Editing the wiring message
The function node allows JavaScript code to edit the wiring message.
The wiring message is an object called msg, the “payload” property of message
object (msg.payload) containing the body of the message.
Double click on the function node brings up the edit dialog Edit the function
with JavaScript code.
WebAccess Engineering Manual 28. WebAccess Node-RED
WebAccess Engineering Manual 28. WebAccess Node-RED
28.3.3 Workspace Management
Users (with edit right) can export, import, create, delete, copy and rename the
project. Users can add and reorder the nodes via drag and drop items on the
workspace.
The default workspace management is specified by:
1. Open the Sidebar
2. Click Workspaces
WebAccess Engineering Manual 28. WebAccess Node-RED
3. Tab rename: Double click the tab -> Edit the tab name
For WebAccess Node-RED, there are three cornerstones: the function nodes, the
project flow, and web storage. All device nodes are relations or attributes of this
base. The project flow is a set of the inputs nodes, the function nodes, and the
output node (outcomes).The default project flow management is specified by:
1. Choose the nodes you want to copy -> Open the Sidebar (Ctrl–Space or
via the dropdown menu) -> Export the nodes to the clipboard -> Copy
the code in the function field
WebAccess Engineering Manual 28. WebAccess Node-RED
2. Open the Sidebar (Ctrl–Space or via the dropdown menu) -> Import
the nodes to the clipboard -> Paste the code into the function field.
28.4 WebAccess I/O Nodes
WebAccess uses a web server as a project node that provides the initial link
between Clients and the SCADA nodes. The SCADA node communicates to the
automation equipment using communication drivers supplied with WebAccess
and also provides alarms, logs, reports, calculations, and other SCADA features.
Tags used to represent data are read from the automation equipment under the
SCADA Node. WebAccess I/O nodes ( , , ) allow
users to retrieve tag information from WebAccess, such as Project nodes,
SCADA nodes, tags.
28.4.1 GetProjectList Node
Description: Use the GetProjectList node to get the project list from WebAccess.
Flow: The simple flow consists of one input node, one GetProjectList node, and
one debug node.
WebAccess Engineering Manual 28. WebAccess Node-RED
Input: Double-click on the function node to bring up the edit dialog.
Name (optional): The node display name
Output : The follow message is the project information result:
[{
"ID": 5,
"Name": "Express",
"Description": "WebAccess Express"
}, {
"ID": 1,
"Name": "RptProject",
"Description": "Project Description"
}]
28.4.2 GetScadaList Node
Description: Use the GetScadaList node to get the SCADA node list from
WebAccess projects.
Flow: The simple flow consists of one input node, one GetScadaList node, and
one debug node.
Input: Double-click on the Function node to bring up the edit dialog.
WebAccess Engineering Manual 28. WebAccess Node-RED
Project: The WebAccess current project.
Name (optional): The node display name.
Output : The follow message is the project information result:
[{
"NodeName": "RemoteScada",
"Description": ""
}, {
"NodeName": "RptNode",
"Description": ""
}, {
"NodeName": "SCADA",
"Description": ""
}]
28.4.3 GetTagList Node
Description: Use the GetTagList node to get the tag list from WebAccess SCADA
node.
Flow: The simple flow consists of one input node, one GetTagList node, and one
debug node.
Input: Double-click on the Function node to bring up the edit dialog.
WebAccess Engineering Manual 28. WebAccess Node-RED
Project: The WebAccess current project.
Scada: The WebAccess SCADA node.
Comport: The WebAccess device comport.
Name (optional): The node display name.
Output : The follow message is the project information result:
[{
"Name": "AoTag01",
"Description": "Description of AoTag01"
}, {
"Name": "AoTag02",
"Description": "Description of AoTag02"
}]
28.4.4 GetTagValue Node
Description: Use the GetTagValue node to get the tag data from WebAccess
SCADA Node.
Flow: The simple flow consists of one input node, one GetTagValue node, and
one debug node.
WebAccess Engineering Manual 28. WebAccess Node-RED
Input: Double-click on the Function node to bring up the edit dialog.
Name (optional): The node display name
Project (Default): The WebAccess Project Name
Tag: Manual or payload
Tag Name: The WebAccess tag Name
Value Type: Number/ Text
DispName (optional): The tag description
Display (optional): The node display name
Add the tag:
Remove the tag:
Output : The follow message is the project information result:
WebAccess Engineering Manual 28. WebAccess Node-RED
[{
"name": "RptTagAi001",
"value": "601.00",
"quality": 0,
"disp": " DISPNAME1"
}, {
"name": "RptTagAi002",
"value": "102.00",
"quality": 0,
"disp": "RptTagAi002"
}, {
"name": "RptTagAi003",
"value": "670.00",
"quality": 0,
"disp": "RptTagAi003"
}]
28.4.5 SetTagValue Node
Description: Use the SetTagValue node to set the value of tags from WebAccess
SCADA Node.
Flow: The simple flow consists of one input node, one SetTagValue node, and
one debug node.
Input: Double-click on the Function node to bring up the edit dialog.
WebAccess Engineering Manual 28. WebAccess Node-RED
Name (optional): The node display name
Project (Default): The WebAccess Project Name
Tag: Manual or payload
Tag Name: The WebAccess tag Name
Value Type: Number/ Text
Tag Value: The WebAccess tag value
Add the tag:
Remove the tag:
Output : msg.payload (Boolean): 1
WebAccess Engineering Manual 28. WebAccess Node-RED
[{
"name": "RptTagAi001",
"value": "601.00",
"quality": 0,
"disp": " DISPNAME1"
}, {
"name": "RptTagAi002",
"value": "102.00",
"quality": 0,
"disp": "RptTagAi002"
}, {
"name": "RptTagAi003",
"value": "670.00",
"quality": 0,
"disp": "RptTagAi003"
}]
28.5 WebAccess Dashboard Nodes
Dashboard Editor, Dashboard Viewer, and Built-in Widgets are three main
components of WebAccess Dashboard. Corresponding to the function of WebAccess
Dashboard, WebAccess Node-RED provides the WebAccess Dashboard Nodes which
includes widget node and dashboard node . Each
WebAccess Widget has its unique structure and properties. Using the WebAccess
Dashboard nodes to create the widget must follow the structure of properties for
every type of widget. The properties of the WebAccess widgets are shown as
follows.
WebAccess Engineering Manual 28. WebAccess Node-RED
Property type Description
Interval Data refresh time interval.
Title The title of Widget
Maximum The maximum scales of coordinate axes
Minimum The minimum scales of coordinate axes
Name The function node name
Interval type Set data refresh time in PC/Pad and Phone
mode (unit: Days/ Hours/ Minutes/
Seconds).
Data Type Last/Maximum/Minimum/Average
Tag list WebAccess/SCADA Tag list array
Comparison type Year base ratio/Link relative ratio
Time mode Choose start interval mode and current
time mode in time setting.
Amount Set number
Start time Set start time.
Hours Set hours
Minutes Set minutes
End time Set end time.
Hours Set hour
Minutes Set minutes
Mode None/Gmapvalue
Zoom The zoom level of the map
Latitude The latitude of the location
Longitude The longitude of the location
WebAccess SCADA node name WebAccess SCADA name
Display text Set text which display in widget
Video URL path The URL of Video
WebAccess Engineering Manual 28. WebAccess Node-RED
28.5.1 BuildinWidget Node and Dashboard Node
Description: Configuring the format of WebAccess Widget and Dashboard.
Flow: The simple flow consists of one input node, one BuildinWidget node, and
one Dashboard node.
Importing data from external or internal data sources to the BuildinWidget
Node.
(1) Internal data source: data from WebAccess
(2) External data source: data from other institute (e.g., The Central Weather
Bureau, CWB). The project flow can listens for a HTTP request from any
source.
Input:
(1) Data from WebAccess: Using the WebAccess IO node to receive data from
WebAccess.
Double click the WebAccess GetTagValue node, and choose the tag you want
to display on the widget.
WebAccess Engineering Manual 28. WebAccess Node-RED
(2) Data from external data source:
Node-Red provides some function node which can receive data from http
requests, web socket, and the received data applied in the other function node
(e.g., ParseTemp node) to filter the useful property.
Double click the http request node, and edit data source path.
WebAccess Engineering Manual 28. WebAccess Node-RED
For internal and external data source, the format of wiring message must be as
follows.
webaccess: {
name: 'YourName',
value: 100,
time: now
Note - The information of editing the function node (see section 28.3.2).
Widget property setting: The widget properties are different from widget types.
WebAccess Engineering Manual 28. WebAccess Node-RED
Dashboard property setting:
Project: WebAccess Project Name.
Mode: The widget display mode such as replace, merge, and no
replace.
Name: The function node name.
Output : Trend, Bar, Area, Gauge, Pie, Text, Google Map Widget
WebAccess Engineering Manual 28. WebAccess Node-RED
28.5.2 CustomWidget Node and Dashboard Node
Description: Use the CustomWidget node and the Dashboard node to create
WebAccess Widget and Dashboard. WebAccess Dashboard provides a
customized widget tool. The user can access the customized widget via the
CustomWidget node.
WebAccess Engineering Manual 28. WebAccess Node-RED
Flow: The simple flow consists of one input node, one CustomWidget Node, and
one Dashboard node.
Importing data from external or internal data sources to the CustomWidget
Node.
(1) Internal: Data from WebAccess
(2) External: Data from other institute (e.g., The Central Weather Bureau,
CWB). The project flow can listens for a HTTP request from any source.
Input:
WebAccess Engineering Manual 28. WebAccess Node-RED
(1) Data from WebAccess: Using the WebAccess IO node to receive data
from WebAccess.
(2) Data from external data source:
Node-Red provides some function node which can receive data from http
requests, web socket, and the received data applied in the other function node
(e.g., ParseTemp node) to filter the useful property.
For internal and external data source, the format of wiring message must be as
follows.
webaccess: {
name: 'YourName',
value: 100,
time: now
Note - The information of editing the function node (see section 28.3.2).
Widget property setting
Choose one of the WebAccess widget
Interval: Data refresh time interval.
WebAccess Engineering Manual 28. WebAccess Node-RED
Title: The title of Widget
Type: The widget user defined
Name: The function node name
Dashboard property setting:
Project: WebAccess Project Name.
Mode: The widget display mode such as replace, merge, and no
replace.
Name: The function node name.
Output: The widget customer defined
WebAccess Engineering Manual 28. WebAccess Node-RED
28.5.3 waGroupAid Node
Description: Use the waGroupAid node to group the data. The waGroupAid node
has to be used with the Real-time Bar Group widget.
Flow: The simple flow consists of one input node, some data nodes
(GetTagValue nodes/ HTTP request nodes), one waGroupAid node, and one
BuildinWidget node, and one Dashboard node.
Input:
Group Name: The group name.
Data Name Order: The order of data labels.
Name: The function node name.
Output: The data display on the WebAccess Dashboard based on different
group.
WebAccess Engineering Manual 28. WebAccess Node-RED
28.6 WebAccess Logic Nodes
In a simple logic computation, you use the function nodes and the
WebAccess Logic nodes (e.g., ) to calculate those values. WebAccess Math
nodes represent the logical operators. Entering values directly in the function node,
the wiring messages represent the logical operand. Output is the calculation result of
the logical computation.
Note - The information of editing the function node (see section 28.3.2).
28.6.1 And Node
Description: The logical operators “AND” specify the relationship between the
input nodes in a logical expression.
Flow: The simple flow consists of one input node, some function nodes, one And
node, and one debug node.
Input:
Multiple input nodes are allowed.
The format of the wiring message: msg.payload = value
WebAccess Engineering Manual 28. WebAccess Node-RED
Output: true or false
28.6.2 Or Node
Description: The logical operators “OR” specify the relationship between the
input nodes in a logical expression.
Flow: The simple flow consists of one input node, some function nodes, one Or
node, and one debug node.
Input:
Multiple input nodes are allowed.
The format of the wiring message: msg.payload = value
WebAccess Engineering Manual 28. WebAccess Node-RED
Output: true or false
28.6.3 Not Node
Description: The logical operators “Not” specify the relationship between the
input nodes in a logical expression.
Flow: The simple flow consists of one input node, one function node, one Not
node, and one debug node.
Input:
Only one input node is required.
The format of the wiring message: msg.payload = value
WebAccess Engineering Manual 28. WebAccess Node-RED
Output: true or false
28.6.4 Equal Node
Description: The “Equal” logic expressions for the calculation used in these input
nodes.
Flow: The simple flow consists of one input node, some function nodes, one
Equal node, and one debug node.
Input:
Multiple input nodes are allowed.
The format of the wiring message: msg.payload = value
WebAccess Engineering Manual 28. WebAccess Node-RED
Output: true or false
28.6.5 Not Equal Node
Description: The “Not Equal” logic expressions for the calculation used in these
input nodes.
Flow: The simple flow consists of one input node, some function nodes, one Not
Equal node, and one debug node.
Input:
Multiple input nodes are allowed.
The format of the wiring message: msg.payload = value
WebAccess Engineering Manual 28. WebAccess Node-RED
Output: true or false
28.6.6 XOR-Gate Node
Description: The logical operators “XOR” specify the relationship between the
input nodes in a logical expression.
Flow: The simple flow consists of one input node, some function nodes, one
XOR-Gate node, and one debug node.
Input:
Multiple input nodes are allowed.
The format of the wiring message:
WebAccess Engineering Manual 28. WebAccess Node-RED
Output: The value of exclusive disjunction operation
28.6.7 NAND-Gate Node
Description: The logical operators “NAND” specify the relationship between the
input nodes in a logical expression.
Flow: The simple flow consists of one input node, some function nodes, one
NAND-Gate node, and one debug node.
Input:
Multiple input nodes are allowed.
The format of the wiring message: msg.payload = value
WebAccess Engineering Manual 28. WebAccess Node-RED
Output: The value of “NAND” operation
28.6.8 Less Than Node
Description: Compares the values of two input nodes. Return true if one node is
less than the other node.
Flow: The simple flow consists of one input node, two function nodes, one Less
Than node, and one debug node.
Input:
Two input nodes are required.
The format of the wiring message:
WebAccess Engineering Manual 28. WebAccess Node-RED
Output: true (left-value < right-value), false (left-value ≥ right-value)
28.6.9 Greater Than Node
Description: Compares the values of two input nodes. Return true if one node is
greater than the other node.
Flow: The simple flow consists of one input node, two function nodes, one
Greater Than node, and one debug node.
WebAccess Engineering Manual 28. WebAccess Node-RED
Input:
Two input nodes are required.
The format of the wiring message:
WebAccess Engineering Manual 28. WebAccess Node-RED
Output: true (left-value > right-value), false (left-value ≤ right-value)
28.6.10 Greater or Equal Node
Description: Compares the values of two input nodes. Return true if one node is
equal or greater than the other node.
Flow: The simple flow consists of one input node, two function nodes, one
Greater or Equal node, and one debug node.
Input:
Two input nodes are required.
The format of the wiring message:
WebAccess Engineering Manual 28. WebAccess Node-RED
Output: true (left-value ≥ right-value), false (left-value < right-value)
28.6.11 Less Or Equal Node
Description: Compares the values of two input nodes. Return true if one node is
equal or less than the other node.
Flow: The simple flow consists of one input node, two function nodes, one Less
Or Equal node, and one debug node.
WebAccess Engineering Manual 28. WebAccess Node-RED
Input:
Two input nodes are required.
The format of the wiring message:
WebAccess Engineering Manual 28. WebAccess Node-RED
Output: true (left-value ≤ right-value), false (left-value > right-value)
28.6.12 NOR-Gate Node
Description: The logical operators “NOR” specify the relationship between the
input nodes in a logical expression.
Flow: The simple flow consists of one input node, some function nodes, one
NOR-Gate node, and one debug node.
Input:
Multiple input nodes are allowed.
The format of the wiring message: msg.payload = value
Output: The value of “NOR” operation
28.6.13 Compare Node
Description: Comparing the values between two input nodes.
WebAccess Engineering Manual 28. WebAccess Node-RED
Flow: The simple flow consists of one input node, two function nodes, one
Compare node, and one debug node.
Input:
Two input nodes are required.
The format of the wiring message:
WebAccess Engineering Manual 28. WebAccess Node-RED
Output: 0(equal), -1(not equal)
28.7 WebAccess Math Nodes
In a simple mathematical computation, you use the function nodes and the
WebAccess Math nodes (e.g., ) to calculate those values. WebAccess Math
nodes represent the math operators. Entering values directly in the function node, the
WebAccess Engineering Manual 28. WebAccess Node-RED
wiring messages represent the math operand. Output is the calculation result of the
mathematical computation.
Note - The information of editing the function node (see section 28.3.2).
28.7.1 ADD Node
Description: Addition; Use the ADD node to add a set of input numbers.
Flow: The simple flow consists of one input node, some function nodes, one ADD
node, and one debug node.
Input:
Multiple input nodes are allowed.
The format of the wiring message: msg.payload = value
Output: The sum of a set of input values (e.g., 1+2+3=6)
WebAccess Engineering Manual 28. WebAccess Node-RED
28.7.2 SUB Node
Description: Subtraction; Obtain the difference between input numbers using
SUB node.
Flow: The simple flow consists of one input node, two function nodes, one SUB
node, and one debug node.
Input:
Two input nodes are required.
The format of the wiring message:
WebAccess Engineering Manual 28. WebAccess Node-RED
Output: Subtract the right-value from the left-value (e.g., 1-2=-1)
28.7.3 MUL Node
Description: Addition; Use the ADD node to add a set of input numbers.
Flow: The simple flow consists of one input node, some function nodes, one MUL
node, and one debug node.
WebAccess Engineering Manual 28. WebAccess Node-RED
Input:
Multiple input nodes are allowed.
The format of the wiring message: msg.payload = value
Output: The sum of a set of input values (e.g., 1+2+3=6)
28.7.4 DIV Node
Description: Division; Use the DIV node to divide numbers.
Flow: The simple flow consists of one input node, two function nodes, one DIV
node, and one debug node.
Input:
WebAccess Engineering Manual 28. WebAccess Node-RED
Two input nodes are required.
The format of the wiring message: msg.payload = value
Output: Multiplication result (e.g., 1× 2× 3=6)
28.7.5 SQRT Node
Description: Use the SQRT node to calculate the Exponential function.
Flow: The simple flow consists of one input node, one function node, one SQRT
node, and one debug node.
WebAccess Engineering Manual 28. WebAccess Node-RED
Input:
Only one input node is required.
The format of the wiring message: msg.payload = value
Output: The value of square root (e.g., √9=3)
28.7.6 MAX Node
Description: Maximum; Use the MAX node to calculate the largest number in a
set of values.
Flow: The simple flow consists of one input node, some function nodes, one MAX
node, and one debug node.
Input:
WebAccess Engineering Manual 28. WebAccess Node-RED
Multiple input nodes are allowed.
The format of the wiring message: msg.payload = value
Output: The largest value in a set of input number (e.g., Max {1, 2, 3} =3)
28.7.7 MIN Node
Description: Minimum; Use the MIN node to calculate the smallest number in a
set of values.
Flow: The simple flow consists of one input node, some function nodes, one MIN
node, and one debug node.
Input:
WebAccess Engineering Manual 28. WebAccess Node-RED
Multiple input nodes are allowed.
The format of the wiring message: msg.payload = value
Output: The smallest value in a set of input number (e.g., Min {1, 2, 3} =1)
28.7.8 EXP Node
Description: Use the EXP node to calculate the Exponential function.
Flow: The simple flow consists of one input node, one function node, one EXP
node, and one debug node.
Input:
Only one input node is required.
The format of the wiring message: msg.payload = value
WebAccess Engineering Manual 28. WebAccess Node-RED
Output: The value of exponential function (e.g., e2=7.39)
28.7.9 LOG Node
Description: Logarithm; Use the LOG node to calculate the logarithm. (Note:
Logarithm base 10)
Flow: The simple flow consists of one input node, one function node, one LOG
node, and one debug node.
Input:
Only one input node is required
The format of the wiring message: msg.payload = value
WebAccess Engineering Manual 28. WebAccess Node-RED
Output: The logarithm of a number to the base you specify (e.g., log 1010=1)
28.7.10 LN Node
Description: Natural logarithm; Use the LN node to calculate the natural
logarithm. (Note: Logarithm base e)
Flow: The simple flow consists of one input node, one function node, one ADD
node, and one debug node.
Input:
Only one input node is required
The format of the wiring message: msg.payload = value
WebAccess Engineering Manual 28. WebAccess Node-RED
Output: The natural logarithm of a number (e.g., ln (2) =0.69)
28.7.11 ABS Node
Description: Absolute value; Use the ABS node to calculate the absolute value of
a number.
Flow: The simple flow consists of one input node, one function node, one ABS
node, and one debug node.
Input:
Only one input node is required.
The format of the wiring message: msg.payload = value
WebAccess Engineering Manual 28. WebAccess Node-RED
Output: The absolute value of a number (e.g.,|-2|=2)
28.7.12 SIN Node
Description: Use the SIN node to calculate the sine of the given angle.
Flow: The simple flow consists of one input node, some function nodes, one SIN
node, and one debug node.
Input:
Only one input node is required.
The format of the wiring message: msg.payload = value
WebAccess Engineering Manual 28. WebAccess Node-RED
Output: The sum of a set of input values (e.g., 1+2+3=6)
28.7.13 COS Node
Description: Use the COS node to calculate the cosine of the given angle.
Flow: The simple flow consists of one input node, some function nodes, one COS
node and one debug node.
Input:
Only one input node is required.
The format of the wiring message: msg.payload = value
WebAccess Engineering Manual 28. WebAccess Node-RED
Output: The cosine of the angle you specify (e.g., cos (-2) =-0.4)
28.7.14 TAN Node
Description: Use the TAN node to calculate the tangent of the given angle.
Flow: The simple flow consists of one input node, some function nodes, one TAN
node, and one debug node.
Input:
Only one input node is required.
The format of the wiring message: msg.payload = value
WebAccess Engineering Manual 28. WebAccess Node-RED
Output: The tangent of the angle you specify (e.g., tan (-2) =2.19)
28.7.15 FilterTagValue Node
Description: Use the FilterTagValue node to filter WebAccess data according to
their property.
Flow: The simple flow consists of one input node, one WebAccess _IO nodes,
one FilterTagValue node, and one debug node.
Input:
Multiple input nodes are allowed.
The format of the wiring message: “property name : value”
WebAccess Engineering Manual 28. WebAccess Node-RED
[{
"name": "AI01",
"quality": -2,
"value": 0,
"disp": "W4012_CC0096-DI0"
}]
Property Name: The one of WebAccess data properties such as
name, quality, value.
Output: The value of the given property (e.g., "W4012_CC0096-DI0")
28.8 WebAccess Conversion Node
There are three common data types in wiring message: Number, String, and
Boolean. The WebAccess Conversion node can convert data
type of the wiring message to another type user specified (e.g., Integer
String).
Note - The information of editing the function node (see section 28.3.2).
28.8.1 Convert Integer to Boolean
Description: Use the WebAccess Conversion node to convert Integer to Boolean.
Flow: The simple flow consists of one input node, one function node, one
Conversion node, and one debug node.
WebAccess Engineering Manual 28. WebAccess Node-RED
Input:
Only one input node is required.
The data type of wiring message must be Integer: msg.payload = Integer
Conversion type (via the dropdown menu): Integer to Boolean
Output: true or false (Boolean).
28.8.2 Convert Integer to String
Description: Use the WebAccess Conversion node to convert Integer to String.
WebAccess Engineering Manual 28. WebAccess Node-RED
Flow: The simple flow consists of one input node, one function node, one
Conversion node, and one debug node.
Input:
Only one input node is required.
The data type of wiring message must be Integer: msg.payload = Integer
Conversion type (via the dropdown menu): Integer to String
Output: String
28.8.3 Convert Boolean to Integer
Description: Use the WebAccess Conversion node to convert Boolean to Integer.
WebAccess Engineering Manual 28. WebAccess Node-RED
Flow: The simple flow consists of one input node, one function node, one
Conversion node, and one debug node.
Input:
Only one input node is required.
The data type of wiring message must be Boolean: msg.payload = true or
false
Conversion type (via the dropdown menu): Boolean to Integer
Output: Integer
WebAccess Engineering Manual 28. WebAccess Node-RED
28.8.4 Convert Boolean to String
Description: Use the WebAccess Conversion node to convert Boolean to String.
Flow: The simple flow consists of one input node, one function node, one
Conversion node, and one debug node.
Input:
Only one input node is required.
The data type of wiring message must be Boolean :msg.payload = true or
false
Conversion type (via the dropdown menu): Boolean to String
WebAccess Engineering Manual 28. WebAccess Node-RED
Output: true or false
28.8.5 Convert Float to String
Description: Use the WebAccess Conversion node to convert Float to String.
Flow: The simple flow consists of one input node, one function node, one
Conversion node, and one debug node.
Input:
Only one input node is required.
The data type of wiring message must be Float :msg.payload = Float
Conversion type (via the dropdown menu): Float to String
WebAccess Engineering Manual 28. WebAccess Node-RED
Output: String
28.8.6 Convert Float to Boolean
Description: Use the WebAccess Conversion node to convert Float to Boolean.
Flow: The simple flow consists of one input node, one function node, one
Conversion node, and one debug node.
Input:
Only one input node is required.
The data type of wiring message must be Float :msg.payload = Float
WebAccess Engineering Manual 28. WebAccess Node-RED
Conversion type (via the dropdown menu): Float to Boolean
Output: true or false
28.8.7 Convert Float to Integer
Description: Use the WebAccess Conversion node to convert Float to Integer.
Flow: The simple flow consists of one input node, one function node, one
Conversion node, and one debug node.
Input:
Only one input node is required.
WebAccess Engineering Manual 28. WebAccess Node-RED
The data type of wiring message must be Float :msg.payload = Float
Conversion type (via the dropdown menu): Float to Integer
Output: Integer
28.9 Reference
[1] Node-RED manual, http://nodered.org/docs/