Set Screen Label


ds_label_option *ID *txtColor *bgColor *txtDim

*ID = id label name
*txtColor = color text
*bgColor = background color
*txtDim = text dimension in pixel

ds_label_xy *ID *X *Y

*X *Y = screen axis

ds_label_dim *ID *W *H

*W *H = width and height

ds_label_close *ID

close label with *ID name


Insert var in text string:

ds_label_set *id *text *value < *var

Inser

Example:

#
# Make Label
var Valve = ON ds_label_option labelID black yellow 15
ds_label_xy labelID 180 60
ds_label_dim labelID 130 30
# connect label to *var ds_label_set labelID Valve
sleep 10
var Valve = OFF

Read From MTMA ( Machine To Machine Api ) SERVER NODE

var voltage = 32
# CONNECT TO M2MA Server
mtm_node MTM_BLOCK https://www.server.com/
mtm_create_node M2M_BLOCK
# LABEL SETUP
ds_label_option labelname black yellow 15
ds_label_xy labelname 180 60
ds_label_dim labelname 130 30
# DECLARE FUNCTION:
make_sub update
#LOAD FROM MTMA SERVER
sub update mtm_load MTM_NODE acs gtest3
#READ FROM MTMA Variables
# CONVERT MTMA DATA IN VARIABLE
sub update var_mtm voltage < gtest3 acs
sub update ds_label_set labelname Volt: 12 < voltage
loop myloop 10 call update
sleep 300
close_loop myloop
end_script