import { Device } from "../device";

export default {
  async sendWup(params: any[], device: Device) {
    const param = params[0] || {};
    param.rspClass = () => {}; // 避免参数校验
    param.unEncode = true; // 请求不需要加密
    param.unDecode = true; // 返回不需要解密
    return await device.sdk.advance.sendWup(param); // rspstr
  },

  async onWupMessage(params: any[], device: Device) {
    const param = params[0] || {};
    param.messageClass = () => {}; // 避免参数校验
    param.unDecode = true; // 回调不需要解密
    return await device.sdk.advance.onWupMessage(param); // rspstr
  },
};
