日本語 English

Analog graph

Overview

Line chart

Displays a line graph
Analog values are logged into an array of up to 65534 elements, and the range you want to see is specified and displayed

Line graph display example
Line graph display example

Oscilloscope-style graph

Displays an oscilloscope-style graph
When the graph reaches the right edge, it returns to the left edge

Oscilloscope-style graph display example
Oscilloscope-style graph display example

Symbols

SetLineGraphDataINT16

SetLineGraphDataINT16 function block
In-out
Data
Data to display in the graph (variable-length array)
Input
OffsetX
X-axis offset
OffsetY
Y-axis offset
ZoomOutX
X-axis zoom
ZoomOutY
Y-axis zoom
OutType
Output type
Output
Graph
Data for graph display (array)

Output type enumeration

When the X axis is zoomed, values are combined according to the scale
This specifies how the values are combined
Average/Sum/Minimum/Maximum
For example, at 2× two values are combined into one, and at 4× four values are combined into one
enum

SetOscilloGraphDataINT16

Creates display data for an oscilloscope-style graph
SetOscilloGraphDataINT16 function block
In-out
RingBuffer
Data to display in the graph (structure for the ring buffer)
Input
OffsetY
Y-axis offset
ZoomOutY
Y-axis zoom
Separator
Display a vertical line marking the update position
Output
Graph
Data for graph display (array)

Ringbuffer structure
Ring buffer structure sRingBuf

Example

SetLineGraphDataINT16

SetLineGraphDataINT16 example ladder

Data contains 1000 traced analog values
The waveform from the position specified by OffsetX is displayed
Specify the Y-axis offset with OffsetY and the zoom with ZoomOutX and ZoomOutY, then execute to output graph display data to Graph
On the HMI, the data is set to a line graph with 600 display points

SetOscilloGraphDataINT16

SetOscilloGraphDataINT16 example ladder

Analog values are added to the ring buffer (RingBuf)
The ring buffer (RingBuf) holds 600 values and records data in a ring
Executing SetOscilloGraphDataINT16 on that data with the Y-axis offset and zoom specified outputs graph display data to Graph

Related pages

Download

Comments