Concept

<< 点击显示目录 >>

主页  mappView帮助助手 > mapp View帮助信息 > Widgets  > Numeric  > Joystick  >

Concept

This section contains additional information about the concept of widget Joystick.

Input

This widget can only be used for input. The user can move the slider thumb in all directions within the circle. The slider thumb can be moved between the x-axis and the y-axis, for example. If the slider thumb is released, the slider thumb automatically jumps back to the center.

eingabe

Example configuration

The widget has 2 properties (xValue, yValue) that can be bound to the process variables or the output widgets. These properties range from -1 to 1 and can be used in the application as a factor, for example to define the movement of an axis.

Example: Movements on the x-axes and y-axes

Step 1: Place the widgets.

Widget "Joystick" and two BasicSlider widgets will be added to the piece of content.

To see how the values change, NumericOutput widgets are placed on the piece of content.

joystick_platzierung_widgets2

Step 2: Data binding

One numeric OPC UA variable is bound to xValue and one is bound to yValue on widget "Joystick". Writing should only be done from the widget side; for this reason, "Init read/write" is used as the binding mode.

joystick_bindung

One numeric OPC UA variable (xValueBasicSlider, yValueBasicSlider) that is added to xValue or YValue in the application is bound to "value" on each of the BasicSlider widgets. "Read-only" is used as the binding mode.

joystick_slider_xbindung

joystick_slider_ybindung

joystick_program

Results:

Widget "Joystick" can look like this when bound to the HMI application:

joystick_move0

If the slider thumb is not moved or released, the values are xValue=0 and yValue=0.

joystick_move1

If the slider thumb is dragged to the top right, the BasicSlider widgets are moved by xValue= 0.5 and yValue= 0.5.

joystick_move2

If the slider thumb is not released, a change will be made again depending on the setting.

The BasicSlider widgets are moved again by xValue= 0.5 and yValue= 0.5.

joystick_move3

The slider thumb can also be dragged into the negative area.

The BasicSlider widgets are moved by xValue= -0.1 and yValue= -0.3.

If the finger remains on the slider thumb, this setting will cause a change every second:

xyjoystick_konzept_cyclic_01