108 lines
2.4 KiB
C++
108 lines
2.4 KiB
C++
#ifndef CHANNELDIALOG_H
|
|
#define CHANNELDIALOG_H
|
|
/*********
|
|
* Fes参数界面下方刺激盒中按钮弹出的对话框
|
|
* ****/
|
|
#include <QDialog>
|
|
#include <QButtonGroup>
|
|
#include "dataformate.h"
|
|
#include "commonStruct.h"
|
|
namespace Ui {
|
|
class ChannelDialog;
|
|
}
|
|
|
|
class ChannelDialog : public QDialog
|
|
{
|
|
Q_OBJECT
|
|
|
|
public:
|
|
explicit ChannelDialog(QWidget *parent = nullptr);
|
|
~ChannelDialog();
|
|
void initWidget();
|
|
|
|
void setTitle(int title);
|
|
|
|
ST_MuscleParam getValue();
|
|
|
|
void setMuscleState(QList<bool>);
|
|
|
|
void setFrequentRange(int min,int max);
|
|
void setPlusRange(int min,int max);
|
|
void setMinCurrentRange(int min,int max);
|
|
void setMaxCurrentRange(int min,int max);
|
|
|
|
void setFrequentValue(int value);
|
|
void setPlusValue(int value);
|
|
void setMinCurrentValue(int value);
|
|
void setMaxCurrentValue(int value);
|
|
|
|
void setMuscleId(int id);
|
|
|
|
//是否运行
|
|
void setChannleDialogState(bool isRunning);
|
|
|
|
int* getMaxCurrentData(); //获取八个通道最大电流值
|
|
|
|
void setMuscleConnectState(bool flag); // 判断是否打开开关
|
|
|
|
protected:
|
|
void paintEvent(QPaintEvent *event);
|
|
|
|
void showEvent(QShowEvent *event);
|
|
|
|
virtual void changeEvent(QEvent* event);
|
|
|
|
private slots:
|
|
void on_confirm_Btn_clicked();
|
|
|
|
void on_frequentMinus_Btn_clicked();
|
|
|
|
void on_frequentPlus_Btn_clicked();
|
|
|
|
void on_frequent_Slider_valueChanged(int value);
|
|
|
|
void on_PWMMinus_Btn_clicked();
|
|
|
|
void on_PWMPlus_Btn_clicked();
|
|
|
|
void on_plus_Slider_valueChanged(int value);
|
|
|
|
void on_minCurrentMinus_Btn_clicked();
|
|
|
|
void on_minCurrentPlus_Btn_clicked();
|
|
|
|
void on_minCurrent_Slider_valueChanged(int value);
|
|
|
|
void on_maxCurrentMinus_Btn_clicked();
|
|
|
|
void on_maxCurrentPlus_Btn_clicked();
|
|
|
|
void on_maxCurrent_Slider_valueChanged(int value);
|
|
|
|
void on_switch_Btn_clicked();
|
|
|
|
void slotButtonClicked(int);
|
|
|
|
void slotButtonClicked(QAbstractButton*);
|
|
|
|
void on_frequent_Slider_sliderReleased();
|
|
|
|
void on_plus_Slider_sliderReleased();
|
|
|
|
void on_minCurrent_Slider_sliderReleased();
|
|
|
|
void on_maxCurrent_Slider_sliderReleased();
|
|
|
|
private:
|
|
Ui::ChannelDialog *ui;
|
|
QButtonGroup *m_buttonGroup;
|
|
ST_MuscleParam st_MuscleParam;
|
|
int m_currentChannel; //当前通道
|
|
AnalogSetting st_AnalogSetting;
|
|
int m_deviceNo; //当前设备号 1,2,3,4
|
|
int m_deviceChannel;//当前设备通道 1,2
|
|
int maxCurrentData[8]; //最大电流
|
|
};
|
|
|
|
#endif // CHANNELDIALOG_H
|