-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
1 changed file
with
137 additions
and
0 deletions.
There are no files selected for viewing
137 changes: 137 additions & 0 deletions
137
GeothermalResearchInstitute/proto/bjdire/v2/service.proto
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,137 @@ | ||
syntax = "proto3"; | ||
|
||
package bjdire.v2; | ||
|
||
import "google/protobuf/field_mask.proto"; | ||
|
||
message Metric { | ||
// 出水温度(摄氏度) | ||
float output_water_celsius_degree = 1; | ||
// 回水温度(摄氏度) | ||
float input_water_celsius_degree = 2; | ||
// 加热器出水温度(摄氏度) | ||
float heater_output_water_celsius_degree = 3; | ||
// 环境温度(摄氏度) | ||
float environment_celsius_degree = 4; | ||
// 出水压力(米) | ||
float output_water_pressure_meter = 5; | ||
// 回水压力(米) | ||
float input_water_pressure_meter = 6; | ||
// 加热器功率(千瓦) | ||
float heater_power_kilowatt = 7; | ||
// 水泵流量(立方米/小时) | ||
float water_pump_flow_rate_cubic_meter_per_hour = 8; | ||
} | ||
|
||
message Switch { | ||
// 设备运行状态 | ||
bool device_power_on = 1; | ||
// 排气运行状态 | ||
bool exhauster_power_on = 2; | ||
// 热泵自动按键状态 | ||
bool heater_auto_on = 3; | ||
// 热泵电源按键状态 | ||
bool heater_power_on = 4; | ||
// 热泵风扇状态 | ||
bool heater_fan_on = 5; | ||
// 热泵压缩机按键状态 | ||
bool heater_compressor_on = 6; | ||
// 热泵四通换向阀状态 | ||
bool heater_four_way_reversing_on = 7; | ||
} | ||
|
||
message RunningParameter { | ||
// 稳定工况夏季设定温度值(摄氏度) | ||
float summer_heater_celsius_degree = 1; | ||
// 稳定工况冬季设定温度值(摄氏度) | ||
float winter_heater_celsius_degree = 2; | ||
// 稳定热流制冷量值(千瓦) | ||
float cold_power_kilowatt = 3; | ||
// 稳定热流制热量值(千瓦) | ||
float warm_power_kilowatt = 4; | ||
// 定流量值(立方米/小时) | ||
float water_pump_flow_rate_cubic_meter_per_hour = 5; | ||
// 定频率值(赫兹) | ||
float water_pump_frequency_hertz = 6; | ||
} | ||
|
||
// 系统工作模式 | ||
enum DeviceWorkingMode { | ||
DEVICE_WORKING_MODE_UNSPECIFIED = 0; | ||
// 温度测定 | ||
DEVICE_WORKING_MODE_TEMPERATURE_DETERMINATION = 1; | ||
// 恒定热流(恒定热量) | ||
DEVICE_WORKING_MODE_FIXED_WARM_POWER = 2; | ||
// 恒定热流(恒定冷量) | ||
DEVICE_WORKING_MODE_FIXED_COLD_POWER = 3; | ||
// 稳定工况(夏季工况) | ||
DEVICE_WORKING_MODE_SUMMER_SITUATION = 4; | ||
// 稳定工况(冬季工况) | ||
DEVICE_WORKING_MODE_WINTER_SITUATION = 5; | ||
} | ||
|
||
// 系统流量调节模式 | ||
enum DeviceFlowRateControlMode { | ||
DEVICE_FLOW_RATE_CONTROL_MODE_UNSPECIFIED = 0; | ||
// 工频 | ||
DEVICE_FLOW_RATE_CONTROL_MODE_WORK_FREQUENCY = 1; | ||
// 变频 | ||
DEVICE_FLOW_RATE_CONTROL_MODE_VARIABLE_FREQUENCY = 2; | ||
} | ||
|
||
// 水泵运行模式 | ||
enum WaterPumpWorkingMode { | ||
WATER_PUMP_WORKING_MODE_UNSPECIFIED = 0; | ||
// 定流量 | ||
WATER_PUMP_WORKING_MODE_FIXED_FLOW_RATE = 1; | ||
// 定频率 | ||
WATER_PUMP_WORKING_MODE_FIXED_FREQUENCY = 2; | ||
} | ||
|
||
message WorkingMode { | ||
// 系统工作模式 | ||
DeviceWorkingMode device_working_mode = 1; | ||
// 系统流量调节模式 | ||
DeviceFlowRateControlMode device_flow_rate_control_mode = 2; | ||
// 水泵运行模式 | ||
WaterPumpWorkingMode water_pump_working_mode = 3; | ||
} | ||
|
||
message GetMetricRequest {} | ||
|
||
message GetSwitchRequest {} | ||
|
||
message UpdateSwitchRequest { | ||
Switch switch = 1; | ||
google.protobuf.FieldMask update_mask = 2; | ||
} | ||
|
||
message GetRunningParameterRequest {} | ||
|
||
message UpdateRunningParameterRequest { | ||
RunningParameter running_parameter = 1; | ||
google.protobuf.FieldMask update_mask = 2; | ||
} | ||
|
||
message GetWorkingModeRequest {} | ||
|
||
message UpdateWorkingModeRequest { | ||
WorkingMode working_mode = 1; | ||
google.protobuf.FieldMask update_mask = 2; | ||
} | ||
|
||
service DeviceService { | ||
rpc GetMetric (GetMetricRequest) returns (Metric) {} | ||
|
||
rpc GetSwitch (GetSwitchRequest) returns (Switch) {} | ||
|
||
rpc UpdateSwitch (UpdateSwitchRequest) returns (Switch) {} | ||
|
||
rpc GetRunningParameter (GetRunningParameterRequest) returns (RunningParameter) {} | ||
|
||
rpc UpdateRunningParameter (UpdateRunningParameterRequest) returns (RunningParameter) {} | ||
|
||
rpc GetWorkingMode (GetWorkingModeRequest) returns (WorkingMode) {} | ||
|
||
rpc UpdateWorkingMode (UpdateWorkingModeRequest) returns (WorkingMode) {} | ||
} |