NDEVR
API Documentation
WinchDeploymentWidget.h
1#pragma once
2#include "DLLInfo.h"
3#include <QWidget>
4namespace Ui
5{
6 class WinchDeploymentDialogUI;
7}
8namespace NDEVR
9{
10 class Motor;
11 class Button;
12 struct PopupInfo;
14 class DistanceEncoder;
19 class HARDWARE_WIDGETS_API MotorDeploymentWidget : public QWidget
20 {
21 public:
26 MotorDeploymentWidget(QWidget* parent = nullptr);
32 MotorDeploymentWidget(Motor* winch, QWidget* parent = nullptr);
37 void setMotor(Motor* winch);
43 void startMotor(bool up, bool constant);
47 void stopWinch();
48 protected:
52 void setupUI();
58 protected:
65 };
66
70 class HARDWARE_WIDGETS_API WinchDeploymentDialog : public QWidget
71 {
72 public:
77 WinchDeploymentDialog(QWidget* parent = nullptr);
83 WinchDeploymentDialog(Motor* winch, QWidget* parent = nullptr);
88 void setMotor(Motor* winch);
89 protected:
93 void setupUI();
94 protected:
97 Ui::WinchDeploymentDialogUI* ui;
98 };
99}
A core widget that allows the user to click one of many button types.
Definition Button.h:68
A distance encoder is a device that measures distance by generating pulses in response to an object's...
Button * m_deploy_down
Button for step-mode downward deployment.
MotorDeploymentWidget(QWidget *parent=nullptr)
Constructs a MotorDeploymentWidget without a motor.
Button * m_deploy_constant_down
Button for constant-speed downward deployment.
void stopWinch()
Stops the motor immediately.
MotorDeploymentWidget(Motor *winch, QWidget *parent=nullptr)
Constructs a MotorDeploymentWidget for a specific motor.
void setupUI()
Initializes the UI layout and buttons.
WinchDeploymentDialog * m_deployment_dialog
Dialog for detailed winch deployment settings.
Motor * m_motor
The motor being controlled.
Button * m_deploy_up
Button for step-mode upward deployment.
void startMotor(bool up, bool constant)
Starts the motor in the specified direction and mode.
Button * m_deploy_constant_up
Button for constant-speed upward deployment.
void setMotor(Motor *winch)
Sets the motor to control.
WinchDeploymentDialog * deploymentDialog()
Returns or creates the winch deployment dialog for detailed motor control.
A motor is a device which produces rotational spin.
Definition Motor.h:46
Dialog providing detailed winch deployment controls and distance encoder feedback.
WinchDeploymentDialog(QWidget *parent=nullptr)
Constructs a WinchDeploymentDialog without a motor.
Motor * m_winch
The motor being controlled.
Ui::WinchDeploymentDialogUI * ui
The auto-generated UI form.
void setMotor(Motor *winch)
Sets the motor to control.
WinchDeploymentDialog(Motor *winch, QWidget *parent=nullptr)
Constructs a WinchDeploymentDialog for a specific motor.
DistanceEncoder * m_encoder
The distance encoder providing position feedback.
void setupUI()
Initializes the UI layout and controls.
The primary namespace for the NDEVR SDK.
Class which is used to pass arguments and requests for creating a popup dialog or widget.
Definition PopupInfo.h:16