예제 #1
0
        public int XML_请求更新文件()
        {
            int result = CM_QueryNodesStatusOfNVS(CM_HANDLE, int.Parse(ViewModel.getInstance().model.nvsid));

            return(result);
        }
예제 #2
0
        public void 电源关闭()
        {
            NodeInfo TheNode = XML_获取设备节点信息("电源控制");

            CM_IOT_POWER_Ctrl(CM_HANDLE, int.Parse(ViewModel.getInstance().model.nvsid), TheNode.netid, TheNode.nodeaddr, 0);
        }
예제 #3
0
        public void 警笛(int seconds)
        {
            NodeInfo TheNode = XML_获取设备节点信息("警笛");

            CM_IOT_WCAW_Ctrl(CM_HANDLE, int.Parse(ViewModel.getInstance().model.nvsid), TheNode.netid, TheNode.nodeaddr, seconds);
        }
예제 #4
0
        public void 暂停窗帘()
        {
            NodeInfo TheNode = XML_获取设备节点信息("窗帘");

            CM_IOT_EC_Ctrl(CM_HANDLE, int.Parse(ViewModel.getInstance().model.nvsid), TheNode.netid, TheNode.nodeaddr, 0);
        }
예제 #5
0
        public void 实验箱关闭()
        {
            NodeInfo TheNode = XML_获取设备节点信息("实验箱取电");

            CM_IOT_CONTROLTC_Ctrl(CM_HANDLE, int.Parse(ViewModel.getInstance().model.nvsid), TheNode.netid, TheNode.nodeaddr, 0);
        }
예제 #6
0
        public void 光照单次取样()
        {
            NodeInfo TheNode = XML_获取设备节点信息("无线光照度采集");

            CM_IOT_IDC_Sampling(CM_HANDLE, int.Parse(ViewModel.getInstance().model.nvsid), TheNode.netid, TheNode.nodeaddr);
        }
예제 #7
0
        public void 开启光照连续取样()
        {
            NodeInfo TheNode = XML_获取设备节点信息("无线光照度采集");

            CM_IOT_IDC_StartContinuousSampling(CM_HANDLE, int.Parse(ViewModel.getInstance().model.nvsid), TheNode.netid, TheNode.nodeaddr, 1000, 1);
        }
예제 #8
0
        public void 查询光照报警范围()
        {
            NodeInfo TheNode = XML_获取设备节点信息("无线光照度采集");

            CM_IOT_IDC_QueryLimit(CM_HANDLE, int.Parse(ViewModel.getInstance().model.nvsid), TheNode.netid, TheNode.nodeaddr);
        }
예제 #9
0
        public void 关闭温湿度连续取样()
        {
            NodeInfo TheNode = XML_获取设备节点信息("无线温湿度采集");

            CM_IOT_THDC_StopContinuousSampling(CM_HANDLE, int.Parse(ViewModel.getInstance().model.nvsid), TheNode.netid, TheNode.nodeaddr);
        }
예제 #10
0
        public int 登录()
        {
            ViewModel vm = ViewModel.getInstance();

            return(CM_Login(CM_HANDLE, vm.model.IP, vm.model.用户名, vm.model.密码));
        }