Widgets Library

widget.start()
Opens TCP-Server and prepares Module for Widgets communication


widget.addStatus(ID,Description,Unit)
Adds a Status-Widget

ID = ID as Integer -> ID´s have to be continious and starting with 0 like 0,1,2,3,...
Description = Name of the Widget as String
Unit = Name of unit of the displayed value (e.g "°C")

Example:


widget.addStatus(0, "Temperature", "C"); /*please check ID*/

widget.addSlider(ID,Description,Unit,Min.Value,Max.Value)
Adds a Slider-Widget

ID = ID as Integer -> ID´s have to be continious and starting with 0 like 0,1,2,3,...
Description = Name of the Widget as String
Unit = Name of unit of the displayed value (e.g "°C")
Min.Value = The minimum value of the slider
Max.Value = The maximum value of the slider

Example:


widget.addSlider(0, "Voltage", "V", 0, 3.3); /*please check ID*/

widget.addSwitch(ID,Description,On-Description,Off-Description )
Adds a Switch-Widget

ID = ID as Integer -> ID´s have to be continious and starting with 0 like 0,1,2,3,...
Description = Name of the Widget as String
On-Description = This describes the state of the switch if the switch is "ON"
Off-Description = This describes the state of the switch if the switch is "Off"

Example:


widget.addSwitch(0, "Light", "on", "off"); /*please check ID*/