GLOBAL.XArm.xarm_printed = True
ret = yield self._wait_until_cmdnum_lt_max()
if ret is not None:
return response(client, cmd_id, ret)
ionum = data.get('ionum')
value = data.get('value')
xyz = data.get('xyz')
tol_r = data.get('tol_r')
code = GLOBAL.XArm.xarm.set_cgpio_analog_with_xyz(ionum, value, xyz, tol_r)
response(client, cmd_id, code)
self.set_cgpio_analog = async (ionum, value, callback) => {
const params = window.GlobalConstant.INIT_CMD_PARAMS_COMMON_DATA();
Object.assign(params.data, {
ionum: ionum,
value: value,
});
console.log('set_cgpio_analog params', params);
const cmd_id = self.sendCmd(window.GlobalConstant.SET_CGPIO_ANALOG, params, (dict) => {
self.codeHandle(dict, 'set cgpio analog', true);
if (callback) {
callback(dict);
}
});
await self.socketCom.wait(cmd_id);
};