|
@ -1,17 +1,47 @@ |
|
|
<template> |
|
|
<template> |
|
|
<div class="h-full flex flex-col"> |
|
|
<div class="h-full flex flex-col"> |
|
|
|
|
|
<div class="border-b p-5 bg-white">进出料</div> |
|
|
<div class="p-5 h-0 grow"> |
|
|
<div class="p-5 h-0 grow"> |
|
|
<div class="border rounded p-5 whitespace-pre-line h-full overflow-y-auto" |
|
|
|
|
|
|
|
|
<div class="border rounded p-5 whitespace-pre-line h-full overflow-y-auto bg-white" |
|
|
>{{ message }}</div> |
|
|
>{{ message }}</div> |
|
|
</div> |
|
|
</div> |
|
|
|
|
|
|
|
|
|
|
|
<div class="p-5 border-t border-b"> |
|
|
|
|
|
<a-row> |
|
|
|
|
|
<a-col class="p-1" :span="8"><a-input prefix="回零超时时间 : " v-model:value="serviceParams.moveToZeroOvertime" /></a-col> |
|
|
|
|
|
<a-col class="p-1" :span="8"><a-input prefix="执行动作的超时时间 : " v-model:value="serviceParams.actionOvertime" /></a-col> |
|
|
|
|
|
<a-col class="p-1" :span="8"><a-input prefix="试管扫码位置 : " v-model:value="serviceParams.tubeScanPos" /></a-col> |
|
|
|
|
|
<a-col class="p-1" :span="8"><a-input prefix="高低试管判断位置 : " v-model:value="serviceParams.tubeHeighJudgmentPos" /></a-col> |
|
|
|
|
|
<a-col class="p-1" :span="8"><a-input prefix="试管预处理位置 : " v-model:value="serviceParams.tubePreProcessPos" /></a-col> |
|
|
|
|
|
<a-col class="p-1" :span="8"><a-input prefix="有无判断位置 : " v-model:value="serviceParams.tubeExistJudgmentPos" /></a-col> |
|
|
|
|
|
<a-col class="p-1" :span="8"><a-input prefix="入料位置 : " v-model:value="serviceParams.tubeRackEnterPos" /></a-col> |
|
|
|
|
|
<a-col class="p-1" :span="8"><a-input prefix="出料位置 : " v-model:value="serviceParams.tubeRackExitPos" /></a-col> |
|
|
|
|
|
<a-col class="p-1" :span="8"><a-input prefix="试管架扫码位置 : " v-model:value="serviceParams.tubeRackScanCodePos" /></a-col> |
|
|
|
|
|
<a-col class="p-1" :span="8"><a-input prefix="水平移动电机位置偏移 : " v-model:value="serviceParams.horizontalMotorOffset" /></a-col> |
|
|
|
|
|
<a-col class="p-1" :span="8"><a-input prefix="水平电机丢步判断 : " v-model:value="serviceParams.horizontalMotorLostStepThresholdVal" /></a-col> |
|
|
|
|
|
<a-col class="p-1" :span="8"><a-input prefix="试管扫码夹紧位置 : " v-model:value="serviceParams.scanCodeClampPos" /></a-col> |
|
|
|
|
|
<a-col class="p-1" :span="8"><a-input prefix="试管扫码释放位置 : " v-model:value="serviceParams.scanCodeReleasePos" /></a-col> |
|
|
|
|
|
<a-col class="p-1" :span="8"> |
|
|
|
|
|
<a-button class="mr-1" @click="actionServiceParamsReload">刷新</a-button> |
|
|
|
|
|
<a-button @click="actionServiceParamsSave">保存</a-button> |
|
|
|
|
|
</a-col> |
|
|
|
|
|
</a-row> |
|
|
|
|
|
</div> |
|
|
|
|
|
|
|
|
<div class="p-5"> |
|
|
<div class="p-5"> |
|
|
<div class="mt-1"><a-button @click="actionMoveToZeroWhenDeviceSetup">设备启动归零</a-button></div> |
|
|
|
|
|
<div class="mt-1"><a-button @click="actionMoveToZero">归零</a-button></div> |
|
|
|
|
|
<div class="mt-1"><a-button @click="actionMoveTubeRackToEnterPos">移动试管架到入口位置</a-button></div> |
|
|
|
|
|
<div class="mt-1"><a-button @click="actionMoveTubeRackToExitPos">移动试管架到出口位置</a-button></div> |
|
|
|
|
|
<div class="mt-1"><a-button @click="actionMoveTubeRackToScanPos">移动试管架到试管架扫码位置</a-button></div> |
|
|
|
|
|
<div class="mt-1"><a-button @click="actionMoveTubeRackToScanPosAndScan">移动试管架到试管架扫码并扫码</a-button></div> |
|
|
|
|
|
|
|
|
<a-button class="m-1" @click="actionQuickExec('moveToZeroWhenDeviceSetup')">设备启动归零</a-button> |
|
|
|
|
|
<a-button class="m-1" @click="actionQuickExec('moveToZero')">归零</a-button> |
|
|
|
|
|
<a-button class="m-1" @click="actionQuickExec('moveTubeRackToEnterPos')">移动试管架到入口位置</a-button> |
|
|
|
|
|
<a-button class="m-1" @click="actionQuickExec('moveTubeRackToExitPos')">移动试管架到出口位置</a-button> |
|
|
|
|
|
<a-button class="m-1" @click="actionQuickExec('moveTubeRackToScanPos')">移动试管架到试管架扫码位置</a-button> |
|
|
|
|
|
<a-button class="m-1" @click="actionQuickExec('moveTubeRackToScanPosAndScan')">移动试管架到试管架扫码并扫码</a-button> |
|
|
|
|
|
<a-button class="m-1" @click="actionQuickExec('isTubeRackInEnterPos')">试管架是否在入料位置</a-button> |
|
|
|
|
|
<a-button class="m-1" @click="actionQuickExec('isTubeRackInExitPos')">试管架是否在出料位置</a-button> |
|
|
|
|
|
<a-button class="m-1" @click="actionQuickExec('getMoveChannelPhotoelectricState',0)">获取移动通道的光电状态(内)</a-button> |
|
|
|
|
|
<a-button class="m-1" @click="actionQuickExec('getMoveChannelPhotoelectricState',1)">获取移动通道的光电状态(外)</a-button> |
|
|
|
|
|
<a-button class="m-1" @click="actionQuickExec('scanClampModuleCompress')">扫描夹紧机构夹紧</a-button> |
|
|
|
|
|
<a-button class="m-1" @click="actionQuickExec('scanClampModuleReset')">扫描夹紧机构复位</a-button> |
|
|
|
|
|
|
|
|
<div class="mt-1"> |
|
|
<div class="mt-1"> |
|
|
<a-input-group compact class="flex flex-row"> |
|
|
<a-input-group compact class="flex flex-row"> |
|
|
<a-input class="!w-64" prefix="TubeType : " v-model:value="moveTubeToScanPosParams[0]"/> |
|
|
<a-input class="!w-64" prefix="TubeType : " v-model:value="moveTubeToScanPosParams[0]"/> |
|
@ -48,14 +78,7 @@ |
|
|
</a-input-group> |
|
|
</a-input-group> |
|
|
</div> |
|
|
</div> |
|
|
|
|
|
|
|
|
<div class="mt-1"><a-button @click="actionQuickExec('isTubeRackInEnterPos')">试管架是否在入料位置</a-button></div> |
|
|
|
|
|
<div class="mt-1"><a-button @click="actionQuickExec('isTubeRackInExitPos')">试管架是否在出料位置</a-button></div> |
|
|
|
|
|
|
|
|
|
|
|
<div class="mt-1"><a-button @click="actionQuickExec('getMoveChannelPhotoelectricState',0)">获取移动通道的光电状态(内)</a-button></div> |
|
|
|
|
|
<div class="mt-1"><a-button @click="actionQuickExec('getMoveChannelPhotoelectricState',1)">获取移动通道的光电状态(外)</a-button></div> |
|
|
|
|
|
|
|
|
|
|
|
<div class="mt-1"><a-button @click="actionQuickExec('scanClampModuleCompress')">扫描夹紧机构夹紧</a-button></div> |
|
|
|
|
|
<div class="mt-1"><a-button @click="actionQuickExec('scanClampModuleReset')">扫描夹紧机构复位</a-button></div> |
|
|
|
|
|
</div> |
|
|
</div> |
|
|
</div> |
|
|
</div> |
|
|
</template> |
|
|
</template> |
|
@ -68,6 +91,31 @@ const moveTubeToScanPosAndScanParams = ref(['',0]); |
|
|
const moveTubeToHeighJudgmentPosParams = ref(['',0]); |
|
|
const moveTubeToHeighJudgmentPosParams = ref(['',0]); |
|
|
const moveTubeToPreProcessPosParams = ref(['',0]); |
|
|
const moveTubeToPreProcessPosParams = ref(['',0]); |
|
|
const moveTubeToExistJudgmentPosParams = ref(['',0]); |
|
|
const moveTubeToExistJudgmentPosParams = ref(['',0]); |
|
|
|
|
|
const serviceParams = ref({}); |
|
|
|
|
|
|
|
|
|
|
|
async function actionServiceParamsReload() { |
|
|
|
|
|
serviceParams.value = {}; |
|
|
|
|
|
message.value = ''; |
|
|
|
|
|
let client = ApiClient.getClient(); |
|
|
|
|
|
try { |
|
|
|
|
|
let res = await client.call('tmp-test/get-service-params'); |
|
|
|
|
|
message.value = res; |
|
|
|
|
|
serviceParams.value = res.data; |
|
|
|
|
|
} catch ( e ) { |
|
|
|
|
|
message.value = e.message |
|
|
|
|
|
} |
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
async function actionServiceParamsSave() { |
|
|
|
|
|
message.value = ''; |
|
|
|
|
|
let client = ApiClient.getClient(); |
|
|
|
|
|
try { |
|
|
|
|
|
let res = await client.call('tmp-test/update-service-params', serviceParams.value); |
|
|
|
|
|
message.value = res; |
|
|
|
|
|
} catch ( e ) { |
|
|
|
|
|
message.value = e.message |
|
|
|
|
|
} |
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
// execute service method |
|
|
// execute service method |
|
|
async function executeServiceMethod( method, params=[]) { |
|
|
async function executeServiceMethod( method, params=[]) { |
|
@ -89,34 +137,6 @@ function actionQuickExec( action, ... params ) { |
|
|
executeServiceMethod(action, params); |
|
|
executeServiceMethod(action, params); |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
// move to zero when device setup |
|
|
|
|
|
function actionMoveToZeroWhenDeviceSetup() { |
|
|
|
|
|
executeServiceMethod('moveToZeroWhenDeviceSetup'); |
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
// move to zero |
|
|
|
|
|
function actionMoveToZero() { |
|
|
|
|
|
executeServiceMethod('moveToZero'); |
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
// moveTubeRackToEnterPos |
|
|
|
|
|
function actionMoveTubeRackToEnterPos() { |
|
|
|
|
|
executeServiceMethod('moveTubeRackToEnterPos'); |
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
// moveTubeRackToExitPos |
|
|
|
|
|
function actionMoveTubeRackToExitPos() { |
|
|
|
|
|
executeServiceMethod('moveTubeRackToExitPos'); |
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
// moveTubeRackToScanPos |
|
|
|
|
|
function actionMoveTubeRackToScanPos() { |
|
|
|
|
|
executeServiceMethod('moveTubeRackToScanPos'); |
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
function actionMoveTubeRackToScanPosAndScan() { |
|
|
|
|
|
executeServiceMethod('moveTubeRackToScanPosAndScan'); |
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
function actionMoveTubeToScanPos() { |
|
|
function actionMoveTubeToScanPos() { |
|
|
executeServiceMethod('moveTubeToScanPos',[ |
|
|
executeServiceMethod('moveTubeToScanPos',[ |
|
|