private void btn_DevSearch_Click(object sender, EventArgs e) { if (SmartDeviceInterface.SmartDevice_Search() == SmartDeviceInterface.OPERATOR_SUCCESS) { UpdateMsg("广播数据:" + "{\"command\":\"COM_DEV_SEARCH_JS\"}"); txtDeviceMgr.Text += "设备搜索成功\r\n"; } else { txtDeviceMgr.Text += "设备搜索失败\r\n"; } }
/// <summary> ///搜索设备接口, 搜到的设备将在回调函数SmartDevice_CallBack通知,对应命令字为COM_DEV_SEARCH_JS /// </summary> /// <returns>返回操作结果码OPERATOR_</returns> public Int32 SmartDevice_Search() { return(SmartDeviceInterface.SmartDevice_Search()); }