mirror of
https://github.com/SyncrowIOT/backend.git
synced 2025-07-10 07:07:21 +00:00
29 lines
928 B
TypeScript
29 lines
928 B
TypeScript
interface BaseCommand {
|
|
code: string;
|
|
value: any;
|
|
}
|
|
export interface ControlCur2Command extends BaseCommand {
|
|
code: 'control';
|
|
value: 'open' | 'close' | 'stop';
|
|
}
|
|
export interface ControlCur2PercentCommand extends BaseCommand {
|
|
code: 'percent_control';
|
|
value: 10 | 20 | 30 | 40 | 50 | 60 | 70 | 80 | 90 | 100;
|
|
}
|
|
export interface ControlCur2AccurateCalibrationCommand extends BaseCommand {
|
|
code: 'accurate_calibration';
|
|
value: 'start' | 'end'; // Assuming this is a numeric value for calibration
|
|
}
|
|
export interface ControlCur2TDirectionConCommand extends BaseCommand {
|
|
code: 'control_t_direction_con';
|
|
value: 'forward' | 'back';
|
|
}
|
|
export interface ControlCur2QuickCalibrationCommand extends BaseCommand {
|
|
code: 'tr_timecon';
|
|
value: number; // between 10 and 120
|
|
}
|
|
export interface ControlCur2MotorModeCommand extends BaseCommand {
|
|
code: 'elec_machinery_mode';
|
|
value: 'strong_power' | 'dry_contact';
|
|
}
|