diff --git a/etc/doxygen/images/JoystickControlWidget_widget.png b/etc/doxygen/images/JoystickControlWidget_widget.png new file mode 100644 index 0000000000000000000000000000000000000000..b00adcb95edbf7ae27be3a00667bd092dfda856f Binary files /dev/null and b/etc/doxygen/images/JoystickControlWidget_widget.png differ diff --git a/etc/doxygen/images/PlatformUnitGuiPlugin_widgetpng.png b/etc/doxygen/images/PlatformUnitGuiPlugin_widgetpng.png new file mode 100644 index 0000000000000000000000000000000000000000..43f6ba7767598bc7fd95f9db3687b909e50ecb22 Binary files /dev/null and b/etc/doxygen/images/PlatformUnitGuiPlugin_widgetpng.png differ diff --git a/source/RobotAPI/gui_plugins/PlatformUnitPlugin/JoystickControlWidget.h b/source/RobotAPI/gui_plugins/PlatformUnitPlugin/JoystickControlWidget.h index b11fb1732b9cffb365c9bccf116b985164ef9cc5..877795cbf12ffebfd1b69b80b8ddb668ac6767af 100644 --- a/source/RobotAPI/gui_plugins/PlatformUnitPlugin/JoystickControlWidget.h +++ b/source/RobotAPI/gui_plugins/PlatformUnitPlugin/JoystickControlWidget.h @@ -79,6 +79,38 @@ namespace armarx /** * @brief Provides a simple joystick control. + * + * The widget emits signals when the control is moved. + * + * The signal + * @code{.cpp} + * positionChanged(QPointF) + * @endcode + * passes the nibble's current position. + * The position is in the unit circle. + * The x-axis is horizontal and increases to the right. + * The y-axis is vertical and increases upwards. + * + * The signal + * @code{.cpp} + * rotationChanged(double) + * @endcode + * passes the position vectors rotation in polar coordinates (-pi,pi]. + * The up position is 0. + * The down position is pi. + * The Quadrants 1 and 4 have positive value. + * + * If the constructor is called with useQuadrant3and4==true the control is the whole unit circle. + * If the constructor is called with useQuadrant3and4==false the control is the unit circle's upper semicircle. (y>=0) + * + * Possible positions can be influenced with + * \code{.cpp} + * setSteps(int steps); + * \endcode + * - steps>0 : only position vectors with a length from {n/steps | n in {0,1,...,steps} are valid. The nibble snaps to a valid position. + * - steps<=0: all positions in the unit circle are valid. + * + * @image html JoystickControlWidget_widget.png "Left: A widget with 2 steps using the whole unit circle. Right: A widget using the unit circle's upper semi circle." width=300px */ class JoystickControlWidget : public QWidget { diff --git a/source/RobotAPI/gui_plugins/PlatformUnitPlugin/PlatformUnitGuiPlugin.h b/source/RobotAPI/gui_plugins/PlatformUnitPlugin/PlatformUnitGuiPlugin.h index b0992092cb79a0ebbcc6cd432bca39669c358664..d418fbffe2c0bf4467d99b980ccfd9905e420494 100644 --- a/source/RobotAPI/gui_plugins/PlatformUnitPlugin/PlatformUnitGuiPlugin.h +++ b/source/RobotAPI/gui_plugins/PlatformUnitPlugin/PlatformUnitGuiPlugin.h @@ -69,6 +69,11 @@ namespace armarx \ingroup ArmarXGuiPlugins \see PlatformUnitGuiPlugin + + \image html PlatformUnitGuiPlugin_widgetpng.png "The plugin's ui." width=300px + -# The current position and rotation, fields to enter a new target and a button to set the platform in motion. + -# A joystick like control widget to move the platform. It has two speed level. The platform does not rotate to move in a direction. Up moves the platform forward. + -# A joystick like control widget to rotate the platform. */ class PlatformUnitWidget : public ArmarXComponentWidgetController,