diff --git a/src/components/SealTest.vue b/src/components/SealTest.vue index ddf1188..4da5a9c 100644 --- a/src/components/SealTest.vue +++ b/src/components/SealTest.vue @@ -98,6 +98,8 @@ import { someAirSwitchJSON, airCompressor_setStateJSON, airCompressor_channelCtrlJSON, + AirInletProportionalValve_setStateJSON, + AirOutletProportionalValve_setStateJSON, } from '@/mock/command' import { useSealStore, useTestStore, useWebSocketStore } from '@/store' @@ -243,6 +245,11 @@ const changeAirStatus = flag => { } } else { if (!testStore.airCompressor) { + // 开始充气时关闭两个阀门 + websocketStore.sendCommandMsg(AirInletProportionalValve_setStateJSON([0])) + websocketStore.sendCommandMsg( + AirOutletProportionalValve_setStateJSON([0]), + ) websocketStore.sendCommandMsg(airCompressor_setStateJSON([1])) testStore.updateAirCompressor(true) } diff --git a/src/components/Test.vue b/src/components/Test.vue index ba51743..400260d 100644 --- a/src/components/Test.vue +++ b/src/components/Test.vue @@ -189,6 +189,31 @@ +
空压机通道
+水浸1
{{ testStore.waterImmersionSensor1 ? '有水' : '没水' }}
@@ -273,6 +298,7 @@ import { import { someAirSwitchJSON, liquidpumpctrlJSON, + airCompressor_channelCtrlJSON, getStateJSON, addLiquidCtrlJSON, test_replenishingFluidsPumpCtrJSON, @@ -513,6 +539,16 @@ const changeDraughtStatus = flag => { } } } + +const changeChannel = flag => { + if (flag == 1) { + websocketStore.sendCommandMsg(airCompressor_channelCtrlJSON([1])) + testStore.updateAirCompressorChannel(true) + } else { + websocketStore.sendCommandMsg(airCompressor_channelCtrlJSON([0])) + testStore.updateAirCompressorChannel(false) + } +}