add full scale range enum values.

This commit is contained in:
pandx 2025-03-28 14:13:30 +08:00
parent 385d30613c
commit 3dd25ff15b
5 changed files with 96 additions and 15 deletions

View File

@ -26,8 +26,10 @@ SOURCES += \
HEADERS += \ HEADERS += \
MyTcpClient.h \ MyTcpClient.h \
acceleration.h \ acceleration.h \
acceleration_ds.h \
common.h \ common.h \
data_config.h \ data_config.h \
displacement_ds.h \
keyphase.h \ keyphase.h \
mainwindow.h \ mainwindow.h \
radial_vibration.h \ radial_vibration.h \
@ -36,7 +38,8 @@ HEADERS += \
setpoint.h \ setpoint.h \
singlerelay.h \ singlerelay.h \
tachometer.h \ tachometer.h \
velocity.h velocity.h \
velocity_ds.h
FORMS += \ FORMS += \
acceleration.ui \ acceleration.ui \

38
acceleration_ds.h Normal file
View File

@ -0,0 +1,38 @@
#ifndef ACCELERATION_DS_H
#define ACCELERATION_DS_H
// 加速度峰值的量程范围
typedef enum {
kAccPK20 = 0, // 0-20 m/s^2 pk
kAccPK50 = 1, // 0-50 m/s^2 pk
kAccPK100 = 2, // 0-100 m/s^2 pk
kAccPK200 = 3, // 0-200 m/s^2 pk
kAccPK250 = 4, // 0-250 m/s^2 pk
kAccPK400 = 5, // 0-400 m/s^2 pk
kAccPKCustom = 6 // custom
} AccPKFullScaleRange;
// 加速度有效值的量程范围
typedef enum {
kAccRMS20 = 0, // 0-20 m/s^2 rms
kAccRMS50 = 1, // 0-50 m/s^2 rms
kAccRMS100 = 2, // 0-100 m/s^2 rms
kAccRMS200 = 3, // 0-200 m/s^2 rms
kAccRMSCustom = 4 // custom
} AccRMSFullScaleRange;
// 速度峰值的量程范围
typedef enum {
kAccVelPK25 = 0, // 0-25 mm/s pk
kAccVelPK50 = 1, // 0-50 mm/s pk
kAccVelPK100 = 2, // 0-100 mm/s pk
kAccVelCustom = 3 // custom
} AccVelPKFullScaleRange;
typedef enum {
kAccVelRMS25 = 0, // 0-25 mm/s rms
kAccVelRMS50 = 1, // 0-50 mm/s rms
kAccVelRMSCustom = 2 // custom
} AccVelRMSFullScaleRange;
#endif // ACCELERATION_DS_H

View File

@ -98,8 +98,7 @@ typedef struct{
int danger_response_time; int danger_response_time;
} Tachometer_Variables; } Tachometer_Variables;
typedef struct typedef struct {
{
QString transducer_name; QString transducer_name;
double scale_factor; double scale_factor;
} Transducer; } Transducer;

13
displacement_ds.h Normal file
View File

@ -0,0 +1,13 @@
#ifndef DISPLACEMENT_DS_H
#define DISPLACEMENT_DS_H
// 位移峰峰值的量程范围
typedef enum {
kDisPP100 = 0, // 0-100 um
kDisPP150 = 1, // 0-150 um
kDisPP200 = 2, // 0-200 um
kDisPP400 = 3, // 0-400 um
kDisPP500 = 4, // 0-500 um
kDisPPCustom = 5 // custom
} DisPPFullScaleRange;
#endif // DISPLACEMENT_DS_H

28
velocity_ds.h Normal file
View File

@ -0,0 +1,28 @@
#ifndef VELOCITY_DS_H
#define VELOCITY_DS_H
// 速度峰值的量程范围
typedef enum {
kVelPK10 = 0, // 0-10 mm/s pk
kVelPK20 = 1, // 0-20 mm/s pk
kVelPK50 = 2, // 0-50 mm/s pk
kVelPKCustom = 3 // custom
} VelPKFullScaleRange;
// 速度有效值的量程范围
typedef enum {
kVelRMS10 = 0, // 0-10 mm/s rms
kVelRMS20 = 1, // 0-20 mm/s rms
kVelRMS50 = 2, // 0-50 mm/s rms
kVelRMSCustom = 3 // custom
} VelRMSFullScaleRange;
// 位移峰峰值的量程范围
typedef enum {
kVelDisPP100 = 0, // 0-100 um pp
kVelDisPP200 = 1, // 0-200 um pp
kVelDisPP500 = 2, // 0-500 um pp
kVelDisPPCustom = 3 // custom
} VelDisPPFullScaleRange;
#endif // VELOCITY_DS_H